Skip To Content
ArcGIS Developers

Validate Datastore


The validate operation ensures that your ArcGIS Server can connect and use the datasets stored within a given data store. While this operation can be called before or after the data store has been registered with your server, it is recommended that the validate operation is performed beforehand. A data store can be validated by using either its datastoreId or the JSON for an unregistered data store. The serverId can be found on the Servers resource page.

Request parameters


The itemId of an existing data store item.



The JSON of a data store not already registered to your portal.

datastore={"path":"/<datastore path>/<data store>","type":"egdb","info":
{"dataStoreConnectionType":"shared","isManaged":false,"connectionString":"SERVER=<server information>;INSTANCE=<instance>;DBCLIENT=postgresql;DB_CONNECTION_PROPERTIES=<database property information>;DATABASE=db2;USER=thatUser;VERSION=sde.DEFAULT;AUTHENTICATION_MODE=DBMS;ENCRYPTED_PASSWORD=<password>"}}



The serverId you want to validate the data store against.



The response format. The default format is html.

Value: html | json

Example usage

Below is a sample URL for the validateDatastores operation.<portal Id>/datastores/validate

JSON Request example

The following example uses the datastoreId and serverId parameters:


Alternatively, you can call the operation using the datastore and serverId parameters:


JSON Response example

If either of the requests above is successful, validate will return the following success message:

{"status": "success"}

If the operation fails, validate will return an error similar to the message below:

{"machines" : [
      "machine" : <machine name>,
      "status" : "error",
      "dataItems" : [
          "dataItem" : "<dataItem information>",
          "path" : <datastore path>,
          "validationState" : "FAILED",
          "message" : <descriptive error message>