Entity History
This request is used to retrieve timestamps (UTC) reflecting when an entity was modified.
Request
GET {TenantURL} /entities/{entity object URI}/_changes
Parameter | Required | Description | ||
---|---|---|---|---|
Headers |
Authorization
|
Yes | Information about authentication access token in format "Bearer
<accessToken> " (see details in Authentication API). |
|
Query |
max
|
No | Positive Integer value to identify maximum number of entities to
return in a response. Can be used to organize pagination in combination
with "offset" parameter. Default value is 50 . |
max=10 |
offset
|
No | Positive Integer value to identify starting what element in a result
set should be returned in a response. Can be used to organize pagination
in combination with "limit" parameter. Default value is
0 . |
offset=120 |
|
order
|
No | Order of sorting. Can be used in combination with "sort" parameter
to have reverse order. Possible values:
desc . |
order=desc |
|
filter
|
No | Enables entities filtering by a condition. Format for filter query
parameter: filter=({Condition Type}[AND/OR {Condition
Type}]*)
There are tree Condition Types:
The For more information see Filtering Entities |
Filter historical events with changes of FirstName attributes, made by 'test.uset'
Filter historical events with timestamp less than specified value.
Filter all '
|
|
showAll
|
No | Specifies if the response should contain all historical events,
despite any real changes on attributes. Filter is ignored if
showAll is set to true . Default
value is false . |
showAll=true |
|
options |
No | Comma-separated list of different options which affect JSON content
in the response. Available options:
|
options=skipReferenceAttributesProcessing |
- Use the
skipReferenceAttributesProcessing
option to significantly reduce response time, even when there are no reference attributes. - If there is no
changes
filter, useshowAll=true
to also reduce response time.
Response
JSON array with timestamps when an entity was modified.
Request
GET {TenantURL}/entities/11/_changes?filter=
changes(configuration/entityTypes/HCP/attributes/FirstName)
Headers: Authorization: Bearer 204938ca-2cf7-44b0-b11a-1b4c59984512
Response
GET {TenantURL}/entities/11/_changes?order=asc
Headers: Authorization: Bearer 204938ca-2cf7-44b0-b11a-1b4c59984512
[{
"timestamp": 1428308955399,
"user": "test.user",
"type": "ENTITY_CREATED"
}, {
"timestamp": 1428309071535,
"user": "test.user",
"type": "ENTITY_CHANGED"
}]