[Deprecated] Create/Update Inventory
post
https://api.flxpoint.com/inventoryDeprecatedUse this when you want to create inventory data through the API.
๐ X-API-TOKENโฑ 2 req/sToken: Account ยท Source ยท Channel
This page explains the endpoint. To send a live test request, use the interactive tester in Stoplight or your own Postman / HTTP client.
Create or update up to 20 parents with variants at a time. This endpoint performs a full update of all data passed. This means any null/missing values provided will also be updated. For updating just variants (that already exist) with new prices/quantities see the `PUT Inventory Variants` endpoint.
Request
Body
application/jsonarray[InventoryParentCreateOrUpdate]
sourceIdintegerOnly required to be passed if you are using an account token type
skustringrequiredtitlestring | nulldescriptionstring | nullmanufacturerstring | nullarchivedboolean | nullimagesarray[InventoryImageCreateOrUpdate]urlstringrequiredsortOrderintegeroptionsarray[InventoryParentOptionCreateOrUpdate]namestringrequiredattributesarray[InventoryParentAttributeCreateOrUpdate]namestringrequiredvaluestringrequiredcustomFieldsarray[InventoryParentCustomFieldCreateOrUpdate]namestringrequiredvaluestringrequiredvariantsarray[InventoryVariantCreateOrUpdate]supplierVariantIdstring | nullshippingCostnumber | nulldropshipFeenumber | nullinventoryListPricenumber | nullreferenceIdentifierstring | nullquantityinteger | nullskustring | nullrequiredmasterSkustring | nullIf available from your data source populate with your primary product master SKU to enable easily linking to your existing products or as the foundation to build new product master SKUs from.
titlestring | nullmpnstring | nullupcstring | nulleanstring | nullasinstring | nullmsrpnumber | nullmapnumber | nullweightnumber | nulllengthnumber | nullwidthnumber | nullheightnumber | nullarchivedboolean | nullcostnumber | nullweightUnitobjecthandlestringallowed
poundouncegramkilogramabbreviatedHandlestringallowed
lbozgkgdimensionUnitobjecthandlestringallowed
inchcentimeterabbreviatedHandlestringallowed
incmdimensionalWeightnumber | nullimagesarray[InventoryImageCreateOrUpdate]urlstringrequiredsortOrderintegeroptionsarray[InventoryVariantOptionCreateOrUpdate]namestringrequiredvaluestringrequiredcustomFieldsarray[InventoryVariantCustomFieldCreateOrUpdate]namestringvaluestringallowBackordersboolean | nullbinLocationstring | nullAn identifier representing the location of a bin in an internal warehouse
descriptionstring | nullrequiresFflboolean | nullIndicate if FFL information will be required to fulfill this inventory variant
categoryOnestring | nullcategoryTwostring | nullcategoryThreestring | nullExample request
post
/inventorycurl -X POST "https://api.flxpoint.com/inventory" \
-H "Accept: application/json" \
-H "X-API-TOKEN: YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '[
{
"sourceId": 0,
"sku": "string",
"title": "string",
"description": "string",
"manufacturer": "string",
"archived": true,
"images": [
{
"url": "string",
"sortOrder": 0
}
],
"options": [
{
"name": "string"
}
],
"attributes": [
{
"name": "string",
"value": "string"
}
],
"customFields": [
{
"name": "string",
"value": "string"
}
],
"variants": [
{
"supplierVariantId": "string",
"shippingCost": 0,
"dropshipFee": 0,
"inventoryListPrice": 0,
"referenceIdentifier": "string",
"quantity": 0,
"sku": "string",
"masterSku": "string",
"title": "string",
"mpn": "string",
"upc": "string",
"ean": "string",
"asin": "string",
"msrp": 0,
"map": 0,
"weight": 0,
"length": 0,
"width": 0,
"height": 0,
"archived": true,
"cost": 0,
"weightUnit": {
"handle": null,
"abbreviatedHandle": null
},
"dimensionUnit": {
"handle": null,
"abbreviatedHandle": null
},
"dimensionalWeight": 0,
"images": [
null
],
"options": [
null
],
"customFields": [
null
],
"allowBackorders": true,
"binLocation": "string",
"description": "string",
"requiresFfl": true
}
],
"categoryOne": "string",
"categoryTwo": "string",
"categoryThree": "string"
}
]'Example body ยท application/json
[
{
"sourceId": 0,
"sku": "string",
"title": "string",
"description": "string",
"manufacturer": "string",
"archived": true,
"images": [
{
"url": "string",
"sortOrder": 0
}
],
"options": [
{
"name": "string"
}
],
"attributes": [
{
"name": "string",
"value": "string"
}
],
"customFields": [
{
"name": "string",
"value": "string"
}
],
"variants": [
{
"supplierVariantId": "string",
"shippingCost": 0,
"dropshipFee": 0,
"inventoryListPrice": 0,
"referenceIdentifier": "string",
"quantity": 0,
"sku": "string",
"masterSku": "string",
"title": "string",
"mpn": "string",
"upc": "string",
"ean": "string",
"asin": "string",
"msrp": 0,
"map": 0,
"weight": 0,
"length": 0,
"width": 0,
"height": 0,
"archived": true,
"cost": 0,
"weightUnit": {
"handle": null,
"abbreviatedHandle": null
},
"dimensionUnit": {
"handle": null,
"abbreviatedHandle": null
},
"dimensionalWeight": 0,
"images": [
null
],
"options": [
null
],
"customFields": [
null
],
"allowBackorders": true,
"binLocation": "string",
"description": "string",
"requiresFfl": true
}
],
"categoryOne": "string",
"categoryTwo": "string",
"categoryThree": "string"
}
]Responses
200OKapplication/json
array[InventoryParentCreateOrUpdateResponse]
idintegerIf the parent was created or updated this will be populated. If the parent did not exist and failed to be created this will not be populated
skustringsuccessbooleanWhether or not the parent was successfully created/updated. If this is false the `errors` property will contain information that you can use to troubleshoot the failure.
errorsarray[GenericApiError]errorstringA generalized error message, may or may not be fit for human consumption.
dataobjectData points that could be useful in debugging the error.
No properties documented.
variantsarray[InventoryVariantCreateOrUpdateResponse]idinteger (int64)If the variant was created or updated this will be populated. If the variant did not exist and failed to be created this will not be populated
skustringsuccessbooleanWhether or not the variant was successfully created/updated. If this is false the `errors` property will contain information that you can use to troubleshoot the failure.
errorsarray[GenericApiError]errorstringA generalized error message, may or may not be fit for human consumption.
dataobjectData points that could be useful in debugging the error.
No properties documented.
Example response
[
{
"id": 0,
"sku": "string",
"success": true,
"errors": [
{
"error": "string",
"data": {}
}
],
"variants": [
{
"id": 0,
"sku": "string",
"success": true,
"errors": [
null
]
}
]
}
]401Unauthorized
No schema documented for this status.
OpenAPI fragment
{
"post": {
"summary": "[Deprecated] Create/Update Inventory",
"description": "Create or update up to 20 parents with variants at a time. This endpoint performs a full update of all data passed. This means any null/missing values provided will also be updated. For updating just variants (that already exist) with new prices/quantities see the `PUT Inventory Variants` endpoint.",
"parameters": [],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "array",
"maxItems": 20,
"items": {
"$ref": "#/components/schemas/InventoryParentCreateOrUpdate"
}
},
"examples": {
"example-minimum": {
"value": [
{
"sku": "PARENT_SKU_A",
"variants": [
{
"sku": "VARIANT_SKU_A_1",
"quantity": 1
},
{
"sku": "VARIANT_SKU_A_2",
"quantity": 1
},
{
"sku": "VARIANT_SKU_A_3",
"quantity": 1
}
]
},
{
"sku": "PARENT_SKU_B",
"variants": [
{
"sku": "VARIANT_SKU_B_1",
"quantity": 1
}
]
},
{
"sku": "PARENT_SKU_C",
"variants": [
{
"sku": "VARIANT_SKU_C_1",
"quantity": 1
}
]
}
]
}
}
}
}
},
"responses": {
"200": {
"description": "OK",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"$ref": "#/components/schemas/InventoryParentCreateOrUpdateResponse"
}
}
}
}
},
"401": {
"description": "Unauthorized"
}
}
}
}Ready to run it? Send the curl from your terminal or Postman, or use the interactive tester in Stoplight.Open in Stoplight