Partner Services Stock REST API
AddStockOrder Request
POST /api/v1/stock/stockorders/addstockorder
Required Headers
Authorization: Bearer <token>
Body
Submit a single JSON encoded AddStockOrderRequest as the POST body.
Important: The number of line items within the order is limited to the value of the constant "MAX_LINE_ITEMS" within the AddStockOrderRequest model.
Returns
HTTP 200 on success (request was understood and the stock order was added into the system)
HTTP 400 on model validation failure (do not resubmit without fixes)
HTTP 401 on invalid/missing Authorization token (do not resubmit without updating Authorization)
HTTP 403 on attempting to access an outlet you do not have access to or attempting to perform stock operations on an outlet that does not have stock enabled
HTTP 5XX on an error internal to the Partner Service.
On failure the response body will be a single JSON encoded ErrorResponse. The Data field within the ErrorResponse will contain additional information about the failure in the form of a AddStockOrderResponse object as long as the original request body submitted was formatted correctly and met all field formatting requirements.
On success the response body will be a single JSON encoded AddStockOrderResponse. This will contain an overall result, and the details of the fully resolved Stock Order that was created.