API documentation
Method list
Test your request
Changelog


addPickPackOrdersToCart
The method allows you to assign multiple orders to a specific PickPack cart in a single API call. You can assign up to 20 orders at once. If any order is already assigned to another cart, it will be moved to the new cart (only one cart assignment per order is allowed).


Input parameters
order_idsarrayArray of order identifiers to be assigned to the cart (maximum 20 orders per call)
cart_idintCart identifier where the orders should be assigned



Output data
The method returns the data in JSON format.
statusvarchar(30)SUCCESS - request executed correctly
ERROR - an error occurred during an API request. Error details will be described in 2 additional returned fields: error_message and error_code
orders_assignedintNumber of orders successfully assigned to the cart
orders_failedarrayArray of order_ids that failed to be assigned (due to validation errors)



Sample
Input data:
Output data:
A sample request in PHP: