General Information
...
Service | API | Method |
---|---|---|
multitenant | /product | POST |
Workflow:
Input
...
Type: application/json
Name | Source | Mandatory | Type | Special Format | Description |
---|---|---|---|---|---|
code | Body | YES | String | The length is between 4 - 5 | Product code |
name | Body | YES | String | N/A | Product name |
description | Body | NO | String | N/A | Product description |
...
Code Block | ||||
---|---|---|---|---|
| ||||
{
"result": true,
"data": [
{
"name": "Fadi2",
"code": "FADI2",
"description": "Some Description",
"scope": {
"acl": {}
},
"packages": [],
"_id": "5d6fedabbed68d11b6f54636"
}
]
} |
...
Code | Description |
---|---|
468 | Product already exists |
469 | Unable to add the product record |
474 | Missing required field: either id or code |
602 | Model error: + %model_error% |
Example (CURL)
...
Request
Code Block | ||||
---|---|---|---|---|
| ||||
> CURL -X GETPOST http://127.0.0.1:4004/product -d { "code": "silver", "name": "Silver", "description": "product description" } |
...