- URL:
- https://[root]/portals/[portalID]/history
- Methods:
GET
Example usage
The following is a sample ArcGIS Online request URL used to access the history
resource:
https://org.arcgis.com/sharing/rest/portals/0123456789ABCDEF/history?num=25&types=g,i&f=pjson
Description
The history
resource allows organization administrators to query historical events that have occurred in an ArcGIS Online organization. When the output format is CSV, only the first 10,000 records can be included.
Request parameters
Parameter | Details |
---|---|
| The maximum number of history events to be included in each batch of result set. The default is Note that the actual number of returned results may be fewer than If the output format is CSV (in other words, Example
|
| Used with Example
|
| If Values: |
| Filter events by specific target user name or target ID in a batch result set. It can be the ID of an item, a group, a role, a collaboration, an identity provider, and so on. Example
|
| Filter events by a comma-separated list of target types in a batch result set. Values: |
| Filter events by a comma-separated list of user names who take the actions in a batch result set. Example
|
| Filter events by a comma-separated list of user names who own the action targets in a batch result set. |
| Filter events by a comma-separated list of action types in a batch result set. Values: |
| Filter events starting from a specific time frame in ISO 8601 format or UNIX time in milliseconds. Example
|
| Filter events that occurred before a specific time frame in ISO 8601 format or UNIX time in milliseconds. |
| Filter events by a comma-separated list of IP addresses in a batch result set. |
| Describes whether the results return in ascending or descending chronological order. The default is ascending. Values: |
| The response format. The default format is Values: |
Response properties
Property | Details |
---|---|
| The number of results included in the result set of the response. Example
|
| Used to fetch the next batch of events by calling with the |
| A JSON array of event items; each event is detailed with properties described in the Items Properties section. Example
|
Items properties
Property | Details |
---|---|
| Target user name or ID. |
| The type of the ID in the Values: |
| Organization ID. |
| The owner of the target. |
| The UNIX time stamp in milliseconds when the event was logged. |
| The actor of the event. |
| Type of action. Values: |
| Actor's IP address. |
| Operation requested by the actor. Example
|
| The unique identifier used to identify certain event logs together to indicate them as "one action" triggered by the actor, in other words, removing members from a group also unshares their items from the group, or bulk share multiple items altogether. Example
|
| ID of the client app where the action was performed on or by the target, for example, a target user signed into ArcGIS Online from ArcGIS Pro. Example
|
| Request parameter information used to take the action where applicable. Example
|
JSON Response syntax
{
"num": <num of results>,
"nextKey": "<next key>",
"items": [
{
"<event 1 obj>"
},
{
"<event 2 obj>"
},
{
"<event 3 obj>"
},
{
"<event 4 obj>"
}
]
}
JSON Response example
{
"num": 25,
"nextKey": "eyJjcmVhdGVkIjp7Ik4iOiIxNTM1NTYxOTU0MzI1In0sImlkIjp7IlMiOiI3ZThmNTM4Zjg2NWE0YWQ4YTlmYTFjODJkNDg3YzEyMyJ9LCJvcmdJZCI6eyJTIjoiSjQyM3ZIOGZSOUhWNDQ0ayJ9fQ",
"items": [
{
"id": "93744920722644fcb926044f2cf327f6",
"idType": "g",
"orgId": "J423vH8fR9HV444l",
"owner": "jsmith",
"created": 1535671479677,
"actor": "jsmith",
"action": "removeusers",
"ip": "172.16.254.1",
"request": "/sharing/rest/community/groups/93744920722644fcb926044f2cf327f6/removeUsers",
"reqId": "563c69aae3474d729aa3db8a4d71a7da",
"appId": "arcgisonline",
"data": "{\"users\":[\"[user1, user2, user3, user4]\"]}"
},
{
"id": "7b2a7f54b5e34a6495f4aef3a877d1d3",
"idType": "i",
"orgId": "J423vH8fR9HV444l",
"owner": "user3",
"created": 1535671479676,
"actor": "jsmith",
"action": "unshare",
"ip": "172.16.254.1",
"request": "/sharing/rest/community/groups/93744920722644fcb926044f2cf327f6/removeUsers",
"reqId": "563c69aae3474d729aa3db8a4d71a7da",
"appId": "arcgisonline",
"data": "{\"groups\":[\"93744920722644fcb926044f2cf327f6\"]}"
},
{
"id": "c1ef98d5330144f6a76e11c06d64de5d",
"idType": "i",
"orgId": "J423vH8fR9HV444l",
"owner": "jsmith",
"created": 1535572693781,
"actor": "jsmith",
"action": "share",
"ip": "172.16.254.1",
"request": "/sharing/rest/content/users/jsmith/shareItems",
"reqId": "be1f4f2992a34c9f96cdae67137f52a5",
"appId": "arcgisonline",
"data": "{\"everyone\":true,\"org\":true,\"groups\":[]}"
},
{
"id": "803c713119084d069c9b2d86575762c7",
"idType": "i",
"orgId": "J423vH8fR9HV444l",
"owner": "jsmith",
"created": 1535572693781,
"actor": "jsmith",
"action": "share",
"ip": "172.16.254.1",
"request": "/sharing/rest/content/users/jsmith/shareItems",
"reqId": "be1f4f2992a34c9f96cdae67137f52a5",
"appId": "arcgisonline",
"data": "{\"everyone\":true,\"org\":true,\"groups\":[]}"
}
]
}