/allDatasets/deleteLayers: Delete Layers

URL:
https://[root]/portals/[portalID]/datastores/allDatasets/deleteLayers
Methods:
GET
Version Introduced:
10.7.1

Example usage

The following is a sample ArcGIS Enterprise POST request for the deleteLayers operation:

1
2
3
4
5
6
POST /webadaptor/sharing/rest/portals/0123456789ABCDEF/datastores/allDatasets/deleteLayers HTTP/1.1
Host: machine.domain.com
Content-Type: application/x-www-form-urlencoded
Content-Length: []

datastoreId=55d87f404a7e420bb969ccb70254bfec&f=pjson

Description

The deleteLayers operation deletes all layers published from the data store. Before a data store can be unregistered from a server, all of its bulk-published layers must be deleted, as the Remove From Server operation cannot be completed if there are outstanding bulk-published layers.

Request parameters

ParameterDetails

datastoreId

(Required)

The itemId of a bulk-published data store.

Example

1
datastoreId=55d87f404a7e420bb969ccb70254bfec

f

The response format. The default format is html.

Value: html | json | pjson

JSON Response examples

This operation is an asynchronous operation. If successful, deleteLayers will return the following information:

1
2
3
4
5
6
7
{
  "success": true,
  "datastoreId": "d50d572d94054706b42cdb74c0cf6db5",
  "serverId": "xpPVgRdFvnEIbZl7",
  "jobType": "deleteAllBPLayers",
  "jobId": "jf8627ef9-d07d-48f6-9dcb-967f6f8b480a"
}

The status operation can be used to check the current state of the operation by making a request of the following form using the datastoreId:

1
https://machine.domain.com/webadaptor/sharing/rest/content/users/admin/items/<datastoreId>/status

If successful, deleteLayers will return a status message (partial, completed, or failed) with the itemId and jobInfo of each deleted layer:

1
2
3
4
5
6
7
8
9
10
{
  "status": "completed",
  "statusMessage": "completed",
  "itemId": "d50d572d94054706b42cdb74c0cf6db5",
  "jobInfo": {
    "serverId": "xpPVgRdFvnEIbZl7",
    "jobId": "jf8627ef9-d07d-48f6-9dcb-967f6f8b480a",
    "jobType": "deleteAllBPLayers"
  }
}

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.

You can no longer sign into this site. Go to your ArcGIS portal or the ArcGIS Location Platform dashboard to perform management tasks.

Your ArcGIS portal

Create, manage, and access API keys and OAuth 2.0 developer credentials, hosted layers, and data services.

Your ArcGIS Location Platform dashboard

Manage billing, monitor service usage, and access additional resources.

Learn more about these changes in the What's new in Esri Developers June 2024 blog post.

Close