Ticketing Shop API enables you to build your own ticket shop. A place where your customers can create and adjust orders, and where customers can pay on a checkout page.
You can integrate this in your application by communicating with our api.
The Ticketing Shop API is a REST API that uses JSON to communicate.
To make use of our API for Ticketing you need to be registered at CM.com, you need to be acquired in the ticketing app and you need to create an event in the ticketing app.
During the implementation you might have questions and we kindly refer to our Help Center documents to get more background information.
We have made a few code samples to quickly get started, each one appealing to some selected programming languages. If you are missing one, please let me know.
This cURL code sample provides you an easy and simple way to test out the connectivity to our Ticketing Shop API on a CLI. Just fill the provided product token and you are good to go.
curl --location \
--request GET 'https://api.cm.com/ticketingapi/v2.0/ticketshop/events' \
--header 'accept: application/json' \
--header 'X-CM-PRODUCTTOKEN: [PASTE_PRODUCT_TOKEN_HERE]'
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.cm.com/ticketingapi/v2.0/ticketshop/events",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => array(
"accept: application/json",
"X-CM-PRODUCTTOKEN: [PASTE_PRODUCT_TOKEN_HERE]"
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var https = require('follow-redirects').https;
var fs = require('fs');
var options = {
'method': 'GET',
'hostname': 'api.cm.com',
'path': '/ticketingapi/v2.0/ticketshop/events',
'headers': {
'accept': 'application/json',
'X-CM-PRODUCTTOKEN': '[PASTE_PRODUCT_TOKEN_HERE]'
},
'maxRedirects': 20
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
req.end();
https://api.cm.com/ticketingapi/v2.0/ticketshop
Our API supports sending messages via HTTP. You can send a POST request containing a JSON body.
The API expects one header containing an authentication token, called X-CM-PRODUCTTOKEN. This token will be provided by your account manager or you can request one via [email protected].
NOTE: Your product token is private information and should never be incorporated into webpages and/or mobile applications where it can be exposed to 3rd parties. Therefor it is not a good practise to store a api key/product token in a frontend application because everything is readable (one way or another).
Communication with the CM servers should be done using the TLS cryptographic protocol, version 1.1 or higher. Older security protocols such as TLSv1.0 and SSLv3 are not supported.
On our API, Cross-Site Scripting (XSS) protection is enabled. XSS enables attackers to inject client-side scripts into web pages viewed by other users.
To protect your web application and our API we disabled the option to make direct request from a web application.
Refers to an event as set-up by client in the Ticketing Dashboard.
Get a list of future and/or ongoing events.
GET https://api.cm.com/ticketingapi/v2.0/ticketshop/events?key=KEY123
Type | Name | Description | Required | Example |
---|---|---|---|---|
Header | X-CM-PRODUCTTOKEN | The product token. | True | 00000000-0000-0000-0000-000000000000 |
Header | Content-Type | The content type which the application expects. | True | application/json |
Query Parameter | key | In some cases, an organiser wants to lock the ticket store. This can be done with our access key option. The end user has a key to unlock the ticket store. In the case the access keys are activated, the key needs to be send to our API. | False | KEY123 |
Http status | Description | Example |
---|---|---|
200 | Successful operation | Event List Object |
400 | Bad request | Info Message |
[
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": "Flow Festival",
"start_at": "2019-12-01T11:30:00+00:00",
"end_at": "2019-12-02T11:30:00+00:00",
"venue_name": "Amsterdam"
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": "Other Event",
"start_at": null,
"end_at": null,
"venue_name": null
}
]
Get all event data for a specific event.
GET https://api.cm.com/ticketingapi/v2.0/ticketshop/events/{event_uuid}?key=KEY123
Type | Name | Description | Required | Example |
---|---|---|---|---|
Header | X-CM-PRODUCTTOKEN | The product token. | True | 00000000-0000-0000-0000-000000000000 |
Header | Content-Type | The content type which the application expects. | True | application/json |
Query Parameter | key | In some cases, an organiser wants to lock the ticket store. This can be done with our access key option. The end user has a key to unlock the ticket store. In the case the access keys are activated, the key needs to be send to our API. | False | KEY123 |
Path Variable | event_uuid | The UUID of an event can be retrieved from the Ticketing Dashboard. | True | 00000000-0000-0000-0000-000000000000 |
Http status | Description | Example |
---|---|---|
200 | Successful operation | Event Object |
400 | Bad request | Info Message |
{
"event": {
"uuid": "00000000-0000-0000-0000-000000000000",
"name": "Flow Festival",
"start_at": null,
"end_at": null,
"online_from": null,
"online_till": null,
"is_ongoing": true,
"description": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"discount_label": {
"nl": "Korting",
"en": "Discount",
"fr": "Code promotionnel",
"de": "Rabatt"
},
"minutes_to_order": 20,
"shop_image": null,
"is_discount_enabled": true,
"is_calendar_enabled": true,
"is_order_invoicing_enabled": false,
"google_analytics_tracking_code": null,
"google_adwords_conversion_code": null,
"google_adwords_conversion_label": null,
"google_adwords_remarketing_code": null,
"google_adwords_remarketing_label": null,
"facebook_pixel_tracking_code": null,
"support_email": null,
"organiser_entity": null,
"privacy_policy_url": null,
"newsletter_label": {
"nl": "Nieuwsbrief en updates ontvangen",
"en": "Subscribe for newsletter and updates",
"fr": "Je m’abonne à la newsletter",
"de": "Newsletter abonnieren"
},
"terms_and_conditions_url": null
},
"shop_style": {
"general_background_color": "transparent",
"general_font_color": "#333333",
"general_link_color": "#337ab7",
"category_background_color": "#F4F4F4",
"category_font_color": "#333333",
"category_background_color_highlight": "#259bdb",
"category_font_color_highlight": "#FFFFFF"
},
"venue": {
"name": "CM Tickets",
"address_line_1": "Konijnenberg 30",
"address_line_2": null,
"zipcode": "4825 BD",
"city": "Breda",
"country_id": "NL"
},
"categories": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"display_order": 10,
"is_visible": true,
"is_initialized": true,
"name": {
"nl": "Tickets",
"en": "Tickets",
"fr": "Des billets",
"de": "Tickets"
},
"tickets": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"price": 0,
"fixed_fee": 0,
"is_visible": true,
"is_selectable_on_calendar": false,
"min_order_amount": 1,
"max_order_amount": 10,
"online_from": null,
"online_till": null,
"display_order": 10,
"name": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"subtitle": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"description": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"ticket_status_type_id": "ONLINE",
"tags": [
{
"id": "00000000-0000-0000-0000-000000000000",
"name": "tag 1"
},
{
"id": "00000000-0000-0000-0000-000000000000",
"name": "tag 2"
}
],
"is_unlimited": true
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"price": 0,
"fixed_fee": 0,
"is_visible": true,
"is_selectable_on_calendar": true,
"min_order_amount": 1,
"max_order_amount": 10,
"online_from": null,
"online_till": null,
"display_order": 20,
"name": {
"nl": "Regulier",
"en": "Regulier",
"fr": "Regulier",
"de": "Regulier"
},
"subtitle": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"description": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"ticket_status_type_id": "ONLINE",
"tags": [
{
"id": "00000000-0000-0000-0000-000000000000",
"name": "tag 1"
},
{
"id": "00000000-0000-0000-0000-000000000000",
"name": "tag 2"
}
],
"is_unlimited": true
}
]
}
],
"ticket_statuses": [
{
"id": "NOT_IN_SALE",
"status": {
"nl": "Momenteel niet in de verkoop",
"en": "Currently not in sale",
"fr": "Actuellement pas en vente",
"de": "Derzeit nicht im Verkauf"
}
},
{
"id": "DOOR_SALE",
"status": {
"nl": "Deurverkoop",
"en": "Door sale",
"fr": "Vente de porte",
"de": "Türverkauf"
}
},
{
"id": "IN_RESERVATION",
"status": {
"nl": "Alles in reservering",
"en": "Everything in reservation",
"fr": "Tout est réservé",
"de": "Alles ist reserviert"
}
},
{
"id": "ONLINE",
"status": {
"nl": "Online",
"en": "Online",
"fr": "En ligne",
"de": "Online"
}
},
{
"id": "SOLD_OUT",
"status": {
"nl": "Uitverkocht",
"en": "Sold Out",
"fr": "Épuisé",
"de": "Ausverkauft"
}
}
],
"customer_data": {
"first_name": "REQUIRED",
"last_name": "REQUIRED",
"email": "REQUIRED",
"mobile": "REQUIRED",
"gender": "REQUIRED",
"address_data": "REQUIRED",
"position_name": "NOT_IN_USE",
"date_of_birth": "NOT_IN_USE",
"organisation_name": "NOT_IN_USE",
"custom_field_1": "NOT_IN_USE",
"custom_field_1_label": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"custom_field_2": "NOT_IN_USE",
"custom_field_2_label": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"custom_field_3": "NOT_IN_USE",
"custom_field_3_label": {
"nl": "",
"en": "",
"fr": "",
"de": ""
}
},
"payment_methods": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": "Ideal",
"description": null,
"fixed_fee": 0.68,
"percentage_fee": 0,
"image_uri": "https://static.ticketflow.eu/assets/images/paymethods/ideal.png",
"display_order": 10,
"currency_id": "EUR"
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": "Bancontact",
"description": null,
"fixed_fee": 0.35,
"percentage_fee": 2.6,
"image_uri": "https://static.ticketflow.eu/assets/images/paymethods/bancontact.png",
"display_order": 30,
"currency_id": "EUR"
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": "Sofort Banking",
"description": null,
"fixed_fee": 0.55,
"percentage_fee": 2.3,
"image_uri": "https://static.ticketflow.eu/assets/images/paymethods/sofort_banking.png",
"display_order": 40,
"currency_id": "EUR"
}
],
"ideal_issuers": [
{
"id": "ABNANL2A",
"name": "ABN AMRO"
},
{
"id": "ASNBNL21",
"name": "ASN Bank"
},
{
"id": "BUNQNL2A",
"name": "bunq"
},
{
"id": "INGBNL2A",
"name": "ING"
},
{
"id": "MOYONL21",
"name": "Moneyou"
},
{
"id": "RABONL2U",
"name": "Rabobank"
},
{
"id": "RBRBNL21",
"name": "RegioBank"
},
{
"id": "KNABNL2H",
"name": "Knab"
},
{
"id": "SNSBNL2A",
"name": "SNS"
},
{
"id": "TRIONL2U",
"name": "Triodos Bank"
},
{
"id": "FVLBNL22",
"name": "Van Lanschot"
}
]
}
To calculate the total purchase amount, ticket fees and transaction fees can be applicable. Below you will find an explanation on how the calculation of the total purchase amount must be made.
The total purchase price can consist of:
If all of the above are applicable the calculation for the total purchase amount must be made using the calculation method below:
Sub_Total = ( Ticket_Price + Ticket_Fee ) x Amount ) + ( Ticket_Price + Ticket_Fee ) x Amount )
Total = ( Sub_Total x Payment_Method_Percentage_Fee ) + Fixed_Fee_Payment_Method
If only fixed fee per payment method is applicable the calculation for the total purchase amount must be made using the calculation method below:
Sub_Total = ( Ticket_Price + Ticket_Fee ) x Amount ) + ( Ticket_Price + Ticket_Fee ) x Amount )
Total = Sub_Total + Fixed_Fee_Payment_Method
If no fees applicable the calculation for the total purchase amount must be made using the calculation method below:
Total = ( Ticket_Price + Ticket_Fee ) x Amount ) + ( Ticket_Price + Ticket_Fee ) x Amount )
Refers to an event as set-up by client in the Ticketing Dashboard.
Get a list of future and/or ongoing events.
GET https://api.cm.com/ticketingapi/v2.0/ticketshop/events?key=KEY123
Type | Name | Description | Required | Example |
---|---|---|---|---|
Header | X-CM-PRODUCTTOKEN | The product token. | True | 00000000-0000-0000-0000-000000000000 |
Header | Content-Type | The content type which the application expects. | True | application/json |
Query Parameter | key | In some cases, an organiser wants to lock the ticket store. This can be done with our access key option. The end user has a key to unlock the ticket store. In the case the access keys are activated, the key needs to be send to our API. | False | KEY123 |
Http status | Description | Example |
---|---|---|
200 | Successful operation | Event List Object |
400 | Bad request | Info Message |
[
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": "Flow Festival",
"start_at": "2019-12-01T11:30:00+00:00",
"end_at": "2019-12-02T11:30:00+00:00",
"venue_name": "Amsterdam"
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": "Other Event",
"start_at": null,
"end_at": null,
"venue_name": null
}
]
Get all event data for a specific event.
GET https://api.cm.com/ticketingapi/v2.0/ticketshop/events/{event_uuid}?key=KEY123
Type | Name | Description | Required | Example |
---|---|---|---|---|
Header | X-CM-PRODUCTTOKEN | The product token. | True | 00000000-0000-0000-0000-000000000000 |
Header | Content-Type | The content type which the application expects. | True | application/json |
Query Parameter | key | In some cases, an organiser wants to lock the ticket store. This can be done with our access key option. The end user has a key to unlock the ticket store. In the case the access keys are activated, the key needs to be send to our API. | False | KEY123 |
Path Variable | event_uuid | The UUID of an event can be retrieved from the Ticketing Dashboard. | True | 00000000-0000-0000-0000-000000000000 |
Http status | Description | Example |
---|---|---|
200 | Successful operation | Event Object |
400 | Bad request | Info Message |
{
"event": {
"uuid": "00000000-0000-0000-0000-000000000000",
"name": "Flow Festival",
"start_at": null,
"end_at": null,
"online_from": null,
"online_till": null,
"is_ongoing": true,
"description": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"discount_label": {
"nl": "Korting",
"en": "Discount",
"fr": "Code promotionnel",
"de": "Rabatt"
},
"minutes_to_order": 20,
"shop_image": null,
"is_discount_enabled": true,
"is_calendar_enabled": true,
"is_order_invoicing_enabled": false,
"google_analytics_tracking_code": null,
"google_adwords_conversion_code": null,
"google_adwords_conversion_label": null,
"google_adwords_remarketing_code": null,
"google_adwords_remarketing_label": null,
"facebook_pixel_tracking_code": null,
"support_email": null,
"organiser_entity": null,
"privacy_policy_url": null,
"newsletter_label": {
"nl": "Nieuwsbrief en updates ontvangen",
"en": "Subscribe for newsletter and updates",
"fr": "Je m’abonne à la newsletter",
"de": "Newsletter abonnieren"
},
"terms_and_conditions_url": null
},
"shop_style": {
"general_background_color": "transparent",
"general_font_color": "#333333",
"general_link_color": "#337ab7",
"category_background_color": "#F4F4F4",
"category_font_color": "#333333",
"category_background_color_highlight": "#259bdb",
"category_font_color_highlight": "#FFFFFF"
},
"venue": {
"name": "CM Tickets",
"address_line_1": "Konijnenberg 30",
"address_line_2": null,
"zipcode": "4825 BD",
"city": "Breda",
"country_id": "NL"
},
"categories": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"display_order": 10,
"is_visible": true,
"is_initialized": true,
"name": {
"nl": "Tickets",
"en": "Tickets",
"fr": "Des billets",
"de": "Tickets"
},
"tickets": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"price": 0,
"fixed_fee": 0,
"is_visible": true,
"is_selectable_on_calendar": false,
"min_order_amount": 1,
"max_order_amount": 10,
"online_from": null,
"online_till": null,
"display_order": 10,
"name": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"subtitle": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"description": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"ticket_status_type_id": "ONLINE",
"tags": [
{
"id": "00000000-0000-0000-0000-000000000000",
"name": "tag 1"
},
{
"id": "00000000-0000-0000-0000-000000000000",
"name": "tag 2"
}
],
"is_unlimited": true
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"price": 0,
"fixed_fee": 0,
"is_visible": true,
"is_selectable_on_calendar": true,
"min_order_amount": 1,
"max_order_amount": 10,
"online_from": null,
"online_till": null,
"display_order": 20,
"name": {
"nl": "Regulier",
"en": "Regulier",
"fr": "Regulier",
"de": "Regulier"
},
"subtitle": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"description": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"ticket_status_type_id": "ONLINE",
"tags": [
{
"id": "00000000-0000-0000-0000-000000000000",
"name": "tag 1"
},
{
"id": "00000000-0000-0000-0000-000000000000",
"name": "tag 2"
}
],
"is_unlimited": true
}
]
}
],
"ticket_statuses": [
{
"id": "NOT_IN_SALE",
"status": {
"nl": "Momenteel niet in de verkoop",
"en": "Currently not in sale",
"fr": "Actuellement pas en vente",
"de": "Derzeit nicht im Verkauf"
}
},
{
"id": "DOOR_SALE",
"status": {
"nl": "Deurverkoop",
"en": "Door sale",
"fr": "Vente de porte",
"de": "Türverkauf"
}
},
{
"id": "IN_RESERVATION",
"status": {
"nl": "Alles in reservering",
"en": "Everything in reservation",
"fr": "Tout est réservé",
"de": "Alles ist reserviert"
}
},
{
"id": "ONLINE",
"status": {
"nl": "Online",
"en": "Online",
"fr": "En ligne",
"de": "Online"
}
},
{
"id": "SOLD_OUT",
"status": {
"nl": "Uitverkocht",
"en": "Sold Out",
"fr": "Épuisé",
"de": "Ausverkauft"
}
}
],
"customer_data": {
"first_name": "REQUIRED",
"last_name": "REQUIRED",
"email": "REQUIRED",
"mobile": "REQUIRED",
"gender": "REQUIRED",
"address_data": "REQUIRED",
"position_name": "NOT_IN_USE",
"date_of_birth": "NOT_IN_USE",
"organisation_name": "NOT_IN_USE",
"custom_field_1": "NOT_IN_USE",
"custom_field_1_label": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"custom_field_2": "NOT_IN_USE",
"custom_field_2_label": {
"nl": "",
"en": "",
"fr": "",
"de": ""
},
"custom_field_3": "NOT_IN_USE",
"custom_field_3_label": {
"nl": "",
"en": "",
"fr": "",
"de": ""
}
},
"payment_methods": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": "Ideal",
"description": null,
"fixed_fee": 0.68,
"percentage_fee": 0,
"image_uri": "https://static.ticketflow.eu/assets/images/paymethods/ideal.png",
"display_order": 10,
"currency_id": "EUR"
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": "Bancontact",
"description": null,
"fixed_fee": 0.35,
"percentage_fee": 2.6,
"image_uri": "https://static.ticketflow.eu/assets/images/paymethods/bancontact.png",
"display_order": 30,
"currency_id": "EUR"
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": "Sofort Banking",
"description": null,
"fixed_fee": 0.55,
"percentage_fee": 2.3,
"image_uri": "https://static.ticketflow.eu/assets/images/paymethods/sofort_banking.png",
"display_order": 40,
"currency_id": "EUR"
}
],
"ideal_issuers": [
{
"id": "ABNANL2A",
"name": "ABN AMRO"
},
{
"id": "ASNBNL21",
"name": "ASN Bank"
},
{
"id": "BUNQNL2A",
"name": "bunq"
},
{
"id": "INGBNL2A",
"name": "ING"
},
{
"id": "MOYONL21",
"name": "Moneyou"
},
{
"id": "RABONL2U",
"name": "Rabobank"
},
{
"id": "RBRBNL21",
"name": "RegioBank"
},
{
"id": "KNABNL2H",
"name": "Knab"
},
{
"id": "SNSBNL2A",
"name": "SNS"
},
{
"id": "TRIONL2U",
"name": "Triodos Bank"
},
{
"id": "FVLBNL22",
"name": "Van Lanschot"
}
]
}
To calculate the total purchase amount, ticket fees and transaction fees can be applicable. Below you will find an explanation on how the calculation of the total purchase amount must be made.
The total purchase price can consist of:
If all of the above are applicable the calculation for the total purchase amount must be made using the calculation method below:
Sub_Total = ( Ticket_Price + Ticket_Fee ) x Amount ) + ( Ticket_Price + Ticket_Fee ) x Amount )
Total = ( Sub_Total x Payment_Method_Percentage_Fee ) + Fixed_Fee_Payment_Method
If only fixed fee per payment method is applicable the calculation for the total purchase amount must be made using the calculation method below:
Sub_Total = ( Ticket_Price + Ticket_Fee ) x Amount ) + ( Ticket_Price + Ticket_Fee ) x Amount )
Total = Sub_Total + Fixed_Fee_Payment_Method
If no fees applicable the calculation for the total purchase amount must be made using the calculation method below:
Total = ( Ticket_Price + Ticket_Fee ) x Amount ) + ( Ticket_Price + Ticket_Fee ) x Amount )
Discount, or a voucher can be applied to specific tickets or on a full order. By letting users enter the discount, or a voucher code and sending it along with the api request; the discount, or a voucher will be automatically applied on the concerning tickets.
Get discount or voucher codes data for a specific event.
GET https://api.cm.com/ticketingapi/v2.0/ticketshop/events/{event_uuid}/codes/{code}?key=KEY123
Type | Name | Description | Required | Example |
---|---|---|---|---|
Header | X-CM-PRODUCTTOKEN | The product token. | True | 00000000-0000-0000-0000-000000000000 |
Header | Content-Type | The content type which the application expects. | True | application/json |
Path Variable | event_uuid | The UUID of an event can be retrieved from the Ticketing Dashboard. | True | 00000000-0000-0000-0000-000000000000 |
Query Parameter | key | In some cases, an organiser wants to lock the ticket store. This can be done with our access key option. The end user has a key to unlock the ticket store. In the case the access keys are activated, the key needs to be send to our API. | False | KEY123 |
Path Variable | code | The discount or voucher code you want to check. This code must be base64 encoded. | True | RElTQ09VTlQxMjM= |
Http status | Description | Example |
---|---|---|
200 | Successful operation | Discount Or Voucher Code Object |
400 | Bad request | Info Message |
{
"discount_code": {
"code": "DISCOUNT123",
"external_code": null,
"fixed_balance": 0,
"percentage": 0,
"capacity": 100,
"stock": 93,
"discount_type_id": "DISCOUNT_TICKET_TYPE",
"description": {
"nl": "Korting",
"en": "Discount",
"fr": "Code promotionnel",
"de": "Rabatt"
},
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"max_order_amount": 1,
"fixed_balance": 2
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"max_order_amount": 2,
"fixed_balance": 5
}
]
},
"voucher_code": null
}
{
"discount_code": null,
"voucher_code": {
"code": "VOUCHER123",
"external_code": null,
"balance": 420
}
}
In the ticket shop there could be a calendar to select ticket types for a specific time slot. This time slot can be added to a reservation (so the time on a location can be blocked for this customer.)
If the calendar function is enabled for an event, a time slot selection is mandatory.
First you need to collect the data of the whole month and later you can 'zoom in' on the day to get the time slots of that day. (Ticket types may vary per time slot.)
When the end-user selected their preferred time slot, the id of this time slot can be added to the create and update reservation end-point as the property 'time_slot_id'.
Get all event calendar data by year and month.
Note: the time slot id can not be used on the create and update reservation end-point when using the month end-point
Type | Name | Description | Required | Example |
---|---|---|---|---|
Header | X-CM-PRODUCTTOKEN | The product token. | True | 00000000-0000-0000-0000-000000000000 |
Header | Content-Type | The content type which the application expects. | True | application/json |
Query Parameter | key | In some cases, an organiser wants to lock the ticket store. This can be done with our access key option. The end user has a key to unlock the ticket store. In the case the access keys are activated, the key needs to be send to our API. | False | KEY123 |
Path Variable | event_uuid | The UUID of an event can be retrieved from the Ticketing Dashboard. | True | 00000000-0000-0000-0000-000000000000 |
Path Variable | year | The year number of which you want to retrieve the calendar for. | True | 2020 |
Path Variable | month | The month number of which you want to retrieve the calendar for. | True | 01 |
Http status | Description | Example |
---|---|---|
200 | Successful operation | Time Slot Objects |
400 | Bad request | Info Message |
[
{
"id": "2019-05-01",
"start_at": "2019-04-30T22:00:00+00:00",
"end_at": "2019-05-01T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-02",
"start_at": "2019-05-01T22:00:00+00:00",
"end_at": "2019-05-02T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-03",
"start_at": "2019-05-02T22:00:00+00:00",
"end_at": "2019-05-03T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-04",
"start_at": "2019-05-03T22:00:00+00:00",
"end_at": "2019-05-04T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-05",
"start_at": "2019-05-04T22:00:00+00:00",
"end_at": "2019-05-05T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-06",
"start_at": "2019-05-05T22:00:00+00:00",
"end_at": "2019-05-06T21:59:59+00:00",
"status_id": "CLOSED",
"stock": 0
},
{
"id": "2019-05-07",
"start_at": "2019-05-06T22:00:00+00:00",
"end_at": "2019-05-07T21:59:59+00:00",
"status_id": "CLOSED",
"stock": 0
},
{
"id": "2019-05-08",
"start_at": "2019-05-07T22:00:00+00:00",
"end_at": "2019-05-08T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-09",
"start_at": "2019-05-08T22:00:00+00:00",
"end_at": "2019-05-09T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-10",
"start_at": "2019-05-09T22:00:00+00:00",
"end_at": "2019-05-10T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-11",
"start_at": "2019-05-10T22:00:00+00:00",
"end_at": "2019-05-11T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-12",
"start_at": "2019-05-11T22:00:00+00:00",
"end_at": "2019-05-12T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-13",
"start_at": "2019-05-12T22:00:00+00:00",
"end_at": "2019-05-13T21:59:59+00:00",
"status_id": "CLOSED",
"stock": 0
},
{
"id": "2019-05-14",
"start_at": "2019-05-13T22:00:00+00:00",
"end_at": "2019-05-14T21:59:59+00:00",
"status_id": "CLOSED",
"stock": 0
},
{
"id": "2019-05-15",
"start_at": "2019-05-14T22:00:00+00:00",
"end_at": "2019-05-15T21:59:59+00:00",
"status_id": "OPEN",
"stock": 286
},
{
"id": "2019-05-16",
"start_at": "2019-05-15T22:00:00+00:00",
"end_at": "2019-05-16T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-17",
"start_at": "2019-05-16T22:00:00+00:00",
"end_at": "2019-05-17T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-18",
"start_at": "2019-05-17T22:00:00+00:00",
"end_at": "2019-05-18T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-19",
"start_at": "2019-05-18T22:00:00+00:00",
"end_at": "2019-05-19T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-20",
"start_at": "2019-05-19T22:00:00+00:00",
"end_at": "2019-05-20T21:59:59+00:00",
"status_id": "CLOSED",
"stock": 0
},
{
"id": "2019-05-21",
"start_at": "2019-05-20T22:00:00+00:00",
"end_at": "2019-05-21T21:59:59+00:00",
"status_id": "CLOSED",
"stock": 0
},
{
"id": "2019-05-22",
"start_at": "2019-05-21T22:00:00+00:00",
"end_at": "2019-05-22T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-23",
"start_at": "2019-05-22T22:00:00+00:00",
"end_at": "2019-05-23T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-24",
"start_at": "2019-05-23T22:00:00+00:00",
"end_at": "2019-05-24T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-25",
"start_at": "2019-05-24T22:00:00+00:00",
"end_at": "2019-05-25T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-26",
"start_at": "2019-05-25T22:00:00+00:00",
"end_at": "2019-05-26T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-27",
"start_at": "2019-05-26T22:00:00+00:00",
"end_at": "2019-05-27T21:59:59+00:00",
"status_id": "CLOSED",
"stock": 0,
},
{
"id": "2019-05-28",
"start_at": "2019-05-27T22:00:00+00:00",
"end_at": "2019-05-28T21:59:59+00:00",
"status_id": "CLOSED",
"stock": 0
},
{
"id": "2019-05-29",
"start_at": "2019-05-28T22:00:00+00:00",
"end_at": "2019-05-29T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-30",
"start_at": "2019-05-29T22:00:00+00:00",
"end_at": "2019-05-30T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
},
{
"id": "2019-05-31",
"start_at": "2019-05-30T22:00:00+00:00",
"end_at": "2019-05-31T21:59:59+00:00",
"status_id": "OPEN",
"stock": 288
}
]
Get all event calendar data by year, month and day.
Note: the time slot id can now be used on the create and update reservation end-point as property 'time_slot_id'
Type | Name | Description | Required | Example |
---|---|---|---|---|
Header | X-CM-PRODUCTTOKEN | The product token. | True | 00000000-0000-0000-0000-000000000000 |
Header | Content-Type | The content type which the application expects. | True | application/json |
Query Parameter | key | In some cases, an organiser wants to lock the ticket store. This can be done with our access key option. The end user has a key to unlock the ticket store. In the case the access keys are activated, the key needs to be send to our API. | False | KEY123 |
Path Variable | event_uuid | The UUID of an event can be retrieved from the Ticketing Dashboard. | True | 00000000-0000-0000-0000-000000000000 |
Path Variable | year | The year number of which you want to retrieve the calendar for. | True | 2020 |
Path Variable | month | The month number of which you want to retrieve the calendar for. | True | 01 |
Path Variable | day | The day number of which you want to retrieve the calendar for. | True | 31 |
Http status | Description | Example |
---|---|---|
200 | Successful operation | Time Slot Objects |
400 | Bad request | Info Message |
[
{
"id": "2019-05-01T10:00:00+00:00",
"start_at": "2019-05-01T10:00:00+00:00",
"end_at": "2019-05-01T10:30:00+00:00",
"status_id": "OPEN",
"stock": 16,
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"nl": "Regular",
"en": "Regular",
"fr": "Regular",
"de": "Regular"
}
}
]
},
{
"id": "2019-05-01T10:30:00+00:00",
"start_at": "2019-05-01T10:30:00+00:00",
"end_at": "2019-05-01T11:00:00+00:00",
"status_id": "OPEN",
"stock": 16,
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"nl": "Regular",
"en": "Regular",
"fr": "Regular",
"de": "Regular"
}
}
]
},
{
"id": "2019-05-01T11:00:00+00:00",
"start_at": "2019-05-01T11:00:00+00:00",
"end_at": "2019-05-01T11:30:00+00:00",
"status_id": "OPEN",
"stock": 16,
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"nl": "Regular",
"en": "Regular",
"fr": "Regular",
"de": "Regular"
}
}
]
},
{
"id": "2019-05-01T11:30:00+00:00",
"start_at": "2019-05-01T11:30:00+00:00",
"end_at": "2019-05-01T12:00:00+00:00",
"status_id": "OPEN",
"stock": 16,
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"nl": "Regular",
"en": "Regular",
"fr": "Regular",
"de": "Regular"
}
}
]
},
{
"id": "2019-05-01T12:00:00+00:00",
"start_at": "2019-05-01T12:00:00+00:00",
"end_at": "2019-05-01T12:30:00+00:00",
"status_id": "OPEN",
"stock": 16,
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"nl": "Regular",
"en": "Regular",
"fr": "Regular",
"de": "Regular"
}
}
]
},
{
"id": "2019-05-01T12:30:00+00:00",
"start_at": "2019-05-01T12:30:00+00:00",
"end_at": "2019-05-01T13:00:00+00:00",
"status_id": "OPEN",
"stock": 16,
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"nl": "Regular",
"en": "Regular",
"fr": "Regular",
"de": "Regular"
}
}
]
},
{
"id": "2019-05-01T13:00:00+00:00",
"start_at": "2019-05-01T13:00:00+00:00",
"end_at": "2019-05-01T13:30:00+00:00",
"status_id": "OPEN",
"stock": 16,
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"nl": "Regular",
"en": "Regular",
"fr": "Regular",
"de": "Regular"
}
}
]
},
{
"id": "2019-05-01T13:30:00+00:00",
"start_at": "2019-05-01T13:30:00+00:00",
"end_at": "2019-05-01T14:00:00+00:00",
"status_id": "OPEN",
"stock": 16,
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"nl": "Regular",
"en": "Regular",
"fr": "Regular",
"de": "Regular"
}
}
]
},
{
"id": "2019-05-01T14:00:00+00:00",
"start_at": "2019-05-01T14:00:00+00:00",
"end_at": "2019-05-01T14:30:00+00:00",
"status_id": "OPEN",
"stock": 16,
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"nl": "Regular",
"en": "Regular",
"fr": "Regular",
"de": "Regular"
}
}
]
},
{
"id": "2019-05-01T14:30:00+00:00",
"start_at": "2019-05-01T14:30:00+00:00",
"end_at": "2019-05-01T15:00:00+00:00",
"status_id": "OPEN",
"stock": 16,
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"nl": "Regular",
"en": "Regular",
"fr": "Regular",
"de": "Regular"
}
}
]
},
{
"id": "2019-05-01T15:00:00+00:00",
"start_at": "2019-05-01T15:00:00+00:00",
"end_at": "2019-05-01T15:30:00+00:00",
"status_id": "OPEN",
"stock": 16,
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"nl": "Regular",
"en": "Regular",
"fr": "Regular",
"de": "Regular"
}
}
]
}
]
At the start of an order a reservation is made. The reservation contains the number of products to be purchased + the details of the person who places the order.
After the user made a product selection (and a time slot selection) in the shop you can make a reservation.
The reservation consists of the product selection and the customer data entered by the user.
After an order is placed successfully you will receive an order ID which can be used for the checkout.
Create a new reservation for a specific event.
Type | Name | Description | Required | Example |
---|---|---|---|---|
Header | X-CM-PRODUCTTOKEN | The product token. | True | 00000000-0000-0000-0000-000000000000 |
Header | Content-Type | The content type which the application expects. | True | application/json |
Path Variable | event_uuid | The UUID of an event can be retrieved from the Ticketing Dashboard. | True | 00000000-0000-0000-0000-000000000000 |
Query Parameter | key | In some cases, an organiser wants to lock the ticket store. This can be done with our access key option. The end user has a key to unlock the ticket store. In the case the access keys are activated, the key needs to be send to our API. | False | KEY123 |
Query Parameter | code | In the case the discount codes are activated and used, the discount code needs to be send to our API. This can be done with a query parameter “code” in the URL. | False | DISCOUNT123 |
Body | Reservation Object | The reservation. | True | Reservation Object |
{
"order_id": null,
"due_at": null,
"time_slot_id" : null,
"customer_data": {
"uuid": null,
"first_name": "John",
"last_name": "Doe",
"email": "[email protected]",
"mobile": "+31612345678",
"gender": "M",
"address_line_1": null,
"address_line_1_building_number": null,
"address_line_2": null,
"address_line_2_building_number": null,
"zipcode": null,
"city": null,
"state": null,
"organisation_name": null,
"position_name": null,
"date_of_birth": null,
"custom_field_1": null,
"custom_field_2": null,
"custom_field_3": null,
"created_at": null,
"updated_at": null,
"country_id": "NL"
},
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"amount": 1
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"amount": 5
}
]
}
Http status | Description | Example |
---|---|---|
201 | Successful operation | Reservation Object |
400 | Bad request | Info Message |
{
"order_id": "CMTICKETS123XX",
"due_at": "2018-12-24T13:34:07+00:00",
"customer_data": {
"uuid": "00000000-0000-0000-0000-000000000000",
"first_name": "John",
"last_name": "Doe",
"email": "[email protected]",
"mobile": "+31612345678",
"gender": "M",
"address_line_1": null,
"address_line_2": null,
"zipcode": null,
"city": null,
"state": null,
"organisation_name": null,
"position_name": null,
"date_of_birth": null,
"custom_field_1": null,
"custom_field_2": null,
"custom_field_3": null,
"created_at": null,
"updated_at": null,
"country_id": "NL"
},
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"amount": 1
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"amount": 5
}
]
}
Update a reservation for a specific event.
Type | Name | Description | Required | Example |
---|---|---|---|---|
Header | X-CM-PRODUCTTOKEN | The product token. | True | 00000000-0000-0000-0000-000000000000 |
Header | Content-Type | The content type which the application expects. | True | application/json |
Path Variable | event_uuid | The UUID of an event can be retrieved from the Ticketing Dashboard. | True | 00000000-0000-0000-0000-000000000000 |
Path Variable | order_id | The order_id which is returned in the response body of the post reservation call. | True | CMTICKETS123XX |
Query Parameter | key | In some cases, an organiser wants to lock the ticket store. This can be done with our access key option. The end user has a key to unlock the ticket store. In the case the access keys are activated, the key needs to be send to our API. | False | KEY123 |
Body | Reservation Object | The reservation. | True | Reservation Object |
{
"time_slot_id" : null,
"order_id": "CMTICKETS123XX",
"due_at": "2018-12-24T13:34:07+00:00",
"customer_data": {
"uuid": "00000000-0000-0000-0000-000000000000",
"first_name": "John",
"last_name": "Doe",
"email": "[email protected]",
"mobile": "+31612345678",
"gender": "M",
"address_line_1": null,
"address_line_2": null,
"zipcode": null,
"city": null,
"state": null,
"organisation_name": null,
"position_name": null,
"date_of_birth": null,
"custom_field_1": null,
"custom_field_2": null,
"custom_field_3": null,
"created_at": null,
"updated_at": null,
"country_id": "NL"
},
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"amount": 1
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"amount": 5
}
]
}
Http status | Description | Example |
---|---|---|
200 | Successful operation | Reservation Object |
400 | Bad request | Info Message |
{
"order_id": "CMTICKETS123XX",
"due_at": "2018-12-24T13:34:07+00:00",
"time_slot_id" : null,
"customer_data": {
"uuid": "00000000-0000-0000-0000-000000000000",
"first_name": "John",
"last_name": "Doe",
"email": "[email protected]",
"mobile": "+31612345678",
"gender": "M",
"address_line_1": null,
"address_line_1_building_number": null,
"address_line_2": null,
"address_line_2_building_number": null,
"zipcode": null,
"city": null,
"state": null,
"organisation_name": null,
"position_name": null,
"date_of_birth": null,
"custom_field_1": null,
"custom_field_2": null,
"custom_field_3": null,
"created_at": null,
"updated_at": null,
"country_id": "NL"
},
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"amount": 1
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"amount": 5
}
]
}
This request creates a completed order. The reservation contains the number of products to be purchased + the details of the person who places the order.
The reservation consists of the product selection and the customer data entered by the user.
This order requires ticket types that have a price of 0.00 and will automatically complete the reservation.
Create a new free reservation for a specific event.
POST https://api.cm.com/ticketingapi/v2.0/ticketshop/events/{event_uuid}/reservations/generate
Type | Name | Description | Required | Example |
---|---|---|---|---|
Header | X-CM-PRODUCTTOKEN | The product token. | True | 00000000-0000-0000-0000-000000000000 |
Header | Content-Type | The content type which the application expects. | True | application/json |
Path Variable | event_uuid | The UUID of an event can be retrieved from the Ticketing Dashboard. | True | 00000000-0000-0000-0000-000000000000 |
Body | Reservation Object | The reservation. | True | Reservation Object |
{
"customer_data": {
"first_name": "John",
"last_name": "Doe",
"email": "[email protected]",
"mobile": "+31612345678",
"gender": "M",
"address_line_1": null,
"address_line_1_building_number": null,
"address_line_2": null,
"address_line_2_building_number": null,
"zipcode": null,
"city": null,
"state": null,
"organisation_name": null,
"position_name": null,
"date_of_birth": null,
"custom_field_1": null,
"custom_field_2": null,
"custom_field_3": null,
"created_at": null,
"updated_at": null,
"country_id": "NL"
},
"ticket_types": [
{
"uuid": "00000000-0000-0000-0000-000000000000",
"amount": 1
},
{
"uuid": "00000000-0000-0000-0000-000000000000",
"amount": 5
}
]
}
Http status | Description | Example |
---|---|---|
201 | Successful operation | Reservation Object |
400 | Bad request | Info Message |
{
"order_id" : "CMTICKETS123XX",
"order_uuid": "00000000-0000-0000-0000-000000000000",
"customer_data_uuid": "00000000-0000-0000-0000-000000000000",
"download_url": "https://order.cmtickets.com/0000000000/00000000-0000-0000-0000-000000000000/00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"barcodes": [
{
"barcode_id": "CMBR123AAAA",
"type": "QRCODE",
"ticket_type_uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"en": "Ticket Name",
"nl": "Ticketnaam",
"fr": "Nom du ticket",
"de": "Ticketname"
},
"subtitle": {
"en": "",
"nl": "",
"fr": "",
"de": ""
}
},
{
"barcode_id": "CMBR123AAAA",
"type": "QRCODE",
"ticket_type_uuid": "00000000-0000-0000-0000-000000000000",
"name": {
"en": "Ticket Name",
"nl": "Ticketnaam",
"fr": "Nom du ticket",
"de": "Ticketname"
},
"subtitle": {
"en": "",
"nl": "",
"fr": "",
"de": ""
}
}
]
}
The checkout handles the payment of the order. This endpoint returns a payment URL where customer can pay for the order.
Create a checkout/payment for a reservation, so you can finish the order.
Type | Name | Description | Required | Example |
---|---|---|---|---|
Header | X-CM-PRODUCTTOKEN | The product token. | True | 00000000-0000-0000-0000-000000000000 |
Header | Content-Type | The content type which the application expects. | True | application/json |
Path Variable | event_uuid | The UUID of an event can be retrieved from the Ticketing Dashboard. | True | 00000000-0000-0000-0000-000000000000 |
Path Variable | order_id | The id of an reservation can be retrieved from the create reservation end-point. | True | CMTICKETS123XX |
Query Parameter | key | In some cases, an organiser wants to lock the ticket store. This can be done with our access key option. The end user has a key to unlock the ticket store. In the case the access keys are activated, the key needs to be send to our API. | False | KEY123 |
Body | Checkout Object | The checkout to make (JSON object.) | True | Checkout Object |
{
"order_id": "CMTICKETS123XX",
"payment_method_uuid": "00000000-0000-0000-0000-000000000000",
"ideal_issuer_id": "ABNANL2A",
"callback_urls": {
"success_url": "https://cm.com/success",
"failed_url": "https://cm.com/failed",
"cancelled_url": "https://cm.com/cancelled",
"expired_url": "https://cm.com/expired"
}
}
Http status | Description | Example |
---|---|---|
201 | Successful operation | Checkout Confirmation Object |
400 | Bad request | Info Message |
{
"order_id": "CMTICKETS123XX",
"due_at": "2020-01-31T23:59:59+00:00",
"status" : "OPEN",
"redirect_url": "https://cm.com/payment"
}