- URL:
- https://<root>/content/users/[userName]/items/[itemID]/canRestore
- Methods:
GET
- Version Introduced:
- ArcGIS Online June 2024
Example Usage
URL for Can Restore
https://org.arcgis.com/sharing/rest/content/users/jsmith/items/b512083cd1b64e2da1d3f66dbb135956/canRestore?f=json
Description
The can
operation indicates whether an item can be restored from the recycle bin or not.
If the returned response from can
is true
, this means that the item can be restored from the recycle bin. If false
, the item is dependent on another item in the recycle bin which is preventing restore. The error response will return the item which is blocking restore in the offending
field. can
will return false
until the source item is restored first.
Request parameters
Parameter | Details |
---|---|
| For a complete listing, see Common parameters. |
Response Properties
Property | Details |
---|---|
| The ID of the queried item. |
| Indicates if the operation was successful. |
JSON Response syntax
{
"itemId": "<item id>",
"success": true | false
}
JSON Response example
The item can be restored from the recycle bin:
{
"itemId": "e03f626be86946f997c29d6dfc7a9666",
"success": true
}
The item cannot be restored from the recycle bin:
{
"itemId": "a34c2e6711494e62b3b8d7452d4d6235",
"success": false,
"error": {
"code": 400,
"messageCode": "CONT_00486",
"message": "Unable to restore item. This service item has a required related Service item in recycle bin.",
"offendingItems": [
{
"itemId": "fb3ca29eaf28498dbdff2385b26d9c85",
"title": "feature service vehicle populattion",
"type": "Feature Service"
}
]
}
}