Skip to content
URL:
https://<root>/exportSite
Methods:
POST
Version Introduced:
10.2

Access requirements

Required privileges

The Sever Administrator API requires privilege-based access. An administrator must be assigned a specific user privilege, or role, to access any given endpoint. Listed below are the user privileges or roles an administrator can be assigned that provides access to this endpoint. If multiple privileges are listed, only one needs to be assigned to gain access.



Note that administrators assigned a custom role must also have the administrative View all content privilege assigned to them to access the API directory as an administrator.

Tokens

This API requires token-based authentication. A token is automatically generated for administrators who sign in to the Server Administrator API directory's HTML interface. Tokens generated in this way are stored for the entirety of the session.

Those accessing the API directory outside of the HTML interface will need to acquire a session token from the generateToken operation in the Portal Directory API. For security reasons, all POST requests made to the Server Administrator API must include a token in the request body.


Learn how to generate a token

Description

The exportSite operation exports the site configuration to a specified location. The exported file includes, and excludes, the following information:

Information included in the backupInformation not included
  • Service configurations and service properties
  • Service webhooks
  • Server object extensions (SOEs)
  • Server object interceptors (SOIs)
  • Registered data store item locations
  • Registered relational data store types
  • User and role information
  • List of machines in the site
  • Log settings
  • Statistics reports
  • Scene tile cache configuration files under arcgiscache/Hosted
  • Cache tiles and tiling schemes
  • Data used by services (unless it was copied to a folder on the server automatically at publish time)
  • Dynamically generated map images and other temporary output
  • Log messages (including geoprocessing job statuses and messages)
  • Primary site administrator name and password
  • Statistics data
  • ArcGIS Web Adaptor configurations

Protecting information not included in the backup

As noted above, some information is not included in the backup of your site. It's recommended you manually back up this information at the same time you run the backup utility. When you restore the site, manually copy or move this information back to the site, for example:

These directories will contain the cache tiles and the tiling scheme file conf.xml. The cache directories may also contain a file geodatabase status.gdb that contains information about which tiles have been built. When you restore the site, move or copy the information back to the original arcgiscache directory.

Request parameters

ParameterDetails

location

(Optional)

A folder path, accessible to ArcGIS Server, where the exported site configuration will be written. Starting at ArcGIS Enterprise 12.0, if ArcGIS Server is configured to use cloud-based storage, the location parameter can instead be used to defined the prefix for where the exported site configuration will be located. If the location parameter is not specified, the server writes the exported site configuration file to a directory owned by the server and returns a virutal path (HTTPS URL) to that directory. The URL returned from that response can be used to download the exported site configuration from the directory.

File pathFile pathCloud-based storage prefix
Use dark colors for code blocksCopy
1
location=//server/share/backup/full/20250517-010949-FULL/server/ssebngeyxa7wpjei/

locationConfig

(Optional)

Introduced at ArcGIS Enterprise 12.0. This parameter defines the location configuration for a file store or cloud-based storage systems. If ArcGIS Server is configured to use cloud-based storage, the JSON object must contain connection information, such as bucket, container, credential, and cloud region information. If this parameter is not defined, or if ArcGIS Server is not configured with cloud-based storage, the parameter will use the file store configuration.

The following is sample input for file store configurations.

Example
Use dark colors for code blocksCopy
1
locationConfig={"type": "fileStore","provider": "FileSystem"}

validate

Introduced at ArcGIS Enterprise 11.1. This parameter validates the folder path specified in the location parameter, ensuring that it is accessible before performing the exportSite operation. If set to true, the path will be validated, and the operation will return either a success response or an error message. The default value is false.

Values: true | false

runAsync

Introduced at ArcGIS Enterprise 12.0. This parameter specifies whether the backup is created asynchronously. If set as true, the operation is performed asynchronously and the JSON response will return a job URL that can be used to poll for the status of the job after it's submitted. The default value is false.

Values: true | false

f

The response format. The default response format is html.

Values: html | json | pjson

Example usages

The following are sample POST requests for the exportSite operation:

Use dark colors for code blocksCopy
1
2
3
4
5
6
POST /<context>/admin/exportSite HTTP/1.1
Host: organization.example.com
Content-Type: application/x-www-form-urlencoded
Content-Length: []

location=\\server\share\backup&locationConfig={"type": "fileStore","provider": "FileSystem"}&validate=true&async=false&f=pjson

JSON Response examples

The following demonstrates the differences in responses when the operation is performed synchronously, with the validate parameter set as false, and either defining a folder location for the site configuration to be exported to or leaving the location parameter empty.

Folder location specifiedFolder location specifiedNo folder location specified
Use dark colors for code blocksCopy
1
2
3
4
{
  status: "success",
  location: "\\server\share\backup\Aug-15-2025_11-50-33.agssite"
}

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