Developer Documentation (API)
- Authentication
- PHP Package
- V2 Endpoints
- Pass Templates
- Get a list of templates
- Describe the structure of a pass template
- Create a new template
- Update a template
- Patch a template
- Publish changes of a template
- Get information about fields of a pass-template only
- Schedule a Push Notification
- List scheduled notifications of a template
- Delete a scheduled Push Notification
- Copy a Pass Template
- Delete a Pass Template
- Create an iFrame Integration for a Template
- Create an URL Integration for a Template
- Passes
- REST Hooks
- Validating passes
- Deprecated endpoints
Get all passes of a template
GET Request
Endpoint URL https://veski.leikbreytir.is/api/pass/list/{pass-template-uid}?start=0&pageSize=100&lastIdOfPriorPage=identifier&lastCreatedOnOfPriorPage=1656500068
Purpose
Returns a list of all passes for the given pass-template ordered by created on date starting at the given index (start-parameter). The pageSize defines how many results you’ll get with one request.
You can optionally use the createdSince or modifiedSince parameters to only return passes that have been created or modified since the given date.
Required input parameters
- HTTP Authorization Header that contains your API key
- pass-template UID – the ID of the template you want to get passes for
- start – the offset where the query should start (defaults to 0)
- pageSize – the number of results per query (maximum is 100, default is 100)
start and pageSize define the pagination, e.g. the first page is start=0 and pageSize=100, the second page is start=100 and pageSize=100 - (recommended) lastIdOfPriorPage – the UUID of the last entry of the prior page. This will be added to the URL automatically that is returned in the next or self keys.
- (recommended) lastCreatedOnOfPriorPage – the timestamp of the last entry of the createdOn field of the prior page. This will be added to the URL automatically that is returned in the next or self keys.
- (optional) createdSince – a date in the format Y-m-d H:i (e.g. 2021-07-01 15:30). If set, the result set will only include passes that have been created at or after that date and time.
- (optional) modifiedSince – a date in the format Y-m-d H:i (e.g. 2021-07-01 15:30). If set, the result set will only include passes that have been modified at or after that date and time.
Please note that you can either use a createdSince or modifiedSince date. If you specify both, the modifiedSince parameter will be ignored.
Returned values
JSON-Array containing an information about the query and the results (these are the actual passes)
- query – information about the current query/li>
- start – the start parameter you’ve specified. Defaults to 0
- pageSize – the pageSize you’ve specified. Defaults to 100.
- self – the URL of the current request
- next – the URL of the next page. If no next parameter is returned this means you’ve reached the end of the list.
- total – the total number of results for your query
- results – an array of passes.
- see the common data format for included data.
{
"query": {
"start": 0,
"pageSize": 1,
"self": "https://veski.leikbreytir.is/api/pass/list/ddc38a8b-7b2d-4c5e-8318-879230e42f1e?start=0&pageSize=2&lastIdOfPriorPage=123413c6-714e-4640-b4ee-b94c8061620c&lastCreatedOnOfPriorPage=1656500068",
"next": "https://veski.leikbreytir.is/api/pass/list/ddc38a8b-7b2d-4c5e-8318-879230e42f1e?start=2&pageSize=2&lastIdOfPriorPage=f36a13c6-714e-4640-b4ee-b94c8061620c&lastCreatedOnOfPriorPage=1656500213"
},
"total": 136,
"results": [
{
"identifier": "f36a13c6-714e-4640-b4ee-b94c8061620c",
"uri": "https://veski.leikbreytir.is/api/pass/f36a13c6-714e-4640-b4ee-b94c8061620c",
"generatedId": "we179wavopfw4zpnae5f7ea7464f4a3",
"searchString": "|https://veski.leikbreytir.is/en/p/nr9pod8myjbv65f7ea7464f436||||Sepp|SMSTEST|||we179wavopfw4zpnae5f7ea7464f4a3|987654321||Sepp|Kryptonit|gifttowallet@gifttowallet.com|",
"passData": "",
"voided": false,
"redeemed": false,
"createdOn": "2020-10-08 07:44:38",
"modifiedOn": "2020-10-08 13:43:59",
"expirationDate": "2080-10-08 13:42:00",
"userProvidedId": "",
"passTemplateGuid": "1068b515-7fcb-456f-9abc-0b508b428301",
"passTemplateName": "NFC Pass",
"linkToPassPage": "https://veski.leikbreytir.is/en/p/nr9pod8myjbv65f7ea7464f436",
"thumbnail": null,
"qrCodeImage": "https://veski.leikbreytir.is/qr/987654321",
"barcodeValue": "987654321",
"numberOfActive": 1,
"numberOfInactive": 0,
"numberOfPrinted": 0,
"passFieldData": {
"5cb1a40ac68f80.15012600": "",
"5e2721b93da442.17595709": "",
"5e552028e62805.33020425": "SMSTEST",
"5e5e0adfc1b6e4.84503451": "Sepp",
"5f7216b0297200.36897838": "",
"5f7216b02972e2.34068785": ""
}
}
]
}