v1
latestOpenAPI 3.0.02026-07-2455104.8 MBProduct
Create new product V1
Creates a new product.<br><br>
<h2>Warning: Multiple request body content types</h2> <p> Due to technical limitations, the information provided here may not display all available request body content types. We are currently working with our third-party documentation provider to address this issue. For a complete and accurate representation of the available content types, we recommend referring to the <a target="_blank" href="https://github.com/xentral/api-spec-public">full OpenAPI specification</a>. </p> <p> We apologize for any inconvenience caused and appreciate your understanding as we work to resolve this matter. </p> <h3>Available request content types:</h3> <ul> <li><b>application/json</b></li> <li>application/vnd.xentral.upsert+json</li> </ul>post/api/v1/products
Request body
Example request
{
"project": {
"id": "1337"
},
"tags": [
{
"color": "ff0000"
}
],
"measurements": {
"width": {
"value": 20,
"unit": "cm"
},
"height": {
"value": 10,
"unit": "cm"
},
"length": {
"value": 30,
"unit": "cm"
},
"weight": {
"value": 2,
"unit": "kg"
},
"netWeight": {
"value": 1.5,
"unit": "kg"
}
},
"category": {
"id": "1337"
},
"standardSupplier": {
"id": "12345"
},
"defaultStorageLocation": {
"id": "1337"
},
"calculatedPurchasePrice": {
"price": {
"amount": "13.37",
"currency": "EUR"
}
},
"freeFields": [
{
"id": "17",
"value": "Sample Product"
}
],
"variantOf": {
"id": "parent-product-98765"
},
"variants": [
{
"name": "OptionalName(overrides autogenerated)",
"options": [
{
"name": "Cotton",
"option": {
"name": "Material"
}
},
{
"name": "M",
"option": {
"name": "Size"
}
},
{
"name": "NoLogo",
"option": {
"name": "Logo"
}
}
]
}
]
}Response
Resource successfully created response