This endpoint shows the list of entries the current user can view in the site. Use to get normal lock events such as openings/remote openings.
This endpoint does not provide real-time data, there may be certain delay before events become available for querying.
This endpoint supports oData
sorting and filtering, and follows the same conventions as other endpoints which we provide. However, it does not support oData
pagination.
Pagination for entries is performed with the help of a continuation token. So instead of requesting a specific page using $skip/$top
arguments, you always request the next page.
When you make the first request you will get continuation_token
property in the response.
To request a second page, you need to provide this token as a value for a custom header:
CLP-Continuation-Token
IMPORTANT: You need to pass the whole JSON which you obtained in continuation_token
property. In order to do so, you first need to unescape the string, because what you have here, is an escaped JSON string inside a JSON object.
You can unescape JSON programmatically or use one of the available online tools: https://www.freeformatter.com/json-escape.html
Your second request will look like this:
And in your second response you can get another continuation token, which you will use to fetch third page and so on.
If there is no continuation token returned, then it means there are no more results to your query.
NOTE: it may be, that you got zero items in your response, but still have a continuation token returned. That means, that the API didn’t find events in some partitions of the data storage, but there is still data left in other partitions. So you can use continuation token to fetch more. In other words, don’t rely on items array being empty to know there are no more events. Instead rely on continuation token value.
You can define page size by using the standard oData $top
argument:
GET {{url}}/v1.1/sites/:site_id/entries?$orderby=local_date_time desc&$top=2
By default the page size is 20
, the maximum page size you can choose is 100
.
If $orderby
argument is not provided by the caller, we will ensure that sorting is stable and paging can still be used, but we won’t provide a default sorting property. So we strongly recommend you to include $orderby
in your request and to sort by a property that makes sense to you. Properties such as local_date_time
and utc_date_time
are good candidates for this role.
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
Endpoint: /v1.1/sites/{site_id}/entries
Method: GET
Parameters:
path {site_id
type: stringId of the site
site_id} (string)
query {$filter
type: stringFilter the results using OData syntax.
$filter} (string)
query {$orderby
type: stringOrder the results using OData syntax.
$orderby} (string)
query {$skip
type: integerThe number of results to skip.
$skip} (integer)
query {$top
type: integerThe number of results to return.
$top} (integer)
query {$count
type: booleanReturn the total count.
$count} (boolean)
header {CLP-Continuation-Token
type: stringContinuation token used for pagination. Should be provided in a custom header: CLP-Continuation-Token
CLP-Continuation-Token} (string)