- URL:
- https://<root>/data/<datastoreID>/switchRole
- Methods:
POST- Version Introduced:
- 10.9
Access requirements
Required privileges
The ArcGIS Enterprise 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.
Tokens
This API requires token-based authentication. A token is automatically generated for administrators who sign in to the ArcGIS Enterprise 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 generate operation in the ArcGIS Portal Directory API. For security reasons, all POST requests made to the ArcGIS Enterprise Administrator API must include a token in the request body.
Description
The switch operation promotes a standby relational data store to the primary data store and downgrades the existing primary data store to a standby data store. This operation may take some time to complete.
Request parameters
| Parameter | Details |
|---|---|
| The response format. The default format is Values: |
Example usage
The following is a sample POST request for the switch operation:
POST /<context>/admin/data/f305883d-6734-432c-b4c4-b76f795e25f7/switchRole
Host: organization.example.com
Content-Type: application/x-www-form-urlencoded
Content-Length: []
f=pjson&token=P4Vn2uao41gcVGxM8p3lwYgQnt9t20hRo8s4TDsH2XRtiF3xh-lNTfn1dIOaw3ke2P8nCQwjxeLV4kNiftyKCESSEPXiIbQGt9Ph7Bx_LQIGkIoXYZBNOWnOi7Fw8Z5GRg2_xYSWoLg8zzZcO3utdVsIG1Ew7Ab8f-Ti28TfUvtv7cWM9BzRaw00EtqbdJj0zu23kTYNsOO0KaXkJ5IR8wF1qGxD6-KmVyOdfC9ms51khCiq473WAo4Ho8zwkdwVJSON Response example
{"status": "success"}