### Idempotent POST Request Example Source: https://docs.api.delyva.com/ Demonstrates how to make an idempotent POST request to the /order endpoint by including an 'idempotency-key' header. This ensures safe retries without duplication. ```http POST /order HTTP/1.1 Host: api.delyva.app Content-Type: application/json idempotency-key: 'your-unique-idempotency-key' { "customerId": 123, "origin": {} "destination": {} ... } ``` -------------------------------- ### Create Order Source: https://docs.api.delyva.com/ The POST /order endpoint is used to create a new order. It supports idempotency keys for safe retries. ```APIDOC ## POST /order ### Description Creates a new order. This endpoint supports idempotency keys. ### Method POST ### Endpoint /order ### Headers - **idempotency-key** (string) - Required - A unique string identifier generated by your app to ensure safe retries. - **Content-Type** (string) - Required - Must be `application/json`. ### Request Body - **customerId** (integer) - Required - The ID of the customer. - **origin** (object) - Required - Details of the order origin. - **destination** (object) - Required - Details of the order destination. ### Request Example ```json { "customerId": 123, "origin": {}, "destination": {} } ``` ### Response #### Success Response (200) - **data** (object) - The response data containing details of the created order. ``` -------------------------------- ### Standard API Response Format Source: https://docs.api.delyva.com/ All valid API responses follow this JSON structure, with a 'data' field containing the response payload. ```json { “data”: } ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.