Get a list of waiting list requests

Content

Resource URL

https://apps.ticketmatic.com/api/1/{accountname}/sales/waitinglistrequests

Example

Request

 1use Ticketmatic\Endpoints\Sales\Waitinglistrequests;
 2
 3$result = Waitinglistrequests::getlist($client, array(
 4    "filter" => "select id from op.waitinglistrequest WHERE createdts > (now() - INTERVAL '30 days')",
 5    "includearchived" => true,
 6    "lastupdatesince" => "2014-09-26 15:24:36",
 7));
 8
 9// The parameters array is optional, it can be omitted when empty.
10$result = Waitinglistrequests::getlist($client);

Response

 1object(Ticketmatic\Endpoints\Sales\WaitinglistrequestsList) (1) {
 2  ["data"]=>
 3  array(1) {
 4    [0]=>
 5    object(\Ticketmatic\Model\WaitingListRequest) (10) {
 6      ["id"]=>
 7      int(0)
 8      ["orderid"]=>
 9      int(0)
10      ["contactid"]=>
11      int(0)
12      ["itemsstatus"]=>
13      int(0)
14      ["requeststatus"]=>
15      int(0)
16      ["saleschannelid"]=>
17      int(0)
18      ["sortorder"]=>
19      int(0)
20      ["isarchived"]=>
21      bool(false)
22      ["createdts"]=>
23      object(\DateTime) (3) {
24        ["date"]=>
25        string(26) "2014-09-26 15:24:36.000000"
26        ["timezone_type"]=>
27        int(3)
28        ["timezone"]=>
29        string(3) "UTC"
30      }
31      ["lastupdatets"]=>
32      object(\DateTime) (3) {
33        ["date"]=>
34        string(26) "2014-09-26 15:24:36.000000"
35        ["timezone_type"]=>
36        int(3)
37        ["timezone"]=>
38        string(3) "UTC"
39      }
40    }
41  }
42}

Request

 1import (
 2    "github.com/ticketmatic/tm-go/ticketmatic"
 3    "github.com/ticketmatic/tm-go/ticketmatic/sales/waitinglistrequests"
 4)
 5
 6result, err := waitinglistrequests.Getlist(client, &ticketmatic.WaitingListRequestQuery{
 7    Filter: "select id from op.waitinglistrequest WHERE createdts > (now() - INTERVAL '30 days')",
 8    Includearchived: true,
 9    Lastupdatesince: ticketmatic.NewTime(ticketmatic.MustParseTime("2014-09-26 15:24:36")),
10})
11
12// The query object is optional, it can be omitted when empty.
13result, err := waitinglistrequests.Getlist(client, nil)

Response

 1result := waitinglistrequests.&List{
 2    Data: []*ticketmatic.WaitingListRequest{
 3        &ticketmatic.WaitingListRequest{
 4            Id: 123,
 5            Orderid: 1,
 6            Contactid: 1,
 7            Itemsstatus: 29101,
 8            Requeststatus: 29201,
 9            Saleschannelid: 1,
10            Sortorder: 1324,
11            Isarchived: false,
12            Createdts: ticketmatic.NewTime(ticketmatic.MustParseTime("2014-09-26 15:24:36")),
13            Lastupdatets: ticketmatic.NewTime(ticketmatic.MustParseTime("2014-09-26 15:24:36")),
14        },
15    },
16}

Request

1GET /api/1/{accountname}/sales/waitinglistrequests HTTP/1.1

Response

 1HTTP/1.1 200 OK
 2Content-Type: application/json
 3
 4{
 5    "data": [
 6        {
 7            "id": 123,
 8            "orderid": 1,
 9            "contactid": 1,
10            "itemsstatus": 29101,
11            "requeststatus": 29201,
12            "saleschannelid": 1,
13            "sortorder": 1324,
14            "isarchived": false,
15            "createdts": "2014-09-26 15:24:36",
16            "lastupdatets": "2014-09-26 15:24:36"
17        }
18    ]
19}

Parameters

FieldDescription
filter
        </td>
        <td class="description">
            <p>Filter the returned items by specifying a query on the public datamodel that returns the ids.</p> 
            <strong>Example value:</strong><code>&#34;select id from op.waitinglistrequest WHERE createdts &gt; (now() - INTERVAL &#39;30 days&#39;)&#34;</code>
        </td>
    </tr><tr>
        <td class="field">
            <div class="name">includearchived</div>
            
        </td>
        <td class="description">
            <p>If this parameter is true, archived items will be returned as well.</p> 
            <strong>Example value:</strong><code>true</code>
        </td>
    </tr><tr>
        <td class="field">
            <div class="name">lastupdatesince</div>
            
        </td>
        <td class="description">
            <p>All items that were updated since this timestamp will be returned. Timestamp should be passed in <code>YYYY-MM-DD hh:mm:ss</code> format.</p> 
            <strong>Example value:</strong><code>&#34;2014-09-26 15:24:36&#34;</code>
        </td>
    </tr>
</tbody>

Type reference: WaitingListRequestQuery

Result fields

This call returns an object with an array of objects in the data field.

FieldDescription
id
int

Unique ID

Example value:123
orderid
int

The id of the order the request is converted to

Example value:1
contactid
int

Contact id

Example value:1
itemsstatus
int

Show the status of the related items, 29101 = no information provided, 29102 = partial information provided and 29103 = full information provided

Example value:29101
requeststatus
int

Show the status of the request, 29201 = requested, 29202 = processed, 29203 = conversion in progress

Example value:29201
saleschannelid
int

The id of the saleschannel used to make the request

Example value:1
sortorder
int

Randomly generated identifier on create. Provides random but consistent ordering of the request (for casting lots)

Example value:1324
isarchived
bool

Whether or not this item is archived

createdts
timestamp

Created timestamp

Example value:"2014-09-26 15:24:36"
lastupdatets
timestamp

Last updated timestamp

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

This type can have custom fields.

Type reference: WaitingListRequest[]