Create a new order
POST
The Order object contains all of the data needed to create and manage an order. Most fields remain static after creation, while dynamic fields such as status and shipments update as the order progresses through its lifecycle.
- Create order with files – You can create an order that already includes the file(s) by
specifying the file URL in the
file_detailsparameter. The order will immediately proceed to file processing once payment is submitted. - Create order without files – You can create an order without attaching the files upfront
and send them later asynchronously. This method uses the same parameters as creating an order
with files, but you leave
file_detailsempty.
application/json- body
merchant_api_key*stringYour API key for authentication.
currency*stringCurrency code (e.g. EUR, USD).
item_details*array<>The items to order. All items must be fulfillable by the same production facility — use the Quote endpoint to check this beforehand.
address_details*details about shipment and billing
order_reference?stringYour internal reference for the order.
purchase_order?stringOptional purchase order reference.
cost_centre?stringA specific department, location, or function that is assigned responsibility for the print costs
billing_entity_id?numberid of the billing entity
shipping_option?stringValue in
"STANDARD""EXPEDITED"Created
application/json- response
order_id?numbercurl -X POST 'https://test.www.peecho.com/rest/v3/order/' \ -H 'Content-Type: application/json' \ -d '{ "merchant_api_key": "API_KEY", "purchase_order": "", "currency": "EUR", "item_details": [ { "item_reference": "hardcover_22", "offering_id": 233309, "quantity": 3, "file_details": { "content_url": "https://calin-thumbnailer.s3-eu-west-1.amazonaws.com/wall-tiles-test.pdf", "content_width": 210, "content_height": 29.7, "number_of_pages": 80, "spine_details": { "dynamic_spine_details": { "text_font": "Arial", "text_size": 10, "text_colour": "#77493f", "text_top": "top text", "text_center": "center text", "text_bottom": "bottom text" } } } }, { "item_reference": "hardcover_23", "offering_id": 233309, "quantity": 2, "file_details": { "content_url": "https://calin-thumbnailer.s3-eu-west-1.amazonaws.com/wall-tiles-test.pdf", "content_width": 210, "content_height": 29.7, "number_of_pages": 80, "spine_details": { "custom_spine_url": "https://calin-thumbnailer.s3-eu-west-1.amazonaws.com/wall-tiles-test.pdf" } } } ], "address_details": { "email_address": "joshua@designy.com", "shipping_address": { "first_name": "Joshua", "last_name": "Grim", "address_line_1": "Test", "address_line_2": "1", "zip_code": "35100", "city": "Florida", "country_code": "AE" } }}'Example Response
{ "order_id": 1234}