Get all tickets for an event

Content

Resource URL

https://apps.ticketmatic.com/api/1/{accountname}/events/{id}/tickets

Description

Returns the list of all tickets that are part of this event.

Example

Request

 1use Ticketmatic\Endpoints\Events;
 2
 3$result = Events::gettickets($client, $id, array(
 4    "simplefilter" => array(
 5        "tickettypeid" => 123,
 6    ),
 7));
 8
 9// The parameters array is optional, it can be omitted when empty.
10$result = Events::gettickets($client, $id);

Request

 1import (
 2    "github.com/ticketmatic/tm-go/ticketmatic"
 3    "github.com/ticketmatic/tm-go/ticketmatic/events"
 4)
 5
 6result, err := events.Gettickets(client, id, &ticketmatic.EventTicketQuery{
 7    Simplefilter: &ticketmatic.EventTicketFilter{
 8        Tickettypeid: 123,
 9    },
10})
11
12// The query object is optional, it can be omitted when empty.
13result, err := events.Gettickets(client, id, nil)

Request

1GET /api/1/{accountname}/events/{id}/tickets HTTP/1.1

Parameters

FieldDescription
simplefilter
        </td>
        <td class="description">
            <p>Filters the tickets based on a given set of fields.</p> 
            <strong>Example value:</strong><code>{ &#34;tickettypeid&#34;: 123 }</code>
        </td>
    </tr>
</tbody>

Type reference: EventTicketQuery

Result stream

This call returns a stream of objects.

Usage example

You can iterate over each result by repeatedly calling the next() method on the returned object.

1while ($item = $result->next()) {
2    // Do something with $item
3}

Usage example

You can iterate over each result by repeatedly calling the Next() method on the returned object. You must call Close() when done.

 1defer result.Close()
 2for {
 3    item, err := result.Next()
 4    if err != nil {
 5        return err
 6    }
 7    if item == nil {
 8        break
 9    }
10
11    // Do something with item
12}

Usage example

Each line of the response contains a JSON object. Lines are delimited by newlines (\n).

Result fields

FieldDescription
id
int

Ticket ID

Example value:128942
orderid
int

Link to the order the ticket is contained in

Example value:6421522
accesscontrollastenteredscandeviceid
int

The id of the scanner used for the last succesful entry

Example value:238
accesscontrollastenteredts
timestamp

The timestamp of the last succesful entry with this ticket

Example value:"2014-09-26 15:24:36"
accesscontrollastexitscandeviceid
int

The id of the scanner used for the last succesful exit

accesscontrollastexitts
timestamp

The timestamp of the last succesful exit with this ticket

Example value:"2014-09-26 15:24:36"
accesscontrolstatus
int

The access control status for this ticket. 0 means not scanned, 1 means succesful entry, 2 means succesful exit

barcode
string

Ticket barcode

Example value:"418981919819"
bundleid
int

Link to the bundle (orderproduct) that this ticket belongs to.

Example value:421
locktypeid
int

Link to the locktype used for locking the ticket

Example value:421
orderfee
decimal

Fee for the ticket in the order

Example value:5.250000
price
decimal

Price for the ticket in the order (without fee)

Example value:25.000000
properties
map<string, string>

String to string key-value mapping of properties

Example value:{ "key1": "value1", "key2": "value2" }
seatdescription
string

The seat description for this ticket (only for seated tickets)

Example value:"Seat 35C"
seatid
string

Seat ID (for seated tickets)

Example value:"s002034001"
seatpriority
int

Number indicating the priority for this ticket for the best available algorithm. Tickets with a higher priority will be considered first when performing a best available allocation.

Example value:1243
seatrownumber
string

Row number for the ticket (only for seated tickets)

Example value:"C"
seatseatnumber
string

Seat number for the ticket (only for seated tickets)

Example value:"12"
seatzoneid
int

Optional seatzone for the ticket

Example value:4
seatzonename
string

Zone name for the ticket (only for seated tickets)

Example value:"Main Grandstand"
ticketholderid
int

Optional link to the contact that is the ticketholder for this ticket

Example value:11023
ticketname
string

Optional name on the ticket

Example value:"Bob Smith"
tickettypeid
int

Link to the contingent this ticket belongs to

Example value:123
tickettypepriceid
int

Link to the tickettypeprice that is assigned to this ticket for the order. Through the tickettypeprice you can retrieve the pricetype

Example value:9482
vouchercodeid
int

Link to the vouchercode that was used to reserve this ticket.

Example value:32

Type reference: stream<EventTicket>