About Ticket Definitions v3

With the Ticket Definitions API, you can create definitions for tickets. A definition includes the following ticket settings:

  • Fee type. Determine whether the fee will be paid by a guest or a seller.
  • Pricing. Define different ticket prices based on factors such as early bird discounts, VIP packages, group rates, or special promotions. Several pricing methods are available for you to select from: Fixed price, Guest price, Free. Additionally, you can customize prices for different groups of people using Price options.
  • Availability. Set the ticket limit available to buy. Also, you are able to check number of purchased or reserved tickets.
  • Sale period. Set the sale start and end dates. Also, when defining the sale period, it is possible to choose to display event tickets to customers even before the sale starts.

Before you begin

It’s important to note the following points before starting to code:

  • Install the Wix Events & Tickets app from Wix App Market.
  • Ticket definition is not the same as ticket. Ticket definitions are used to define settings for a set of tickets. After paying for selected tickets, the Checkout API automatically generates the ticket.

Use cases

Terminology

  • Pricing method: Different pricing methods are available for an event:
    • Fixed price: All tickets in the same definition are sold at the exact same price, regardless of when they are purchased or other factors.
    • Guest price: A minimum price a guest must pay for a ticket. For example, money goes to donation.
    • Price options: All tickets in the same ticket definition are priced at different rates, such as different prices for adults, children, and students.
  • Ticket availability: The status of ticket inventory, indicating whether tickets are available or sold out. This type can also include availability limits and timeframes for ticket sales.
  • Sale period: Duration of time during which event tickets are available for purchase.
  • Event Dashboard: Control center in the Wix site UI for managing site event settings and features.
Was this helpful?
Yes
No

Ticket Definitions v3: Supported Filters and Sorting

The following table shows field support for filters and sorting for the Ticket Definition object:

FieldQuery Filter OperatorsSortable
id$eq, $ne, $lt, $lte, $gt, $gte, $in, $nin, $existsSortable
eventId$eq, $ne, $lt, $lte, $gt, $gte, $in, $nin, $existsSortable
name$eq, $ne, $lt, $lte, $gt, $gte, $in, $nin, $existsSortable
description$eq, $ne, $lt, $lte, $gt, $gte, $in, $nin, $existsSortable
limit$eq, $ne, $lt, $lte, $gt, $gte, $in, $nin, $existsSortable
pricing_method.pricing_type$eq, $ne, $lt, $lte, $gt, $gte, $in, $nin, $existsSortable
feeType$eq, $ne, $lt, $lte, $gt, $gte, $in, $nin, $existsSortable
saleStatus$eq, $ne, $lt, $lte, $gt, $gte, $in, $nin, $existsSortable
updatedDate$eq, $ne, $lt, $lte, $gt, $gte, $in, $nin, $existsSortable
createdDate$eq, $ne, $lt, $lte, $gt, $gte, $in, $nin, $existsSortable
hidden$eq, $ne, $in, $nin, $existsSortable
pricing_method.free$eq, $ne, $in, $nin, $existsSortable

Related content: API Query Language, Ticket Definitions Query endpoint

Was this helpful?
Yes
No

Ticket Definitions v3: Sample Use Cases & Flows

This article presents possible use cases and corresponding sample flows that your app can support. It provides a useful starting point as you plan your app's implementation.

Add a specific-price ticket counter for an event

This use case demonstrates how you can update your event site with a ticket counter for specific-price tickets. This counter provides real-time information on the availability of tickets for customers to see. For example, your page can have a counter that says "Only 3 tickets left for this price." By displaying the number of tickets remaining, you can motivate customers to buy tickets promptly.

Note: This flow assumes you have already created the UI component of the counter for your site.

To create a ticket counter, follow these steps:

  1. Call Get Ticket Definition and retrieve either:
  • The salesDetails.unsoldCount and fixedPrice.value values (for fixedPrice pricing method).
  • The salesDetails.unsoldCount and pricingOptions.optionDetails.price.value field values (for optionalPrice pricing method).
  1. Pass these retrieved values in your app to initialize the counter on your website, displaying the number of available tickets at the specified price.

  2. On an ongoing basis, listen for each new ticket purchase using the Order Confirmed Webhook.

  3. When the webhook is triggered, you'll receive an order in the payload. Retrieve the ticketDefinitionId value from the event data.

  4. Send the extracted ticketDefinitionId value to your site and compare it with the ticket definition ID for which the counter is set. If they match, call Get Ticket Definition again to retrieve the updated salesDetails.unsoldCount value. Send this new decreased value to your website to update the ticket counter.

Sync ticket definitions with an external ticketing system

If you're using a Wix site to manage events and another system to handle ticketing, you can synchronize ticket definitions between them whenever a definition is updated on the site. This includes aspects such as ticket types, pricing, availability, and any other relevant ticket settings. This synchronization eliminates the need for manual updates and reduces the risk of discrepancies between systems.

To upload and update all ticket definitions defined on the Wix site to your external system for the first time, follow these flows:

Part 1: Initial setup

  1. Create a custom field in your system that stores the ticket definition ID for a particular event to ensure a 1-to-1 relationship with the external ticketing system. Craft your code so that this ID won't be overwritten by future updates from your app.

  2. Create a mapping from the site ticket definition fields to the system fields that will be used whenever site ticket definitions and the external system are synchronized.

  3. Query Ticket Definitions by eventId and send the relevant information to the external ticketing system.

Part 2: Synchronize to the external system

  1. On an ongoing basis, listen for changes to site ticket definitions with these webhooks:

  2. When one of the above webhooks is triggered, you'll receive the ticket definition in the payload. You can bring those changes to the ticketing system by retrieving the relevant info from the payload, and use mapping to take action on the external system:

    • For created and updated ticket definitions retrieve the relevant info from the createdEvent.currentEntity object.

    • For deleted ticket definitions retrieve the createdEvent.currentEntity.id value.

Notify customers when tickets go on sale

Let customers know when ticket sales for an event begin. You can send automated notifications to customers with email or push notifications. These notifications make customers aware of ticket availability so they can secure their tickets promptly.

Note: This flow assumes your customers already have the ability to subscribe to your newsletters.

To send notifications about the start of ticket sales, follow these steps:

  1. Get Ticket Definition.

  2. Retrieve the salePeriod.startDate field value, and write your code so that the value can be passed to your marketing tool.

  3. Request and filter the list of subscribers in your external marketing tool based on customers subscription status for the current event.

  4. When the ticket sale start date arrives, send notifications to your customers who have opted in to receive marketing emails.

Was this helpful?
Yes
No

Ticket Definition Object

Properties
idstringRead-onlyformat GUID
Ticket definition ID.

eventIdstringformat GUID
Event ID to which the ticket definition belongs.

revisionintegerRead-onlyformat int64
Revision number, which increments by 1 each time the ticket definition is updated. To prevent conflicting changes, the existing revision must be used when updating a ticket definition.

createdDatestringRead-onlyformat date-time
Date and time when the ticket definition was created.

updatedDatestringRead-onlyformat date-time
Date and time when the ticket definition was updated.

namestringminLength 1maxLength 30
Ticket definition name.

descriptionstringmaxLength 500
Ticket definition description.

policyTextstringmaxLength 1000
Ticket definition policy.

hiddenboolean
Whether this ticket definition is hidden to site visitors and can't be purchased.

limitedbooleanRead-only
Whether the ticket has a limited maximum quantity.

initialLimitintegerformat int32
The maximum number of tickets that can be sold for the event when first defining the event. If a seating map is defined after you created a ticket definition, this property is ignored and actualLimit is used instead.

actualLimitintegerRead-onlyformat int32
The maximum number of tickets that can be sold for the event after adding a seating map to the event. If no seating map is defined, this property is the same as initialLimit.

pricingMethodobject
Ticket pricing method.

feeTypestring
4 enum supported values:
UNKNOWN_FEE_TYPEFEE_INCLUDEDFEE_ADDED_AT_CHECKOUTNO_FEE
Whether fee is included in the ticket price or customer pays it additionally at checkout. Possible values:
  • FEE_INCLUDED: The fee is deducted from the ticket price for a seller. For example, if you're selling tickets for $10, then a service fee of $0.25 will be deducted from the price and you'll get $9.75.
  • FEE_ADDED_AT_CHECKOUT: The fee is shown in addition to the ticket price at checkout and a guest pays the fee. For example, if you sell tickets for $10, a customer will see a service fee of $0.25 and will pay $10.25 in total.

salePeriodobject
Ticket sale period.

saleStatusstringRead-only
4 enum supported values:
UNKNOWN_SALE_STATUSSALE_SCHEDULEDSALE_STARTEDSALE_ENDED
Ticket sale status. Possible values:
  • SALE_SCHEDULED: Tickets are not on sale yet.
  • SALE_STARTED: Tickets are on sale.
  • SALE_ENDED: Tickets are not on sale.

salesDetailsobject
Ticket sales information.
Note: This field is only returned when SALES_DETAILS fieldset is included in the request.

limitPerCheckoutintegerRead-onlyminimum 0maximum 50format int32
Number of tickets that can be purchased per checkout.
Note: If the actuaLimit or salesDetails.unsoldCount field value is smaller than limitPerCheckout, then it overrides this field.
Was this helpful?
Yes
No

PostCreate Ticket Definition

Creates a ticket definition. Allowed to create up to 100 definitions per event.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Events - all permissions
Manage Ticket Definitions
Learn more about permission scopes.
Endpoint
POST
https://www.wixapis.com/events-ticket-definitions/v3/ticket-definitions

Event TriggersThis method triggers the following events:
Was this helpful?
Yes
No

PatchUpdate Ticket Definition

Updates a ticket definition.

Each time the ticket definition is updated, revision increments by 1. The existing revision must be included when updating the ticket definition. This ensures you're working with the latest ticket definition and prevents unintended overwrites.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Events - all permissions
Manage Ticket Definitions
Learn more about permission scopes.
Endpoint
PATCH
https://www.wixapis.com/events-ticket-definitions/v3/ticket-definitions/{ticketDefinition.id}

Event TriggersThis method triggers the following events:
Was this helpful?
Yes
No

GetGet Ticket Definition

Retrieves a ticket definition by ID.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Events - all permissions
Manage Orders
Manage Ticket Definitions
Learn more about permission scopes.
Endpoint
GET
https://www.wixapis.com/events-ticket-definitions/v3/ticket-definitions/{ticketDefinitionId}

Was this helpful?
Yes
No

DeleteDelete Ticket Definition

Permanently deletes a ticket definition.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Events - all permissions
Manage Ticket Definitions
Learn more about permission scopes.
Endpoint
DELETE
https://www.wixapis.com/events-ticket-definitions/v3/ticket-definitions/{ticketDefinitionId}

Event TriggersThis method triggers the following events:
Was this helpful?
Yes
No

PostReorder Ticket Definitions

Changes ticket definitions order in an event dashboard and the list of available tickets in the ticket picker.

Note: It is possible to use both beforeTicketDefinitionId and afterTicketDefinitionId at the same time but only the last one defined will be executed.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Events - all permissions
Manage Ticket Definitions
Learn more about permission scopes.
Endpoint
POST
https://www.wixapis.com/events-ticket-definitions/v3/ticket-definitions/reorder

Event TriggersThis method triggers the following events:
Was this helpful?
Yes
No

PostQuery Ticket Definitions

Retrieves a list of ticket definitions, given the provided paging, filtering, and sorting. Query Ticket Definitions runs with these defaults, which you can override:

  • createdDate is sorted in ASC order
  • paging.limit is 100
  • paging.offset is 0

For field support for filters and sorting, see Ticket Definitions: Supported Filters and Sorting. To learn about working with Query endpoints, see API Query Language.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Events - all permissions
Manage Orders
Manage Ticket Definitions
Learn more about permission scopes.
Endpoint
POST
https://www.wixapis.com/events-ticket-definitions/v3/ticket-definitions/query

Was this helpful?
Yes
No

PostBulk Delete Ticket Definitions By Filter

Deletes multiple ticket definitions.

All ticket definitions that meet the specified filter criteria are deleted.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Events - all permissions
Manage Ticket Definitions
Learn more about permission scopes.
Endpoint
POST
https://www.wixapis.com/events-ticket-definitions/v3/bulk/ticket-definitions/delete

Event TriggersThis method triggers the following events:
Was this helpful?
Yes
No

PostChange Currency

Changes ticket price currency per event.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Events - all permissions
Manage Ticket Definitions
Learn more about permission scopes.
Endpoint
POST
https://www.wixapis.com/events-ticket-definitions/v3/ticket-definitions/currency

Event TriggersThis method triggers the following events:
Was this helpful?
Yes
No

Ticket Definition Created

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Events - all permissions
Manage Orders
Manage Ticket Definitions
Learn more about permission scopes.
Event BodyEvent Body Event data is received as a JSON Web Token (JWT). It may be delayed. Be sure to verify the data was sent by Wix.
Event Data
idstring
Unique event ID. Allows clients to ignore duplicate webhooks.

entityFqdnstring
Fully qualified domain name of the entity associated with the event. Expected wix.events.v3.ticket_definition.

slugstring
Event name. Expected created.

entityIdstring
ID of the entity associated with the event.

eventTimestringformat date-time
Event timestamp.

triggeredByAnonymizeRequestboolean
Whether the event was triggered as a result of a privacy regulation application (for example, GDPR).

originatedFromstring
If present, indicates the action that triggered the event.

createdEventobject
Event information.
Was this helpful?
Yes
No

Ticket Definition Updated

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Events - all permissions
Manage Orders
Manage Ticket Definitions
Learn more about permission scopes.
Event BodyEvent Body Event data is received as a JSON Web Token (JWT). It may be delayed. Be sure to verify the data was sent by Wix.
Event Data
idstring
Unique event ID. Allows clients to ignore duplicate webhooks.

entityFqdnstring
Fully qualified domain name of the entity associated with the event. Expected wix.events.v3.ticket_definition.

slugstring
Event name. Expected updated.

entityIdstring
ID of the entity associated with the event.

eventTimestringformat date-time
Event timestamp.

triggeredByAnonymizeRequestboolean
Whether the event was triggered as a result of a privacy regulation application (for example, GDPR).

originatedFromstring
If present, indicates the action that triggered the event.

updatedEventobject
Event information.
Was this helpful?
Yes
No

Ticket Definition Deleted

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Events - all permissions
Manage Orders
Manage Ticket Definitions
Learn more about permission scopes.
Event BodyEvent Body Event data is received as a JSON Web Token (JWT). It may be delayed. Be sure to verify the data was sent by Wix.
Event Data
idstring
Unique event ID. Allows clients to ignore duplicate webhooks.

entityFqdnstring
Fully qualified domain name of the entity associated with the event. Expected wix.events.v3.ticket_definition.

slugstring
Event name. Expected deleted.

entityIdstring
ID of the entity associated with the event.

eventTimestringformat date-time
Event timestamp.

triggeredByAnonymizeRequestboolean
Whether the event was triggered as a result of a privacy regulation application (for example, GDPR).

originatedFromstring
If present, indicates the action that triggered the event.

deletedEventstruct
Event information.
Was this helpful?
Yes
No