Creates a new product
POST/api/company/:company_id/product
Creates a new product
Request
Path Parameters
company_id uuidrequired
The id of the company
- application/json
Body
required
name stringrequired
The name of the product.
description stringrequired
The description of the product. Can be null.
images url[]required
An array of image URLs associated with the product.
Responses
- 200
- 422
- default
Detailed information about the product
- application/json
- Schema
- Example (from schema)
Schema
- Array [
- ]
id uuidrequired
The unique identifier of the product.
name stringrequired
The name of the product.
company_id uuidrequired
The unique identifier of the company.
description stringrequired
The description of the product. Can be null.
images object[]required
An array of image URLs associated with the product.
id uuidrequired
The unique identifier of the product image.
company_id uuidrequired
The unique identifier of the company.
url urlrequired
The URL of the product image.
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"name": "string",
"company_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"description": "string",
"images": [
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"company_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"url": "string"
}
]
}
Company not found
Unexpected error
- application/json
- Schema
- Example (from schema)
Schema
code int32required
The error code
message stringrequired
A human-readable error message
{
"code": 0,
"message": "string"
}
Loading...