Ticket

A registration of a Badge to an Event. You must have the registration ConventionPrivilege to access this. Tickets are accessed via /api/ticket.

Properties

See "Object Properties" in Introduction for basic shared properties.

Complete details in TicketProperties.

Related Objects

See "Related Objects" in Introduction for how to use them.

badge

The Badge this ticket belongs to.

badgetype

The BadgeType of the ticket, if the ticket was complimentary with a BadgeType.

convention

The Convention this ticket belongs to.

event

The Event this ticket belongs to.

eventgroup

The EventGroup of the ticket, if the ticket was complimentary with an EventGroup associated with a BadgeType.

Includes

See "Includes" in Introduction for how to use them.

longname

A very descriptive name for this ticket. It pulls data from several objects, which is why it is not included by default. For a ticket, it is the shortname concatenated with a ":" and the mediumname.

mediumname

The name of the event concatenated with the user's badge name, e.g. "[event name] for [badge name/info]".

Services

The services used to fetch and manipulate tickets.

Search Tickets

This section describes basic searchability of Tickets, which is now available across several main Ticket endpoints.

Available Endpoints

To request Tickets, a user must make a request via an endpoint for a parent or related object. The parent objects for which this consolidated search behavior is valid are:

Badge
BadgeType
Convention
Discount
Event
EventGroup

Departures/differences from basic behavior will be discussed in the documentation for the specific parent=>ticket relationship.

This search behavior is not available on the following relationships: ConventionCart, ConventionReceipt.

A user can always see Tickets which belong to Badges they own, or which belong to a Convention for which the user has the merch privilege.

Returns:

 {
    "paging" : {...},
    "items" : [
        {
          "id" : "xxx",
          "ticket_number" : 101,
          ...
        },
        ...
    ]
 }
Optional Params
Queryables

Pass a string query to search for a partial match in specifically allowed text fields.

The fields with ** can be searched only by specifying the field with query_field=[fieldname]; see options below.

badge.badge_number **
badge.email **
badge.firstname **
badge.lastname **
badge.name_full

(default field; limit search to just this field by specifying field with query_field=badge.name_full; see options below)

event.event_number **
event.name

(default field; limit search to just this field by specifying field with query_field=event.name; see options below)

ticket_number **
Queryable options
query_field

By default, any use of query will search in the text fields badge.name_full and event.name. You can make your search faster by specifying a single field with the query_field option. Simply set query_field to the field you want to search in. (Several fields in the list above can be searched only using query_field.)

Qualifiers
badge_id
badgetype_id
collected

0 is default and means uncollected; 1 means collected.

convention_id

convention_id is a valid qualifier but will be part of the URI (e.g. in /api/convention/xxx/tickets) or is implicit in all other object endpoints, so there is never need to pass it explicitly.

conventioncart_id
conventionreceipt_id
discount_id
event_id
eventgroup_id
for_reservation

0 is default and means not for a reservation; 1 means the ticket is for a reservation.

generic

0 is default and means not generic (created for a specific Event); 1 means the ticket is generic (originally created with no association to an Event).

in_tournament

0 is default and means not for a tournament; 1 means for a tournament.

picked_up

0 is default and means not picked up; 1 means picked up.

print_count
ticket_number
verified

0 is default and means not verified (still in cart process or not yet enabled for use); 1 means verified.

badge.badge_number
badge.email
badge.firstname
badge.lastname
badge.name_full
event.event_number
event.is_cancelled

0 is default and means not cancelled; 1 means cancelled.

event.is_scheduled

0 is default and means not scheduled; 1 means scheduled.

Note that this is only a shorthand flag field; other factors also designate the event as "scheduled", such as that the Event has assigned Slots.

event.name

Create Ticket

You almost certainly want to add it to a ConventionCart instead of creating one. Or if you want to administratively create one, then use that method.

 POST /api/ticket
Required Params
convention_id
event_id
badge_id

Returns the same as a normal read.

Administratively Create Ticket

This will create a ticket that is fully verified. You'll need to have the registration ConventionPrivilege to do this.

 POST /api/ticket/verified
Required Params

The same as the Create Ticket service.

Returns the same as a normal read.

Read Ticket

 GET /api/ticket/xxx

Returns:

 {
   "id" : "xxx",
   "name" : "The Captain is Dead",
   ...
 }

Update Ticket

 PUT /api/ticket/xxx

Returns the same as a normal read.

Delete Ticket

 DELETE /api/ticket/xxx
Optional params
cashdrawer_id

You need to specify this to refund if purchased with cash in the point of sale system.

Returns:

 {
   "success" : 1
 }

Mark Picked Up

 PUT /api/ticket/xxx/pick-up

Returns the same as a normal read.

Unmark Picked Up

 PUT /api/ticket/xxx/reverse-pick-up

Returns the same as a normal read.

Convert Ticket to Free

This refunds a charge for a ticket without deleting it. Use of this endpoint requires the registration privilege.

 PUT /api/ticket/xxx/convert/free

Returns the same as a normal read.

Convert Ticket

Convert a ticket purchase to a different Event. This will charge or refund the difference in the costs. This cannot be used for organizer-granted tickets.

 POST /api/ticket/xxx/convert/event/:event_id
Required Params
event_id

The ID of the Event to convert the ticket to.

Returns a normal read of the add-on converted to.

Toggle Ticket's Tournament Status

Toggle a ticket's tournament status (in tournament, or eliminated). Calling this for tickets which are not for a tournament event will raise an error.

 PUT /api/ticket/xxx/in-tournament