Перейти к основному содержанию
POST
/
v1
/
workshop
/
resources
cURL
curl --request POST \
  --url https://api.example.com/v1/workshop/resources/ \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "price": "<string>",
  "count": -1
}
'
{
  "id": 123,
  "name": "<string>",
  "price": "<string>",
  "count": -1
}

Тело

name
string
обязательно
Maximum string length: 255
price
string<decimal>
Pattern: ^-?\d{0,14}(?:\.\d{0,2})?$
count
integer
Требуемый диапазон: -2147483648 <= x <= 2147483647

Ответ

201 - application/json
id
integer
обязательно
name
string
обязательно
Maximum string length: 255
price
string<decimal>
Pattern: ^-?\d{0,14}(?:\.\d{0,2})?$
count
integer
Требуемый диапазон: -2147483648 <= x <= 2147483647