NAV Navbar
curl PHP Ruby Python

Ticket Tailor API

Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

Whether it's your first event ever, or your biggest event yet, Ticket Tailor makes it simple to sell tickets online.

Getting started

Conventions

Sign up

If you haven't already, create a Ticket Tailor account. When prompted, fill out details to create a box office. Api keys are associated to the box office, meaning an api key can only access data from the box office that issued it.

Authentication

  # We only added a colon at the end of the API key
  # because we do not need to add a password.
  curl -X GET https://api.tickettailor.com/v1/orders \
    -H 'Accept: application/json' \
    -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'


  <?php
  // Example using Guzzle
  $headers = [
      'Accept' => 'application/json',
  ];

  // The second item of the array for the auth option
  // is empty because we do not need to add a password.
  $client = new \GuzzleHttp\Client([
      'auth' => [
          'sk_1000_1000_VGlja2V0VGFpbG9y',
          ''
      ]
  ]);

  try {
      $response = $client->request(
          'GET','https://api.tickettailor.com/v1/orders',
          [
              'headers' => $headers,
          ]
      );
      print_r($response->getBody()->getContents());
  }
  catch (\GuzzleHttp\Exception\BadResponseException $e) {
      // Handle exception or api errors.
      print_r($e->getMessage());
  }


    <?php
    // Example using cURL

    // We only added a colon at the end of the API key
    // because we do not need to add a password.
    $curlHandler = curl_init();
    curl_setopt($curlHandler, CURLOPT_URL, 'https://api.tickettailor.com/v1/orders');
    curl_setopt($curlHandler, CURLOPT_USERPWD, 'sk_1000_1000_VGlja2V0VGFpbG9y:');
    $result = curl_exec($curlHandler);
    curl_close($curlHandler);

require 'rest-client'
require 'json'
headers = {
 'Accept' => 'application/json'
}
# The third parameter is an empty string because we do not need to add a password.
resource = RestClient::Resource.new('https://api.tickettailor.com/v1/orders', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' ) response = resource.get(:headers => headers)
parsedResponse = JSON.parse(response)
import requests
headers = {
  'Accept': 'application/json'
}
# The second parameter in the auth option is an empty string because we do not need to add a password.
response = requests.get('https://my.website.com/rest/path', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)
print response.json()

The Ticket Tailor API uses API keys to authenticate requests. You can manage your API keys in your box office settings. Authentication to the API is performed via HTTP Basic Auth. Provide your API key as the basic auth username. You do not need to provide a password.

Event series

List event series

Code samples

# You can also use wget
curl -X GET /v1/event_series \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/event_series', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/event_series', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/event_series', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/event_series

Returns all paginated event series

Parameters

Name In Type Required Description
created_at query integer false Unix timestamp filter that returns items with matched created_at value.
created_at.gt query integer false Unix timestamp filter that returns items with created_at greater than given value.
created_at.gte query integer false Unix timestamp filter that returns items with created_at greater than or equal given value.
created_at.lt query integer false Unix timestamp filter that returns items with created_at less than given value.
created_at.lte query integer false Unix timestamp filter that returns items with created_at less than or equal given value.
limit query string false The number of items to retrieve

Example responses

200 Response

{
  "data": [
    {
      "object": "event_series",
      "id": "es_1",
      "access_code": null,
      "call_to_action": "Buy tickets / Join the guestlist",
      "currency": "gbp",
      "default_ticket_groups": [
        {
          "id": "tg_21099",
          "max_per_order": null,
          "name": "April 20th",
          "sort_order": 50050,
          "ticket_ids": [
            "tt_230625",
            "tt_230626"
          ]
        },
        {
          "id": "tg_21100",
          "max_per_order": null,
          "name": "April 21st",
          "sort_order": 50100,
          "ticket_ids": [
            "tt_230631",
            "tt_230632"
          ]
        }
      ],
      "default_ticket_types": [
        {
          "object": "ticket_type",
          "id": "tt_230625",
          "access_code": null,
          "booking_fee": 0,
          "description": null,
          "group_id": "tg_21099",
          "max_per_order": 100,
          "min_per_order": 1,
          "name": "4.20 Adult (13-61) - Presale",
          "price": 800,
          "status": "hidden",
          "sort_order": 50050,
          "type": "paid",
          "quantity": 10000,
          "quantity_held": 0,
          "quantity_issued": 5000,
          "quantity_total": 15000
        },
        {
          "object": "ticket_type",
          "id": "tt_230626",
          "access_code": null,
          "booking_fee": 0,
          "description": null,
          "group_id": "tg_21099",
          "max_per_order": 100,
          "min_per_order": 1,
          "name": "4.20 Senior (62+) - Presale",
          "price": 600,
          "status": "on_sale",
          "sort_order": 50051,
          "type": "paid",
          "quantity": 10000,
          "quantity_held": 0,
          "quantity_issued": 2000,
          "quantity_total": 12000
        },
        {
          "object": "ticket_type",
          "id": "tt_230631",
          "access_code": null,
          "booking_fee": 0,
          "description": null,
          "group_id": "tg_21100",
          "max_per_order": 100,
          "min_per_order": 1,
          "name": "4.21 Adult (13-61) - Presale",
          "price": 800,
          "status": "on_sale",
          "sort_order": 50100,
          "type": "paid",
          "quantity": 10000,
          "quantity_held": 0,
          "quantity_issued": 4000,
          "quantity_total": 14000
        },
        {
          "object": "ticket_type",
          "id": "tt_230632",
          "access_code": null,
          "booking_fee": 0,
          "description": null,
          "group_id": "tg_21100",
          "max_per_order": 100,
          "min_per_order": 1,
          "name": "4.21 Senior (62+) - Presale",
          "price": 600,
          "status": "on_sale",
          "sort_order": 50101,
          "type": "paid",
          "quantity": 10000,
          "quantity_held": 0,
          "quantity_issued": 1000,
          "quantity_total": 11000
        }
      ],
      "description": null,
      "images": {
        "header": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,g_center,h_326,q_85,w_1024/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg",
        "thumbnail": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,h_108,q_85,w_108/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg"
      },
      "name": "Hackney Downs 2020 Tulip Festival",
      "next_occurrence_date": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "online_event": "false",
      "payment_methods": [
        {
          "external_id": null,
          "id": "pm_6687",
          "instructions": "Pay when you arrive to festival",
          "name": "Pay on the door",
          "type": "offline"
        },
        {
          "external_id": "seller222@example.com",
          "id": "pm_6691",
          "instructions": null,
          "name": null,
          "type": "paypal"
        }
      ],
      "private": "false",
      "status": "published",
      "timezone": "Europe/London",
      "total_occurrences": 20,
      "upcoming_occurrences": 5,
      "url": "https://www.tickettailor.com/events/flowerfestival/40980",
      "venue": {
        "name": "Flower festival gardens",
        "postal_code": "SW1 3BR"
      },
      "voucher_ids": [
        "vo_123",
        "vo_345",
        "vo_567"
      ]
    }
  ],
  "links": {
    "next": "/v1/event_series?starting_after=es_120",
    "previous": "/v1/event_series?ending_before=es_100"
  }
}

Response Schema

Status Code 200

Name Type Description
» data [EventSeries] none
»» object string none
»» id string A unique identifier for the event series
»» access_code string¦null Code to access a protected event series
»» call_to_action string Call to action text used on the event series page
»» created_at object Date and time when the event series were created
»»» date string ISO-8601 date for the end of the event
»»» formatted string A formatted date string for the end of the event
»»» iso string ISO-8601 date and time for the end of the event
»»» time string Time of the end of the event
»»» timezone string Timezone offset for the end of the event
»»» unix integer Unix timestamp for for the end of the event
»» currency string Information about the currency the event series is configured to use
»» default_ticket_groups [any] Ticket groups that are not overridden
»»» id string A unique ticket group identifier
»»» max_per_order integer Maximum number of ticket types that this group can sell
»»» name string Name of the ticket types group
»»» sort_order integer Sort index of the group in the UI
»»» ticket_ids [any] Unique identifiers of ticket type ids that belong to this group
»»»» id string none
»» default_ticket_types [TicketType]¦null Ticket types that are not overridden
»»» object string none
»»» id string A unique identifier for the ticket type
»»» access_code string¦null Code to access a hidden ticket
»»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»»» description string¦null none
»»» group_id string¦null ID of the group this ticket type belongs to
»»» has_overrides string Specifies whether the ticket type has overrides
»»» max_per_order integer Maximum number of ticket types you can select per order
»»» min_per_order integer Minimum number of ticket types you can select per order
»»» name string Name of the ticket type
»»» override_id string¦null The ID of the override associated with the ticket type
»»» price any Cost of the ticket type

anyOf

Name Type Description
»»»» anonymous integer none

or

Name Type Description
»»»» anonymous number none

continued

Name Type Description
»»» status string Status of the ticket type
»»» sort_order integer Sort index of ticket type in the UI
»»» type string none
»»» quantity integer Number available for purchase
»»» quantity_held integer Number held
»»» quantity_issued integer Number issued
»»» quantity_total integer Total number including issued and still available
»» description string¦null Description of the event series
»» images object Imagages that have been uploaded to this event series
»»» header string Image URL of the header image used on the event series page
»»» thumbnail string Image URL of the thumbnail used on the event series page
»» name string Name of the event series
»» next_occurrence_date object Date and time when the next event in the series happens
»»» date string ISO-8601 date for the end of the event
»»» formatted string A formatted date string for the end of the event
»»» iso string ISO-8601 date and time for the end of the event
»»» time string Time of the end of the event
»»» timezone string Timezone offset for the end of the event
»»» unix integer Unix timestamp for for the end of the event
»» online_event string Returns whether or not the event is online
»» payment_methods [any] An array of payment methods
»»» external_id string A unique identifier for the payment method
»»» id string A unique identifier for internal payment methods
»»» type string The type of payment method
»»» name string Name of the payment method
»»» instructions string Instructions for the customer on how to pay. Used for offline payments.
»» private string Returns whether or not the event is private
»» status string Status of the event
»» timezone string TZ format timezone string
»» total_occurrences integer Total number of time the event series occurs
»» upcoming_occurrences integer The number of upcoming occurrences of the event series
»» url string Event series URL
»» venue object none
»»» name string Name of the venue
»»» postal_code string Postal code of the venue
»» voucher_ids [string] List of voucher IDs
» links object none
»» next string¦null none
»» previous string¦null none

Enumerated Values

Property Value
currency gbp
currency usd
currency eur
currency sgd
currency aud
currency brl
currency cad
currency czk
currency dkk
currency hkd
currency huf
currency ils
currency jpy
currency myr
currency mxn
currency nok
currency nzd
currency php
currency pln
currency rub
currency sek
currency chf
currency twd
currency thb
currency try
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free
online_event true
online_event false
type stripe
type paypal
type offline
private true
private false
status draft
status published
status sales_closed

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Create an event series

Code samples

# You can also use wget
curl -X POST /v1/event_series \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/event_series', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/event_series', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/event_series', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/event_series

Creates a new event series

Body parameter

currency: gbp
description: null
name: Hackney Downs 2020 Tulip Festival
postal_code: SW1 3BR
venue: Hackney Downs gardens
voucher_ids:
  - vo_123
  - vo_345

Parameters

Name In Type Required Description
body body object true none
» currency body string false Information about the currency the event series is configured to use
» description body string¦null false Description of the event series
» name body string true Name of the event series
» postal_code body string false Event series postal code
» venue body string false Venue name
» voucher_ids body [string] false List of applicable voucher IDs

Enumerated Values

Parameter Value
» currency gbp
» currency usd
» currency eur
» currency sgd
» currency aud
» currency brl
» currency cad
» currency czk
» currency dkk
» currency hkd
» currency huf
» currency ils
» currency jpy
» currency myr
» currency mxn
» currency nok
» currency nzd
» currency php
» currency pln
» currency rub
» currency sek
» currency chf
» currency twd
» currency thb
» currency try

Example responses

201 Response

{
  "object": "event_series",
  "id": "es_1",
  "access_code": null,
  "call_to_action": "Buy tickets / Join the guestlist",
  "currency": "gbp",
  "default_ticket_groups": [
    {
      "id": "tg_21099",
      "max_per_order": null,
      "name": "April 20th",
      "sort_order": 50050,
      "ticket_ids": [
        "tt_230625",
        "tt_230626"
      ]
    },
    {
      "id": "tg_21100",
      "max_per_order": null,
      "name": "April 21st",
      "sort_order": 50100,
      "ticket_ids": [
        "tt_230631",
        "tt_230632"
      ]
    }
  ],
  "default_ticket_types": [
    {
      "object": "ticket_type",
      "id": "tt_230625",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Adult (13-61) - Presale",
      "price": 800,
      "status": "hidden",
      "sort_order": 50050,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 5000,
      "quantity_total": 15000
    },
    {
      "object": "ticket_type",
      "id": "tt_230626",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50051,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 2000,
      "quantity_total": 12000
    },
    {
      "object": "ticket_type",
      "id": "tt_230631",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21100",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.21 Adult (13-61) - Presale",
      "price": 800,
      "status": "on_sale",
      "sort_order": 50100,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 4000,
      "quantity_total": 14000
    },
    {
      "object": "ticket_type",
      "id": "tt_230632",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21100",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.21 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50101,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 1000,
      "quantity_total": 11000
    }
  ],
  "description": null,
  "images": {
    "header": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,g_center,h_326,q_85,w_1024/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg",
    "thumbnail": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,h_108,q_85,w_108/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg"
  },
  "name": "Hackney Downs 2020 Tulip Festival",
  "next_occurrence_date": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "online_event": "false",
  "payment_methods": [
    {
      "external_id": null,
      "id": "pm_6687",
      "instructions": "Pay when you arrive to festival",
      "name": "Pay on the door",
      "type": "offline"
    },
    {
      "external_id": "seller222@example.com",
      "id": "pm_6691",
      "instructions": null,
      "name": null,
      "type": "paypal"
    }
  ],
  "private": "false",
  "status": "published",
  "timezone": "Europe/London",
  "total_occurrences": 20,
  "upcoming_occurrences": 5,
  "url": "https://www.tickettailor.com/events/flowerfestival/40980",
  "venue": {
    "name": "Flower festival gardens",
    "postal_code": "SW1 3BR"
  },
  "voucher_ids": [
    "vo_123",
    "vo_345",
    "vo_567"
  ]
}

Response Schema

Status Code 201

Name Type Description
» object string none
» id string A unique identifier for the event series
» access_code string¦null Code to access a protected event series
» call_to_action string Call to action text used on the event series page
» created_at object Date and time when the event series were created
»» date string ISO-8601 date for the end of the event
»» formatted string A formatted date string for the end of the event
»» iso string ISO-8601 date and time for the end of the event
»» time string Time of the end of the event
»» timezone string Timezone offset for the end of the event
»» unix integer Unix timestamp for for the end of the event
» currency string Information about the currency the event series is configured to use
» default_ticket_groups [any] Ticket groups that are not overridden
»» id string A unique ticket group identifier
»» max_per_order integer Maximum number of ticket types that this group can sell
»» name string Name of the ticket types group
»» sort_order integer Sort index of the group in the UI
»» ticket_ids [any] Unique identifiers of ticket type ids that belong to this group
»»» id string none
» default_ticket_types [TicketType]¦null Ticket types that are not overridden
»» object string none
»» id string A unique identifier for the ticket type
»» access_code string¦null Code to access a hidden ticket
»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»» description string¦null none
»» group_id string¦null ID of the group this ticket type belongs to
»» has_overrides string Specifies whether the ticket type has overrides
»» max_per_order integer Maximum number of ticket types you can select per order
»» min_per_order integer Minimum number of ticket types you can select per order
»» name string Name of the ticket type
»» override_id string¦null The ID of the override associated with the ticket type
»» price any Cost of the ticket type

anyOf

Name Type Description
»»» anonymous integer none

or

Name Type Description
»»» anonymous number none

continued

Name Type Description
»» status string Status of the ticket type
»» sort_order integer Sort index of ticket type in the UI
»» type string none
»» quantity integer Number available for purchase
»» quantity_held integer Number held
»» quantity_issued integer Number issued
»» quantity_total integer Total number including issued and still available
» description string¦null Description of the event series
» images object Imagages that have been uploaded to this event series
»» header string Image URL of the header image used on the event series page
»» thumbnail string Image URL of the thumbnail used on the event series page
» name string Name of the event series
» next_occurrence_date object Date and time when the next event in the series happens
»» date string ISO-8601 date for the end of the event
»» formatted string A formatted date string for the end of the event
»» iso string ISO-8601 date and time for the end of the event
»» time string Time of the end of the event
»» timezone string Timezone offset for the end of the event
»» unix integer Unix timestamp for for the end of the event
» online_event string Returns whether or not the event is online
» payment_methods [any] An array of payment methods
»» external_id string A unique identifier for the payment method
»» id string A unique identifier for internal payment methods
»» type string The type of payment method
»» name string Name of the payment method
»» instructions string Instructions for the customer on how to pay. Used for offline payments.
» private string Returns whether or not the event is private
» status string Status of the event
» timezone string TZ format timezone string
» total_occurrences integer Total number of time the event series occurs
» upcoming_occurrences integer The number of upcoming occurrences of the event series
» url string Event series URL
» venue object none
»» name string Name of the venue
»» postal_code string Postal code of the venue
» voucher_ids [string] List of voucher IDs

Enumerated Values

Property Value
currency gbp
currency usd
currency eur
currency sgd
currency aud
currency brl
currency cad
currency czk
currency dkk
currency hkd
currency huf
currency ils
currency jpy
currency myr
currency mxn
currency nok
currency nzd
currency php
currency pln
currency rub
currency sek
currency chf
currency twd
currency thb
currency try
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free
online_event true
online_event false
type stripe
type paypal
type offline
private true
private false
status draft
status published
status sales_closed

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Get a single event series

Code samples

# You can also use wget
curl -X GET /v1/event_series/{event_series_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/event_series/{event_series_id}', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/event_series/{event_series_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/event_series/{event_series_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/event_series/{event_series_id}

Returns existing event series by ID

Parameters

Name In Type Required Description
event_series_id path string true The unique identifier for the existing event series

Example responses

200 Response

{
  "object": "event_series",
  "id": "es_1",
  "access_code": null,
  "call_to_action": "Buy tickets / Join the guestlist",
  "currency": "gbp",
  "default_ticket_groups": [
    {
      "id": "tg_21099",
      "max_per_order": null,
      "name": "April 20th",
      "sort_order": 50050,
      "ticket_ids": [
        "tt_230625",
        "tt_230626"
      ]
    },
    {
      "id": "tg_21100",
      "max_per_order": null,
      "name": "April 21st",
      "sort_order": 50100,
      "ticket_ids": [
        "tt_230631",
        "tt_230632"
      ]
    }
  ],
  "default_ticket_types": [
    {
      "object": "ticket_type",
      "id": "tt_230625",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Adult (13-61) - Presale",
      "price": 800,
      "status": "hidden",
      "sort_order": 50050,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 5000,
      "quantity_total": 15000
    },
    {
      "object": "ticket_type",
      "id": "tt_230626",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50051,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 2000,
      "quantity_total": 12000
    },
    {
      "object": "ticket_type",
      "id": "tt_230631",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21100",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.21 Adult (13-61) - Presale",
      "price": 800,
      "status": "on_sale",
      "sort_order": 50100,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 4000,
      "quantity_total": 14000
    },
    {
      "object": "ticket_type",
      "id": "tt_230632",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21100",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.21 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50101,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 1000,
      "quantity_total": 11000
    }
  ],
  "description": null,
  "images": {
    "header": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,g_center,h_326,q_85,w_1024/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg",
    "thumbnail": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,h_108,q_85,w_108/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg"
  },
  "name": "Hackney Downs 2020 Tulip Festival",
  "next_occurrence_date": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "online_event": "false",
  "payment_methods": [
    {
      "external_id": null,
      "id": "pm_6687",
      "instructions": "Pay when you arrive to festival",
      "name": "Pay on the door",
      "type": "offline"
    },
    {
      "external_id": "seller222@example.com",
      "id": "pm_6691",
      "instructions": null,
      "name": null,
      "type": "paypal"
    }
  ],
  "private": "false",
  "status": "published",
  "timezone": "Europe/London",
  "total_occurrences": 20,
  "upcoming_occurrences": 5,
  "url": "https://www.tickettailor.com/events/flowerfestival/40980",
  "venue": {
    "name": "Flower festival gardens",
    "postal_code": "SW1 3BR"
  },
  "voucher_ids": [
    "vo_123",
    "vo_345",
    "vo_567"
  ]
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the event series
» access_code string¦null Code to access a protected event series
» call_to_action string Call to action text used on the event series page
» created_at object Date and time when the event series were created
»» date string ISO-8601 date for the end of the event
»» formatted string A formatted date string for the end of the event
»» iso string ISO-8601 date and time for the end of the event
»» time string Time of the end of the event
»» timezone string Timezone offset for the end of the event
»» unix integer Unix timestamp for for the end of the event
» currency string Information about the currency the event series is configured to use
» default_ticket_groups [any] Ticket groups that are not overridden
»» id string A unique ticket group identifier
»» max_per_order integer Maximum number of ticket types that this group can sell
»» name string Name of the ticket types group
»» sort_order integer Sort index of the group in the UI
»» ticket_ids [any] Unique identifiers of ticket type ids that belong to this group
»»» id string none
» default_ticket_types [TicketType]¦null Ticket types that are not overridden
»» object string none
»» id string A unique identifier for the ticket type
»» access_code string¦null Code to access a hidden ticket
»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»» description string¦null none
»» group_id string¦null ID of the group this ticket type belongs to
»» has_overrides string Specifies whether the ticket type has overrides
»» max_per_order integer Maximum number of ticket types you can select per order
»» min_per_order integer Minimum number of ticket types you can select per order
»» name string Name of the ticket type
»» override_id string¦null The ID of the override associated with the ticket type
»» price any Cost of the ticket type

anyOf

Name Type Description
»»» anonymous integer none

or

Name Type Description
»»» anonymous number none

continued

Name Type Description
»» status string Status of the ticket type
»» sort_order integer Sort index of ticket type in the UI
»» type string none
»» quantity integer Number available for purchase
»» quantity_held integer Number held
»» quantity_issued integer Number issued
»» quantity_total integer Total number including issued and still available
» description string¦null Description of the event series
» images object Imagages that have been uploaded to this event series
»» header string Image URL of the header image used on the event series page
»» thumbnail string Image URL of the thumbnail used on the event series page
» name string Name of the event series
» next_occurrence_date object Date and time when the next event in the series happens
»» date string ISO-8601 date for the end of the event
»» formatted string A formatted date string for the end of the event
»» iso string ISO-8601 date and time for the end of the event
»» time string Time of the end of the event
»» timezone string Timezone offset for the end of the event
»» unix integer Unix timestamp for for the end of the event
» online_event string Returns whether or not the event is online
» payment_methods [any] An array of payment methods
»» external_id string A unique identifier for the payment method
»» id string A unique identifier for internal payment methods
»» type string The type of payment method
»» name string Name of the payment method
»» instructions string Instructions for the customer on how to pay. Used for offline payments.
» private string Returns whether or not the event is private
» status string Status of the event
» timezone string TZ format timezone string
» total_occurrences integer Total number of time the event series occurs
» upcoming_occurrences integer The number of upcoming occurrences of the event series
» url string Event series URL
» venue object none
»» name string Name of the venue
»» postal_code string Postal code of the venue
» voucher_ids [string] List of voucher IDs

Enumerated Values

Property Value
currency gbp
currency usd
currency eur
currency sgd
currency aud
currency brl
currency cad
currency czk
currency dkk
currency hkd
currency huf
currency ils
currency jpy
currency myr
currency mxn
currency nok
currency nzd
currency php
currency pln
currency rub
currency sek
currency chf
currency twd
currency thb
currency try
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free
online_event true
online_event false
type stripe
type paypal
type offline
private true
private false
status draft
status published
status sales_closed

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Update an event series

Code samples

# You can also use wget
curl -X POST /v1/event_series/{event_series_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/event_series/{event_series_id}', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/event_series/{event_series_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/event_series/{event_series_id}', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/event_series/{event_series_id}

Updates an existing event series

Body parameter

call_to_action: Buy tickets / Join the guestlist
currency: gbp
description: Event series description
name: Event series name
postal_code: SW1 3XY
venue: Test venue name
voucher_ids:
  - vo_123
  - vo_345
  - vo_567

Parameters

Name In Type Required Description
event_series_id path string true The unique identifier for event series
body body object false none
» call_to_action body string false Call to action text used on the event series page
» currency body string¦null false Information about the currency the event series is configured to use
» description body string¦null false Description of the event series
» name body string¦null false Name of the event series
» postal_code body string¦null false Postal code of the venue
» venue body string¦null false Name of the venue
» voucher_ids body [string]¦null false List of voucher ids

Enumerated Values

Parameter Value
» currency gbp
» currency usd
» currency eur
» currency sgd
» currency aud
» currency brl
» currency cad
» currency czk
» currency dkk
» currency hkd
» currency huf
» currency ils
» currency jpy
» currency myr
» currency mxn
» currency nok
» currency nzd
» currency php
» currency pln
» currency rub
» currency sek
» currency chf
» currency twd
» currency thb
» currency try

Example responses

200 Response

{
  "object": "event_series",
  "id": "es_1",
  "access_code": null,
  "call_to_action": "Buy tickets / Join the guestlist",
  "currency": "gbp",
  "default_ticket_groups": [
    {
      "id": "tg_21099",
      "max_per_order": null,
      "name": "April 20th",
      "sort_order": 50050,
      "ticket_ids": [
        "tt_230625",
        "tt_230626"
      ]
    },
    {
      "id": "tg_21100",
      "max_per_order": null,
      "name": "April 21st",
      "sort_order": 50100,
      "ticket_ids": [
        "tt_230631",
        "tt_230632"
      ]
    }
  ],
  "default_ticket_types": [
    {
      "object": "ticket_type",
      "id": "tt_230625",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Adult (13-61) - Presale",
      "price": 800,
      "status": "hidden",
      "sort_order": 50050,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 5000,
      "quantity_total": 15000
    },
    {
      "object": "ticket_type",
      "id": "tt_230626",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50051,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 2000,
      "quantity_total": 12000
    },
    {
      "object": "ticket_type",
      "id": "tt_230631",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21100",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.21 Adult (13-61) - Presale",
      "price": 800,
      "status": "on_sale",
      "sort_order": 50100,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 4000,
      "quantity_total": 14000
    },
    {
      "object": "ticket_type",
      "id": "tt_230632",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21100",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.21 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50101,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 1000,
      "quantity_total": 11000
    }
  ],
  "description": null,
  "images": {
    "header": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,g_center,h_326,q_85,w_1024/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg",
    "thumbnail": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,h_108,q_85,w_108/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg"
  },
  "name": "Hackney Downs 2020 Tulip Festival",
  "next_occurrence_date": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "online_event": "false",
  "payment_methods": [
    {
      "external_id": null,
      "id": "pm_6687",
      "instructions": "Pay when you arrive to festival",
      "name": "Pay on the door",
      "type": "offline"
    },
    {
      "external_id": "seller222@example.com",
      "id": "pm_6691",
      "instructions": null,
      "name": null,
      "type": "paypal"
    }
  ],
  "private": "false",
  "status": "published",
  "timezone": "Europe/London",
  "total_occurrences": 20,
  "upcoming_occurrences": 5,
  "url": "https://www.tickettailor.com/events/flowerfestival/40980",
  "venue": {
    "name": "Flower festival gardens",
    "postal_code": "SW1 3BR"
  },
  "voucher_ids": [
    "vo_123",
    "vo_345",
    "vo_567"
  ]
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the event series
» access_code string¦null Code to access a protected event series
» call_to_action string Call to action text used on the event series page
» created_at object Date and time when the event series were created
»» date string ISO-8601 date for the end of the event
»» formatted string A formatted date string for the end of the event
»» iso string ISO-8601 date and time for the end of the event
»» time string Time of the end of the event
»» timezone string Timezone offset for the end of the event
»» unix integer Unix timestamp for for the end of the event
» currency string Information about the currency the event series is configured to use
» default_ticket_groups [any] Ticket groups that are not overridden
»» id string A unique ticket group identifier
»» max_per_order integer Maximum number of ticket types that this group can sell
»» name string Name of the ticket types group
»» sort_order integer Sort index of the group in the UI
»» ticket_ids [any] Unique identifiers of ticket type ids that belong to this group
»»» id string none
» default_ticket_types [TicketType]¦null Ticket types that are not overridden
»» object string none
»» id string A unique identifier for the ticket type
»» access_code string¦null Code to access a hidden ticket
»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»» description string¦null none
»» group_id string¦null ID of the group this ticket type belongs to
»» has_overrides string Specifies whether the ticket type has overrides
»» max_per_order integer Maximum number of ticket types you can select per order
»» min_per_order integer Minimum number of ticket types you can select per order
»» name string Name of the ticket type
»» override_id string¦null The ID of the override associated with the ticket type
»» price any Cost of the ticket type

anyOf

Name Type Description
»»» anonymous integer none

or

Name Type Description
»»» anonymous number none

continued

Name Type Description
»» status string Status of the ticket type
»» sort_order integer Sort index of ticket type in the UI
»» type string none
»» quantity integer Number available for purchase
»» quantity_held integer Number held
»» quantity_issued integer Number issued
»» quantity_total integer Total number including issued and still available
» description string¦null Description of the event series
» images object Imagages that have been uploaded to this event series
»» header string Image URL of the header image used on the event series page
»» thumbnail string Image URL of the thumbnail used on the event series page
» name string Name of the event series
» next_occurrence_date object Date and time when the next event in the series happens
»» date string ISO-8601 date for the end of the event
»» formatted string A formatted date string for the end of the event
»» iso string ISO-8601 date and time for the end of the event
»» time string Time of the end of the event
»» timezone string Timezone offset for the end of the event
»» unix integer Unix timestamp for for the end of the event
» online_event string Returns whether or not the event is online
» payment_methods [any] An array of payment methods
»» external_id string A unique identifier for the payment method
»» id string A unique identifier for internal payment methods
»» type string The type of payment method
»» name string Name of the payment method
»» instructions string Instructions for the customer on how to pay. Used for offline payments.
» private string Returns whether or not the event is private
» status string Status of the event
» timezone string TZ format timezone string
» total_occurrences integer Total number of time the event series occurs
» upcoming_occurrences integer The number of upcoming occurrences of the event series
» url string Event series URL
» venue object none
»» name string Name of the venue
»» postal_code string Postal code of the venue
» voucher_ids [string] List of voucher IDs

Enumerated Values

Property Value
currency gbp
currency usd
currency eur
currency sgd
currency aud
currency brl
currency cad
currency czk
currency dkk
currency hkd
currency huf
currency ils
currency jpy
currency myr
currency mxn
currency nok
currency nzd
currency php
currency pln
currency rub
currency sek
currency chf
currency twd
currency thb
currency try
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free
online_event true
online_event false
type stripe
type paypal
type offline
private true
private false
status draft
status published
status sales_closed

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Delete an event series

Code samples

# You can also use wget
curl -X DELETE /v1/event_series/{event_series_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('DELETE','/v1/event_series/{event_series_id}', [
        'headers' => $headers,
         => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/event_series/{event_series_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.delete(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.delete('/v1/event_series/{event_series_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

DELETE /v1/event_series/{event_series_id}

Delete event series and its associated events. This action is irreversible. The event series and its events will be permanently removed.

Parameters

Name In Type Required Description
event_series_id path string true The unique identifier for event series

Example responses

200 Response

{
  "id": "es_123",
  "object": "event_series",
  "deleted": true
}

Response Schema

Status Code 200

Name Type Description
» id string ID of the deleted event series
» object string none
» deleted string Delete operation successful

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Change event series status

Code samples

# You can also use wget
curl -X POST /v1/event_series/{event_series_id}/status \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/event_series/{event_series_id}/status', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/event_series/{event_series_id}/status', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/event_series/{event_series_id}/status', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/event_series/{event_series_id}/status

For the given event series ID, change its status

Body parameter

status: DRAFT

Parameters

Name In Type Required Description
event_series_id path string true The unique identifier for the event series
body body object true none
» status body string true New event series status

Enumerated Values

Parameter Value
» status DRAFT
» status PUBLISHED
» status CLOSE_SALES

Example responses

200 Response

{
  "object": "event_series",
  "id": "es_1",
  "access_code": null,
  "call_to_action": "Buy tickets / Join the guestlist",
  "currency": "gbp",
  "default_ticket_groups": [
    {
      "id": "tg_21099",
      "max_per_order": null,
      "name": "April 20th",
      "sort_order": 50050,
      "ticket_ids": [
        "tt_230625",
        "tt_230626"
      ]
    },
    {
      "id": "tg_21100",
      "max_per_order": null,
      "name": "April 21st",
      "sort_order": 50100,
      "ticket_ids": [
        "tt_230631",
        "tt_230632"
      ]
    }
  ],
  "default_ticket_types": [
    {
      "object": "ticket_type",
      "id": "tt_230625",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Adult (13-61) - Presale",
      "price": 800,
      "status": "hidden",
      "sort_order": 50050,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 5000,
      "quantity_total": 15000
    },
    {
      "object": "ticket_type",
      "id": "tt_230626",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50051,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 2000,
      "quantity_total": 12000
    },
    {
      "object": "ticket_type",
      "id": "tt_230631",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21100",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.21 Adult (13-61) - Presale",
      "price": 800,
      "status": "on_sale",
      "sort_order": 50100,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 4000,
      "quantity_total": 14000
    },
    {
      "object": "ticket_type",
      "id": "tt_230632",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21100",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.21 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50101,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 1000,
      "quantity_total": 11000
    }
  ],
  "description": null,
  "images": {
    "header": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,g_center,h_326,q_85,w_1024/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg",
    "thumbnail": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,h_108,q_85,w_108/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg"
  },
  "name": "Hackney Downs 2020 Tulip Festival",
  "next_occurrence_date": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "online_event": "false",
  "payment_methods": [
    {
      "external_id": null,
      "id": "pm_6687",
      "instructions": "Pay when you arrive to festival",
      "name": "Pay on the door",
      "type": "offline"
    },
    {
      "external_id": "seller222@example.com",
      "id": "pm_6691",
      "instructions": null,
      "name": null,
      "type": "paypal"
    }
  ],
  "private": "false",
  "status": "published",
  "timezone": "Europe/London",
  "total_occurrences": 20,
  "upcoming_occurrences": 5,
  "url": "https://www.tickettailor.com/events/flowerfestival/40980",
  "venue": {
    "name": "Flower festival gardens",
    "postal_code": "SW1 3BR"
  },
  "voucher_ids": [
    "vo_123",
    "vo_345",
    "vo_567"
  ]
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the event series
» access_code string¦null Code to access a protected event series
» call_to_action string Call to action text used on the event series page
» created_at object Date and time when the event series were created
»» date string ISO-8601 date for the end of the event
»» formatted string A formatted date string for the end of the event
»» iso string ISO-8601 date and time for the end of the event
»» time string Time of the end of the event
»» timezone string Timezone offset for the end of the event
»» unix integer Unix timestamp for for the end of the event
» currency string Information about the currency the event series is configured to use
» default_ticket_groups [any] Ticket groups that are not overridden
»» id string A unique ticket group identifier
»» max_per_order integer Maximum number of ticket types that this group can sell
»» name string Name of the ticket types group
»» sort_order integer Sort index of the group in the UI
»» ticket_ids [any] Unique identifiers of ticket type ids that belong to this group
»»» id string none
» default_ticket_types [TicketType]¦null Ticket types that are not overridden
»» object string none
»» id string A unique identifier for the ticket type
»» access_code string¦null Code to access a hidden ticket
»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»» description string¦null none
»» group_id string¦null ID of the group this ticket type belongs to
»» has_overrides string Specifies whether the ticket type has overrides
»» max_per_order integer Maximum number of ticket types you can select per order
»» min_per_order integer Minimum number of ticket types you can select per order
»» name string Name of the ticket type
»» override_id string¦null The ID of the override associated with the ticket type
»» price any Cost of the ticket type

anyOf

Name Type Description
»»» anonymous integer none

or

Name Type Description
»»» anonymous number none

continued

Name Type Description
»» status string Status of the ticket type
»» sort_order integer Sort index of ticket type in the UI
»» type string none
»» quantity integer Number available for purchase
»» quantity_held integer Number held
»» quantity_issued integer Number issued
»» quantity_total integer Total number including issued and still available
» description string¦null Description of the event series
» images object Imagages that have been uploaded to this event series
»» header string Image URL of the header image used on the event series page
»» thumbnail string Image URL of the thumbnail used on the event series page
» name string Name of the event series
» next_occurrence_date object Date and time when the next event in the series happens
»» date string ISO-8601 date for the end of the event
»» formatted string A formatted date string for the end of the event
»» iso string ISO-8601 date and time for the end of the event
»» time string Time of the end of the event
»» timezone string Timezone offset for the end of the event
»» unix integer Unix timestamp for for the end of the event
» online_event string Returns whether or not the event is online
» payment_methods [any] An array of payment methods
»» external_id string A unique identifier for the payment method
»» id string A unique identifier for internal payment methods
»» type string The type of payment method
»» name string Name of the payment method
»» instructions string Instructions for the customer on how to pay. Used for offline payments.
» private string Returns whether or not the event is private
» status string Status of the event
» timezone string TZ format timezone string
» total_occurrences integer Total number of time the event series occurs
» upcoming_occurrences integer The number of upcoming occurrences of the event series
» url string Event series URL
» venue object none
»» name string Name of the venue
»» postal_code string Postal code of the venue
» voucher_ids [string] List of voucher IDs

Enumerated Values

Property Value
currency gbp
currency usd
currency eur
currency sgd
currency aud
currency brl
currency cad
currency czk
currency dkk
currency hkd
currency huf
currency ils
currency jpy
currency myr
currency mxn
currency nok
currency nzd
currency php
currency pln
currency rub
currency sek
currency chf
currency twd
currency thb
currency try
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free
online_event true
online_event false
type stripe
type paypal
type offline
private true
private false
status draft
status published
status sales_closed

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Event occurrence

List event occurrences

Code samples

# You can also use wget
curl -X GET /v1/event_series/{event_series_id}/events \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/event_series/{event_series_id}/events', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/event_series/{event_series_id}/events', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/event_series/{event_series_id}/events', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/event_series/{event_series_id}/events

For the given event series ID, find all the associated events and list them

Parameters

Name In Type Required Description
start_at query integer false Unix timestamp filter that returns items with matched start_at value.
start_at.gt query integer false Unix timestamp filter that returns items with start_at greater than given value.
start_at.gte query integer false Unix timestamp filter that returns items with start_at greater than or equal given value.
start_at.lt query integer false Unix timestamp filter that returns items with start_at less than given value.
start_at.lte query integer false Unix timestamp filter that returns items with start_at less than or equal given value.
end_at query integer false Unix timestamp filter that returns items with matched end_at value.
end_at.gt query integer false Unix timestamp filter that returns items with end_at greater than given value.
end_at.gte query integer false Unix timestamp filter that returns items with end_at greater than or equal given value.
end_at.lt query integer false Unix timestamp filter that returns items with end_at less than given value.
end_at.lte query integer false Unix timestamp filter that returns items with end_at less than or equal given value.
starting_after query string false A paginator cursor value of object id (e.g. "or_123") that defines place in the list. To fetch next page of results, use the last object id from the current result list, e.g. starting_after=or_223.
ending_before query string false A paginator cursor value of object id (e.g. "or_123") that defines place in the list. To fetch previous page of results, use the first object id from the current result list, e.g. ending_before=or_123.
limit query string false The number of items to retrieve
status query string false A comma separated list of event series status. (e.g. draft, published)

Enumerated Values

Parameter Value
status published
status draft
status sales_closed

Example responses

200 Response

{
  "data": [
    {
      "object": "event",
      "id": "ev_1",
      "end": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "event_series_id": "es_1",
      "hidden": "true",
      "override_id": "ov_123",
      "start": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 6:00 PM",
        "iso": "2020-05-01T18:00:00+01:00",
        "time": "18:00",
        "timezone": "+01:00",
        "unix": 1588352400
      },
      "tickets_available": "true",
      "ticket_groups": [
        {
          "id": "tg_21099",
          "max_per_order": null,
          "name": "April 20th",
          "sort_order": 50050,
          "ticket_ids": [
            "tt_230625",
            "tt_230626"
          ]
        },
        {
          "id": "tg_21100",
          "max_per_order": null,
          "name": "April 21st",
          "sort_order": 50100,
          "ticket_ids": [
            "tt_230631",
            "tt_230632"
          ]
        }
      ],
      "ticket_types": [
        {
          "object": "ticket_type",
          "id": "tt_230625",
          "access_code": null,
          "booking_fee": 0,
          "description": null,
          "group_id": "tg_21099",
          "max_per_order": 100,
          "min_per_order": 1,
          "name": "4.20 Adult (13-61) - Presale",
          "price": 800,
          "status": "hidden",
          "sort_order": 50050,
          "type": "paid",
          "quantity": 10000,
          "quantity_held": 0,
          "quantity_issued": 5000,
          "quantity_total": 15000
        },
        {
          "object": "ticket_type",
          "id": "tt_230626",
          "access_code": null,
          "booking_fee": 0,
          "description": null,
          "group_id": "tg_21099",
          "max_per_order": 100,
          "min_per_order": 1,
          "name": "4.20 Senior (62+) - Presale",
          "price": 600,
          "status": "on_sale",
          "sort_order": 50051,
          "type": "paid",
          "quantity": 10000,
          "quantity_held": 0,
          "quantity_issued": 2000,
          "quantity_total": 12000
        }
      ],
      "total_issued_tickets": 5,
      "unavailable": "true",
      "unavailable_status": "This event occurrence is not available"
    }
  ],
  "links": {
    "next": "/v1/event_series/es_123/events?starting_after=ev_120",
    "previous": "/v1/event_series/es_123/events?ending_before=ev_100"
  }
}

Response Schema

Status Code 200

Name Type Description
» data [EventOccurrence] none
»» object string none
»» id string A unique identifier for the event occurrence
»» end object The end date and time for the event
»»» date string ISO-8601 date for the end of the event
»»» formatted string A formatted date string for the end of the event
»»» iso string ISO-8601 date and time for the end of the event
»»» time string Time of the end of the event
»»» timezone string Timezone offset for the end of the event
»»» unix integer Unix timestamp for for the end of the event
»» event_series_id string A unique identifier for the associated event series
»» hidden string True, if event is set to hidden
»» override_id string¦null A unique identifier for the associated override
»» start object The start date and time for the event
»»» date string ISO-8601 date for the start of the event
»»» formatted string A formatted date string for the start of the event
»»» iso string ISO-8601 date and time for the start of the event
»»» time string Time of the start of the event
»»» timezone string Timezone offset for the start of the event
»»» unix integer Unix timestamp for the start of the event
»» tickets_available string¦null Are there any ticket types available?
»» ticket_groups [any] none
»»» id string A unique ticket group identifier
»»» max_per_order integer Maximum number of ticket types that this group can sell
»»» name string Name of the ticket types group
»»» sort_order integer Sort index of the group in the UI
»»» ticket_ids [any] Unique identifiers of ticket type ids that belong to this group
»»»» id string none
»» ticket_types [TicketType]¦null none
»»» object string none
»»» id string A unique identifier for the ticket type
»»» access_code string¦null Code to access a hidden ticket
»»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»»» description string¦null none
»»» group_id string¦null ID of the group this ticket type belongs to
»»» has_overrides string Specifies whether the ticket type has overrides
»»» max_per_order integer Maximum number of ticket types you can select per order
»»» min_per_order integer Minimum number of ticket types you can select per order
»»» name string Name of the ticket type
»»» override_id string¦null The ID of the override associated with the ticket type
»»» price any Cost of the ticket type

anyOf

Name Type Description
»»»» anonymous integer none

or

Name Type Description
»»»» anonymous number none

continued

Name Type Description
»»» status string Status of the ticket type
»»» sort_order integer Sort index of ticket type in the UI
»»» type string none
»»» quantity integer Number available for purchase
»»» quantity_held integer Number held
»»» quantity_issued integer Number issued
»»» quantity_total integer Total number including issued and still available
»» total_issued_tickets integer Total number of issued tickets
»» unavailable string True, if event is set to unavailable
»» unavailable_status string¦null Optional custom status message when event is set to be unavailable
» links object none
»» next string¦null none
»» previous string¦null none

Enumerated Values

Property Value
hidden true
hidden false
tickets_available true
tickets_available false
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free
unavailable true
unavailable false

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Create an event occurrence

Code samples

# You can also use wget
curl -X POST /v1/event_series/{event_series_id}/events \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/event_series/{event_series_id}/events', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/event_series/{event_series_id}/events', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/event_series/{event_series_id}/events', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/event_series/{event_series_id}/events

For the given event series ID, create an event

Body parameter

end_date: 2022-10-22
end_time: 23:15:00
hidden: false
start_date: 2022-10-21
start_time: 19:15:00
unavailable: true
unavailable_status: This event is not available yet

Parameters

Name In Type Required Description
event_series_id path string true The unique identifier for the event series
body body object true none
» end_date body string true Event end date in the YYYY-MM-dd format
» end_time body string false Event end time in the HH:ii:ss format
» hidden body boolean false True, if the event is set to hidden. False otherwise
» start_date body string true Event start date in the YYYY-MM-dd format
» start_time body string false Event start time in the HH:ii:ss format
» unavailable body boolean false True, if the event is set to unavailable. False otherwise
» unavailable_status body string false Optional custom status message when the event is set to unavailable

Enumerated Values

Parameter Value
» hidden true
» hidden false
» unavailable true
» unavailable false

Example responses

201 Response

{
  "object": "event",
  "id": "ev_1",
  "end": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "event_series_id": "es_1",
  "hidden": "true",
  "override_id": "ov_123",
  "start": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 6:00 PM",
    "iso": "2020-05-01T18:00:00+01:00",
    "time": "18:00",
    "timezone": "+01:00",
    "unix": 1588352400
  },
  "tickets_available": "true",
  "ticket_groups": [
    {
      "id": "tg_21099",
      "max_per_order": null,
      "name": "April 20th",
      "sort_order": 50050,
      "ticket_ids": [
        "tt_230625",
        "tt_230626"
      ]
    },
    {
      "id": "tg_21100",
      "max_per_order": null,
      "name": "April 21st",
      "sort_order": 50100,
      "ticket_ids": [
        "tt_230631",
        "tt_230632"
      ]
    }
  ],
  "ticket_types": [
    {
      "object": "ticket_type",
      "id": "tt_230625",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Adult (13-61) - Presale",
      "price": 800,
      "status": "hidden",
      "sort_order": 50050,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 5000,
      "quantity_total": 15000
    },
    {
      "object": "ticket_type",
      "id": "tt_230626",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50051,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 2000,
      "quantity_total": 12000
    }
  ],
  "total_issued_tickets": 5,
  "unavailable": "true",
  "unavailable_status": "This event occurrence is not available"
}

Response Schema

Status Code 201

Name Type Description
» object string none
» id string A unique identifier for the event occurrence
» end object The end date and time for the event
»» date string ISO-8601 date for the end of the event
»» formatted string A formatted date string for the end of the event
»» iso string ISO-8601 date and time for the end of the event
»» time string Time of the end of the event
»» timezone string Timezone offset for the end of the event
»» unix integer Unix timestamp for for the end of the event
» event_series_id string A unique identifier for the associated event series
» hidden string True, if event is set to hidden
» override_id string¦null A unique identifier for the associated override
» start object The start date and time for the event
»» date string ISO-8601 date for the start of the event
»» formatted string A formatted date string for the start of the event
»» iso string ISO-8601 date and time for the start of the event
»» time string Time of the start of the event
»» timezone string Timezone offset for the start of the event
»» unix integer Unix timestamp for the start of the event
» tickets_available string¦null Are there any ticket types available?
» ticket_groups [any] none
»» id string A unique ticket group identifier
»» max_per_order integer Maximum number of ticket types that this group can sell
»» name string Name of the ticket types group
»» sort_order integer Sort index of the group in the UI
»» ticket_ids [any] Unique identifiers of ticket type ids that belong to this group
»»» id string none
» ticket_types [TicketType]¦null none
»» object string none
»» id string A unique identifier for the ticket type
»» access_code string¦null Code to access a hidden ticket
»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»» description string¦null none
»» group_id string¦null ID of the group this ticket type belongs to
»» has_overrides string Specifies whether the ticket type has overrides
»» max_per_order integer Maximum number of ticket types you can select per order
»» min_per_order integer Minimum number of ticket types you can select per order
»» name string Name of the ticket type
»» override_id string¦null The ID of the override associated with the ticket type
»» price any Cost of the ticket type

anyOf

Name Type Description
»»» anonymous integer none

or

Name Type Description
»»» anonymous number none

continued

Name Type Description
»» status string Status of the ticket type
»» sort_order integer Sort index of ticket type in the UI
»» type string none
»» quantity integer Number available for purchase
»» quantity_held integer Number held
»» quantity_issued integer Number issued
»» quantity_total integer Total number including issued and still available
» total_issued_tickets integer Total number of issued tickets
» unavailable string True, if event is set to unavailable
» unavailable_status string¦null Optional custom status message when event is set to be unavailable

Enumerated Values

Property Value
hidden true
hidden false
tickets_available true
tickets_available false
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free
unavailable true
unavailable false

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Get a single event occurrence

Code samples

# You can also use wget
curl -X GET /v1/event_series/{event_series_id}/events/{event_occurrence_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/event_series/{event_series_id}/events/{event_occurrence_id}', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/event_series/{event_series_id}/events/{event_occurrence_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/event_series/{event_series_id}/events/{event_occurrence_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/event_series/{event_series_id}/events/{event_occurrence_id}

Returns existing event occurrence by ID

Parameters

Name In Type Required Description
event_series_id path string true The unique identifier for the existing event series
event_occurrence_id path string true The unique identifier for the existing event occurrence

Example responses

200 Response

{
  "object": "event",
  "id": "ev_1",
  "end": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "event_series_id": "es_1",
  "hidden": "true",
  "override_id": "ov_123",
  "start": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 6:00 PM",
    "iso": "2020-05-01T18:00:00+01:00",
    "time": "18:00",
    "timezone": "+01:00",
    "unix": 1588352400
  },
  "tickets_available": "true",
  "ticket_groups": [
    {
      "id": "tg_21099",
      "max_per_order": null,
      "name": "April 20th",
      "sort_order": 50050,
      "ticket_ids": [
        "tt_230625",
        "tt_230626"
      ]
    },
    {
      "id": "tg_21100",
      "max_per_order": null,
      "name": "April 21st",
      "sort_order": 50100,
      "ticket_ids": [
        "tt_230631",
        "tt_230632"
      ]
    }
  ],
  "ticket_types": [
    {
      "object": "ticket_type",
      "id": "tt_230625",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Adult (13-61) - Presale",
      "price": 800,
      "status": "hidden",
      "sort_order": 50050,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 5000,
      "quantity_total": 15000
    },
    {
      "object": "ticket_type",
      "id": "tt_230626",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50051,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 2000,
      "quantity_total": 12000
    }
  ],
  "total_issued_tickets": 5,
  "unavailable": "true",
  "unavailable_status": "This event occurrence is not available"
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the event occurrence
» end object The end date and time for the event
»» date string ISO-8601 date for the end of the event
»» formatted string A formatted date string for the end of the event
»» iso string ISO-8601 date and time for the end of the event
»» time string Time of the end of the event
»» timezone string Timezone offset for the end of the event
»» unix integer Unix timestamp for for the end of the event
» event_series_id string A unique identifier for the associated event series
» hidden string True, if event is set to hidden
» override_id string¦null A unique identifier for the associated override
» start object The start date and time for the event
»» date string ISO-8601 date for the start of the event
»» formatted string A formatted date string for the start of the event
»» iso string ISO-8601 date and time for the start of the event
»» time string Time of the start of the event
»» timezone string Timezone offset for the start of the event
»» unix integer Unix timestamp for the start of the event
» tickets_available string¦null Are there any ticket types available?
» ticket_groups [any] none
»» id string A unique ticket group identifier
»» max_per_order integer Maximum number of ticket types that this group can sell
»» name string Name of the ticket types group
»» sort_order integer Sort index of the group in the UI
»» ticket_ids [any] Unique identifiers of ticket type ids that belong to this group
»»» id string none
» ticket_types [TicketType]¦null none
»» object string none
»» id string A unique identifier for the ticket type
»» access_code string¦null Code to access a hidden ticket
»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»» description string¦null none
»» group_id string¦null ID of the group this ticket type belongs to
»» has_overrides string Specifies whether the ticket type has overrides
»» max_per_order integer Maximum number of ticket types you can select per order
»» min_per_order integer Minimum number of ticket types you can select per order
»» name string Name of the ticket type
»» override_id string¦null The ID of the override associated with the ticket type
»» price any Cost of the ticket type

anyOf

Name Type Description
»»» anonymous integer none

or

Name Type Description
»»» anonymous number none

continued

Name Type Description
»» status string Status of the ticket type
»» sort_order integer Sort index of ticket type in the UI
»» type string none
»» quantity integer Number available for purchase
»» quantity_held integer Number held
»» quantity_issued integer Number issued
»» quantity_total integer Total number including issued and still available
» total_issued_tickets integer Total number of issued tickets
» unavailable string True, if event is set to unavailable
» unavailable_status string¦null Optional custom status message when event is set to be unavailable

Enumerated Values

Property Value
hidden true
hidden false
tickets_available true
tickets_available false
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free
unavailable true
unavailable false

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Update an event occurrence

Code samples

# You can also use wget
curl -X POST /v1/event_series/{event_series_id}/events/{event_occurrence_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/event_series/{event_series_id}/events/{event_occurrence_id}', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/event_series/{event_series_id}/events/{event_occurrence_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/event_series/{event_series_id}/events/{event_occurrence_id}', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/event_series/{event_series_id}/events/{event_occurrence_id}

Updates an existing event occurrence

Body parameter

end_date: 2022-10-22
end_time: 23:15:00
hidden: false
start_date: 2022-10-21
start_time: 19:15:00
unavailable: true
unavailable_status: This event is not available yet

Parameters

Name In Type Required Description
event_series_id path string true The unique identifier for the existing event series
event_occurrence_id path string true The unique identifier for the existing event occurrence
body body object false none
» end_date body string false Event end date in the YYYY-MM-dd format
» end_time body string false Event end time in the HH:ii:ss format
» hidden body boolean false True, if the event is set to hidden. False otherwise
» start_date body string false Event start date in the YYYY-MM-dd format
» start_time body string false Event start time in the HH:ii:ss format
» unavailable body boolean false True, if the event is set to unavailable. False otherwise
» unavailable_status body string false Optional custom status message when the event is set to unavailable

Enumerated Values

Parameter Value
» hidden true
» hidden false
» unavailable true
» unavailable false

Example responses

200 Response

{
  "object": "event",
  "id": "ev_1",
  "end": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "event_series_id": "es_1",
  "hidden": "true",
  "override_id": "ov_123",
  "start": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 6:00 PM",
    "iso": "2020-05-01T18:00:00+01:00",
    "time": "18:00",
    "timezone": "+01:00",
    "unix": 1588352400
  },
  "tickets_available": "true",
  "ticket_groups": [
    {
      "id": "tg_21099",
      "max_per_order": null,
      "name": "April 20th",
      "sort_order": 50050,
      "ticket_ids": [
        "tt_230625",
        "tt_230626"
      ]
    },
    {
      "id": "tg_21100",
      "max_per_order": null,
      "name": "April 21st",
      "sort_order": 50100,
      "ticket_ids": [
        "tt_230631",
        "tt_230632"
      ]
    }
  ],
  "ticket_types": [
    {
      "object": "ticket_type",
      "id": "tt_230625",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Adult (13-61) - Presale",
      "price": 800,
      "status": "hidden",
      "sort_order": 50050,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 5000,
      "quantity_total": 15000
    },
    {
      "object": "ticket_type",
      "id": "tt_230626",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50051,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 2000,
      "quantity_total": 12000
    }
  ],
  "total_issued_tickets": 5,
  "unavailable": "true",
  "unavailable_status": "This event occurrence is not available"
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the event occurrence
» end object The end date and time for the event
»» date string ISO-8601 date for the end of the event
»» formatted string A formatted date string for the end of the event
»» iso string ISO-8601 date and time for the end of the event
»» time string Time of the end of the event
»» timezone string Timezone offset for the end of the event
»» unix integer Unix timestamp for for the end of the event
» event_series_id string A unique identifier for the associated event series
» hidden string True, if event is set to hidden
» override_id string¦null A unique identifier for the associated override
» start object The start date and time for the event
»» date string ISO-8601 date for the start of the event
»» formatted string A formatted date string for the start of the event
»» iso string ISO-8601 date and time for the start of the event
»» time string Time of the start of the event
»» timezone string Timezone offset for the start of the event
»» unix integer Unix timestamp for the start of the event
» tickets_available string¦null Are there any ticket types available?
» ticket_groups [any] none
»» id string A unique ticket group identifier
»» max_per_order integer Maximum number of ticket types that this group can sell
»» name string Name of the ticket types group
»» sort_order integer Sort index of the group in the UI
»» ticket_ids [any] Unique identifiers of ticket type ids that belong to this group
»»» id string none
» ticket_types [TicketType]¦null none
»» object string none
»» id string A unique identifier for the ticket type
»» access_code string¦null Code to access a hidden ticket
»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»» description string¦null none
»» group_id string¦null ID of the group this ticket type belongs to
»» has_overrides string Specifies whether the ticket type has overrides
»» max_per_order integer Maximum number of ticket types you can select per order
»» min_per_order integer Minimum number of ticket types you can select per order
»» name string Name of the ticket type
»» override_id string¦null The ID of the override associated with the ticket type
»» price any Cost of the ticket type

anyOf

Name Type Description
»»» anonymous integer none

or

Name Type Description
»»» anonymous number none

continued

Name Type Description
»» status string Status of the ticket type
»» sort_order integer Sort index of ticket type in the UI
»» type string none
»» quantity integer Number available for purchase
»» quantity_held integer Number held
»» quantity_issued integer Number issued
»» quantity_total integer Total number including issued and still available
» total_issued_tickets integer Total number of issued tickets
» unavailable string True, if event is set to unavailable
» unavailable_status string¦null Optional custom status message when event is set to be unavailable

Enumerated Values

Property Value
hidden true
hidden false
tickets_available true
tickets_available false
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free
unavailable true
unavailable false

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Delete an event occurrence

Code samples

# You can also use wget
curl -X DELETE /v1/event_series/{event_series_id}/events/{event_occurrence_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('DELETE','/v1/event_series/{event_series_id}/events/{event_occurrence_id}', [
        'headers' => $headers,
         => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/event_series/{event_series_id}/events/{event_occurrence_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.delete(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.delete('/v1/event_series/{event_series_id}/events/{event_occurrence_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

DELETE /v1/event_series/{event_series_id}/events/{event_occurrence_id}

Delete event occurrence, only if there are no associated orders. Otherwise, set it as hidden. This action is irreversible. The event occurrence will be permanentrly removed.

Parameters

Name In Type Required Description
event_series_id path string true The unique identifier for the existing event series
event_occurrence_id path string true The unique identifier for the existing event occurrence

Example responses

200 Response

{
  "id": "es_123",
  "object": "event",
  "deleted": "true",
  "hidden": "false"
}

Response Schema

Status Code 200

Name Type Description
» id string ID of the deleted event series
» object string none
» deleted string Delete operation successful if the event occurrence has no orders
» hidden string The event occurrence is hidden if it has orders

Enumerated Values

Property Value
deleted true
deleted false
hidden true
hidden false

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Ticket type

Create a ticket type

Code samples

# You can also use wget
curl -X POST /v1/event_series/{event_series_id}/ticket_types \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/event_series/{event_series_id}/ticket_types', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/event_series/{event_series_id}/ticket_types', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/event_series/{event_series_id}/ticket_types', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/event_series/{event_series_id}/ticket_types

For the given event series ID, create a ticket type

Body parameter

access_code: secret_code_123
booking_fee: 155
description: General admission ticket
discounts:
  - di_123
  - di_456
name: General Admission
price: 600
quantity: 55
status: ON_SALE

Parameters

Name In Type Required Description
event_series_id path string true The unique identifier for the event series
body body object true none
» access_code body string false Code to access a hidden ticket
» booking_fee body integer false Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
» description body string false Description of the ticket type
» discounts body [string] false List of associated discount IDs
» name body string true Name of the ticket type
» price body integer true Cost of the ticket type
» quantity body integer true Number of ticket types available for purchase
» status body string false Event series status

Enumerated Values

Parameter Value
» status ON_SALE
» status SOLD_OUT
» status UNAVAILABLE
» status HIDDEN
» status ADMIN_ONLY
» status LOCKED

Example responses

201 Response

{
  "object": "ticket_type",
  "id": "tt_230656",
  "access_code": null,
  "booking_fee": 0,
  "description": null,
  "group_id": "tg_21103",
  "has_overrides": "true",
  "max_per_order": 100,
  "min_per_order": 1,
  "name": "4.24 Child (3-12)- Day of event",
  "override_id": "ov_11",
  "price": 600,
  "status": "on_sale",
  "sort_order": 50255,
  "type": "paid",
  "quantity": 10000,
  "quantity_held": 10,
  "quantity_issued": 700,
  "quantity_total": 10710
}

Response Schema

Status Code 201

Name Type Description
» object string none
» id string A unique identifier for the ticket type
» access_code string¦null Code to access a hidden ticket
» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
» description string¦null none
» group_id string¦null ID of the group this ticket type belongs to
» has_overrides string Specifies whether the ticket type has overrides
» max_per_order integer Maximum number of ticket types you can select per order
» min_per_order integer Minimum number of ticket types you can select per order
» name string Name of the ticket type
» override_id string¦null The ID of the override associated with the ticket type
» price any Cost of the ticket type

anyOf

Name Type Description
»» anonymous integer none

or

Name Type Description
»» anonymous number none

continued

Name Type Description
» status string Status of the ticket type
» sort_order integer Sort index of ticket type in the UI
» type string none
» quantity integer Number available for purchase
» quantity_held integer Number held
» quantity_issued integer Number issued
» quantity_total integer Total number including issued and still available

Enumerated Values

Property Value
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Update a ticket type

Code samples

# You can also use wget
curl -X POST /v1/event_series/{event_series_id}/ticket_types/{ticket_type_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/event_series/{event_series_id}/ticket_types/{ticket_type_id}', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/event_series/{event_series_id}/ticket_types/{ticket_type_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/event_series/{event_series_id}/ticket_types/{ticket_type_id}', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/event_series/{event_series_id}/ticket_types/{ticket_type_id}

Update existing ticket type

Body parameter

access_code: secret_code_123
booking_fee: 155
description: General admission ticket
discounts:
  - di_123
  - di_456
modify_quantity: 10
name: General Admission
price: 600
status: ON_SALE
zero_tickets: "true"

Parameters

Name In Type Required Description
event_series_id path string true The unique identifier for the event series
ticket_type_id path string true The unique identifier for the ticket type
body body object false none
» access_code body string false Code to access a hidden ticket
» booking_fee body integer false Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
» description body string false Description of the ticket type
» discounts body [string] false List of associated discount IDs
» modify_quantity body string false Number of ticket types to add or remove. The number should be preceded by a + or - sign
» name body string false Name of the ticket type
» price body integer false Cost of the ticket type
» status body string false Event series status
» zero_tickets body string false Set the number of available tickets to zero

Enumerated Values

Parameter Value
» status ON_SALE
» status SOLD_OUT
» status UNAVAILABLE
» status HIDDEN
» status ADMIN_ONLY
» status LOCKED
» zero_tickets true
» zero_tickets false

Example responses

200 Response

{
  "object": "ticket_type",
  "id": "tt_230656",
  "access_code": null,
  "booking_fee": 0,
  "description": null,
  "group_id": "tg_21103",
  "has_overrides": "true",
  "max_per_order": 100,
  "min_per_order": 1,
  "name": "4.24 Child (3-12)- Day of event",
  "override_id": "ov_11",
  "price": 600,
  "status": "on_sale",
  "sort_order": 50255,
  "type": "paid",
  "quantity": 10000,
  "quantity_held": 10,
  "quantity_issued": 700,
  "quantity_total": 10710
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the ticket type
» access_code string¦null Code to access a hidden ticket
» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
» description string¦null none
» group_id string¦null ID of the group this ticket type belongs to
» has_overrides string Specifies whether the ticket type has overrides
» max_per_order integer Maximum number of ticket types you can select per order
» min_per_order integer Minimum number of ticket types you can select per order
» name string Name of the ticket type
» override_id string¦null The ID of the override associated with the ticket type
» price any Cost of the ticket type

anyOf

Name Type Description
»» anonymous integer none

or

Name Type Description
»» anonymous number none

continued

Name Type Description
» status string Status of the ticket type
» sort_order integer Sort index of ticket type in the UI
» type string none
» quantity integer Number available for purchase
» quantity_held integer Number held
» quantity_issued integer Number issued
» quantity_total integer Total number including issued and still available

Enumerated Values

Property Value
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Delete a ticket type

Code samples

# You can also use wget
curl -X DELETE /v1/event_series/{event_series_id}/ticket_types/{ticket_type_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('DELETE','/v1/event_series/{event_series_id}/ticket_types/{ticket_type_id}', [
        'headers' => $headers,
         => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/event_series/{event_series_id}/ticket_types/{ticket_type_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.delete(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.delete('/v1/event_series/{event_series_id}/ticket_types/{ticket_type_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

DELETE /v1/event_series/{event_series_id}/ticket_types/{ticket_type_id}

Delete a ticket type. This action is irreversible. The event occurrence will be permanentrly removed.

Parameters

Name In Type Required Description
event_series_id path string true The unique identifier for the event series
ticket_type_id path string true The unique identifier for the ticket type

Example responses

200 Response

{
  "id": "tt_123",
  "object": "ticket_type",
  "deleted": "false"
}

Response Schema

Status Code 200

Name Type Description
» id string ID of the deleted ticket type
» object string none
» deleted string Delete operation successful

Enumerated Values

Property Value
deleted true
deleted false

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Hold

List holds

Code samples

# You can also use wget
curl -X GET /v1/holds \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/holds', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/holds', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/holds', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/holds

Returns a paginated list of holds

Parameters

Name In Type Required Description
limit query string false The number of items to retrieve
event_id query string false A string representing the event ID
created_at query integer false Unix timestamp filter that returns items with matched created_at value.
created_at.gt query integer false Unix timestamp filter that returns items with created_at greater than given value.
created_at.gte query integer false Unix timestamp filter that returns items with created_at greater than or equal given value.
created_at.lt query integer false Unix timestamp filter that returns items with created_at less than given value.
created_at.lte query integer false Unix timestamp filter that returns items with created_at less than or equal given value.
updated_at query integer false Unix timestamp filter that returns items with matched updated_at value.
updated_at.gt query integer false Unix timestamp filter that returns items with updated_at greater than the given value.
updated_at.gte query integer false Unix timestamp filter that returns items with updated_at greater than or equal to the given value.
updated_at.lt query integer false Unix timestamp filter that returns items with updated_at less than given value.
updated_at.lte query integer false Unix timestamp filter that returns items with updated_at less than or equal given value.

Example responses

200 Response

{
  "data": [
    {
      "object": "hold",
      "id": "ho_1",
      "created_at": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "note": "This is the note about the hold",
      "total_on_hold": 6,
      "update_at": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "quantities": [
        {
          "ticket_type_id": "tt_1",
          "quantity": 1
        },
        {
          "ticket_type_id": "tt_2",
          "quantity": 5
        }
      ]
    }
  ],
  "links": {
    "next": "/v1/holds?starting_after=ho_120",
    "previous": "/v1/holds?ending_before=ho_100"
  }
}

Response Schema

Status Code 200

Name Type Description
» data [Hold] none
»» object string none
»» id string A unque identifier for the hold
»» created_at object none
»»» date string ISO-8601 date for the created timestamp of the hold
»»» formatted string A formatted date string for the created timestamp of the hold
»»» iso string ISO-8601 date and time for the created timestamp of the hold
»»» time string Time of the created timestamp of the hold
»»» timezone string Timezone offset for the created timestamp of the hold
»»» unix integer Unix timestamp for when the hold was created
»» event_id string ID of the event that the hold belongs to
»» note string A note for the hold
»» total_on_hold integer Total number of tickets on hold
»» updated_at object none
»»» date string ISO-8601 date for the updated timestamp of the hold
»»» formatted string A formatted date string for the updated timestamp of the hold
»»» iso string ISO-8601 date and time for the updated timestamp of the hold
»»» time string Time of the updated timestamp of the hold
»»» timezone string Timezone offset for the updated timestamp of the hold
»»» unix integer Unix timestamp for when the hold was updated
»» quantities [object] Hold quantities for each of the associated ticket type ID
»»» ticket_type_id string Ticket type ID
»»» quantity integer Number of held tickets of this type
» links object none
»» next string¦null none
»» previous string¦null none

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Create a hold

Code samples

# You can also use wget
curl -X POST /v1/holds \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/holds', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/holds', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/holds', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/holds

Creates a new hold

Body parameter

event_id: ev_123
note: This hold contains 5 General Admission tickets
ticket_type_id:
  tt_1: 1
  tt_2: 5

Parameters

Name In Type Required Description
body body object true none
» event_id body string true The ID of the associated event for which to create the hold
» note body string true A string that gives more information about the created hold
» ticket_type_id body object true List of ticket types and their quantities
»» additionalProperties body string false none
»»» ticket_type_id body string false none
»»» quantity body integer false none

Example responses

201 Response

{
  "object": "hold",
  "id": "ho_1",
  "created_at": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "note": "This is the note about the hold",
  "total_on_hold": 6,
  "update_at": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "quantities": [
    {
      "ticket_type_id": "tt_1",
      "quantity": 1
    },
    {
      "ticket_type_id": "tt_2",
      "quantity": 5
    }
  ]
}

Response Schema

Status Code 201

Name Type Description
» object string none
» id string A unque identifier for the hold
» created_at object none
»» date string ISO-8601 date for the created timestamp of the hold
»» formatted string A formatted date string for the created timestamp of the hold
»» iso string ISO-8601 date and time for the created timestamp of the hold
»» time string Time of the created timestamp of the hold
»» timezone string Timezone offset for the created timestamp of the hold
»» unix integer Unix timestamp for when the hold was created
» event_id string ID of the event that the hold belongs to
» note string A note for the hold
» total_on_hold integer Total number of tickets on hold
» updated_at object none
»» date string ISO-8601 date for the updated timestamp of the hold
»» formatted string A formatted date string for the updated timestamp of the hold
»» iso string ISO-8601 date and time for the updated timestamp of the hold
»» time string Time of the updated timestamp of the hold
»» timezone string Timezone offset for the updated timestamp of the hold
»» unix integer Unix timestamp for when the hold was updated
» quantities [object] Hold quantities for each of the associated ticket type ID
»» ticket_type_id string Ticket type ID
»» quantity integer Number of held tickets of this type

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Get a single hold

Code samples

# You can also use wget
curl -X GET /v1/holds/{hold_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/holds/{hold_id}', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/holds/{hold_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/holds/{hold_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/holds/{hold_id}

Returns existing hold by ID

Parameters

Name In Type Required Description
hold_id path string true The unique identifier for the hold

Example responses

200 Response

{
  "object": "hold",
  "id": "ho_1",
  "created_at": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "note": "This is the note about the hold",
  "total_on_hold": 6,
  "update_at": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "quantities": [
    {
      "ticket_type_id": "tt_1",
      "quantity": 1
    },
    {
      "ticket_type_id": "tt_2",
      "quantity": 5
    }
  ]
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unque identifier for the hold
» created_at object none
»» date string ISO-8601 date for the created timestamp of the hold
»» formatted string A formatted date string for the created timestamp of the hold
»» iso string ISO-8601 date and time for the created timestamp of the hold
»» time string Time of the created timestamp of the hold
»» timezone string Timezone offset for the created timestamp of the hold
»» unix integer Unix timestamp for when the hold was created
» event_id string ID of the event that the hold belongs to
» note string A note for the hold
» total_on_hold integer Total number of tickets on hold
» updated_at object none
»» date string ISO-8601 date for the updated timestamp of the hold
»» formatted string A formatted date string for the updated timestamp of the hold
»» iso string ISO-8601 date and time for the updated timestamp of the hold
»» time string Time of the updated timestamp of the hold
»» timezone string Timezone offset for the updated timestamp of the hold
»» unix integer Unix timestamp for when the hold was updated
» quantities [object] Hold quantities for each of the associated ticket type ID
»» ticket_type_id string Ticket type ID
»» quantity integer Number of held tickets of this type

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Update a hold

Code samples

# You can also use wget
curl -X POST /v1/holds/{hold_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/holds/{hold_id}', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/holds/{hold_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/holds/{hold_id}', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/holds/{hold_id}

Updates an existing hold

Body parameter

note: This hold contains 5 General Admission tickets
ticket_type_id:
  tt_1: 1
  tt_2: 0

Parameters

Name In Type Required Description
hold_id path string true The unique identifier for the hold
body body object false none
» note body string false A string that gives more information about the created hold
» ticket_type_id body object false An array of associated ticket type IDs
»» additionalProperties body object false none
»»» ticket_type_id body string false none
»»» association body integer false 0 = remove from hold reservation, any other integer = keep or add

Example responses

200 Response

{
  "object": "hold",
  "id": "ho_1",
  "created_at": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "note": "This is the note about the hold",
  "total_on_hold": 6,
  "update_at": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "quantities": [
    {
      "ticket_type_id": "tt_1",
      "quantity": 1
    },
    {
      "ticket_type_id": "tt_2",
      "quantity": 5
    }
  ]
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unque identifier for the hold
» created_at object none
»» date string ISO-8601 date for the created timestamp of the hold
»» formatted string A formatted date string for the created timestamp of the hold
»» iso string ISO-8601 date and time for the created timestamp of the hold
»» time string Time of the created timestamp of the hold
»» timezone string Timezone offset for the created timestamp of the hold
»» unix integer Unix timestamp for when the hold was created
» event_id string ID of the event that the hold belongs to
» note string A note for the hold
» total_on_hold integer Total number of tickets on hold
» updated_at object none
»» date string ISO-8601 date for the updated timestamp of the hold
»» formatted string A formatted date string for the updated timestamp of the hold
»» iso string ISO-8601 date and time for the updated timestamp of the hold
»» time string Time of the updated timestamp of the hold
»» timezone string Timezone offset for the updated timestamp of the hold
»» unix integer Unix timestamp for when the hold was updated
» quantities [object] Hold quantities for each of the associated ticket type ID
»» ticket_type_id string Ticket type ID
»» quantity integer Number of held tickets of this type

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Delete a hold

Code samples

# You can also use wget
curl -X DELETE /v1/holds/{hold_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('DELETE','/v1/holds/{hold_id}', [
        'headers' => $headers,
         => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/holds/{hold_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.delete(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.delete('/v1/holds/{hold_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

DELETE /v1/holds/{hold_id}

Delete a hold. This action is irreversible. The hold will be permanently removed.

Parameters

Name In Type Required Description
hold_id path string true The unique identifier for the hold

Example responses

200 Response

{
  "id": "ho_123",
  "object": "hold",
  "deleted": "true"
}

Response Schema

Status Code 200

Name Type Description
» id string ID of the deleted hold
» object string none
» deleted string Delete operation successful

Enumerated Values

Property Value
deleted true
deleted false

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Order

List orders

Code samples

# You can also use wget
curl -X GET /v1/orders \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/orders', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/orders', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/orders', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/orders

Returns a list of orders belonging to box office

Parameters

Name In Type Required Description
created_at query integer false Unix timestamp filter that returns items with matched created_at value.
created_at.gt query integer false Unix timestamp filter that returns items with created_at greater than given value.
created_at.gte query integer false Unix timestamp filter that returns items with created_at greater than or equal given value.
created_at.lt query integer false Unix timestamp filter that returns items with created_at less than given value.
created_at.lte query integer false Unix timestamp filter that returns items with created_at less than or equal given value.
starting_after query string false A paginator cursor value of object id (e.g. "or_123") that defines place in the list. To fetch next page of results, use the last object id from the current result list, e.g. starting_after=or_223.
ending_before query string false A paginator cursor value of object id (e.g. "or_123") that defines place in the list. To fetch previous page of results, use the first object id from the current result list, e.g. ending_before=or_123.
limit query string false The number of items to retrieve
name query string false The first, last or full name of the buyer
email query string false The email of the buyer
txn_id query string false The transaction id
barcode query string false The ticket barcode
event_id query string false The event id
event_series_id query string false The event series id
status query string false The order status
referral_tag query string false The tag that tracks where sales originated

Enumerated Values

Parameter Value
status completed
status pending
status canceled

Example responses

200 Response

{
  "data": [
    {
      "object": "order",
      "id": "or_737352",
      "buyer_details": {
        "address": {
          "address_1": "The Queen's Walk",
          "address_2": "Bishop's",
          "address_3": "London",
          "postal_code": "SE1 7PB"
        },
        "custom_questions": [],
        "email": "john@example.com",
        "first_name": "John",
        "last_name": "Doe",
        "name": "John Doe",
        "phone": "07123456789"
      },
      "created_at": 1587042691,
      "currency": {
        "base_multiplier": 100,
        "code": "gbp"
      },
      "event_summary": {
        "id": "ev_40980",
        "end_date": {
          "date": "2020-05-01",
          "formatted": "Fri 1 May 2020 10:30 PM",
          "iso": "2020-05-01T22:30:00+01:00",
          "time": "22:30",
          "timezone": "+01:00",
          "unix": 1588368600
        },
        "name": "Hackney Downs 2020 Tulip Festival",
        "start_date": {
          "date": "2020-05-01",
          "formatted": "Fri 1 May 2020 6:00 PM",
          "iso": "2020-05-01T18:00:00+01:00",
          "time": "18:00",
          "timezone": "+01:00",
          "unix": 1588352400
        }
      },
      "issued_tickets": [
        {
          "object": "issued_ticket",
          "id": "it_50198",
          "barcode": "al4R5",
          "barcode_url": "https://www.tickettailor.com/userfiles/cache/barcode/qr/attendee/50198/42bf63ef2a055b91a62f",
          "checked_in": "false",
          "created_at": 1587042697,
          "custom_questions": [],
          "description": "Free ticket",
          "email": "john@example.com",
          "event_id": "ev_40980",
          "reference": "my reference code",
          "full_name": null,
          "first_name": null,
          "last_name": null,
          "status": "valid",
          "source": "api",
          "ticket_type_id": "tt_230656",
          "updated_at": 1587042697,
          "voided_at": null,
          "order_id": "or_737352",
          "qr_code_url": "https://www.tickettailor.com/userfiles/cache/barcode/st/attendee/50198/42bf63ef2a055b91a62f"
        },
        {
          "object": "issued_ticket",
          "id": "it_50199",
          "barcode": "dx2Fv",
          "barcode_url": "https://www.tickettailor.com/userfiles/cache/barcode/qr/attendee/50199/633d33a7ff6eba30a565",
          "checked_in": "false",
          "created_at": 1587042697,
          "custom_questions": [],
          "description": "Free ticket",
          "email": "john@example.com",
          "event_id": "ev_40980",
          "reference": "my reference code",
          "full_name": null,
          "first_name": null,
          "last_name": null,
          "status": "valid",
          "source": "api",
          "ticket_type_id": "tt_230656",
          "updated_at": 1587042697,
          "voided_at": null,
          "order_id": "or_737352",
          "qr_code_url": "https://www.tickettailor.com/userfiles/cache/barcode/st/attendee/50199/633d33a7ff6eba30a565"
        }
      ],
      "line_items": [
        {
          "object": "line_item",
          "id": "li_1505167",
          "booking_fee": 0,
          "description": "Free ticket",
          "type": "ticket",
          "total": 0,
          "value": 0,
          "quantity": 2
        }
      ],
      "marketing_opt_in": null,
      "payment_method": {
        "external_id": "seller222@example.com",
        "id": "pm_6691",
        "instructions": null,
        "name": null,
        "type": "paypal"
      },
      "referral_tag": "website",
      "refund_amount": 0,
      "status": "completed",
      "status_message": null,
      "subtotal": 0,
      "tax": 0,
      "total": 0,
      "txn_id": "ABCD1234"
    }
  ],
  "links": {
    "next": "/v1/orders?starting_after=or_120",
    "previous": "/v1/orders?ending_before=or_100"
  }
}

Response Schema

Status Code 200

Name Type Description
» data [Order] none
»» object string none
»» id string A unique identifier for the order
»» buyer_details object Information buyer provided in the checkout
»»» address object Information about buyer address
»»»» address_1 string¦null First line of address
»»»» address_2 string¦null Second line of address
»»»» address_3 string¦null Third line of address
»»»» postal_code string¦null Postal code, zip code or postcode
»»» custom_questions [object] Buyer provided answers to custom questions in checkout
»»»» question string none
»»»» answer string¦null none
»»» email string Buyer email address
»»» first_name string Buyer first name
»»» last_name string Buyer last name
»»» name string Buyer full name
»»» phone string¦null Buyer phone number
»» created_at integer Order creation timestamp
»» currency object Information about order currency
»»» code string Currency used for purchase
»»» base_multiplier integer Base multiplier for conversions
»» event_summary object Short event summary this order was made for
»»» id string ID of the event order belongs to
»»» name string Name of the event
»»» start_date object The start date for the event in various formats
»»»» date string ISO-8601 date for the start of the event
»»»» formatted string A formatted date string for the start of the event
»»»» iso string ISO-8601 date and time for the start of the event
»»»» time string Time for the start of the event
»»»» timezone string Timezone offset for the start of the event
»»»» unix integer Unix timestamp for the start of the event
»»» end_date object The end date for the event in various formats
»»»» date string ISO-8601 date for the end of the event
»»»» formatted string A formatted date string for the end of the event
»»»» iso string ISO-8601 date and time for the end of the event
»»»» time string Time for the end of the event
»»»» timezone string Timezone offset for the end of the event
»»»» unix integer Unix timestamp for the end of the event
»» issued_tickets [IssuedTicket]¦null Issued tickets for order
»»» object string none
»»» id string A unique identifier for the issued ticket
»»» add_on_id string¦null A unique identifier for the associated add-on
»»» barcode string Barcode text value
»»» barcode_url string URL to barcode image
»»» checked_in string Returns whether or not issued ticket is checked in
»»» created_at integer Timestamp when issued ticket was created
»»» custom_questions [any] Buyer provided answers to custom questions in checkout
»»»» question string none
»»»» answer string¦null none
»»» description string none
»»» email string¦null The order email address
»»» event_id string ID of the event issued ticket belongs to
»»» reference string¦null An external reference for imported tickets (via the API or Dashboard)
»»» full_name string¦null Full name of attendee
»»» first_name string¦null First name of attendee
»»» last_name string¦null Last name of attendee
»»» reservation string¦null Reservation from seating chart where applicable
»»» status string none
»»» source string¦null none
»»» ticket_type_id string ID of the ticket type
»»» updated_at integer Timestamp when issued ticket was last updated
»»» voided_at integer¦null Timestamp when issued ticket was voided
»»» order_id string¦null A unique identifier for the order
»»» qr_code_url string URL to QR code image
»» line_items [object] none
»»» object string none
»»» id string A unique identifier for the basket item
»»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»»» description string Basket item description
»»» type string ticket is a purchased ticket, transaction_charge is a transaction fee to orders. This is charged once per order as opposed to ticket booking fees which are charged once per ticket. void means ticket was voided after the purchase, tax is sales tax eg. VAT, gift_card is discount or voucher applied and donation is for donating value
»»» total integer Total amount including tax for line item
»»» value integer Amount without tax
»»» quantity integer Amount of line item objects
»» marketing_opt_in string¦null Whether the buyer opted in to receive marketing emails
»» payment_method PaymentMethod none
»»» external_id string¦null A unique identifier for the payment method
»»» id string¦null A unique identifier for internal payment methods
»»» type string The type of payment method
»»» name string¦null Name of the payment method
»»» instructions string¦null Instructions for the customer on how to pay. Used for offline payments.
»» refund_amount integer none
»» referral_tag string¦null A unique tag to track where sales originated
»» status string Possible states of the order
»» status_message string¦null Message associated with status.
»» subtotal integer Sum without tax
»» tax integer Tax sum
»» total integer Total value of order
»» total_paid integer Total amount paid for this order including tax
»» txn_id string¦null A unique identifier for the transaction
» links object none
»» next string¦null none
»» previous string¦null none

Enumerated Values

Property Value
code gbp
code usd
code eur
code sgd
code aud
code brl
code cad
code czk
code dkk
code hkd
code huf
code ils
code jpy
code myr
code mxn
code nok
code nzd
code php
code pln
code rub
code sek
code chf
code twd
code thb
code try
checked_in true
checked_in false
status valid
status void
source api
source dashboard_import
type ticket
type transaction_charge
type void
type tax
type gift_card
type donation
type stripe
type paypal
type offline
type operator
type no_cost
status completed
status pending
status cancelled

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Get a single order

Code samples

# You can also use wget
curl -X GET /v1/orders/{order_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/orders/{order_id}', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/orders/{order_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/orders/{order_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/orders/{order_id}

Returns an order belonging to the box office

Parameters

Name In Type Required Description
order_id path string true The unique identifier for the order

Example responses

200 Response

{
  "object": "order",
  "id": "or_737352",
  "buyer_details": {
    "address": {
      "address_1": "The Queen's Walk",
      "address_2": "Bishop's",
      "address_3": "London",
      "postal_code": "SE1 7PB"
    },
    "custom_questions": [],
    "email": "john@example.com",
    "first_name": "John",
    "last_name": "Doe",
    "name": "John Doe",
    "phone": "07123456789"
  },
  "created_at": 1587042691,
  "currency": {
    "base_multiplier": 100,
    "code": "gbp"
  },
  "event_summary": {
    "id": "ev_40980",
    "end_date": {
      "date": "2020-05-01",
      "formatted": "Fri 1 May 2020 10:30 PM",
      "iso": "2020-05-01T22:30:00+01:00",
      "time": "22:30",
      "timezone": "+01:00",
      "unix": 1588368600
    },
    "name": "Hackney Downs 2020 Tulip Festival",
    "start_date": {
      "date": "2020-05-01",
      "formatted": "Fri 1 May 2020 6:00 PM",
      "iso": "2020-05-01T18:00:00+01:00",
      "time": "18:00",
      "timezone": "+01:00",
      "unix": 1588352400
    }
  },
  "issued_tickets": [
    {
      "object": "issued_ticket",
      "id": "it_50198",
      "barcode": "al4R5",
      "barcode_url": "https://www.tickettailor.com/userfiles/cache/barcode/qr/attendee/50198/42bf63ef2a055b91a62f",
      "checked_in": "false",
      "created_at": 1587042697,
      "custom_questions": [],
      "description": "Free ticket",
      "email": "john@example.com",
      "event_id": "ev_40980",
      "reference": "my reference code",
      "full_name": null,
      "first_name": null,
      "last_name": null,
      "status": "valid",
      "source": "api",
      "ticket_type_id": "tt_230656",
      "updated_at": 1587042697,
      "voided_at": null,
      "order_id": "or_737352",
      "qr_code_url": "https://www.tickettailor.com/userfiles/cache/barcode/st/attendee/50198/42bf63ef2a055b91a62f"
    },
    {
      "object": "issued_ticket",
      "id": "it_50199",
      "barcode": "dx2Fv",
      "barcode_url": "https://www.tickettailor.com/userfiles/cache/barcode/qr/attendee/50199/633d33a7ff6eba30a565",
      "checked_in": "false",
      "created_at": 1587042697,
      "custom_questions": [],
      "description": "Free ticket",
      "email": "john@example.com",
      "event_id": "ev_40980",
      "reference": "my reference code",
      "full_name": null,
      "first_name": null,
      "last_name": null,
      "status": "valid",
      "source": "api",
      "ticket_type_id": "tt_230656",
      "updated_at": 1587042697,
      "voided_at": null,
      "order_id": "or_737352",
      "qr_code_url": "https://www.tickettailor.com/userfiles/cache/barcode/st/attendee/50199/633d33a7ff6eba30a565"
    }
  ],
  "line_items": [
    {
      "object": "line_item",
      "id": "li_1505167",
      "booking_fee": 0,
      "description": "Free ticket",
      "type": "ticket",
      "total": 0,
      "value": 0,
      "quantity": 2
    }
  ],
  "marketing_opt_in": null,
  "payment_method": {
    "external_id": "seller222@example.com",
    "id": "pm_6691",
    "instructions": null,
    "name": null,
    "type": "paypal"
  },
  "referral_tag": "website",
  "refund_amount": 0,
  "status": "completed",
  "status_message": null,
  "subtotal": 0,
  "tax": 0,
  "total": 0,
  "txn_id": "ABCD1234"
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the order
» buyer_details object Information buyer provided in the checkout
»» address object Information about buyer address
»»» address_1 string¦null First line of address
»»» address_2 string¦null Second line of address
»»» address_3 string¦null Third line of address
»»» postal_code string¦null Postal code, zip code or postcode
»» custom_questions [object] Buyer provided answers to custom questions in checkout
»»» question string none
»»» answer string¦null none
»» email string Buyer email address
»» first_name string Buyer first name
»» last_name string Buyer last name
»» name string Buyer full name
»» phone string¦null Buyer phone number
» created_at integer Order creation timestamp
» currency object Information about order currency
»» code string Currency used for purchase
»» base_multiplier integer Base multiplier for conversions
» event_summary object Short event summary this order was made for
»» id string ID of the event order belongs to
»» name string Name of the event
»» start_date object The start date for the event in various formats
»»» date string ISO-8601 date for the start of the event
»»» formatted string A formatted date string for the start of the event
»»» iso string ISO-8601 date and time for the start of the event
»»» time string Time for the start of the event
»»» timezone string Timezone offset for the start of the event
»»» unix integer Unix timestamp for the start of the event
»» end_date object The end date for the event in various formats
»»» date string ISO-8601 date for the end of the event
»»» formatted string A formatted date string for the end of the event
»»» iso string ISO-8601 date and time for the end of the event
»»» time string Time for the end of the event
»»» timezone string Timezone offset for the end of the event
»»» unix integer Unix timestamp for the end of the event
» issued_tickets [IssuedTicket]¦null Issued tickets for order
»» object string none
»» id string A unique identifier for the issued ticket
»» add_on_id string¦null A unique identifier for the associated add-on
»» barcode string Barcode text value
»» barcode_url string URL to barcode image
»» checked_in string Returns whether or not issued ticket is checked in
»» created_at integer Timestamp when issued ticket was created
»» custom_questions [any] Buyer provided answers to custom questions in checkout
»»» question string none
»»» answer string¦null none
»» description string none
»» email string¦null The order email address
»» event_id string ID of the event issued ticket belongs to
»» reference string¦null An external reference for imported tickets (via the API or Dashboard)
»» full_name string¦null Full name of attendee
»» first_name string¦null First name of attendee
»» last_name string¦null Last name of attendee
»» reservation string¦null Reservation from seating chart where applicable
»» status string none
»» source string¦null none
»» ticket_type_id string ID of the ticket type
»» updated_at integer Timestamp when issued ticket was last updated
»» voided_at integer¦null Timestamp when issued ticket was voided
»» order_id string¦null A unique identifier for the order
»» qr_code_url string URL to QR code image
» line_items [object] none
»» object string none
»» id string A unique identifier for the basket item
»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»» description string Basket item description
»» type string ticket is a purchased ticket, transaction_charge is a transaction fee to orders. This is charged once per order as opposed to ticket booking fees which are charged once per ticket. void means ticket was voided after the purchase, tax is sales tax eg. VAT, gift_card is discount or voucher applied and donation is for donating value
»» total integer Total amount including tax for line item
»» value integer Amount without tax
»» quantity integer Amount of line item objects
» marketing_opt_in string¦null Whether the buyer opted in to receive marketing emails
» payment_method PaymentMethod none
»» external_id string¦null A unique identifier for the payment method
»» id string¦null A unique identifier for internal payment methods
»» type string The type of payment method
»» name string¦null Name of the payment method
»» instructions string¦null Instructions for the customer on how to pay. Used for offline payments.
» refund_amount integer none
» referral_tag string¦null A unique tag to track where sales originated
» status string Possible states of the order
» status_message string¦null Message associated with status.
» subtotal integer Sum without tax
» tax integer Tax sum
» total integer Total value of order
» total_paid integer Total amount paid for this order including tax
» txn_id string¦null A unique identifier for the transaction

Enumerated Values

Property Value
code gbp
code usd
code eur
code sgd
code aud
code brl
code cad
code czk
code dkk
code hkd
code huf
code ils
code jpy
code myr
code mxn
code nok
code nzd
code php
code pln
code rub
code sek
code chf
code twd
code thb
code try
checked_in true
checked_in false
status valid
status void
source api
source dashboard_import
type ticket
type transaction_charge
type void
type tax
type gift_card
type donation
type stripe
type paypal
type offline
type operator
type no_cost
status completed
status pending
status cancelled

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Update an order

Code samples

# You can also use wget
curl -X POST /v1/orders/{order_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/orders/{order_id}', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/orders/{order_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/orders/{order_id}', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/orders/{order_id}

Updates an existing order

Body parameter

address_1: Test address 1
email: test@test.com
first_name: Test
last_name: User
phone: "+44123456789"
postal_code: SW1 4RT

Parameters

Name In Type Required Description
order_id path string true The unique identifier for the order
body body object false none
» address_1 body string¦null false The first line of the address.
» address_2 body string¦null false The second line of the address.
» address_3 body string¦null false The third line of the address.
» email body string¦null false Buyer email address
» first_name body string¦null false Buyer first name
» last_name body string¦null false Buyer last name
» phone body string¦null false Buyer phone number
» postal_code body string¦null false Postal code, zip code or postcode

Example responses

200 Response

{
  "object": "order",
  "id": "or_737352",
  "buyer_details": {
    "address": {
      "address_1": "The Queen's Walk",
      "address_2": "Bishop's",
      "address_3": "London",
      "postal_code": "SE1 7PB"
    },
    "custom_questions": [],
    "email": "john@example.com",
    "first_name": "John",
    "last_name": "Doe",
    "name": "John Doe",
    "phone": "07123456789"
  },
  "created_at": 1587042691,
  "currency": {
    "base_multiplier": 100,
    "code": "gbp"
  },
  "event_summary": {
    "id": "ev_40980",
    "end_date": {
      "date": "2020-05-01",
      "formatted": "Fri 1 May 2020 10:30 PM",
      "iso": "2020-05-01T22:30:00+01:00",
      "time": "22:30",
      "timezone": "+01:00",
      "unix": 1588368600
    },
    "name": "Hackney Downs 2020 Tulip Festival",
    "start_date": {
      "date": "2020-05-01",
      "formatted": "Fri 1 May 2020 6:00 PM",
      "iso": "2020-05-01T18:00:00+01:00",
      "time": "18:00",
      "timezone": "+01:00",
      "unix": 1588352400
    }
  },
  "issued_tickets": [
    {
      "object": "issued_ticket",
      "id": "it_50198",
      "barcode": "al4R5",
      "barcode_url": "https://www.tickettailor.com/userfiles/cache/barcode/qr/attendee/50198/42bf63ef2a055b91a62f",
      "checked_in": "false",
      "created_at": 1587042697,
      "custom_questions": [],
      "description": "Free ticket",
      "email": "john@example.com",
      "event_id": "ev_40980",
      "reference": "my reference code",
      "full_name": null,
      "first_name": null,
      "last_name": null,
      "status": "valid",
      "source": "api",
      "ticket_type_id": "tt_230656",
      "updated_at": 1587042697,
      "voided_at": null,
      "order_id": "or_737352",
      "qr_code_url": "https://www.tickettailor.com/userfiles/cache/barcode/st/attendee/50198/42bf63ef2a055b91a62f"
    },
    {
      "object": "issued_ticket",
      "id": "it_50199",
      "barcode": "dx2Fv",
      "barcode_url": "https://www.tickettailor.com/userfiles/cache/barcode/qr/attendee/50199/633d33a7ff6eba30a565",
      "checked_in": "false",
      "created_at": 1587042697,
      "custom_questions": [],
      "description": "Free ticket",
      "email": "john@example.com",
      "event_id": "ev_40980",
      "reference": "my reference code",
      "full_name": null,
      "first_name": null,
      "last_name": null,
      "status": "valid",
      "source": "api",
      "ticket_type_id": "tt_230656",
      "updated_at": 1587042697,
      "voided_at": null,
      "order_id": "or_737352",
      "qr_code_url": "https://www.tickettailor.com/userfiles/cache/barcode/st/attendee/50199/633d33a7ff6eba30a565"
    }
  ],
  "line_items": [
    {
      "object": "line_item",
      "id": "li_1505167",
      "booking_fee": 0,
      "description": "Free ticket",
      "type": "ticket",
      "total": 0,
      "value": 0,
      "quantity": 2
    }
  ],
  "marketing_opt_in": null,
  "payment_method": {
    "external_id": "seller222@example.com",
    "id": "pm_6691",
    "instructions": null,
    "name": null,
    "type": "paypal"
  },
  "referral_tag": "website",
  "refund_amount": 0,
  "status": "completed",
  "status_message": null,
  "subtotal": 0,
  "tax": 0,
  "total": 0,
  "txn_id": "ABCD1234"
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the order
» buyer_details object Information buyer provided in the checkout
»» address object Information about buyer address
»»» address_1 string¦null First line of address
»»» address_2 string¦null Second line of address
»»» address_3 string¦null Third line of address
»»» postal_code string¦null Postal code, zip code or postcode
»» custom_questions [object] Buyer provided answers to custom questions in checkout
»»» question string none
»»» answer string¦null none
»» email string Buyer email address
»» first_name string Buyer first name
»» last_name string Buyer last name
»» name string Buyer full name
»» phone string¦null Buyer phone number
» created_at integer Order creation timestamp
» currency object Information about order currency
»» code string Currency used for purchase
»» base_multiplier integer Base multiplier for conversions
» event_summary object Short event summary this order was made for
»» id string ID of the event order belongs to
»» name string Name of the event
»» start_date object The start date for the event in various formats
»»» date string ISO-8601 date for the start of the event
»»» formatted string A formatted date string for the start of the event
»»» iso string ISO-8601 date and time for the start of the event
»»» time string Time for the start of the event
»»» timezone string Timezone offset for the start of the event
»»» unix integer Unix timestamp for the start of the event
»» end_date object The end date for the event in various formats
»»» date string ISO-8601 date for the end of the event
»»» formatted string A formatted date string for the end of the event
»»» iso string ISO-8601 date and time for the end of the event
»»» time string Time for the end of the event
»»» timezone string Timezone offset for the end of the event
»»» unix integer Unix timestamp for the end of the event
» issued_tickets [IssuedTicket]¦null Issued tickets for order
»» object string none
»» id string A unique identifier for the issued ticket
»» add_on_id string¦null A unique identifier for the associated add-on
»» barcode string Barcode text value
»» barcode_url string URL to barcode image
»» checked_in string Returns whether or not issued ticket is checked in
»» created_at integer Timestamp when issued ticket was created
»» custom_questions [any] Buyer provided answers to custom questions in checkout
»»» question string none
»»» answer string¦null none
»» description string none
»» email string¦null The order email address
»» event_id string ID of the event issued ticket belongs to
»» reference string¦null An external reference for imported tickets (via the API or Dashboard)
»» full_name string¦null Full name of attendee
»» first_name string¦null First name of attendee
»» last_name string¦null Last name of attendee
»» reservation string¦null Reservation from seating chart where applicable
»» status string none
»» source string¦null none
»» ticket_type_id string ID of the ticket type
»» updated_at integer Timestamp when issued ticket was last updated
»» voided_at integer¦null Timestamp when issued ticket was voided
»» order_id string¦null A unique identifier for the order
»» qr_code_url string URL to QR code image
» line_items [object] none
»» object string none
»» id string A unique identifier for the basket item
»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»» description string Basket item description
»» type string ticket is a purchased ticket, transaction_charge is a transaction fee to orders. This is charged once per order as opposed to ticket booking fees which are charged once per ticket. void means ticket was voided after the purchase, tax is sales tax eg. VAT, gift_card is discount or voucher applied and donation is for donating value
»» total integer Total amount including tax for line item
»» value integer Amount without tax
»» quantity integer Amount of line item objects
» marketing_opt_in string¦null Whether the buyer opted in to receive marketing emails
» payment_method PaymentMethod none
»» external_id string¦null A unique identifier for the payment method
»» id string¦null A unique identifier for internal payment methods
»» type string The type of payment method
»» name string¦null Name of the payment method
»» instructions string¦null Instructions for the customer on how to pay. Used for offline payments.
» refund_amount integer none
» referral_tag string¦null A unique tag to track where sales originated
» status string Possible states of the order
» status_message string¦null Message associated with status.
» subtotal integer Sum without tax
» tax integer Tax sum
» total integer Total value of order
» total_paid integer Total amount paid for this order including tax
» txn_id string¦null A unique identifier for the transaction

Enumerated Values

Property Value
code gbp
code usd
code eur
code sgd
code aud
code brl
code cad
code czk
code dkk
code hkd
code huf
code ils
code jpy
code myr
code mxn
code nok
code nzd
code php
code pln
code rub
code sek
code chf
code twd
code thb
code try
checked_in true
checked_in false
status valid
status void
source api
source dashboard_import
type ticket
type transaction_charge
type void
type tax
type gift_card
type donation
type stripe
type paypal
type offline
type operator
type no_cost
status completed
status pending
status cancelled

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Issued ticket

List issued tickets

Code samples

# You can also use wget
curl -X GET /v1/issued_tickets \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/issued_tickets', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/issued_tickets', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/issued_tickets', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/issued_tickets

Returns all issued tickets

Parameters

Name In Type Required Description
event_id query integer false The numeric ID of the event to filter issued tickets for
order_id query integer false The numeric ID of the order to filter issued tickets for
barcode query string false The barcode of the issued ticket
name query string false The name of the person attending an event
email query string false The email of the person attending an event
status query string false The status of the issued ticket
created_at query integer false Unix timestamp filter that returns items with matched created_at value.
created_at.gt query integer false Unix timestamp filter that returns items with created_at greater than given value.
created_at.gte query integer false Unix timestamp filter that returns items with created_at greater than or equal given value.
created_at.lt query integer false Unix timestamp filter that returns items with created_at less than given value.
created_at.lte query integer false Unix timestamp filter that returns items with created_at less than or equal given value.
starting_after query string false A paginator cursor value of object id (e.g. "or_123") that defines place in the list. To fetch next page of results, use the last object id from the current result list, e.g. starting_after=or_223.
ending_before query string false A paginator cursor value of object id (e.g. "or_123") that defines place in the list. To fetch previous page of results, use the first object id from the current result list, e.g. ending_before=or_123.
limit query string false The number of items to retrieve

Enumerated Values

Parameter Value
status valid
status voided

Example responses

200 Response

{
  "data": [
    {
      "object": "issued_ticket",
      "id": "it_50198",
      "barcode": "al4R5",
      "barcode_url": "https://www.tickettailor.com/userfiles/cache/barcode/qr/attendee/50198/42bf63ef2a055b91a62f",
      "checked_in": "false",
      "created_at": 1587042697,
      "custom_questions": [],
      "description": "Free ticket",
      "email": "john@example.com",
      "event_id": "ev_40980",
      "reference": "my reference code",
      "full_name": null,
      "first_name": null,
      "last_name": null,
      "status": "valid",
      "source": "api",
      "ticket_type_id": "tt_230656",
      "updated_at": 1587042697,
      "voided_at": null,
      "order_id": "or_737352",
      "qr_code_url": "https://www.tickettailor.com/userfiles/cache/barcode/st/attendee/50198/42bf63ef2a055b91a62f"
    }
  ],
  "links": {
    "next": "/v1/events/{event_id}/issued_tickets?starting_after=it_120",
    "previous": "/v1/events/{event_id}/issued_tickets?ending_before=it_100"
  }
}

Response Schema

Status Code 200

Name Type Description
» data [IssuedTicket] none
»» object string none
»» id string A unique identifier for the issued ticket
»» add_on_id string¦null A unique identifier for the associated add-on
»» barcode string Barcode text value
»» barcode_url string URL to barcode image
»» checked_in string Returns whether or not issued ticket is checked in
»» created_at integer Timestamp when issued ticket was created
»» custom_questions [any] Buyer provided answers to custom questions in checkout
»»» question string none
»»» answer string¦null none
»» description string none
»» email string¦null The order email address
»» event_id string ID of the event issued ticket belongs to
»» reference string¦null An external reference for imported tickets (via the API or Dashboard)
»» full_name string¦null Full name of attendee
»» first_name string¦null First name of attendee
»» last_name string¦null Last name of attendee
»» reservation string¦null Reservation from seating chart where applicable
»» status string none
»» source string¦null none
»» ticket_type_id string ID of the ticket type
»» updated_at integer Timestamp when issued ticket was last updated
»» voided_at integer¦null Timestamp when issued ticket was voided
»» order_id string¦null A unique identifier for the order
»» qr_code_url string URL to QR code image
» links object none
»» next string¦null none
»» previous string¦null none

Enumerated Values

Property Value
checked_in true
checked_in false
status valid
status void
source api
source dashboard_import

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Create an issued ticket

Code samples

# You can also use wget
curl -X POST /v1/issued_tickets \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/issued_tickets', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/issued_tickets', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/issued_tickets', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/issued_tickets

Creates a new issued ticket for an event occurrence from the available inventory. Send the event_id and ticket_type_id to create the issued ticket from an event occurrence's ticket type allocation. Alternatively, send the hold_id to create the issued ticket from a pre-existing hold. The issued ticket is not associated to an order. This will NOT send an email to the recipient with the issued ticket details. The request will fail if no tickets are available to fulfil the request, or the ticket type is a 'seated' type (uses a seating chart).

Body parameter

event_id: ev_1
ticket_type_id: tt_230656
email: john@example.com
full_name: John Doe

Parameters

Name In Type Required Description
body body object true none
» event_id body string false Event occurrence ID (required if creating from ticket type inventory)
» ticket_type_id body string false Ticket type ID (required if creating from ticket type inventory)
» hold_id body string false Hold ID to create the issued ticket from (required if creating from hold)
» full_name body string true The full name of the person attending the event
» email body string false The email of the person attending the event
» barcode body string false The barcode (ticket code) of the issued ticket (if empty, a barcode will be generated).
» reference body string false An external reference for this issued ticket (e.g order number in external system)

Example responses

201 Response

{
  "data": [
    {
      "object": "issued_ticket",
      "id": "it_50198",
      "barcode": "al4R5",
      "barcode_url": "https://www.tickettailor.com/userfiles/cache/barcode/qr/attendee/50198/42bf63ef2a055b91a62f",
      "checked_in": "false",
      "created_at": 1587042697,
      "custom_questions": [],
      "description": "Free ticket",
      "email": "john@example.com",
      "event_id": "ev_40980",
      "reference": "my reference code",
      "full_name": null,
      "first_name": null,
      "last_name": null,
      "status": "valid",
      "source": "api",
      "ticket_type_id": "tt_230656",
      "updated_at": 1587042697,
      "voided_at": null,
      "order_id": "or_737352",
      "qr_code_url": "https://www.tickettailor.com/userfiles/cache/barcode/st/attendee/50198/42bf63ef2a055b91a62f"
    }
  ]
}

Response Schema

Status Code 201

Name Type Description
» data [IssuedTicket] none
»» object string none
»» id string A unique identifier for the issued ticket
»» add_on_id string¦null A unique identifier for the associated add-on
»» barcode string Barcode text value
»» barcode_url string URL to barcode image
»» checked_in string Returns whether or not issued ticket is checked in
»» created_at integer Timestamp when issued ticket was created
»» custom_questions [any] Buyer provided answers to custom questions in checkout
»»» question string none
»»» answer string¦null none
»» description string none
»» email string¦null The order email address
»» event_id string ID of the event issued ticket belongs to
»» reference string¦null An external reference for imported tickets (via the API or Dashboard)
»» full_name string¦null Full name of attendee
»» first_name string¦null First name of attendee
»» last_name string¦null Last name of attendee
»» reservation string¦null Reservation from seating chart where applicable
»» status string none
»» source string¦null none
»» ticket_type_id string ID of the ticket type
»» updated_at integer Timestamp when issued ticket was last updated
»» voided_at integer¦null Timestamp when issued ticket was voided
»» order_id string¦null A unique identifier for the order
»» qr_code_url string URL to QR code image

Enumerated Values

Property Value
checked_in true
checked_in false
status valid
status void
source api
source dashboard_import

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Get a single issued ticket

Code samples

# You can also use wget
curl -X GET /v1/issued_tickets/{issued_ticket_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/issued_tickets/{issued_ticket_id}', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/issued_tickets/{issued_ticket_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/issued_tickets/{issued_ticket_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/issued_tickets/{issued_ticket_id}

Returns an issued ticket

Parameters

Name In Type Required Description
issued_ticket_id path string true The unique identifier for the issued ticket

Example responses

200 Response

{
  "object": "issued_ticket",
  "id": "it_50198",
  "barcode": "al4R5",
  "barcode_url": "https://www.tickettailor.com/userfiles/cache/barcode/qr/attendee/50198/42bf63ef2a055b91a62f",
  "checked_in": "false",
  "created_at": 1587042697,
  "custom_questions": [],
  "description": "Free ticket",
  "email": "john@example.com",
  "event_id": "ev_40980",
  "reference": "my reference code",
  "full_name": null,
  "first_name": null,
  "last_name": null,
  "status": "valid",
  "source": "api",
  "ticket_type_id": "tt_230656",
  "updated_at": 1587042697,
  "voided_at": null,
  "order_id": "or_737352",
  "qr_code_url": "https://www.tickettailor.com/userfiles/cache/barcode/st/attendee/50198/42bf63ef2a055b91a62f"
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the issued ticket
» add_on_id string¦null A unique identifier for the associated add-on
» barcode string Barcode text value
» barcode_url string URL to barcode image
» checked_in string Returns whether or not issued ticket is checked in
» created_at integer Timestamp when issued ticket was created
» custom_questions [any] Buyer provided answers to custom questions in checkout
»» question string none
»» answer string¦null none
» description string none
» email string¦null The order email address
» event_id string ID of the event issued ticket belongs to
» reference string¦null An external reference for imported tickets (via the API or Dashboard)
» full_name string¦null Full name of attendee
» first_name string¦null First name of attendee
» last_name string¦null Last name of attendee
» reservation string¦null Reservation from seating chart where applicable
» status string none
» source string¦null none
» ticket_type_id string ID of the ticket type
» updated_at integer Timestamp when issued ticket was last updated
» voided_at integer¦null Timestamp when issued ticket was voided
» order_id string¦null A unique identifier for the order
» qr_code_url string URL to QR code image

Enumerated Values

Property Value
checked_in true
checked_in false
status valid
status void
source api
source dashboard_import

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Void an issued ticket

Code samples

# You can also use wget
curl -X POST /v1/issued_tickets/{issued_ticket_id}/void \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/issued_tickets/{issued_ticket_id}/void', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/issued_tickets/{issued_ticket_id}/void', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/issued_tickets/{issued_ticket_id}/void', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/issued_tickets/{issued_ticket_id}/void

Mark an issued ticket as voided. This action is irreversible. This will only mark the ticket as voided (no longer valid) and will not cancel an entire order or issue a refund. Learn more about voiding an issued ticket.

You can also void an issued ticket to a hold, which will create a hold from the issued ticket and not put the allocation back on sale.

Body parameter

void_to_hold: "true"

Parameters

Name In Type Required Description
issued_ticket_id path string true The unique identifier for the issued ticket
body body object false none
» void_to_hold body string false Indicate whether to turn the existing issued ticket into a hold

Enumerated Values

Parameter Value
» void_to_hold true
» void_to_hold false

Example responses

200 Response

{
  "id": "it_123",
  "hold_id": "ho_345",
  "object": "issued_ticket",
  "voided": "true"
}

Response Schema

Status Code 200

Name Type Description
» id string ID of the voided ticket
» hold_id string¦null ID of the associated hold, if applicable, 'null' if not
» object string none
» voided string Voiding operation successful or not

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Check in

List check ins

Code samples

# You can also use wget
curl -X GET /v1/check_ins \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/check_ins', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/check_ins', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/check_ins', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/check_ins

Returns a paginated list of checkins

Parameters

Name In Type Required Description
limit query string false The number of items to retrieve
event_id query string false A string representing the event ID
issued_ticket_id query string false A string representing the issued ticket ID
created_at query integer false Unix timestamp filter that returns items with matched created_at value.
created_at.gt query integer false Unix timestamp filter that returns items with created_at greater than given value.
created_at.gte query integer false Unix timestamp filter that returns items with created_at greater than or equal given value.
created_at.lt query integer false Unix timestamp filter that returns items with created_at less than given value.
created_at.lte query integer false Unix timestamp filter that returns items with created_at less than or equal given value.
check_in_at query integer false Unix timestamp filter that returns items with matched check_in_at value.
check_in_at.gt query integer false Unix timestamp filter that returns items with check_in_at greater than the given value.
check_in_at.gte query integer false Unix timestamp filter that returns items with check_in_at greater than or equal to the given value.
check_in_at.lt query integer false Unix timestamp filter that returns items with check_in_at less than given value.
check_in_at.lte query integer false Unix timestamp filter that returns items with check_in_at less than or equal given value.

Example responses

200 Response

{
  "data": [
    {
      "object": "check_in",
      "id": "ci_123",
      "checkin_at": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "created_at": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "event_id": "ev_40980",
      "issued_ticket_id": "it_50199",
      "quantity": 1
    },
    {
      "object": "check_in",
      "id": "ci_456",
      "checkin_at": {
        "date": "2022-07-12",
        "formatted": "Tue 12 Jul 2022 10:30 PM",
        "iso": "2022-07-12T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1657610827
      },
      "created_at": {
        "date": "2022-07-12",
        "formatted": "Tue 12 Jul 2022 10:30 PM",
        "iso": "2022-07-12T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1657610827
      },
      "event_id": "ev_40980",
      "issued_ticket_id": "it_50245",
      "quantity": -1
    }
  ],
  "links": {
    "next": "/v1/check_ins?starting_after=ci_123",
    "previous": "/v1/check_ins?ending_before=ci_234"
  }
}

Response Schema

Status Code 200

Name Type Description
» data [object] none
»» object string none
»» id string none
»» checkin_at integer Timestamp of when the ticket is checked in or out
»» created_at integer Check in creation timestamp
»» event_id string The ID of the associated event
»» issued_ticket_id string The ID of the associated ticket that is to be checked in or out
»» quantity integer in=1, out=-1
» links object none
»» next string¦null none
»» previous string¦null none

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Create a check in

Code samples

# You can also use wget
curl -X POST /v1/check_ins \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/check_ins', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/check_ins', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/check_ins', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/check_ins

Creates a check in

Body parameter

check_in_at: 1657204364
issued_ticket_id: it_123
local_unique_id: 4c2eae10-2dd7-11ed-a261-0242ac120002-b3fd6e91-334e-4d99-8cb3-322452a54b2a
quantity: 1

Parameters

Name In Type Required Description
body body object true none
» check_in_at body integer false Unix timestamp for when the device checked the issued ticket. If not provided, our system will default to the current Unix timestamp.
» issued_ticket_id body string true Issued ticket identifier
» local_unique_id body string false Used for safely retrying a check in without creating it multiple times. If not provided, it will be generated automatically.
» quantity body integer true -1 for check out, 1 for check in

Enumerated Values

Parameter Value
» quantity -1
» quantity 1

Example responses

201 Response

{
  "object": "check_in",
  "id": "ci_123",
  "checkin_at": 1580211492,
  "created_at": 1580211492,
  "event_id": "ev_40980",
  "issued_ticket_id": "it_50199",
  "local_unique_id": "4c2eae10-2dd7-11ed-a261-0242ac120002-b3fd6e91-334e-4d99-8cb3-322452a54b2a",
  "quantity": 1
}

Response Schema

Status Code 201

Name Type Description
» object string none
» id string none
» checkin_at integer Timestamp of when the ticket is checked in or out
» created_at integer Check in creation timestamp
» event_id string The ID of the associated event
» issued_ticket_id string The ID of the associated ticket that is to be checked in or out
» local_unique_id string The optional unique ID that safegards from accidentally checking in multiple times
» quantity integer in=1, out=-1

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Discount code

List discounts

Code samples

# You can also use wget
curl -X GET /v1/discounts \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/discounts', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/discounts', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/discounts', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/discounts

Returns a list of paginated discounts

Parameters

Name In Type Required Description
limit query string false The number of items to retrieve
code query string false A string representing the discount code filter

Example responses

200 Response

{
  "data": [
    {
      "object": "discount",
      "id": "di_123",
      "code": "discount_test123",
      "max_redemptions": 5,
      "name": "Test discount",
      "price": 540,
      "ticket_types": [
        "tt_123",
        "tt_456",
        "tt_78"
      ],
      "times_redeemed": 3,
      "type": "fixed_amount"
    },
    {
      "object": "discount",
      "id": "di_234",
      "code": "discount_test123",
      "expires": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "max_redemptions": 2,
      "name": "Another test discount",
      "price_percent": 5,
      "ticket_types": [],
      "times_redeemed": 2,
      "type": "percentage"
    }
  ],
  "links": {
    "next": "/v1/discounts?starting_after=di_123",
    "previous": "/v1/discounts?ending_before=di_234"
  }
}

Response Schema

Status Code 200

Name Type Description
» data [object] none
» links object none
»» next string¦null none
»» previous string¦null none

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Create a discount code

Code samples

# You can also use wget
curl -X POST /v1/discounts \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/discounts', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/discounts', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/discounts', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/discounts

Creates a discount code that can be used on checkout.

Body parameter

code: discount_test123
expires: 1588368600
max_redemptions: 5
name: Test discount
price: 540
ticket_types:
  - tt_123
  - tt_456
  - tt_78
type: fixed_amount

Parameters

Name In Type Required Description
body body object true none
» booking_fee body integer¦null false Booking fee amount in cents. Could be null.
» booking_fee_percent body integer¦null false Percent of the booking fee. Could be null.
» code body string true Discount code
» expires body integer¦null false Discount code's expiry date as Unix timestamp
» max_redemptions body integer¦null false The maximum number of times this discount can be used.
» name body string true A descriptive name given to the discount
» price body integer¦null false Price in cents. Could be null.
» price_percent body integer¦null false Percent of the price. Could be null.
» ticket_types body [string] false An array of associated ticket types.
» type body string true Type of discount. Either a fixed amount or a percentage

Enumerated Values

Parameter Value
» type fixed_amount
» type percentage

Example responses

201 Response

{
  "object": "discount",
  "id": "di_123",
  "code": "discount_test123",
  "expires": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "max_redemptions": 5,
  "name": "Test discount",
  "price": 540,
  "ticket_types": [
    "tt_78",
    "tt_123",
    "tt_456"
  ],
  "times_redeemed": 3,
  "type": "fixed_amount"
}

Response Schema

Status Code 201

Name Type Description
» object string none
» id string A unique identifier for the discount
» booking_fee integer¦null Booking fee amount in cents. Could be null.
» booking_fee_percent integer¦null Percent of the booking fee. Could be null.
» code string Discount code
» expires object¦null Discount code's expiry date
»» date string ISO-8601 date for the start of the event
»» formatted string A formatted date string for the start of the event
»» iso string ISO-8601 date and time for the start of the event
»» time string Time for the start of the event
»» timezone string Timezone offset for the start of the event
»» unix integer Unix timestamp for the start of the event
» max_redemptions integer¦null The maximum number of times this discount can be used.
» name string A descriptive name given to the discount
» price integer¦null Price in cents. Could be null.
» price_percent integer¦null Percent of the price. Could be null.
» ticket_types [string] An array of associated ticket types.
» times_redeemed integer¦null The number of times that the discount was used
» type string Type of discount. Either a fixed amount or a percentage

Enumerated Values

Property Value
type fixed_amount
type percentage

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Get a single discount

Code samples

# You can also use wget
curl -X GET /v1/discounts/{discount_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/discounts/{discount_id}', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/discounts/{discount_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/discounts/{discount_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/discounts/{discount_id}

Retuns existing discount by ID

Parameters

Name In Type Required Description
discount_id path string true The unique identifier for the existing discount

Example responses

200 Response

{
  "object": "discount",
  "id": "di_123",
  "code": "discount_test123",
  "expires": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "max_redemptions": 5,
  "name": "Test discount",
  "price": 540,
  "ticket_types": [
    "tt_78",
    "tt_123",
    "tt_456"
  ],
  "times_redeemed": 3,
  "type": "fixed_amount"
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the discount
» booking_fee integer¦null Booking fee amount in cents. Could be null.
» booking_fee_percent integer¦null Percent of the booking fee. Could be null.
» code string Discount code
» expires object¦null Discount code's expiry date
»» date string ISO-8601 date for the start of the event
»» formatted string A formatted date string for the start of the event
»» iso string ISO-8601 date and time for the start of the event
»» time string Time for the start of the event
»» timezone string Timezone offset for the start of the event
»» unix integer Unix timestamp for the start of the event
» max_redemptions integer¦null The maximum number of times this discount can be used.
» name string A descriptive name given to the discount
» price integer¦null Price in cents. Could be null.
» price_percent integer¦null Percent of the price. Could be null.
» ticket_types [string] An array of associated ticket types.
» times_redeemed integer¦null The number of times that the discount was used
» type string Type of discount. Either a fixed amount or a percentage

Enumerated Values

Property Value
type fixed_amount
type percentage

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Update a discount

Code samples

# You can also use wget
curl -X POST /v1/discounts/{discount_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/discounts/{discount_id}', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/discounts/{discount_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/discounts/{discount_id}', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/discounts/{discount_id}

Updates an existing discount

Body parameter

code: discount_test123
expires: 1588368600
max_redemptions: 5
name: Test discount
price: 540
ticket_types:
  tt_123: "1"
  tt_456: "0"
  tt_78: ""
type: fixed_amount

Parameters

Name In Type Required Description
discount_id path string true The unique identifier for the existing discount
body body object false none
» booking_fee body integer¦null false Booking fee amount in cents. Could be null.
» booking_fee_percent body integer¦null false Percent of the booking fee. Could be null.
» code body string false Discount code
» expires body integer¦null false Discount code's expiry date as Unix timestamp
» max_redemptions body integer¦null false The maximum number of times this discount can be used.
» name body string false A descriptive name given to the discount
» price body integer¦null false Price in cents. Could be null.
» price_percent body integer¦null false Percent of the price. Could be null.
» ticket_types body object false An array of associated ticket types.
»» additionalProperties body string false none
»»» ticket_type_id body string false none
»»» discount_association body string false '1' = add to discount, '0' = remove from discount, '' = do nothing
» type body string false Type of discount. Either a fixed amount or a percentage

Enumerated Values

Parameter Value
» type fixed_amount
» type percentage

Example responses

200 Response

{
  "object": "discount",
  "id": "di_123",
  "code": "discount_test123",
  "expires": "2022-10-22 14:15:16",
  "face_value_amount": 540,
  "max_redemptions": 5,
  "name": "Test discount",
  "ticket_types": [
    "tt_123",
    "tt_78"
  ],
  "times_redeemed": 3,
  "type": "fixed_amount"
}

default Response

{
  "status": 0,
  "error_code": "string",
  "message": "string",
  "errors": [
    {
      "field": "string",
      "messages": [
        "string"
      ]
    }
  ]
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the discount
» booking_fee integer¦null Booking fee amount in cents. Could be null.
» booking_fee_percent integer¦null Percent of the booking fee. Could be null.
» code string Discount code
» expires object¦null Discount code's expiry date
»» date string ISO-8601 date for the start of the event
»» formatted string A formatted date string for the start of the event
»» iso string ISO-8601 date and time for the start of the event
»» time string Time for the start of the event
»» timezone string Timezone offset for the start of the event
»» unix integer Unix timestamp for the start of the event
» max_redemptions integer¦null The maximum number of times this discount can be used.
» name string A descriptive name given to the discount
» price integer¦null Price in cents. Could be null.
» price_percent integer¦null Percent of the price. Could be null.
» ticket_types [string] An array of associated ticket types.
» times_redeemed integer¦null The number of times that the discount was used
» type string Type of discount. Either a fixed amount or a percentage

Enumerated Values

Property Value
type fixed_amount
type percentage

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Delete a discount

Code samples

# You can also use wget
curl -X DELETE /v1/discounts/{discount_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('DELETE','/v1/discounts/{discount_id}', [
        'headers' => $headers,
         => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/discounts/{discount_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.delete(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.delete('/v1/discounts/{discount_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

DELETE /v1/discounts/{discount_id}

Delete a discount. This action is irreversible. The discount will be permanently removed.

Parameters

Name In Type Required Description
discount_id path string true The unique identifier for the existing discount

Example responses

200 Response

{
  "id": "di_123",
  "object": "discount",
  "deleted": true
}

Response Schema

Status Code 200

Name Type Description
» id string ID of the deleted discount
» object string none
» deleted string Delete operation successful

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Voucher

List vouchers

Code samples

# You can also use wget
curl -X GET /v1/vouchers \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/vouchers', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/vouchers', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/vouchers', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/vouchers

Returns a list of paginated of vouchers

Parameters

Name In Type Required Description
limit query string false The number of items to retrieve
expiry_date query integer false Unix timestamp filter that returns items with matched expiry_date value.
expiry_date.gt query integer false Unix timestamp filter that returns items with expiry_date greater than the given value.
expiry_date.gte query integer false Unix timestamp filter that returns items with expiry_date greater than or equal to the given value.
expiry_date.lt query integer false Unix timestamp filter that returns items with expiry_date less than given value.
expiry_date.lte query integer false Unix timestamp filter that returns items with expiry_date less than or equal given value.
created_at query integer false Unix timestamp filter that returns items with matched created_at value.
created_at.gt query integer false Unix timestamp filter that returns items with created_at greater than given value.
created_at.gte query integer false Unix timestamp filter that returns items with created_at greater than or equal given value.
created_at.lt query integer false Unix timestamp filter that returns items with created_at less than given value.
created_at.lte query integer false Unix timestamp filter that returns items with created_at less than or equal given value.

Example responses

200 Response

{
  "data": [
    {
      "object": "voucher",
      "id": "vo_123",
      "available_codes": 7,
      "event_series_ids": [
        "es_123",
        "es_234",
        "es_345"
      ],
      "expiry": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "name": "Test Voucher",
      "total_codes": 25,
      "value": 540
    },
    {
      "object": "voucher",
      "id": "vo_234",
      "available_codes": 1,
      "expiry": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "name": "Another Test Voucher",
      "total_codes": 12,
      "value": 300
    }
  ],
  "links": {
    "next": "/v1/vouchers?starting_after=vo_123",
    "previous": "/v1/vouchers?ending_before=vo_234"
  }
}

Response Schema

Status Code 200

Name Type Description
» data [object] none
»» object string none
»» id string A unique identifier for the voucher
»» available_codes integer The number of unused voucher codes belonging to the voucher
»» event_series_ids [string] List of event series IDs
»» expiry object¦null Voucher's expiry date
»»» date string ISO-8601 date for the start of the event
»»» formatted string A formatted date string for the start of the event
»»» iso string ISO-8601 date and time for the start of the event
»»» time string Time for the start of the event
»»» timezone string Timezone offset for the start of the event
»»» unix integer Unix timestamp for the start of the event
»» name string A descriptive name given to the voucher
»» total_codes integer Total number of voucher codes belonging to the voucher
»» value integer The integer value in cents given to the voucher
» links object none
»» next string¦null none
»» previous string¦null none

Create a voucher and its voucher codes

Code samples

# You can also use wget
curl -X POST /v1/vouchers \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/vouchers', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/vouchers', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/vouchers', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/vouchers

Creates a new voucher and the associated voucher codes, if given.

Body parameter

codes:
  - testCode1
  - testCode2
event_series_ids:
  - es_1
  - es_2
expiry: 1588368600
name: Test voucher with codes
value: 540

Parameters

Name In Type Required Description
body body object true none
» codes body [string] true An array of associated voucher codes.
» event_series_ids body [string] false An array of associated event series IDs
» expiry body integer true Voucher's expiry date as Unix timestamp.
» name body string true A descriptive name given to the voucher
» value body integer true Voucher value in cents.

Example responses

201 Response

{
  "object": "voucher",
  "id": "vo_123",
  "available_codes": 7,
  "event_series_ids": [
    "es_123",
    "es_234",
    "es_345"
  ],
  "expiry": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "name": "Test Voucher",
  "total_codes": 25,
  "value": 540
}

Response Schema

Status Code 201

Name Type Description
» object string none
» id string A unique identifier for the voucher
» available_codes integer The number of unused voucher codes belonging to the voucher
» event_series_ids [string] List of event series IDs
» expiry object¦null Voucher's expiry date
»» date string ISO-8601 date for the start of the event
»» formatted string A formatted date string for the start of the event
»» iso string ISO-8601 date and time for the start of the event
»» time string Time for the start of the event
»» timezone string Timezone offset for the start of the event
»» unix integer Unix timestamp for the start of the event
» name string A descriptive name given to the voucher
» total_codes integer Total number of voucher codes belonging to the voucher
» value integer The integer value in cents given to the voucher

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Get a single voucher

Code samples

# You can also use wget
curl -X GET /v1/vouchers/{voucher_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/vouchers/{voucher_id}', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/vouchers/{voucher_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/vouchers/{voucher_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/vouchers/{voucher_id}

Returns existing voucher by ID

Parameters

Name In Type Required Description
voucher_id path string true The unique identifier for the existing voucher

Example responses

200 Response

{
  "object": "voucher",
  "id": "vo_123",
  "available_codes": 7,
  "event_series_ids": [
    "es_123",
    "es_234",
    "es_345"
  ],
  "expiry": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "name": "Test Voucher",
  "total_codes": 25,
  "value": 540
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the voucher
» available_codes integer The number of unused voucher codes belonging to the voucher
» event_series_ids [string] List of event series IDs
» expiry object¦null Voucher's expiry date
»» date string ISO-8601 date for the start of the event
»» formatted string A formatted date string for the start of the event
»» iso string ISO-8601 date and time for the start of the event
»» time string Time for the start of the event
»» timezone string Timezone offset for the start of the event
»» unix integer Unix timestamp for the start of the event
» name string A descriptive name given to the voucher
» total_codes integer Total number of voucher codes belonging to the voucher
» value integer The integer value in cents given to the voucher

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Update a voucher

Code samples

# You can also use wget
curl -X POST /v1/vouchers/{voucher_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Content-Type: application/x-www-form-urlencoded' \
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Content-Type' => 'application/x-www-form-urlencoded',
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/vouchers/{voucher_id}', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/x-www-form-urlencoded',
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/vouchers/{voucher_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Content-Type': 'application/x-www-form-urlencoded',
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/vouchers/{voucher_id}', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/vouchers/{voucher_id}

Update an exiting voucher's name. If any voucher codes are given, create new voucher codes and associate them with the voucher

Body parameter

codes:
  - testCode1
  - testCode2
event_series_ids:
  es_1: "1"
  es_2: "0"
  es_3: ""
expiry: 1588368600
name: Test voucher with codes
value: 540

Parameters

Name In Type Required Description
voucher_id path string true The unique identifier for the existing voucher
body body object false none
» codes body [string]¦null false An array of associated voucher codes.
» event_series_ids body object false An array of associated event series IDs
»» additionalProperties body string false none
»»» event_series_id body string false none
»»» voucher_association body string false '1' = add to voucher, '0' = remove from voucher, '' = do nothing
» expiry body integer¦null false Voucher's expiry date as Unix timestamp.
» name body string¦null false A descriptive name given to the voucher
» value body integer¦null false Voucher value in cents.

Example responses

201 Response

{
  "object": "voucher",
  "id": "vo_123",
  "available_codes": 7,
  "event_series_ids": [
    "es_123",
    "es_234",
    "es_345"
  ],
  "expiry": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "name": "Test Voucher",
  "total_codes": 25,
  "value": 540
}

Response Schema

Status Code 201

Name Type Description
» object string none
» id string A unique identifier for the voucher
» available_codes integer The number of unused voucher codes belonging to the voucher
» event_series_ids [string] List of event series IDs
» expiry object¦null Voucher's expiry date
»» date string ISO-8601 date for the start of the event
»» formatted string A formatted date string for the start of the event
»» iso string ISO-8601 date and time for the start of the event
»» time string Time for the start of the event
»» timezone string Timezone offset for the start of the event
»» unix integer Unix timestamp for the start of the event
» name string A descriptive name given to the voucher
» total_codes integer Total number of voucher codes belonging to the voucher
» value integer The integer value in cents given to the voucher

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Delete a voucher

Code samples

# You can also use wget
curl -X DELETE /v1/vouchers/{voucher_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('DELETE','/v1/vouchers/{voucher_id}', [
        'headers' => $headers,
         => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/vouchers/{voucher_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.delete(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.delete('/v1/vouchers/{voucher_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

DELETE /v1/vouchers/{voucher_id}

Delete voucher and its associated voucher codes. This action is irreversible. The voucher and its voucher codes will be permanently removed.

Parameters

Name In Type Required Description
voucher_id path string true The unique identifier for the existing voucher

Example responses

200 Response

{
  "id": "vo_123",
  "object": "voucher",
  "deleted": true
}

Response Schema

Status Code 200

Name Type Description
» id string ID of the deleted voucher
» object string none
» deleted string Delete operation successful

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Voucher code

List voucher codes

Code samples

# You can also use wget
curl -X GET /v1/vouchers/{voucher_id}/codes \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/vouchers/{voucher_id}/codes', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/vouchers/{voucher_id}/codes', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/vouchers/{voucher_id}/codes', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/vouchers/{voucher_id}/codes

Returns a list of paginated voucher codes

Parameters

Name In Type Required Description
voucher_id path string true The unique identifier for the existing voucher
limit query string false The number of items to retrieve
expiry_date query integer false Unix timestamp filter that returns items with matched expiry_date value.
expiry_date.gt query integer false Unix timestamp filter that returns items with expiry_date greater than the given value.
expiry_date.gte query integer false Unix timestamp filter that returns items with expiry_date greater than or equal to the given value.
expiry_date.lt query integer false Unix timestamp filter that returns items with expiry_date less than given value.
expiry_date.lte query integer false Unix timestamp filter that returns items with expiry_date less than or equal given value.
created_at query integer false Unix timestamp filter that returns items with matched created_at value.
created_at.gt query integer false Unix timestamp filter that returns items with created_at greater than given value.
created_at.gte query integer false Unix timestamp filter that returns items with created_at greater than or equal given value.
created_at.lt query integer false Unix timestamp filter that returns items with created_at less than given value.
created_at.lte query integer false Unix timestamp filter that returns items with created_at less than or equal given value.

Example responses

200 Response

{
  "data": [
    {
      "object": "voucher_code",
      "id": "vc_123",
      "code": "Test Voucher Code",
      "expiry": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "used": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "value": 540,
      "voucher_id": "vo_123456"
    },
    {
      "object": "voucher_code",
      "id": "vc_345",
      "code": "Second Test Voucher Code",
      "expiry": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "used": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "value": 350,
      "voucher_id": "vo_123456"
    }
  ],
  "links": {
    "next": "/v1/vouchers/vo_123456/codes?starting_after=vc_123",
    "previous": "/v1/vouchers/vo_123456/codes?ending_before=vc_321"
  }
}

Response Schema

Status Code 200

Name Type Description
» data [object] none
»» object string none
»» id string A unique identifier for the voucher code
»» code string A descriptive name given to the voucher code
»» expiry object Voucher code's expiry date
»»» date string ISO-8601 date for the start of the event
»»» formatted string A formatted date string for the start of the event
»»» iso string ISO-8601 date and time for the start of the event
»»» time string Time for the start of the event
»»» timezone string Timezone offset for the start of the event
»»» unix integer Unix timestamp for the start of the event
»» used object¦null Voucher code's used date
»»» date string ISO-8601 date for the start of the event
»»» formatted string A formatted date string for the start of the event
»»» iso string ISO-8601 date and time for the start of the event
»»» time string Time for the start of the event
»»» timezone string Timezone offset for the start of the event
»»» unix integer Unix timestamp for the start of the event
»» value integer The integer value in cents given to the voucher code
»» voucher_id string A unique identifier of the voucher that the code belongs To
» links object none
»» next string¦null none
»» previous string¦null none

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Void a voucher code

Code samples

# You can also use wget
curl -X POST /v1/vouchers/{voucher_id}/codes/{voucher_code_id}/void \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('POST','/v1/vouchers/{voucher_id}/codes/{voucher_code_id}/void', [
        'headers' => $headers,
        'form_params' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

params = {:event_id => "ev_1", :ticket_type_id => "tt_230656", :email => "john@example.com", :full_name => "John Doe"}

resource = RestClient::Resource.new('/v1/vouchers/{voucher_id}/codes/{voucher_code_id}/void', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.post(params, :headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

params = {"event_id": "ev_1", "ticket_type_id": "tt_230656", "email": "john@example.com", "full_name": "John Doe"}

response = requests.post('/v1/vouchers/{voucher_id}/codes/{voucher_code_id}/void', data=params, auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

POST /v1/vouchers/{voucher_id}/codes/{voucher_code_id}/void

Mark a voucher code as voided. This action is irreversible. This will only mark one voucher code as voided, and will not impact the other related codes.

Parameters

Name In Type Required Description
voucher_id path string true The unique identifier for the voucher
voucher_code_id path string true The unique identifier for the voucher code

Example responses

200 Response

{
  "id": "vc_123",
  "object": "voucher_code",
  "voided": true
}

Response Schema

Status Code 200

Name Type Description
» id string ID of the voided voucher code
» object string none
» voided string Voiding operation successful or not

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Event

List all events

Code samples

# You can also use wget
curl -X GET /v1/events \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/events', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/events', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/events', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/events

Returns a list of events belonging to the box office. The event series and event occurrence endpoints should be used instead of this endpoint as they provide more optimised ways to search and filter events.

Parameters

Name In Type Required Description
start_at query integer false Unix timestamp filter that returns items with matched start_at value.
start_at.gt query integer false Unix timestamp filter that returns items with start_at greater than given value.
start_at.gte query integer false Unix timestamp filter that returns items with start_at greater than or equal given value.
start_at.lt query integer false Unix timestamp filter that returns items with start_at less than given value.
start_at.lte query integer false Unix timestamp filter that returns items with start_at less than or equal given value.
end_at query integer false Unix timestamp filter that returns items with matched end_at value.
end_at.gt query integer false Unix timestamp filter that returns items with end_at greater than given value.
end_at.gte query integer false Unix timestamp filter that returns items with end_at greater than or equal given value.
end_at.lt query integer false Unix timestamp filter that returns items with end_at less than given value.
end_at.lte query integer false Unix timestamp filter that returns items with end_at less than or equal given value.
starting_after query string false A paginator cursor value of object id (e.g. "or_123") that defines place in the list. To fetch next page of results, use the last object id from the current result list, e.g. starting_after=or_223.
ending_before query string false A paginator cursor value of object id (e.g. "or_123") that defines place in the list. To fetch previous page of results, use the first object id from the current result list, e.g. ending_before=or_123.
limit query string false The number of items to retrieve
status query string false A comma separated list of event series status. (e.g. draft,published)

Enumerated Values

Parameter Value
status published
status draft
status sales_closed

Example responses

200 Response

{
  "data": [
    {
      "object": "event",
      "id": "ev_1",
      "access_code": null,
      "call_to_action": "Buy tickets / Join the guestlist",
      "created_at": 1583771084,
      "currency": "gbp",
      "description": null,
      "end": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 10:30 PM",
        "iso": "2020-05-01T22:30:00+01:00",
        "time": "22:30",
        "timezone": "+01:00",
        "unix": 1588368600
      },
      "hidden": "false",
      "images": {
        "header": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,g_center,h_326,q_85,w_1024/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg",
        "thumbnail": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,h_108,q_85,w_108/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg"
      },
      "name": "Hackney Downs 2020 Tulip Festival",
      "online_event": "false",
      "payment_methods": [
        {
          "external_id": null,
          "id": "pm_6687",
          "instructions": "Pay when you arrive to festival",
          "name": "Pay on the door",
          "type": "offline"
        },
        {
          "external_id": "seller222@example.com",
          "id": "pm_6691",
          "instructions": null,
          "name": null,
          "type": "paypal"
        }
      ],
      "private": "false",
      "start": {
        "date": "2020-05-01",
        "formatted": "Fri 1 May 2020 6:00 PM",
        "iso": "2020-05-01T18:00:00+01:00",
        "time": "18:00",
        "timezone": "+01:00",
        "unix": 1588352400
      },
      "status": "published",
      "ticket_groups": [
        {
          "id": "tg_21099",
          "max_per_order": null,
          "name": "April 20th",
          "sort_order": 50050,
          "ticket_ids": [
            "tt_230625",
            "tt_230626"
          ]
        },
        {
          "id": "tg_21100",
          "max_per_order": null,
          "name": "April 21st",
          "sort_order": 50100,
          "ticket_ids": [
            "tt_230631",
            "tt_230632"
          ]
        }
      ],
      "ticket_types": [
        {
          "object": "ticket_type",
          "id": "tt_230625",
          "access_code": null,
          "booking_fee": 0,
          "description": null,
          "group_id": "tg_21099",
          "max_per_order": 100,
          "min_per_order": 1,
          "name": "4.20 Adult (13-61) - Presale",
          "price": 800,
          "status": "hidden",
          "sort_order": 50050,
          "type": "paid",
          "quantity": 10000,
          "quantity_held": 0,
          "quantity_issued": 5000,
          "quantity_total": 15000
        },
        {
          "object": "ticket_type",
          "id": "tt_230626",
          "access_code": null,
          "booking_fee": 0,
          "description": null,
          "group_id": "tg_21099",
          "max_per_order": 100,
          "min_per_order": 1,
          "name": "4.20 Senior (62+) - Presale",
          "price": 600,
          "status": "on_sale",
          "sort_order": 50051,
          "type": "paid",
          "quantity": 10000,
          "quantity_held": 0,
          "quantity_issued": 2000,
          "quantity_total": 12000
        },
        {
          "object": "ticket_type",
          "id": "tt_230631",
          "access_code": null,
          "booking_fee": 0,
          "description": null,
          "group_id": "tg_21100",
          "max_per_order": 100,
          "min_per_order": 1,
          "name": "4.21 Adult (13-61) - Presale",
          "price": 800,
          "status": "on_sale",
          "sort_order": 50100,
          "type": "paid",
          "quantity": 10000,
          "quantity_held": 0,
          "quantity_issued": 4000,
          "quantity_total": 14000
        },
        {
          "object": "ticket_type",
          "id": "tt_230632",
          "access_code": null,
          "booking_fee": 0,
          "description": null,
          "group_id": "tg_21100",
          "max_per_order": 100,
          "min_per_order": 1,
          "name": "4.21 Senior (62+) - Presale",
          "price": 600,
          "status": "on_sale",
          "sort_order": 50101,
          "type": "paid",
          "quantity": 10000,
          "quantity_held": 0,
          "quantity_issued": 1000,
          "quantity_total": 11000
        }
      ],
      "tickets_available": "true",
      "timezone": "Europe/London",
      "total_holds": 0,
      "total_issued_tickets": 2,
      "total_orders": 1,
      "unavailable": "false",
      "unavailable_status": null,
      "url": "https://www.tickettailor.com/events/flowerfestival/40980",
      "venue": {
        "name": null,
        "postal_code": null
      }
    }
  ],
  "links": {
    "next": "/v1/events?starting_after=ev_123",
    "previous": "/v1/events?ending_before=ev_100"
  }
}

Response Schema

Status Code 200

Name Type Description
» data [Event] none
»» object string none
»» id string A unique identifier for the event
»» access_code string¦null Code to access a protected event
»» call_to_action string Call to action text used on the event page
»» created_at integer none
»» currency string Information about the currency the event is configured to use
»» description string¦null Description of the event
»» end object none
»»» date string ISO-8601 date for the end of the event
»»» formatted string A formatted date string for the end of the event
»»» iso string ISO-8601 date and time for the end of the event
»»» time string Time of the end of the event
»»» timezone string Timezone offset for the end of the event
»»» unix integer Unix timestamp for for the end of the event
»» event_series_id string Recurring events are grouped by an event_series_id
»» hidden string True, if event is set to hidden
»» images object Images that have been uploaded to this event
»»» header string Image URL of the header image used on your event page
»»» thumbnail string Image URL of the thumbnail used on your event page
»» name string Name of the event
»» online_event string Returns whether or not the event is online
»» payment_methods [any] none
»»» external_id string A unique identifier for the payment method
»»» id string A unique identifier for internal payment methods
»»» type string The type of payment method
»»» name string Name of the payment method
»»» instructions string Instructions for the customer on how to pay. Used for offline payments.
»» private string Returns whether or not the event is private
»» start object none
»»» date string ISO-8601 date for the start of the event
»»» formatted string A formatted date string for the start of the event
»»» iso string ISO-8601 date and time for the start of the event
»»» time string Time of the start of the event
»»» timezone string Timezone offset for the start of the event
»»» unix integer Unix timestamp for the start of the event
»» status string Status of the event
»» ticket_groups [any] none
»»» id string A unique ticket group identifier
»»» max_per_order integer Maximum number of ticket types that this group can sell
»»» name string Name of the ticket types group
»»» sort_order integer Sort index of the group in the UI
»»» ticket_ids [any] Unique identifiers of ticket type ids that belong to this group
»»»» id string none
»» ticket_types [TicketType]¦null none
»»» object string none
»»» id string A unique identifier for the ticket type
»»» access_code string¦null Code to access a hidden ticket
»»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»»» description string¦null none
»»» group_id string¦null ID of the group this ticket type belongs to
»»» has_overrides string Specifies whether the ticket type has overrides
»»» max_per_order integer Maximum number of ticket types you can select per order
»»» min_per_order integer Minimum number of ticket types you can select per order
»»» name string Name of the ticket type
»»» override_id string¦null The ID of the override associated with the ticket type
»»» price any Cost of the ticket type

anyOf

Name Type Description
»»»» anonymous integer none

or

Name Type Description
»»»» anonymous number none

continued

Name Type Description
»»» status string Status of the ticket type
»»» sort_order integer Sort index of ticket type in the UI
»»» type string none
»»» quantity integer Number available for purchase
»»» quantity_held integer Number held
»»» quantity_issued integer Number issued
»»» quantity_total integer Total number including issued and still available
»» tickets_available string¦null Are there any ticket types available?
»» timezone string TZ format timezone string
»» total_holds integer Total number of holds
»» total_issued_tickets integer Total number of issued tickets
»» total_orders integer Total number of orders
»» unavailable string True, if event is set to unavailable
»» unavailable_status string¦null optional custom status message when event is set to be unavailable
»» url string Event page URL
»» venue object none
»»» name string Name of the venue
»»» postal_code string Postal code of the venue
» links object none
»» next string¦null none
»» previous string¦null none

Enumerated Values

Property Value
currency gbp
currency usd
currency eur
currency sgd
currency aud
currency brl
currency cad
currency czk
currency dkk
currency hkd
currency huf
currency ils
currency jpy
currency myr
currency mxn
currency nok
currency nzd
currency php
currency pln
currency rub
currency sek
currency chf
currency twd
currency thb
currency try
hidden true
hidden false
online_event true
online_event false
type stripe
type paypal
type offline
private true
private false
status draft
status published
status sales_closed
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free
tickets_available true
tickets_available false
unavailable true
unavailable false

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Retrieve an event

Code samples

# You can also use wget
curl -X GET /v1/events/{event_id} \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/events/{event_id}', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/events/{event_id}', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/events/{event_id}', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/events/{event_id}

Returns an event belonging to the box office. The event series and event occurrence endpoints should be used instead of this endpoint as they provide more fine grained ways to fetch event data.

Parameters

Name In Type Required Description
event_id path string true The unique identifier for the event

Example responses

200 Response

{
  "object": "event",
  "id": "ev_1",
  "access_code": null,
  "call_to_action": "Buy tickets / Join the guestlist",
  "created_at": 1583771084,
  "currency": "gbp",
  "description": null,
  "end": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 10:30 PM",
    "iso": "2020-05-01T22:30:00+01:00",
    "time": "22:30",
    "timezone": "+01:00",
    "unix": 1588368600
  },
  "hidden": "false",
  "images": {
    "header": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,g_center,h_326,q_85,w_1024/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg",
    "thumbnail": "https://d37ecpm5it19bz.cloudfront.net/c_crop,dpr_1.0,h_1921,q_100,w_1922,x_479,y_0/c_scale,h_108,q_85,w_108/v1/stitching/userfiles/acfi9eknr1vur6wguu5s.jpg"
  },
  "name": "Hackney Downs 2020 Tulip Festival",
  "online_event": "false",
  "payment_methods": [
    {
      "external_id": null,
      "id": "pm_6687",
      "instructions": "Pay when you arrive to festival",
      "name": "Pay on the door",
      "type": "offline"
    },
    {
      "external_id": "seller222@example.com",
      "id": "pm_6691",
      "instructions": null,
      "name": null,
      "type": "paypal"
    }
  ],
  "private": "false",
  "start": {
    "date": "2020-05-01",
    "formatted": "Fri 1 May 2020 6:00 PM",
    "iso": "2020-05-01T18:00:00+01:00",
    "time": "18:00",
    "timezone": "+01:00",
    "unix": 1588352400
  },
  "status": "published",
  "ticket_groups": [
    {
      "id": "tg_21099",
      "max_per_order": null,
      "name": "April 20th",
      "sort_order": 50050,
      "ticket_ids": [
        "tt_230625",
        "tt_230626"
      ]
    },
    {
      "id": "tg_21100",
      "max_per_order": null,
      "name": "April 21st",
      "sort_order": 50100,
      "ticket_ids": [
        "tt_230631",
        "tt_230632"
      ]
    }
  ],
  "ticket_types": [
    {
      "object": "ticket_type",
      "id": "tt_230625",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Adult (13-61) - Presale",
      "price": 800,
      "status": "hidden",
      "sort_order": 50050,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 5000,
      "quantity_total": 15000
    },
    {
      "object": "ticket_type",
      "id": "tt_230626",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21099",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.20 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50051,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 2000,
      "quantity_total": 12000
    },
    {
      "object": "ticket_type",
      "id": "tt_230631",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21100",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.21 Adult (13-61) - Presale",
      "price": 800,
      "status": "on_sale",
      "sort_order": 50100,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 4000,
      "quantity_total": 14000
    },
    {
      "object": "ticket_type",
      "id": "tt_230632",
      "access_code": null,
      "booking_fee": 0,
      "description": null,
      "group_id": "tg_21100",
      "max_per_order": 100,
      "min_per_order": 1,
      "name": "4.21 Senior (62+) - Presale",
      "price": 600,
      "status": "on_sale",
      "sort_order": 50101,
      "type": "paid",
      "quantity": 10000,
      "quantity_held": 0,
      "quantity_issued": 1000,
      "quantity_total": 11000
    }
  ],
  "tickets_available": "true",
  "timezone": "Europe/London",
  "total_holds": 0,
  "total_issued_tickets": 2,
  "total_orders": 1,
  "unavailable": "false",
  "unavailable_status": null,
  "url": "https://www.tickettailor.com/events/flowerfestival/40980",
  "venue": {
    "name": null,
    "postal_code": null
  }
}

Response Schema

Status Code 200

Name Type Description
» object string none
» id string A unique identifier for the event
» access_code string¦null Code to access a protected event
» call_to_action string Call to action text used on the event page
» created_at integer none
» currency string Information about the currency the event is configured to use
» description string¦null Description of the event
» end object none
»» date string ISO-8601 date for the end of the event
»» formatted string A formatted date string for the end of the event
»» iso string ISO-8601 date and time for the end of the event
»» time string Time of the end of the event
»» timezone string Timezone offset for the end of the event
»» unix integer Unix timestamp for for the end of the event
» event_series_id string Recurring events are grouped by an event_series_id
» hidden string True, if event is set to hidden
» images object Images that have been uploaded to this event
»» header string Image URL of the header image used on your event page
»» thumbnail string Image URL of the thumbnail used on your event page
» name string Name of the event
» online_event string Returns whether or not the event is online
» payment_methods [any] none
»» external_id string A unique identifier for the payment method
»» id string A unique identifier for internal payment methods
»» type string The type of payment method
»» name string Name of the payment method
»» instructions string Instructions for the customer on how to pay. Used for offline payments.
» private string Returns whether or not the event is private
» start object none
»» date string ISO-8601 date for the start of the event
»» formatted string A formatted date string for the start of the event
»» iso string ISO-8601 date and time for the start of the event
»» time string Time of the start of the event
»» timezone string Timezone offset for the start of the event
»» unix integer Unix timestamp for the start of the event
» status string Status of the event
» ticket_groups [any] none
»» id string A unique ticket group identifier
»» max_per_order integer Maximum number of ticket types that this group can sell
»» name string Name of the ticket types group
»» sort_order integer Sort index of the group in the UI
»» ticket_ids [any] Unique identifiers of ticket type ids that belong to this group
»»» id string none
» ticket_types [TicketType]¦null none
»» object string none
»» id string A unique identifier for the ticket type
»» access_code string¦null Code to access a hidden ticket
»» booking_fee integer Optional booking fee which is charged per ticket type to the customer and the funds are paid to you. We would recommend charging no more than 10% of the ticket price.
»» description string¦null none
»» group_id string¦null ID of the group this ticket type belongs to
»» has_overrides string Specifies whether the ticket type has overrides
»» max_per_order integer Maximum number of ticket types you can select per order
»» min_per_order integer Minimum number of ticket types you can select per order
»» name string Name of the ticket type
»» override_id string¦null The ID of the override associated with the ticket type
»» price any Cost of the ticket type

anyOf

Name Type Description
»»» anonymous integer none

or

Name Type Description
»»» anonymous number none

continued

Name Type Description
»» status string Status of the ticket type
»» sort_order integer Sort index of ticket type in the UI
»» type string none
»» quantity integer Number available for purchase
»» quantity_held integer Number held
»» quantity_issued integer Number issued
»» quantity_total integer Total number including issued and still available
» tickets_available string¦null Are there any ticket types available?
» timezone string TZ format timezone string
» total_holds integer Total number of holds
» total_issued_tickets integer Total number of issued tickets
» total_orders integer Total number of orders
» unavailable string True, if event is set to unavailable
» unavailable_status string¦null optional custom status message when event is set to be unavailable
» url string Event page URL
» venue object none
»» name string Name of the venue
»» postal_code string Postal code of the venue

Enumerated Values

Property Value
currency gbp
currency usd
currency eur
currency sgd
currency aud
currency brl
currency cad
currency czk
currency dkk
currency hkd
currency huf
currency ils
currency jpy
currency myr
currency mxn
currency nok
currency nzd
currency php
currency pln
currency rub
currency sek
currency chf
currency twd
currency thb
currency try
hidden true
hidden false
online_event true
online_event false
type stripe
type paypal
type offline
private true
private false
status draft
status published
status sales_closed
has_overrides true
has_overrides false
status on_sale
status sold_out
status unavailable
status hidden
status admin_only
status locked
type paid
type free
tickets_available true
tickets_available false
unavailable true
unavailable false

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Ping

Ping server

Code samples

# You can also use wget
curl -X GET /v1/ping \
  -u 'sk_1000_1000_VGlja2V0VGFpbG9y:'
  -H 'Accept: application/json'

<?php

require 'vendor/autoload.php';

$headers = [
    'Accept' => 'application/json',

    ];

$client = new \GuzzleHttp\Client([
   'auth' => [
       'sk_1000_1000_VGlja2V0VGFpbG9y',
       ''
   ]
]);

// Define array of request body.
$request_body = [];

try {
    $response = $client->request('GET','/v1/ping', [
        'headers' => $headers,
        'json' => $request_body,
       ]
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json'
}

resource = RestClient::Resource.new('/v1/ping', :user => 'sk_1000_1000_VGlja2V0VGFpbG9y', :password =>  '' )
response = resource.get(:headers => headers)

parsedResponse = JSON.parse(response)

import requests
headers = {
  'Accept': 'application/json'
}

response = requests.get('/v1/ping', auth=('sk_1000_1000_VGlja2V0VGFpbG9y', ''), headers=headers)

print response.json()

GET /v1/ping

Checks if server is responsive

Example responses

200 Response

{
  "version": "pong"
}

Response Schema

Status Code 200

Name Type Description
» version string none

Status Code default

Name Type Description
» status integer Http status code
» error_code string Readable error code
» message string Detailed error message
» errors [object] Validation errors if POST request was sent. Otherwise not present.
»» field string Field name that failed validation
»» messages [string] Validation error message

Pagination

Endpoints which enumerate objects support cursor-based (eg. or_1234) pagination via the starting_after and ending_before parameters. Both parameters take an existing value and return objects in reverse chronological order. If both parameters are provided, only ending_before is used.

Request Arguments
ending_before
optional
Returns objects listed before the named object
starting_after
optional
Returns objects listed after the named object
limit
optional
Limits the number of results per-page.
Maximum: 100

Rate limiting

You can make up to 2000 requests per hour to each API. To see your current rate limit status, check the HTTP headers returned by any API request. If you’re running into this error frequently, or think you need a higher rate limit, drop us a line at hi@tickettailor.com.

Header Name
X-Rate-Limit-Limit The maximum number of requests that the consumer is permitted to make per hour.
X-Rate-Limit-Remaining The number of requests remaining in the current rate limit window.
X-Rate-Limit-Reset The number of seconds left in the current period.
Retry-After The number of seconds to wait until the rate limit window resets. This is only sent when the rate limit is reached.

Errors


status: integer

error_code: string

message: string

The Ticket Tailor API returns conventional HTTP response codes to indicate the success or failure of an API request. For errors, the response will include additional information about what went wrong, encoded in the response as JSON.

Status Error code Message
400 Bad Request The request was invalid, often due to a missing a required parameter.
401 Unauthorized Your request was not authenticated correctly.
403 Forbidden You do not have permission to perform the request.
404 Not Found The requested resource does not exist.
422 Validation error A validation error occurred.
429 Too Many Requests Too many requests hit the API too quickly.
50X Internal Server Error An error occurred on Ticket Tailor's end with our API.

Webhooks

Introduction

Webhooks can be used to send updates to clients when data in Ticket Tailor has changed. After you have subscribed to a webhook, your app will receive updates, instead of having to continuously poll API for changes.

Configuration

Go to: Settings > API > Webhooks

Webhooks are triggered by events in Ticket Tailor. At the moment we support the following events:

Order

Event Description
Created Fires a webhook when an order is created.
Updated Fires a webhook when an order is updated. This includes cancelling an order.

Issued ticket

Event Description
Created Fires a webhook when an issued ticket is created.
Updated Fires a webhook when an issued ticket is updated. This includes voiding issued tickets.

Event

Event Description
Created Fires a webhook when an event is created.
Updated Fires a webhook when an event is updated.
Deleted Fires a webhook when an event is deleted.

Structure

Webhook requests are application/json POST requests with the following data structure:

It is good practice to make clients idempotent in case webhooks are sent more than once. You can track ids of already processed requests to not execute tasks more than once.

Security

<?php

$sharedSecret = 'ABCD123';
$body = file_get_contents('php://input');
$headerParts = explode(',', $_SERVER['HTTP_TICKETTAILOR_WEBHOOK_SIGNATURE']);
$timestamp = explode('=', $headerParts[0])[1];
$signature = explode('=', $headerParts[1])[1];

$hash = hash_hmac('sha256', $timestamp . $body, $sharedSecret);
if (! hash_equals($hash, $signature)) {
    throw new \Exception('Invalid signature');
}

$tolerance = 60 * 5; // 5 minutes
if ((time() - $timestamp) > $tolerance) {
    throw new \Exception('Webhook is out of date');
}
sharedSecret = 'ABCD123'
headerParts = request.headers['TicketTailor-Webhook-Signature'].split(',')
timestamp = headerParts[0].split('=')[1]
signature = headerParts[1].split('=')[1]

hash = OpenSSL::HMAC.hexdigest(
  OpenSSL::Digest.new('sha256'), sharedSecret, timestamp + request.body.string
)

if ActiveSupport::SecurityUtils.secure_compare(signature, hash)
  logger.info 'Valid signature'
else
  logger.info 'Invalid signature'
end

tolerance = 60 * 5 # 5 minutes
if Time.now.to_i - timestamp.to_i > tolerance
  logger.info 'Out of date'
end
sharedSecret = 'ABCD123'

headerParts = request.headers.get('TicketTailor-Webhook-Signature').split(',')
timestamp = headerParts[0].split('=')[1]
signature = headerParts[1].split('=')[1]
requestBody = request.data

newSignature = hmac.new(
    key=sharedSecret,
    msg=timestamp + requestBody,
    digestmod=hashlib.sha256
)

if hmac.compare_digest(newSignature.hexdigest(), str(signature)):
    logging.info("Valid signature")
else:
    logging.error("Invalid signature")

tolerance = 60 * 5 # 5 mintues
if time.time() - int(timestamp) > tolerance:
    logging.error("Out of date")

Webhook requests are signed using a shared secret. You can find this in the webooks dashboard. The resulting signature with signing timestamp is sent with the request in Tickettailor-Webhook-Signature header. We recommend to verify that the request is sent from Ticket Tailor. To do this, you must generate a HMAC-SHA256 signature of the request payload combined with the timestamp, compare it with the sent signature from Ticket Tailor, and verify they match.

We also recommend to invalidate webhooks received where the sent timestamp is older than 5 minutes.

See the code examples of how to verify webhook request.

Retry Strategy

Webhook calls are retried with exponential backoff over a 72 hour period. We mark a webhook as failed immediately when we receive redirect response or network error.

You can see all sent webhooks, their status and next delivery due date on the webhook history page.

Go to: Settings > API > Webhooks > Select "History" from webhook subscription actions dropdown menu.

Retry Interval
01 Immediately
02 00:00:16
03 00:01:21
04 00:04:16
05 00:10:25
06 00:21:36
07 00:40:01
08 01:08:16
09 01:49:21
10 02:46:40
11 04:04:01
12 05:45:36
13 07:56:01
14 10:40:16
15 14:03:45
16 18:12:16
17 23:12:01
18 29:09:36
19 36:12:01
20 44:26:40
21 54:01:21
22 65:04:16

NOTE if a webhook continuously fails for 5 days, we will send warning email regarding disabling the webhook, and disable webhook if it continuously fails for 10 days. It will then have to be manually re-enabled by you in the Webhooks dashboard.

Testing

As webhooks need a public URL, it can be difficult to test your integration when developing locally. To overcome this issue we suggest two ways to test your webhooks: