> For the complete documentation index, see [llms.txt](https://developers.tiqets.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developers.tiqets.dev/basics/openapi/booking-api/create-order.md). Agents can also search and read this documentation through its [MCP server](https://developers.tiqets.dev/~gitbook/mcp).

# Create order

Creates a non-confirmed order (reservation) that expires after 30 minutes.\
To confirm an already created order, use the [Confirm Order](https://developers.tiqets.dev/basics/openapi/booking-api/confirm-order.md) endpoint.

Order creation may  fail validation for reasons such as insufficient availability, invalid/missing customer data or if we were unable to generate a reservation on the supplier's booking platform.

Also see [Error Codes](https://developers.tiqets.dev/basics/error-handling.md)

{% hint style="warning" %}
In order to use the Booking API, please make sure to refer to our guide on how to Sign your API requests to our standard. [JWT Signing for Secure API Requests](https://developers.tiqets.dev/integration-guides/jwt-signing-for-secure-api-requests.md)
{% endhint %}

#### Ticket Language

By default, emails sent to the customers by Tiqets as well as the PDF tickets are made available in English. It is possible to set the language to any of the [supported Tiqets languages](https://developers.tiqets.dev/basics/conventions-and-standards.md#languages) by using the query parameter `lang`.

We recommend using the parameter if the customer has a preferred language different to English. By setting the language to the customer's preferred language, you make sure that the customer receives all relevant details in a language they understand.<br>

#### Creating orders with external reference

The Tiqets Distributor API allows partners to add their own order reference ID (external reference) when creating orders. This external reference will be added in Tiqets' order system to help partners:

* Cross-reference orders from a partner's system to Tiqets' orders
* Handle errors in case of timeout or other errors during the order creation<br>

The external reference ID's max. length is 255 characters and must be unique.\
Attempting to re-use an external reference ID will result in a unique constraint error response.

In case of timeouts or other errors during order creation, the own reference ID can be used to check the order status using the '[Get Order Information](https://developers.tiqets.dev/basics/openapi/booking-api/get-order-information.md)' endpoint.

#### Order Status Change Notification Webhook

The optional `callback_url` parameter can be used to provide a URL on your systems that we will call to inform you the status of this order has changed.

For more info: See the webhook's specific documentation.

## POST /orders

> Create order

```json
{"openapi":"3.1.0","info":{"title":"Tiqets Distributor API","version":"2.10.0"},"tags":[{"name":"Booking API"}],"servers":[{"url":"https://api.tiqets.com/v2","description":"Production Environment"},{"url":"https://api-tiqt-test.steq.it/v2","description":"Test Environment (until February 4th, 2026)"},{"url":"https://api.api-tiqt-test.steq.it/v2","description":"Test Environment (from February 4th, 2026)"}],"paths":{"/orders":{"post":{"tags":["Booking API"],"summary":"Create order","parameters":[{"$ref":"#/components/parameters/Authorization"},{"name":"lang","in":"query","description":"Order language. The language of the generated tickets follow this language. Defaults to English if undefined.","required":false,"schema":{"type":"string","description":"Language of the variants to retrieve."}}],"requestBody":{"description":"The request body must be signed with the Distributors private key. See the API Integration document for details on how to generate the key pair and JWT [**Request Signing**](#section/API-Basics/Request-signing)","required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"product_id":{"type":"integer","description":"ID of the product"},"day":{"type":"string","description":"Visit date of the product","format":"date"},"timeslot":{"type":["string","null"],"description":"Selected timeslot to visit. Required only for products that manage their availability using timeslots"},"variants":{"type":"array","description":"Variants to include in this order","items":{"type":"object","properties":{"variant_id":{"type":"integer","description":"The ID of the variant"},"count":{"type":"integer","description":"Number of tickets requested for this variant"}}}},"customer_details":{"$ref":"#/components/schemas/CustomerDetailsRequest"},"visitors_details":{"$ref":"#/components/schemas/VisitorsDetails"},"passport_id":{"type":["string","null"],"minLength":6,"maxLength":20,"pattern":"^[a-zA-Z0-9]{6,20}$","description":"Passport ID of the (main) visitor. Must contain 6–20 ASCII alphanumeric characters. Only if required for the product as advertised in Availability API. (On order level, not per individual visitor.)"},"zipcode":{"type":["integer","null"],"description":"The 5-digit US zipcode/postal code if the visitor lives in the United States. Only if required for the product as advertised in Availability API. (On order level, not per individual visitor.)"},"pickup_location":{"type":["string","null"],"description":"The holiday address of visitors. The tour provider may contact the visitor to arrange the nearest pickup location. Only if required for the product as advertised in Availability API. (On order level, not per individual visitor.)"},"dropoff_location":{"type":["string","null"],"description":"The address where the visitors want to be dropped off after the ordered product/activity. Only if required for the product as advertised in Availability API. (On order level, not per individual visitor.)"},"flight_number":{"type":["string","null"],"description":"The number of the flight the visitors arrive with. This allows the supplier to be at the right time and location if a product includes an airport pickup/dropoff. Only if required for the product as advertised in Availability API. (On order level, not per individual visitor.)"},"callback_url":{"type":["string","null"],"description":"Optional Callback URL (webhook) for order status change notifications. This URL will be called for all order status changes, including cancellation."},"external_reference":{"type":["string","null"],"description":"Partner's order reference ID. Maximum 255 characters, needs to be unique"}},"required":["product_id","day","variants","customer_details"]}}}},"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"order_reference_id":{"type":"string","description":"The unique order reference ID created for this order."},"payment_confirmation_token":{"type":"string","description":"Unique token that must be used to confirm the order."},"price_components_eur":{"$ref":"#/components/schemas/PriceComponentMediationInEUR"},"price_components":{"$ref":"#/components/schemas/PriceComponentMediation"},"expected_ticket_delivery_date":{"description":"The date on which the tickets will be expected to be delivered. Relevant when ticket_delivery != direct_via_tiqets_api","type":"string","format":"date","nullable":true},"estimated_commissions":{"type":"array","description":"Estimated commission for the order.","items":{"type":"object","properties":{"currency":{"type":"string","description":"Currency code (ISO 4217) for the estimated commission amount."},"variant_id":{"type":"integer","description":"Variant identifier."},"value":{"type":"number","description":"Value of the estimated commission."}}}}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/MethodNotAllowed"},"429":{"$ref":"#/components/responses/TooManyRequests"},"500":{"$ref":"#/components/responses/InternalServerError"},"503":{"$ref":"#/components/responses/ServiceUnavailable","description":"Service Unavailable -- API maintenance or temporary supplier/Connection Service unavailability during reservation. Reservation dependency failures return `reservation_error` with message `Ticket reservation error.`. Unknown reservation failures remain HTTP 500. A 503 does not confirm the supplier-side booking outcome; do not automatically retry. Follow the existing idempotency and booking-reconciliation workflow."}}}}},"components":{"parameters":{"Authorization":{"name":"Authorization","in":"header","required":true,"description":"Token <Your_API_Key>.","schema":{"type":"string","default":"Token <Partner_API_key>."}}},"schemas":{"CustomerDetailsRequest":{"type":"object","description":"Customer details required to create an order. Note: The Tiqets support team might contact the provided email address and/or phone number in case of sudden changes.","properties":{"firstname":{"type":"string","description":"Customer's first name. Unicode characters, including accents and non-Latin scripts, are supported."},"lastname":{"type":"string","description":"Customer's last name. Unicode characters, including accents and non-Latin scripts, are supported."},"email":{"type":"string","format":"email","description":"Customer's email address. Must be a valid email address."},"phone":{"type":"string","description":"Customer's phone number. Following the regex format '^\\+[1-9][0-9]{7,14}$'."}},"required":["firstname","lastname","email","phone"]},"VisitorsDetails":{"type":"array","description":"Additional checkout information of every visitor.\n**Note**: these fields are only required for a few products which have `requires_visitors_details` on the variant endpoint. In case it is required, the details of the visitors must be provided for every visitor/ticket purchased within the order.","items":{"type":"object","properties":{"variant_id":{"type":"integer","description":"The ID of the variant."},"visitors_data":{"type":"array","description":"Additional information required of each visitor associated with the `variant_id`. One value per key.\n*The full_name example shows the correct format for a request to create an order for 2 variants and 3 guests in total.*","items":{"type":"object","properties":{"full_name":{"type":["string","null"],"minLength":1,"maxLength":100,"pattern":"^\\S+\\s\\S.*$","description":"Visitor's full name. Must not be blank, must contain at least two name parts separated by whitespace, and must be no more than 100 characters. Unicode characters, including accents and non-Latin scripts, are supported."},"passport_ids":{"type":["string","null"],"minLength":1,"pattern":".*\\S.*","description":"Visitor's passport ID. Must not be blank when required for the product."},"date_of_birth":{"type":["string","null"],"format":"date","description":"Visitor's date of birth. Date format YYYY-MM-DD."},"nationality":{"type":["string","null"],"description":"Visitor's nationality in Latin characters."},"weight_kg":{"type":["string","null"],"description":"Visitor's weight in kg. Expects an integer value as a string."},"weight_lb":{"type":["string","null"],"description":"Visitor's weight in lb. Expects an integer value as a string."},"address":{"type":["string","null"],"description":"Visitor's home address."},"email":{"type":["string","null"],"format":"email","minLength":5,"maxLength":255,"pattern":"^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$","description":"Visitor's email address. Must use a valid user@domain.tld format."},"phone":{"type":["string","null"],"minLength":7,"maxLength":20,"pattern":"^[+0-9\\s\\-().]{7,20}$","description":"Visitor's phone number. May contain digits, plus signs, whitespace, hyphens, parentheses, and periods."},"dietary_preference":{"type":["string","null"],"description":"Visitor's dietary preferences or restrictions"}}}}}}},"PriceComponentMediationInEUR":{"type":["object","null"],"description":"Order pricing details in EUR.","properties":{"sale_ticket_value_incl_vat":{"type":"number","description":"Sale tickets value, including VAT. Sum of `sale_ticket_value_incl_vat` of all the tickets in the order."},"booking_fee_incl_vat":{"type":"number","description":"Booking fee, including VAT."},"sale_order_value__incl_vat":{"type":"number","description":"Sale order value, including VAT. Sum of `sale_ticket_value_incl_vat` and `booking_fee_incl_vat` of all the tickets in the order."},"distributor_commission_excl_vat":{"type":"number","description":"Total distributor commission of the order, excluding VAT."}}},"PriceComponentMediation":{"type":["object","null"],"description":"Order pricing details in the distributor's invoicing currency.","properties":{"sale_ticket_value_incl_vat":{"type":"number","description":"Sale tickets value, including VAT. Sum of `sale_ticket_value_incl_vat` of all the tickets in the order."},"booking_fee_incl_vat":{"type":"number","description":"Booking fee, including VAT."},"sale_order_value__incl_vat":{"type":"number","description":"Sale order value, including VAT. Sum of `sale_ticket_value_incl_vat` and `booking_fee_incl_vat` of all the tickets in the order."},"distributor_commission_excl_vat":{"type":"number","description":"Total distributor commission of the order, excluding VAT."},"currency":{"type":"string","description":"Currency code (ISO 4217) for the existing amounts."},"estimated_partner_rate":{"type":["number","null"],"description":"As an intermediary of Tiqets, you receive a partner commission for your services in accordance with your partner contract. The Estimated Partner Rate is merely displayed to indicate the estimated difference between the ticket retail price (including VAT) and your estimated partner commission (excluding VAT). No rights can be derived from this estimation. The terms of your partner contract shall prevail and take precedence in all cases."}}}},"responses":{"BadRequest":{"description":"Bad Request -- Check your request parameters (typo in parameter or invalid value).","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"message":{"type":"string"},"error":{"type":"string"},"field_errors":{"type":"object"}}}}}},"Unauthorized":{"description":"Unauthorized -- Your API key is incorrect.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"message":{"type":"string"},"error":{"type":"string"}}}}}},"Forbidden":{"description":"Forbidden -- The endpoint or parameters are not allowed for the matching API key.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"message":{"type":"string"},"error":{"type":"string"}}}}}},"NotFound":{"description":"Not Found -- Requested resource/endpoint could not be found.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"message":{"type":"string"},"error":{"type":"string"}}}}}},"MethodNotAllowed":{"description":"Method Not Allowed -- Check your request method.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"message":{"type":"string"},"error":{"type":"string"}}}}}},"TooManyRequests":{"description":"Too Many Requests -- We currently apply a fair-use policy, but we might enforce limits in the future.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"message":{"type":"string"},"error":{"type":"string"}}}}}},"InternalServerError":{"description":"Internal Server Error -- We had a problem with our server. Try again later.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"message":{"type":"string"},"error":{"type":"string"}}}}}},"ServiceUnavailable":{"description":"Service Unavailable -- We're temporarily offline for maintenance. Please try again later.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"message":{"type":"string"},"error":{"type":"string"}}}}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://developers.tiqets.dev/basics/openapi/booking-api/create-order.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
