# Account Management API
**Base URL**: https://dev-cloud.acronis.com/api/2
## Security
### x-api-key
### Request parameters
#### Headers
| Name | Description |
|------|-------------|
| `Cookie` | (Required) **Type**: String |
### Responses
| Code | Description |
|------|-------------|
| `401` | The request was denied due to an invalid session token. |
| `403` | The request was denied due to the current session token
having insufficient privileges. |
### Basic Authentication
### Request parameters
#### Headers
| Name | Description |
|------|-------------|
| `Authorization` | (Required) Used to send the base64-encoded "client_id:client_secret" credentials.
**Type**: String
**Pattern**: `^Basic [0-9a-zA-Z\-\._~+/]*=$` |
### Responses
| Code | Description |
|------|-------------|
| `403` | The request was denied due to the credentials having insufficient privileges. |
### OAuth 2.0
Supported grant types:
* `client_credentials`
* `authorization_code`
* `password`
Authorization URI example: `/api/2/idp/authorize`
Access token URI example: `/api/2/idp/token`
### Request parameters
#### Headers
| Name | Description |
|------|-------------|
| `Authorization` | (Required) Used to send a valid OAuth 2 access token. Do not use with the "access_token" query string parameter.
**Type**: String
**Pattern**: `^Bearer [0-9a-zA-Z\-\._~+/]*=*$` |
#### Query parameters
| Name | Description |
|------|-------------|
| `access_token` | (Required) Used to send a valid OAuth 2 access token. Do not use together with the "Authorization" header.
**Type**: String |
### Responses
| Code | Description |
|------|-------------|
| `401` | The request was denied due to an invalid or missing bearer access token. |
| `403` | The request was denied due to the bearer access token having insufficient privileges. |
### Scopes
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
* `urn:acronis.com::account-server::readonly_admin`
* `urn:acronis.com::account-server::tenant_admin`
* `urn:acronis.com::account-server::tenant_viewer`
* `urn:acronis.com::account-server::user_admin`
* `urn:acronis.com::account-server::replication_manager`
* `urn:acronis.com::account-server::managed_clients_admin`
* `urn:acronis.com::account-server::oauth2_client_admin`
* `urn:acronis.com::account-server::legal_docs_signer`
* `urn:acronis.com::accounts::email_token_requester`
* `urn:acronis.com::accounts::licensing_admin`
* `urn:acronis.com::accounts::usage_reporter`
* `urn:acronis.com::backup::backup_user`
* `urn:acronis.com::backup::protection_admin`
* `urn:acronis.com::files_cloud::sync_share_user`
* `urn:acronis.com::acep::consumer`
* `urn:acronis.com::account-server::security_groups_admin`
* `urn:acronis.com::account-server::security_groups_viewer`
* `urn:acronis.com::account-server::token_introspector`
* `urn:acronis.com::account-server::custom_role_manager`
* `urn:acronis.com::account-server::custom_role_viewer`
## Endpoints
### Get Forgot Link (GET /accounts/forgot_link)
Get forgot password link by login.
*WARNING.* Endpoint is disabled.
#### Security
The endpoint does not require authorization.
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `login` | (Required) User login.
**Type**: String |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `link` — URL to forgot password page
**Type**: String
**Example**:
```json
{
"link": "/forgot_password"
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Fetch Applications (GET /applications)
Fetches a list of all registered applications.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"name": "Backup",
"usages": [
"assigned_compute_points",
"child_storages",
"cloud_to_cloud_backup",
"compute_points",
"dr_cloud_servers",
"dr_internet_access",
"dr_storage",
"google_drive_storage",
"google_mail_storage",
"google_team_drive_storage",
"group_mailbox_storage",
"group_site_storage",
"gsuite_seats",
"local_storage",
"mailbox_instance_size",
"mailbox_storage",
"mailboxes",
"mobile_storage",
"mobiles",
"onedrive_storage",
"public_ips",
"server_storage",
"servers",
"sharepoint_online_site_storage",
"site_collection_storage",
"storage",
"total_storage",
"universal_devices",
"universal_devices_storage",
"virtualhost_storage",
"virtualhosts",
"vm_storage",
"vms",
"website_storage",
"websites",
"win_server_essentials",
"win_server_essentials_storage",
"workstation_storage",
"workstations"
],
"id": "6e6d758d-8e74-3ae3-ac84-50eb0dff12eb",
"type": "backup",
"api_base_url": "/bc/"
},
{
"name": "Physical Data Shipping",
"usages": [
"drives_shipped_from_cloud",
"drives_shipped_to_cloud"
],
"id": "b71b2c18-590a-303c-9d5a-8444fbe713ac",
"type": "physical_data_shipping",
"api_base_url": "/pds/"
},
{
"name": "File Sync & Share",
"usages": [
"fc_child_storages",
"fc_seats",
"fc_storage",
"fc_total_storage"
],
"id": "dfd85a5f-a464-32ab-81fd-99bcc66a070f",
"type": "files_cloud",
"api_base_url": "/fc/"
},
{
"name": "Notary",
"usages": [
"esignatures",
"esignatures_api",
"notarizations",
"notarizations_api",
"notarizations_total",
"notary_storage"
],
"id": "f9c5744e-bd1a-36b6-b0f0-ecd7483e1796",
"type": "notary",
"api_base_url": "/notary/console"
},
{
"name": "Acronis Storage SPLA",
"usages": [
"hci_cifs_storage",
"hci_compute_points",
"hci_iscsi_storage",
"hci_nfs_storage",
"hci_s3_storage",
"hci_storage",
"hci_total_cifs_storage",
"hci_total_compute_points",
"hci_total_iscsi_storage",
"hci_total_nfs_storage",
"hci_total_s3_storage",
"hci_total_storage",
"hci_total_vm_provisioned_cpu",
"hci_total_vm_provisioned_ram",
"hci_total_vm_storage",
"hci_total_vtl_storage",
"hci_vm_provisioned_cpu",
"hci_vm_provisioned_ram",
"hci_vm_storage",
"hci_vtl_storage"
],
"id": "cc29685d-a9ca-3e87-a83d-069f18b588f0",
"type": "hci",
"api_base_url": "/hci/"
},
{
"name": "Management Portal",
"usages": [],
"id": "7459244f-68f3-3bf4-9f53-5f63ecc1d91f",
"type": "platform",
"api_base_url": "/mc/"
}
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
### Fetch Application (GET /applications/{application_id})
Fetches the information about the application by ID.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `name` — Human-readable name that will be displayed to the users.
**Type**: String
- `type` — A type of application.
**Type**: String
**Allowed values**:
- `backup`
- `files_cloud`
- `monitoring`
- `storage`
- `platform`
- `hci`
- `physical_data_shipping`
- `notary`
- `usages` — Available usages for this application.
**Type**: Array of String
**Array type description:**
Usage name.
**Type**: String
- `api_base_url` — Base URL for application's HTTP API.
**Type**: String
**Example**:
```json
{
"name": "Acronis Backup Cloud",
"usages": [
"workstations",
"vms"
],
"id": "8aaf366b-fe24-4f25-93b3-bd729c86cc95",
"type": "backup",
"api_base_url": "/bc"
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Turn On Tenant Application (POST /applications/{application_id}/bindings/tenants/{tenant_id})
Turns the application on for the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
#### Responses
##### `204` — Application was successfully turned on.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Turn Off Tenant Application (DELETE /applications/{application_id}/bindings/tenants/{tenant_id})
Turns the application off for the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
#### Responses
##### `204` — Application was successfully turned off.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Delete Tenant Application Setting (DELETE /applications/{application_id}/settings/tenants/{tenant_id}/{setting_name})
Deletes own setting of the tenant's application.
The setting will be inherited from parent tenants when deleted.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
#### Responses
##### `204` — Own application setting was successfully deleted.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Update Tenant Application Setting (PUT /applications/{application_id}/settings/tenants/{tenant_id}/{setting_name})
Updates a setting of the tenant's application.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `value` — Value of the setting.
**Type**: any
- `lock` — Flag that controls whether the value can be overridden at another tenant's level.
**Type**: Boolean
- `exclusive` — If true, the value set for this tenant does not affect inheritance; this tenant's children will inherit the value from their grandparent tenant.
**Type**: Boolean
**Example**:
```json
{
"value": "qwerty",
"lock": false
}
```
#### Responses
##### `200` — Own setting was successfully updated.
**Media type**: `application/json`
- `name` — Name of the setting, for internal use by the platform and applications. Serves as the setting's ID.
**Type**: String
- `application_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `own` — Data which was set for this tenant.
**Type**: Object
- `effective` — Inherited data. This field can have a null value.
**Type**: Object
**Example**:
```json
{
"name": "setting_1",
"application_id": "2f2a4239-f140-4337-a107-bed298fed3f1",
"own": {
"value": "new_stuff",
"lock": false,
"exclusive": false
},
"effective": {
"owner": {
"type": "tenant",
"id": "81129b10-9f2a-4ee7-bf90-8698c4af055c"
},
"value": "old_Stuff",
"lock": false
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Fetch Tenant Application Setting (GET /applications/{application_id}/settings/tenants/{tenant_id}/{setting_name})
Fetches a setting of the tenant's application.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `name` — Name of the setting, for internal use by the platform and applications. Serves as the setting's ID.
**Type**: String
- `application_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `own` — Data which was set for this tenant.
**Type**: Object
- `effective` — Inherited data. This field can have a null value.
**Type**: Object
**Example**:
```json
{
"name": "setting_1",
"application_id": "2f2a4239-f140-4337-a107-bed298fed3f1",
"own": {
"value": "new_stuff",
"lock": false,
"exclusive": false
},
"effective": {
"owner": {
"type": "tenant",
"id": "81129b10-9f2a-4ee7-bf90-8698c4af055c"
},
"value": "old_Stuff",
"lock": false
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Create Client (POST /clients)
Creates a new client.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
* `urn:acronis.com::account-server::replication_manager`
* `urn:acronis.com::account-server::managed_clients_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `type` — Client type.
**Type**: String
**Allowed values**:
- `api_client`
- `managed_client`
- `tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `data` — Additional metadata, like agentType, hostname, etc...
**Type**: Object
- `token_endpoint_auth_method` — Explicit specified auth method.
**Type**: String
**Allowed values**:
- `client_secret_basic`
- `client_secret_post`
- `none`
- `redirect_uris` — List of possible redirect uris.
**Type**: Array of String
**Array type description:**
**Type**: String
- `origin_id` — Client origin ID.
**Type**: String
**Example**:
```json
{
"tenant_id": "48f86be5-c628-49c3-8575-62e78f54e4eb",
"data": {
"client_name": "Some application client",
"origin_dc_id": "ff7625c0-d649-445c-a2b3-9b59e66bfc2d"
},
"origin_id": "72403667-8e45-4dd9-bcbc-3e6047b98b3d",
"token_endpoint_auth_method": "client_secret_basic",
"type": "managed_client"
}
```
#### Responses
##### `201` — Client was successfully created.
**Media type**: `application/json`
- `client_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `client_secret_expires_at` — Time at which the client_secret will expire or 0 if it will not expire, according to the configured client secret lifetime. Its value is represented as number of seconds since the Unix epoch.
**Type**: Integer
- `type` — Client type.
**Type**: String
**Allowed values**:
- `api_client`
- `managed_client`
- `data` — Additional metadata, like agentType, hostname, etc...
**Type**: Object
- `token_endpoint_auth_method` — Explicit specified auth method.
**Type**: String
**Allowed values**:
- `client_secret_basic`
- `client_secret_post`
- `none`
- `client_secret` — Client secret.
**Type**: String
- `registration_access_token` — Client registration access token.
**Type**: String
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `created_by` — ID of the user who registered the client.
**Type**: String
- `status` — Client status - either enabled or disabled. Disabled clients can no longer be used to receive Access Tokens.
**Type**: String
**Allowed values**:
- `enabled`
- `disabled`
- `redirect_uris` — List of possible redirect uris.
**Type**: Array of String
**Array type description:**
**Type**: String
- `origin_id` — Client origin ID.
**Type**: String
**Example**:
```json
{
"created_by": "ab9d9f43-f9aa-4f83-9409-5547172daa27",
"tenant_id": "48f86be5-c628-49c3-8575-62e78f54e4eb",
"data": {
"client_name": "Some application client",
"origin_dc_id": "ff7625c0-d649-445c-a2b3-9b59e66bfc2d"
},
"registration_access_token": "94fe1f5e59b64bd69ad6754a34f37674",
"client_id": "3663410d-4b70-4860-860c-8db82bffab8e",
"origin_id": "72403667-8e45-4dd9-bcbc-3e6047b98b3d",
"token_endpoint_auth_method": "client_secret_basic",
"status": "enabled",
"created_at": "2019-08-24T01:23:15",
"client_secret": "cfffe6f6271b4addbe90ca63236de581",
"type": "managed_client",
"client_secret_expires_at": 0
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Fetch Clients Batch (GET /clients)
Fetches a batch of clients.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `uuids` | (Optional) A filter by comma-separated list of client's UUIDs.
**Type**: String
**Min length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}(,[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12})*` |
| `origin_id` | (Optional) A filter by clients origin ID. Can be used together with uuids or separately.
**Type**: String |
| `allow_deleted` | (Optional) If true, info for deleted clients may be returned.
**Type**: Boolean |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"created_by": "ab9ae709-0d00-521a-8be3-7891b1041e18",
"tenant_id": "0a305354-6efc-4b81-858d-2ae5dd1f08b1",
"data": {
"client_name": "backup_api_gateway"
},
"client_id": "4557d5f5-7881-54f4-83a5-212f19d355c1",
"token_endpoint_auth_method": "client_secret_basic",
"status": "enabled",
"created_at": "2023-07-06T16:26:33Z",
"redirect_uris": [
"/bc/api/gateway/cb",
"/bc/api/gateway/cb:ui"
],
"type": "api_client",
"client_secret_expires_at": 0,
"last_access_at": "2023-07-28T14:16:19Z",
"last_access_from_ip": "10.233.106.171"
},
{
"created_by": "ab9d9f43-f9aa-4f83-9409-5547172daa27",
"tenant_id": "48f86be5-c628-49c3-8575-62e78f54e4eb",
"data": {
"client_name": "Some application client",
"origin_dc_id": "ff7625c0-d649-445c-a2b3-9b59e66bfc2d"
},
"client_id": "3663410d-4b70-4860-860c-8db82bffab8e",
"origin_id": "72403667-8e45-4dd9-bcbc-3e6047b98b3d",
"token_endpoint_auth_method": "client_secret_basic",
"status": "enabled",
"created_at": "2019-08-24T01:23:15",
"type": "managed_client",
"client_secret_expires_at": 0,
"last_access_at": "2023-07-20T16:11:01Z",
"last_access_from_ip": "10.233.106.172"
}
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
### Delete Client (DELETE /clients/{client_id})
Deletes a client by ID.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
* `urn:acronis.com::account-server::replication_manager`
* `urn:acronis.com::account-server::managed_clients_admin`
#### Request parameters
#### Responses
##### `204` — Client was successfully deleted.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Update Client (PUT /clients/{client_id})
Updates a client by ID.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
* `urn:acronis.com::account-server::replication_manager`
* `urn:acronis.com::account-server::managed_clients_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `data` — Additional metadata that will be updated.
**Type**: Object
- `status` — Client status - either enabled or disabled. Disabled clients can no longer be used to receive Access Tokens.
**Type**: String
**Allowed values**:
- `enabled`
- `disabled`
- `redirect_uris` — List of possible redirect uris.
**Type**: Array of String
**Array type description:**
**Type**: String
- `origin_id` — Client origin ID.
**Type**: String
**Example**:
```json
{
"data": {
"client_name": "Some application client"
},
"status": "disabled",
"redirect_uris": [
"com.acronis.abc://oauth"
]
}
```
#### Responses
##### `200` — Client was successfully updated.
**Media type**: `application/json`
- `client_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `client_secret_expires_at` — Time at which the client_secret will expire or 0 if it will not expire, according to the configured client secret lifetime. Its value is represented as number of seconds since the Unix epoch.
**Type**: Integer
- `type` — Client type.
**Type**: String
**Allowed values**:
- `api_client`
- `managed_client`
- `data` — Additional metadata, like agentType, hostname, etc...
**Type**: Object
- `token_endpoint_auth_method` — Explicit specified auth method.
**Type**: String
**Allowed values**:
- `client_secret_basic`
- `client_secret_post`
- `none`
- `created_at` — Date and time when the client was created. This field can have a null value.
**Type**: any
- `created_by` — ID of the user who registered the client.
**Type**: String
- `last_access_at` — Date and time when client was used to issue token last time. This field can have a null value.
**Type**: any
- `last_access_from_ip` — IP address from witch client was used to issue token last time. This field can have a null value.
**Type**: any
- `status` — Client status - either enabled or disabled. Disabled clients can no longer be used to receive Access Tokens.
**Type**: String
**Allowed values**:
- `enabled`
- `disabled`
- `redirect_uris` — List of possible redirect uris.
**Type**: Array of String
**Array type description:**
**Type**: String
- `origin_id` — Client origin ID.
**Type**: String
**Example**:
```json
{
"created_by": "ab9ae709-0d00-521a-8be3-7891b1041e18",
"tenant_id": "0a305354-6efc-4b81-858d-2ae5dd1f08b1",
"data": {
"client_name": "backup_api_gateway"
},
"client_id": "4557d5f5-7881-54f4-83a5-212f19d355c1",
"token_endpoint_auth_method": "client_secret_basic",
"status": "enabled",
"created_at": "2023-07-06T16:26:33Z",
"redirect_uris": [
"/bc/api/gateway/cb",
"/bc/api/gateway/cb:ui"
],
"type": "api_client",
"client_secret_expires_at": 0,
"last_access_at": "2023-07-28T14:16:19Z",
"last_access_from_ip": "10.233.106.171"
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Fetch Client (GET /clients/{client_id})
Fetches a client by ID.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `client_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `client_secret_expires_at` — Time at which the client_secret will expire or 0 if it will not expire, according to the configured client secret lifetime. Its value is represented as number of seconds since the Unix epoch.
**Type**: Integer
- `type` — Client type.
**Type**: String
**Allowed values**:
- `api_client`
- `managed_client`
- `data` — Additional metadata, like agentType, hostname, etc...
**Type**: Object
- `token_endpoint_auth_method` — Explicit specified auth method.
**Type**: String
**Allowed values**:
- `client_secret_basic`
- `client_secret_post`
- `none`
- `created_at` — Date and time when the client was created. This field can have a null value.
**Type**: any
- `created_by` — ID of the user who registered the client.
**Type**: String
- `last_access_at` — Date and time when client was used to issue token last time. This field can have a null value.
**Type**: any
- `last_access_from_ip` — IP address from witch client was used to issue token last time. This field can have a null value.
**Type**: any
- `status` — Client status - either enabled or disabled. Disabled clients can no longer be used to receive Access Tokens.
**Type**: String
**Allowed values**:
- `enabled`
- `disabled`
- `redirect_uris` — List of possible redirect uris.
**Type**: Array of String
**Array type description:**
**Type**: String
- `origin_id` — Client origin ID.
**Type**: String
**Example**:
```json
{
"created_by": "ab9ae709-0d00-521a-8be3-7891b1041e18",
"tenant_id": "0a305354-6efc-4b81-858d-2ae5dd1f08b1",
"data": {
"client_name": "backup_api_gateway"
},
"client_id": "4557d5f5-7881-54f4-83a5-212f19d355c1",
"token_endpoint_auth_method": "client_secret_basic",
"status": "enabled",
"created_at": "2023-07-06T16:26:33Z",
"redirect_uris": [
"/bc/api/gateway/cb",
"/bc/api/gateway/cb:ui"
],
"type": "api_client",
"client_secret_expires_at": 0,
"last_access_at": "2023-07-28T14:16:19Z",
"last_access_from_ip": "10.233.106.171"
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Request Tokens (POST /idp/token)
Requests an access token, an ID token and, optionally, a refresh token.
To additionally request a refresh token, refer to [OpenID Connect Core 1.0 Section 11](https://openid.net/specs/openid-connect-core-1_0.html#rfc.section.11).
#### Security
The endpoint does not require authorization.
#### Request parameters
##### Headers
| Name | Description |
|------|-------------|
| `Authorization` | (Optional) Used to send the base64-encoded "client_id:client_secret" credentials.
May be required depending on the grant type and 'token_endpoint_auth_method'
**Type**: String
**Pattern**: `^Basic [0-9a-zA-Z\-\._~+/]*=$` |
##### Request body
**Media type**: `application/x-www-form-urlencoded`
- `grant_type` — The following authorization grant types are supported:
- `password` grant type implementation is in accordance with [RFC6749 Section 4.3](https://datatracker.ietf.org/doc/html/rfc6749#section-4.3).
- `md5_password` grant type is the same as `password` grant type, but password provided as MD5 hashsum.
- `authorization_code`, `refresh_token` and `client_credentials` grant types implementation is in accordance with [OpenID Connect Core 1.0 Section 3.1.3](https://openid.net/specs/openid-connect-core-1_0.html#TokenEndpoint).
- `authorization_code` grant type implementation also supports PKCE extension in accordance with [RFC7636](https://datatracker.ietf.org/doc/html/rfc7636)
- `urn:ietf:params:oauth:grant-type:device_code` grant type implementation is in accordance with [RFC8628](https://datatracker.ietf.org/doc/html/rfc8628).
- `urn:ietf:params:oauth:grant-type:jwt-bearer` grant type implementation is in accordance with [RFC7523](https://datatracker.ietf.org/doc/html/rfc7523).
**Type**: String
**Allowed values**:
- `password`
- `md5_password`
- `authorization_code`
- `refresh_token`
- `client_credentials`
- `urn:ietf:params:oauth:grant-type:device_code`
- `urn:ietf:params:oauth:grant-type:jwt-bearer`
- `client_id` — OAuth 2.0 / OpenID Connect client's identifier (UUID).
Required for the `urn:ietf:params:oauth:grant-type:device_code` grant type.
Required for `authorization_code` and `client_credentials` grant types if the client was created with `token_endpoint_auth_method` set to `client_secret_post`.
**Type**: String
- `client_secret` — OAuth 2.0 / OpenID Connect clients secret.
Required for `authorization_code` and `client_credentials` grant types if the client was created with `token_endpoint_auth_method` set to `client_secret_post`.
**Type**: String
- `username` — Required for the `password` and `md5_password` grant types.
**Type**: String
- `password` — Required for the `password` and `md5_password` grant types.
**Type**: String
- `refresh_token` — Required for the `refresh_token` grant type.
**Type**: String
- `code` — Required for the `authorization_code` grant type.
**Type**: String
- `scope` — Not used for the `authorization_code` grant type. Optional for all other supported grant types.
**Type**: String
**Pattern**: `^[\w_]+(\s+[\w_]+)*$`
- `assertion` — Required for the `urn:ietf:params:oauth:grant-type:jwt-bearer` grant type.
**Type**: String
- `device_code` — Required for the `urn:ietf:params:oauth:grant-type:device_code` grant type.
**Type**: String
- `totp_code` — Required for the `password` grant type with TOTP authentication.
**Type**: String
- `code_verifier` — A cryptographically random string that is used to correlate the authorization request to the token request.
Required for the `authorization_code` grant type if `code_challenge` was provided during the authorization request.
**Type**: String
**Pattern**: `^[A-Za-z0-9\-\._~]{43,128}$`
- `not_required_introspection` — Determines what kind of the access token will be issued: that require introspection or that do not require it.
Tokens that require introspection we call "hybrid" because we use combined approach to work with them: one part of the tokens' data could be obtained from the token itself but another part requires making a request to the introspection endpoint.
They contain not the full list of associated access policies in the scope and their introspection is required by the resource server for proper authorization.
If `not_required_introspection` is set to `true`, the issued token will contain all associated access policies in the scope and its introspection will not be required.
Such JWT token has `"nri": 1` in the header section ("nri" - not required introspection).
If `not_required_introspection` is not set or set to `false`, Account Server will decide whether to issue a "hybrid" token or not based on the its internal logic and roles configuration.
Non "hybrid" JWT token has `"nri": 0` in the header section or does not have this field at all.
**Type**: Boolean
**Example**:
```form-urlencoded
grant_type=password¬_required_introspection=true
```
#### Responses
##### `200` — Authentication was successful and the tokens were issued.
**Media type**: `application/json`
- `access_token` — **Type**: String
- `token_type` — **Type**: String
- `expires_in` — **Type**: Integer
- `expires_on` — **Type**: Integer
- `id_token` — **Type**: String
- `refresh_token` — **Type**: String
**Example**:
```json
{
"expires_on": 1388444763,
"id_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.....",
"access_token": "nowhere_to_apply",
"expires_in": 600,
"refresh_token": "OhYc9oko5ej9",
"token_type": "bearer"
}
```
##### `400` — Failed authentication factors check and when `redirect_uri` form parameter is not defined.
**Media type**: `application/json`
- `error` — **Type**: String
**Allowed values**:
- `totp_setup_required`
- `totp_required`
- `invalid_totp`
- `access_denied`
- `invalid_request`
- `error_description` — **Type**: String
**Example**:
*`example_0`*:
```json
{
"error": "invalid_request",
"error_description": "Invalid request"
}
```
##### `401` — Failed authentication factors check and when `redirect_uri` form parameter is not defined.
**Media type**: `application/json`
- `error` — **Type**: String
**Allowed values**:
- `totp_setup_required`
- `totp_required`
- `invalid_totp`
- `access_denied`
- `invalid_request`
- `error_description` — **Type**: String
**Example**:
*`example_1`*:
```json
{
"error": "totp_required",
"error_description": "TOTP code is required"
}
```
##### `403` — Requested scope is not allowed.
**Media type**: `application/json`
- `error` — **Type**: String
**Allowed values**:
- `totp_setup_required`
- `totp_required`
- `invalid_totp`
- `access_denied`
- `invalid_request`
- `error_description` — **Type**: String
**Example**:
*`example_0`*:
```json
{
"error": "access_denied",
"error_description": "Requested scope is not a subset of previously issued token's scope"
}
```
### Revoke Token (POST /idp/revoke_token)
Revokes an access token and, if any, a refresh token in accordance with [RFC7009](https://datatracker.ietf.org/doc/html/rfc7009).
Confidential clients must either follow Basic authentication scheme or provide credentials in the request body.
Public clients must provide `client_id` in the request body.
If `access_token` revocation is requested, the refresh token, if any, issued together with provided access token will also be revoked.
If `refresh_token` revocation is requested, the access token issued together with provided refresh token will also be revoked.
#### Security
The endpoint does not require authorization.
#### Request parameters
##### Headers
| Name | Description |
|------|-------------|
| `Authorization` | (Optional) Used to send the base64-encoded "client_id:client_secret" credentials.
**Type**: String
**Pattern**: `^Basic [0-9a-zA-Z\-\._~+/]*=$` |
##### Request body
**Media type**: `application/x-www-form-urlencoded`
- `token` — The token that the client wants to revoke.
**Type**: String
- `token_type_hint` — A hint about the token type submitted for revocation.
**Type**: String
**Allowed values**:
- `access_token`
- `refresh_token`
- `client_id` — OAuth 2.0 / OpenID Connect client's identifier (UUID).
Required for public clients.
**Type**: String
- `client_secret` — OAuth 2.0 / OpenID Connect clients secret.
Can be used by confidential clients for authentication.
**Type**: String
**Example**:
```form-urlencoded
token_type_hint=access_token
```
#### Responses
##### `200` — Authentication was successful and the token was revoked.
##### `400` — Invalid request.
**Media type**: `application/json`
- `error` — **Type**: String
**Allowed values**:
- `invalid_client`
- `invalid_request`
- `unsupported_token_type`
- `error_description` — **Type**: String
**Example**:
*`example_0`*:
```json
{
"error": "unsupported_token_type",
"error_description": "Unsupported token type"
}
```
##### `401` — Failed authentication factors check.
**Media type**: `application/json`
- `error` — **Type**: String
**Allowed values**:
- `invalid_client`
- `invalid_request`
- `unsupported_token_type`
- `error_description` — **Type**: String
**Example**:
*`example_1`*:
```json
{
"error": "invalid_client",
"error_description": "Invalid client credentials"
}
```
### Introspect Token (POST /idp/introspect_token)
Introspect an access token in accordance with [RFC7662](https://datatracker.ietf.org/doc/html/rfc7662).
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::token_introspector`
#### Request parameters
##### Request body
**Media type**: `application/x-www-form-urlencoded`
- `token` — The token that the client wants to introspect.
**Type**: String
#### Responses
##### `200` — Authentication and authorization were successful and the token's was introspected.
Note if the token from the request body is invalid (signature verification failed, token is expired, or something else), 200 HTTP code will be returned, but the response body will contain `{"active": false}`.
**Media type**: `application/json`
- `active` — **Type**: Boolean
- `token_type` — **Type**: String
- `exp` — **Type**: Integer
- `aud` — **Type**: String
- `jti` — **Type**: String
- `iss` — **Type**: String
- `sub` — **Type**: String
- `sub_type` — **Type**: String
- `client_id` — **Type**: String
- `owner_tuid` — **Type**: String
- `scope` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"owner_tuid": "7fce5f09-2e4b-4c26-8311-31a361c13190",
"scope": [
{
"rn": "task_manager",
"role": "consumer",
"rp": "queue_c2c_acc_registration",
"tuid": "7fce5f09-2e4b-4c26-8311-31a361c13190",
"tid": "1"
},
{
"tid": "1",
"tuid": "7fce5f09-2e4b-4c26-8311-31a361c13190",
"rn": "credentials_store",
"role": "consumer"
}
],
"sub_type": "c2c_backup_manager",
"jti": "ded74262-94ab-490a-b852-0214fe09a7ad",
"token_type": "access_token",
"client_id": "f5c64710-6726-5fea-97fd-b2263b9c4d8b",
"exp": 1721745289,
"sub": "f5c64710-6726-5fea-97fd-b2263b9c4d8b",
"aud": "mc-global.do.acronis.fun",
"iss": "https://mc-global.do.acronis.fun/bc",
"active": true
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
### Request One Time Token (POST /idp/ott)
Available in cloud version only and this method can be accessed only by OAuth 2.0 / OpenID Connect client.
Requests a one-time token for authentication on behalf of the specified user.
Either user external ID or Acronis user login or Acronis user UUID can be supplied.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::user_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `purpose` — Purposes of one-time tokens.
**Type**: String
**Allowed values**:
- `user_login`
- `verify`
- `login` — **Type**: String
- `external_id` — **Type**: String
- `user_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `audit_data` — An arbitrary optional text field that could be later used for auditing purposes.
**Type**: String
**Example**:
```json
{
"login": "user@mail.org",
"purpose": "user_login",
"audit_data": "external system support department user ID"
}
```
#### Responses
##### `200` — One-time token was successfully issued.
**Media type**: `application/json`
- `ott` — A base64-encoded one-time token.
**Type**: String
**Example**:
```json
{
"ott": "dGhpcyBpcyB0ZXN0IG9uZS10aW1lIHRva2Vu"
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
### Log In With One Time Token (POST /idp/ott/login)
Authenticates to the platform using one-time token and provides the IdP session cookie.
Available in cloud version only.
#### Security
The endpoint does not require authorization.
#### Request parameters
##### Request body
**Media type**: `application/json`
- `ott` — **Type**: String
**Example**:
```json
{
"ott": "dGhpcyBpcyB0ZXN0IG9uZS10aW1lIHRva2Vu"
}
```
#### Responses
##### `200` — Authentication with one-time token was successful.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `login` — User's login.
**Type**: String
- `contact` — **Type**: Object
- `activated` — Flag, indicates whether the user has been activated or not.
**Type**: Boolean
- `enabled` — Flag, indicates whether the user is enabled or disabled.
**Type**: Boolean
- `access_policies` — Will be returned with all user access policies if query param `with_access_policies` is provided.
**Type**: Array of Object
**Array type description:**
**Type**: Object
**Min items**: 0
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `updated_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `deleted_at` — Soft deletion timestamp.
**Type**: any
- `language` — Preferred locale.
**Type**: String
- `idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `external_id` — User's ID in external identity provider (e.g. SID in AD).
**Type**: String
- `origin_id` — User's origin ID, for example, ID of a Cyber Application responsible for creating this user.
**Type**: String
- `origin_external_id` — User's external origin ID.
**Type**: String
- `disable_after` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `personal_tenant_id` — UUID of user's personal tenant. This field can have a null value.
**Type**: any
- `business_types` — Business types.
**Type**: Array of String
**Array type description:**
**Type**: String
**Allowed values**:
- `buyer`
- `notifications` — User notifications.
**Type**: Array of String
**Array type description:**
**Type**: String
**Allowed values**:
- `maintenance`
- `quota`
- `reports`
- `backup_error`
- `backup_warning`
- `backup_info`
- `backup_daily_report`
- `backup_critical`
- `device_control_warning`
- `certificate_management_error`
- `certificate_management_warning`
- `certificate_management_info`
- `mfa_status` — Multi-factor authentication status of the user.
**Type**: String
**Allowed values**:
- `disabled`
- `forcibly_disabled`
- `setup_required`
- `enabled`
- `session_mfa_status` — Multi-factor authentication status of the user session.
**Type**: String
**Allowed values**:
- `passed_or_not_required`
- `passed_as_trusted`
- `required`
- `external_operation_status` — Indicates if some external operation in progress for this user (his personal tenant).
**Type**: any
- `terms_accepted` — Flag that defines if this user has accepted EULA.
**Type**: Boolean
- `login_totp_time` — The time when the user in the current session passed TOTP verification.
**Type**: any
- `tenant_kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `tenant_pricing_model` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `brand_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
**Example**:
```json
{
"disable_after": "2017-06-22T18:25:16",
"idp_id": "e6f73a28-ff2e-4728-8f78-49eb74b20fce",
"activated": true,
"tenant_id": "0ef03214-6e47-4e50-87f2-a5955ba6095c",
"enabled": true,
"mfa_status": "setup_required",
"personal_tenant_id": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"brand_id": "a77b1af2-3ac5-576d-1db3-27b054e7d2aa",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [],
"deleted_at": "2020-05-19T11:50:00",
"email_confirmed": false,
"phone": "123456789"
},
"terms_accepted": true,
"version": 2,
"origin_id": "pillr.mdr",
"id": "948efcf2-b740-4c40-bb2d-4e4a46adfd87",
"language": "ru",
"tenant_kind": "partner",
"origin_external_id": "c66b1af2-2ac5-4764-8db6-97b054e7d27e",
"external_id": "S-1-5-21-917267712-1342860078-1792151419-500",
"created_at": "2016-06-22T18:25:16",
"business_types": [],
"login": "mylogin",
"updated_at": "2016-06-22T18:25:16",
"notifications": [
"maintenance",
"quota",
"reports",
"backup_error",
"backup_warning",
"backup_info",
"backup_daily_report",
"backup_critical",
"device_control_warning",
"certificate_management_error",
"certificate_management_warning",
"certificate_management_info"
],
"session_mfa_status": "required",
"deleted_at": null,
"tenant_pricing_model": "trial"
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
### POST /idp/device_authorization
Registers device codes and issues device and user codes.
#### Security
The endpoint does not require authorization.
#### Request parameters
##### Request body
**Media type**: `application/x-www-form-urlencoded`
- `client_id` — OAuth 2.0 / OpenID Connect client's identifier (UUID).
**Type**: String
- `display_name` — Device display name (machine name, cluster ID, etc.).
**Type**: String
- `scope` — Scopes requested or authorized by the end user for the client.
Supported scopes:
- urn:acronis.com:tenant-id::backup_agent_admin - For backup agent registration
- urn:acronis.com:tenant-id::cyber_frame_registrator - For Cyber Frame Connector registration
**Type**: Array of String
**Array type description:**
**Type**: String
**Pattern**: `^urn:acronis\.com:tenant-id:(?:[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12})?:(?:backup_agent_admin|cyber_frame_registrator)$`
#### Responses
##### `200` — Device code successfully registered.
**Media type**: `application/json`
- `device_code` — The device verification code.
**Type**: String
- `user_code` — The end-user verification code.
**Type**: String
- `verification_uri` — The end-user verification URI.
**Type**: String
- `verification_uri_complete` — A verification URI that includes the `user_code`.
**Type**: String
- `expires_in` — The lifetime in seconds of the `device_code` and `user_code`.
**Type**: Integer
- `interval` — The minimum interval time in seconds for the client polling requests to the token endpoint.
**Type**: Integer
**Example**:
```json
{
"expires_in": 30,
"device_code": "qVqLLfXHCdFS7nT4M_WI-_hMGXaxzylUBhqZ-CXUPGd-g4B5CFQfgrrDFtHqxSX4",
"user_code": "RDRD-WNDB",
"verification_uri": "http://127.0.0.1:61827/abc",
"interval": 100,
"verification_uri_complete": "http://127.0.0.1:61827/abc?code=RDRD-WNDB"
}
```
### Device Authorization Approval (GET /idp/device_authorization/approval)
Returns information about existing device authorization by the user code.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::backup::backup_user`
* `urn:acronis.com::backup::protection_admin`
* `urn:acronis.com::files_cloud::sync_share_user`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `code` | (Required) The end-user verification code.
**Type**: String |
| `tenant_uuid` | (Optional) Personal tenant UUID for which the device code will be approved.
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}` |
#### Responses
##### `200` — Device authorization exists.
**Media type**: `application/json`
- `client_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `display_name` — Device display name (machine name, cluster ID, etc.).
**Type**: String
- `scope` — Scopes requested or authorized by the end user for the client.
**Type**: Array of String
**Array type description:**
**Type**: String
- `tenant_id` — ID of the scoped tenant.
**Type**: String
- `tenant_name` — Name of the scoped tenant.
**Type**: String
- `is_current_tenant` — True if the tenant ID provided by ApiGW is in the path of the scoped tenant ID; false otherwise.
**Type**: Boolean
**Example**:
```json
{
"tenant_id": "822",
"scope": [
"urn:acronis.com:tenant-id::backup_agent_admin"
],
"display_name": "Super Device",
"client_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"tenant_name": "Ivan Ivanov",
"is_current_tenant": false
}
```
##### `400` — Invalid request parameters, device code expired or associated public client not found.
Scoped tenant or its owner not satisfied the requirements.
**Media type**: `application/json`
- `error` — **Type**: String
**Allowed values**:
- `totp_setup_required`
- `totp_required`
- `invalid_totp`
- `access_denied`
- `invalid_request`
- `error_description` — **Type**: String
**Example**:
*`example_0`*:
```json
{
"error": "invalid_request",
"error_description": "Invalid request"
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
Current user has no access to the scoped tenant.
User code is invalid or the related device code already deleted.
**Media type**: `application/json`
- `error` — **Type**: String
**Allowed values**:
- `totp_setup_required`
- `totp_required`
- `invalid_totp`
- `access_denied`
- `invalid_request`
- `error_description` — **Type**: String
**Example**:
*`example_0`*:
```json
{
"error": "access_denied",
"error_description": "Requested scope is not a subset of previously issued token's scope"
}
```
### Device Authorization Approval (POST /idp/device_authorization/approval)
Approves existing device code.
In case of setting tenant_uuid parameter in the request body or in the scope
the current user and target tenant should satisfy next requirements:
user should be a partner_admin,
user should have RW access to the target tenant,
target tenant should be personal,
target tenant's owner should have protection_admin or backup_user roles.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::backup::backup_user`
* `urn:acronis.com::backup::protection_admin`
* `urn:acronis.com::files_cloud::sync_share_user`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `code` — The end-user verification code.
**Type**: String
- `tenant_uuid` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
**Example**:
```json
{
"code": "RDRD-WNDB",
"tenant_uuid": "ab7869a9-f5e1-4faf-a56c-5a0ae866dc41"
}
```
#### Responses
##### `204` — Device code successfully approved.
##### `400` — Invalid request parameters, device code expired or associated public client not found.
Scoped tenant or its owner not satisfied the requirements.
**Media type**: `application/json`
- `error` — **Type**: String
**Allowed values**:
- `totp_setup_required`
- `totp_required`
- `invalid_totp`
- `access_denied`
- `invalid_request`
- `error_description` — **Type**: String
**Example**:
*`example_0`*:
```json
{
"error": "invalid_request",
"error_description": "Invalid request"
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
Current user has no access to the scoped tenant.
User code is invalid or the related device code already deleted.
**Media type**: `application/json`
- `error` — **Type**: String
**Allowed values**:
- `totp_setup_required`
- `totp_required`
- `invalid_totp`
- `access_denied`
- `invalid_request`
- `error_description` — **Type**: String
**Example**:
*`example_0`*:
```json
{
"error": "access_denied",
"error_description": "Requested scope is not a subset of previously issued token's scope"
}
```
### Fetch One Time Token Login Page (GET /idp/external-login)
Fetches an HTML page that handles the login flow from external systems with one-time tokens and redirects users to the provided
`targetURI`. The legacy way to provide one-time token and target URI is via the following URL fragment parameters:
- `ott` - a URL-encoded one-time token.
- `targetURI` - a URI the user should be redirected to on successful authentication.
Example: `/idp/external-login#ott=dG9rZW4gd2l0aCBzYWZlIGVuY29kaW5n&targetURI=https://example.com/app`.
Please use the query parameters instead to access up-to-date features like branding.
#### Security
The endpoint supports the following authorization methods: `x-api-key`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `ott` | (Optional) a URL-encoded one-time token.
**Type**: String |
| `targetURI` | (Optional) a URI the user should be redirected to on successful authentication.
**Type**: String |
#### Responses
##### `200` — The request was successful.
**Media type**: `text/html`
- `schema` — **Type**: any
**Example**:
```text
{{ _('Please wait...') }}
```
### Fetch Infrastructures Batch (GET /infra)
Fetches batch of infrastructure components.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
* `urn:acronis.com::account-server::readonly_admin`
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `uuids` | (Required) Comma-separated list of infrastructures' UUIDs.
**Type**: String |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"capabilities": [
"backup",
"files_cloud"
],
"name": "Infrastructure Component",
"url": "acronis+fes://storage20.corp.acronis.com:44445",
"owner_tenant_id": "0bb386ae-e66d-4e7b-84fb-cddcf60002de",
"location_id": "f79546d7-d051-4e19-96f3-4cc68c2c5575",
"version": 3,
"id": "8fcd353b-0a40-40f2-9a55-ef8137d48800",
"content_url": "https://browse.storage20.corp.acronis.com/",
"backend_type": "azure",
"content_mobile_url": "https://browse.storage20.corp.acronis.com/mobile/",
"platform_owned": true
},
{
"capabilities": [
"disaster_recovery"
],
"name": "DR Infrastructure Component",
"url": "amazon+s3://dr.corp.acronis.com",
"owner_tenant_id": "3f545595-0e77-4a34-9259-dab5256f9559",
"location_id": "bfdf24b0-5a72-49a8-a2bd-2fc7c085ff7b",
"version": 5,
"id": "3d1efc54-4e9a-4db1-abe6-7d2aee50cead",
"backend_type": "acronis",
"platform_owned": false
}
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Register Infrastructure (POST /infra)
Registers a new infrastructure component.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `owner_tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `location_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `name` — Human-readable name of infrastructure component that will be displayed to the users.
**Type**: String
- `url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `capabilities` — Capabilities of infrastructure component.
**Type**: Array of String
**Array type description:**
Capability of infrastructure component.
**Type**: String
**Allowed values**:
- `backup`
- `disaster_recovery`
- `files_cloud`
- `vcd`
- `content_url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `content_mobile_url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `backend_type` — **Type**: any
**Example**:
```json
{
"capabilities": [
"backup",
"disaster_recovery"
],
"name": "Default Infrastructure Component",
"url": "acronis+fes://storage20.acronis.com:44445",
"owner_tenant_id": "0bb386ae-e66d-4e7b-84fb-cddcf60002de",
"location_id": "bfdf24b0-5a72-49a8-a2bd-2fc7c085ff7b",
"content_url": "https://browse.storage20.acronis.com/",
"backend_type": "azure",
"content_mobile_url": "https://browse.storage20.acronis.com/mobile/"
}
```
#### Responses
##### `201` — Infrastructure component was successfully registered.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `owner_tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `location_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `platform_owned` — Is infra component owned by Platform.
**Type**: Boolean
- `name` — Human-readable name of infrastructure component that will be displayed to the users.
**Type**: String
- `url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `capabilities` — Capabilities of infrastructure component.
**Type**: Array of String
**Array type description:**
Capability of infrastructure component.
**Type**: String
**Allowed values**:
- `backup`
- `disaster_recovery`
- `files_cloud`
- `vcd`
- `content_url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `content_mobile_url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `backend_type` — **Type**: any
- `version` — Auto-incremented infrastructure component version.
**Type**: Integer
- `readonly` — True if infra details are accessible in a limited way, e.g. infra is owned by some ancestor.
**Type**: Boolean
**Example**:
```json
{
"capabilities": [
"backup",
"disaster_recovery"
],
"name": "Infrastructure Component",
"url": "acronis+fes://storage20.corp.acronis.com:44445",
"owner_tenant_id": "0bb386ae-e66d-4e7b-84fb-cddcf60002de",
"readonly": false,
"location_id": "f79546d7-d051-4e19-96f3-4cc68c2c5575",
"version": 3,
"id": "8fcd353b-0a40-40f2-9a55-ef8137d48800",
"content_url": "https://browse.storage20.corp.acronis.com/",
"backend_type": "azure",
"content_mobile_url": "https://browse.storage20.corp.acronis.com/mobile/",
"platform_owned": true
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Unregister Infrastructure (DELETE /infra/{infra_id})
Unregisters infrastructure component.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `force` | (Optional) If true, existing usage will be ignored in case there are no customer tenants having offering items associated with this infrastructure component turned on.
**Type**: Boolean |
| `version` | (Required) Growing number of object internal version.
**Type**: Integer |
#### Responses
##### `204` — Infrastructure component was successfully unregistered.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_6`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "conflict",
"details": {
"info": "Conflict"
},
"message": "Conflict"
}
}
```
### Update Infrastructure (PUT /infra/{infra_id})
Updates infrastructure component.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `name` — Human-readable name of infrastructure component that will be displayed to the users.
**Type**: String
- `location_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `capabilities` — Capabilities of infrastructure component.
**Type**: Array of String
**Array type description:**
Capability of infrastructure component.
**Type**: String
**Allowed values**:
- `backup`
- `disaster_recovery`
- `files_cloud`
- `vcd`
- `content_url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `content_mobile_url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `backend_type` — **Type**: any
- `version` — Auto-incremented infrastructure component version.
**Type**: Integer
**Example**:
```json
{
"capabilities": [
"files_cloud"
],
"name": "Infrastructure Component",
"url": "acronis+fes://storage20.corp.acronis.com:44445",
"version": 10,
"content_url": "https://browse.storage20.corp.acronis.com/",
"backend_type": "azure",
"content_mobile_url": "https://browse.storage20.corp.acronis.com/mobile/"
}
```
#### Responses
##### `200` — Infrastructure component was successfully updated.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `owner_tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `location_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `platform_owned` — Is infra component owned by Platform.
**Type**: Boolean
- `name` — Human-readable name of infrastructure component that will be displayed to the users.
**Type**: String
- `url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `capabilities` — Capabilities of infrastructure component.
**Type**: Array of String
**Array type description:**
Capability of infrastructure component.
**Type**: String
**Allowed values**:
- `backup`
- `disaster_recovery`
- `files_cloud`
- `vcd`
- `content_url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `content_mobile_url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `backend_type` — **Type**: any
- `version` — Auto-incremented infrastructure component version.
**Type**: Integer
- `readonly` — True if infra details are accessible in a limited way, e.g. infra is owned by some ancestor.
**Type**: Boolean
**Example**:
```json
{
"capabilities": [
"backup",
"disaster_recovery"
],
"name": "Infrastructure Component",
"url": "acronis+fes://storage20.corp.acronis.com:44445",
"owner_tenant_id": "0bb386ae-e66d-4e7b-84fb-cddcf60002de",
"readonly": false,
"location_id": "f79546d7-d051-4e19-96f3-4cc68c2c5575",
"version": 3,
"id": "8fcd353b-0a40-40f2-9a55-ef8137d48800",
"content_url": "https://browse.storage20.corp.acronis.com/",
"backend_type": "azure",
"content_mobile_url": "https://browse.storage20.corp.acronis.com/mobile/",
"platform_owned": true
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_6`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "conflict",
"details": {
"info": "Conflict"
},
"message": "Conflict"
}
}
```
### Fetch Infrastructure (GET /infra/{infra_id})
Fetches infrastructure component.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
* `urn:acronis.com::account-server::readonly_admin`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `owner_tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `location_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `platform_owned` — Is infra component owned by Platform.
**Type**: Boolean
- `name` — Human-readable name of infrastructure component that will be displayed to the users.
**Type**: String
- `url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `capabilities` — Capabilities of infrastructure component.
**Type**: Array of String
**Array type description:**
Capability of infrastructure component.
**Type**: String
**Allowed values**:
- `backup`
- `disaster_recovery`
- `files_cloud`
- `vcd`
- `content_url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `content_mobile_url` — URL.
**Type**: String
**Pattern**: `^[a-z0-9\+]+:\/\/[^\s\/$.?#].[^\s]*`
- `backend_type` — **Type**: any
- `version` — Auto-incremented infrastructure component version.
**Type**: Integer
- `readonly` — True if infra details are accessible in a limited way, e.g. infra is owned by some ancestor.
**Type**: Boolean
**Example**:
```json
{
"capabilities": [
"backup",
"disaster_recovery"
],
"name": "Infrastructure Component",
"url": "acronis+fes://storage20.corp.acronis.com:44445",
"owner_tenant_id": "0bb386ae-e66d-4e7b-84fb-cddcf60002de",
"readonly": false,
"location_id": "f79546d7-d051-4e19-96f3-4cc68c2c5575",
"version": 3,
"id": "8fcd353b-0a40-40f2-9a55-ef8137d48800",
"content_url": "https://browse.storage20.corp.acronis.com/",
"backend_type": "azure",
"content_mobile_url": "https://browse.storage20.corp.acronis.com/mobile/",
"platform_owned": true
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Fetch Infrastructures Locations Batch (GET /locations)
Fetches a batch of infrastructure locations.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
* `urn:acronis.com::account-server::readonly_admin`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `uuids` | (Required) Comma-separated list of infrastructures locations' UUIDs.
**Type**: String |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"name": "Capetown Infrastructure",
"owner_tenant_id": "0bb386ae-e66d-4e7b-84fb-cddcf60002de",
"readonly": false,
"version": 3,
"id": "8fcd353b-0a40-40f2-9a55-ef8137d48800",
"platform_owned": true
},
{
"name": "Singapore Infrastructure",
"owner_tenant_id": "0bb386ae-e66d-4e7b-84fb-cddcf60002de",
"readonly": false,
"version": 5,
"id": "3d1efc54-4e9a-4db1-abe6-7d2aee50cead",
"platform_owned": false
}
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Create Infrastructures Location (POST /locations)
Creates a new infrastructures location.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `owner_tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `name` — Human-readable name of infrastructure location that will be displayed to the users.
**Type**: String
**Example**:
```json
{
"owner_tenant_id": "0bb386ae-e66d-4e7b-84fb-cddcf60002de",
"name": "Boston Infrastructure"
}
```
#### Responses
##### `201` — Infrastructure location was successfully created.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `owner_tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `platform_owned` — Is infra location owned by Platform.
**Type**: Boolean
- `name` — Human-readable name of infrastructure location that will be displayed to the users.
**Type**: String
- `version` — Auto-incremented infrastructure location version.
**Type**: Integer
- `readonly` — True if location details are accessible in a limited way, e.g. location is owned by some ancestor.
**Type**: Boolean
**Example**:
```json
{
"name": "Boston Infrastructure",
"owner_tenant_id": "0bb386ae-e66d-4e7b-84fb-cddcf60002de",
"readonly": false,
"version": 3,
"id": "8fcd353b-0a40-40f2-9a55-ef8137d48800",
"platform_owned": true
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Delete Infrastructures Location (DELETE /locations/{location_id})
Deletes an infrastructure location by ID.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `version` | (Required) Growing number of object internal version.
**Type**: Integer |
#### Responses
##### `204` — Infrastructure location was successfully removed.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_6`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "conflict",
"details": {
"info": "Conflict"
},
"message": "Conflict"
}
}
```
### Update Infrastructures Location (PUT /locations/{location_id})
Updates an infrastructure location by ID.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `name` — Human-readable name of infrastructure location that will be displayed to the users.
**Type**: String
- `version` — Auto-incremented infrastructure location version.
**Type**: Integer
**Example**:
```json
{
"name": "Boston Infrastructure",
"version": 10
}
```
#### Responses
##### `200` — Infrastructure location was successfully updated.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `owner_tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `platform_owned` — Is infra location owned by Platform.
**Type**: Boolean
- `name` — Human-readable name of infrastructure location that will be displayed to the users.
**Type**: String
- `version` — Auto-incremented infrastructure location version.
**Type**: Integer
- `readonly` — True if location details are accessible in a limited way, e.g. location is owned by some ancestor.
**Type**: Boolean
**Example**:
```json
{
"name": "Boston Infrastructure",
"owner_tenant_id": "0bb386ae-e66d-4e7b-84fb-cddcf60002de",
"readonly": false,
"version": 3,
"id": "8fcd353b-0a40-40f2-9a55-ef8137d48800",
"platform_owned": true
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_6`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "conflict",
"details": {
"info": "Conflict"
},
"message": "Conflict"
}
}
```
### Fetch Infrastructures Location (GET /locations/{location_id})
Fetches an infrastructure location by ID.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
* `urn:acronis.com::account-server::readonly_admin`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `owner_tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `platform_owned` — Is infra location owned by Platform.
**Type**: Boolean
- `name` — Human-readable name of infrastructure location that will be displayed to the users.
**Type**: String
- `version` — Auto-incremented infrastructure location version.
**Type**: Integer
- `readonly` — True if location details are accessible in a limited way, e.g. location is owned by some ancestor.
**Type**: Boolean
**Example**:
```json
{
"name": "Boston Infrastructure",
"owner_tenant_id": "0bb386ae-e66d-4e7b-84fb-cddcf60002de",
"readonly": false,
"version": 3,
"id": "8fcd353b-0a40-40f2-9a55-ef8137d48800",
"platform_owned": true
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Fetch Location Infrastructures (GET /locations/{location_id}/infra)
Fetches batch of infrastructure components of the provided location.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
* `urn:acronis.com::account-server::readonly_admin`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `infras` — **Type**: Array of String
**Array type description:**
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
**Example**:
```json
{
"infras": [
"d9fd4cc3-4309-40a2-bd79-88da24a1c99d",
"7068976a-22c0-476e-ae3b-5f0469981ff1"
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Create Registration Token (POST /registration_tokens)
*DEPRECATED.* Use /api/2/tenants//registration_tokens.
Creates a registration token.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::oauth2_client_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `expires_in` — Token expiration time in seconds. Should be less than or equal to one year.
**Type**: Integer
- `scopes` — Access scopes that are applied to the registered resource. The following access scope patterns are available:
- `urn:acronis.com:tenant-id:{personal_tenant_id}:backup_agent_admin` - binds the resource to the user by personal tenant ID specified in `{personal_tenant_id}`.
- `urn:acronis.com::policy_management:{tenant_id}|{policy_id}:apply_revoke` - applies a protection plan to a resource by policy ID specified in `{policy_id}` from a resource owner tenant specified in `{tenant_id}`.
**Type**: Array of String
**Array type description:**
**Type**: String
**Example**:
```json
{
"tenant_id": "72acaf6a-b15a-11e6-80f5-76304dec7eb7",
"expires_in": 3600,
"scopes": [
"urn:acronis.com:tenant-id:734fe814-748a-41cb-8a94-60e18fb3c442:backup_agent_admin"
]
}
```
#### Responses
##### `201` — Registration token was successfully created.
**Media type**: `application/json`
- `id` — Initial registration token unique identifier.
**Type**: Integer
- `token` — Initial registration token.
**Type**: String
**Pattern**: `[A-Z0-9]{4}-[A-Z0-9]{4}-[A-Z0-9]{4}`
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `expires_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `tenant_id` — Numeric identifier of the resource owner tenant.
**Type**: String
**Pattern**: `\d+`
- `tenant_uuid` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `scopes` — Access scopes that are applied to the registered resource. The following access scope patterns are available:
- `urn:acronis.com:tenant-id:{personal_tenant_id}:backup_agent_admin` - binds the resource to the user by personal tenant ID specified in `{personal_tenant_id}`.
- `urn:acronis.com::policy_management:{tenant_id}|{policy_id}:apply_revoke` - applies a protection plan to a resource by policy ID specified in `{policy_id}` from a resource owner tenant specified in `{tenant_id}`.
**Type**: Array of String
**Array type description:**
**Type**: String
**Example**:
```json
{
"tenant_uuid": "4b07e4a1-a49b-4d4e-b8f2-253f1fef98ad",
"tenant_id": "11",
"scopes": [
"urn:acronis.com:tenant-id:734fe814-748a-41cb-8a94-60e18fb3c442:backup_agent_admin",
"urn:acronis.com::policy_management:4b07e4a1-a49b-4d4e-b8f2-253f1fef98ad|10858a46-db9b-4725-aa60-fff6252841fd:apply_revoke"
],
"id": 2,
"expires_at": "2022-04-05T18:46:45Z",
"token": "27F9-5234-41C3",
"created_at": "2022-04-02T18:46:45Z"
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Create Report (POST /reports)
Creates a new usage report.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `recipients` — IDs of subscribed users.
**Type**: Array of String
**Array type description:**
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `result_action` — What to do with report.
**Type**: String
**Allowed values**:
- `save`
- `send`
- `parameters` — **Type**: Object
- `schedule` — **Type**: Object
- `generation_date` — Formatted date: YYYY-MM-DD.
**Type**: String
**Min length**: 10
**Max length**: 10
**Pattern**: `\d{4}-\d{2}-\d{2}`
**Example**:
```json
{
"result_action": "send",
"recipients": [
"ca451758-b48a-45d9-9ae6-8f1059f67619",
"ab00e527-219b-481b-b01b-311b5be0ed3c"
],
"schedule": {
"type": "once"
},
"generation_date": "2017-05-08",
"parameters": {
"tenant_id": "2a91a14d-ffd3-4ac1-9b4d-3990162c5acc",
"formats": [
"csv",
"json_v1",
"csv_v2_0",
"json_v2_0"
],
"show_skus": false,
"hide_zero_usage": true,
"kind": "usage_summary",
"period": {
"start": "2017-05-01",
"end": "2017-05-07"
},
"level": "accounts"
}
}
```
#### Responses
##### `200` — Usage report was successfully created
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `result_action` — What to do with report.
**Type**: String
**Allowed values**:
- `save`
- `send`
- `recipients` — IDs of subscribed users.
**Type**: Array of String
**Array type description:**
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `parameters` — **Type**: Object
- `schedule` — **Type**: Object
- `generation_date` — Formatted date: YYYY-MM-DD.
**Type**: String
**Min length**: 10
**Max length**: 10
**Pattern**: `\d{4}-\d{2}-\d{2}`
**Example**:
```json
{
"result_action": "send",
"recipients": [
"ca451758-b48a-45d9-9ae6-8f1059f67619",
"ab00e527-219b-481b-b01b-311b5be0ed3c"
],
"version": 2,
"id": "20dffb36-d77b-45c6-b2fa-39276e98d5fc",
"schedule": {
"type": "once",
"enabled": true
},
"generation_date": "2017-05-08",
"parameters": {
"tenant_id": "2a91a14d-ffd3-4ac1-9b4d-3990162c5acc",
"formats": [
"csv"
],
"show_skus": false,
"hide_zero_usage": true,
"kind": "usage_summary",
"period": {
"start": "2017-05-01",
"end": "2017-05-07"
},
"level": "accounts"
}
}
```
##### `400` — Usage history is not ready and shouldn't be ready yet (from 1 to 6 am).
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_7`*:
```json
{
"error": {
"domain": "PlatformReportingService",
"context": {},
"code": 400,
"details": {
"info": "History aggregation is in progress for specified date interval",
"addition": []
},
"message": "Bad Request"
}
}
```
##### `500` — Usage history is not ready but should be available already (after 6 am).
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_8`*:
```json
{
"error": {
"domain": "PlatformReportingService",
"context": {},
"code": 500,
"details": {
"info": "History aggregation was not finished in time",
"addition": []
},
"message": "Internal Server Error"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Delete Report (DELETE /reports/{report_id})
Deletes a usage report by ID.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `version` | (Required) Growing number of object internal version.
**Type**: Integer |
#### Responses
##### `204` — Usage report was successfully deleted.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
### Update Report (PUT /reports/{report_id})
Updates a usage report configuration. Only scheduled reports can be updated.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `recipients` — IDs of subscribed users.
**Type**: Array of String
**Array type description:**
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `parameters` — **Type**: Object
- `schedule` — **Type**: Object
**Example**:
```json
{
"recipients": [
"ca451758-b48a-45d9-9ae6-8f1059f67619"
],
"parameters": {
"tenant_id": "2a91a14d-ffd3-4ac1-9b4d-3990162c5acc",
"show_skus": false,
"hide_zero_usage": true,
"kind": "usage_current",
"level": "direct_partners"
}
}
```
#### Responses
##### `200` — Usage report was successfully updated.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `result_action` — What to do with report.
**Type**: String
**Allowed values**:
- `save`
- `send`
- `recipients` — IDs of subscribed users.
**Type**: Array of String
**Array type description:**
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `parameters` — **Type**: Object
- `schedule` — **Type**: Object
- `generation_date` — Formatted date: YYYY-MM-DD.
**Type**: String
**Min length**: 10
**Max length**: 10
**Pattern**: `\d{4}-\d{2}-\d{2}`
**Example**:
```json
{
"result_action": "send",
"recipients": [
"ca451758-b48a-45d9-9ae6-8f1059f67619",
"ab00e527-219b-481b-b01b-311b5be0ed3c"
],
"version": 2,
"id": "20dffb36-d77b-45c6-b2fa-39276e98d5fc",
"schedule": {
"type": "once",
"enabled": true
},
"generation_date": "2017-05-08",
"parameters": {
"tenant_id": "2a91a14d-ffd3-4ac1-9b4d-3990162c5acc",
"formats": [
"csv"
],
"show_skus": false,
"hide_zero_usage": true,
"kind": "usage_summary",
"period": {
"start": "2017-05-01",
"end": "2017-05-07"
},
"level": "accounts"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Fetch Report (GET /reports/{report_id})
Fetches a usage report configuration.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
* `urn:acronis.com::account-server::readonly_admin`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `result_action` — What to do with report.
**Type**: String
**Allowed values**:
- `save`
- `send`
- `recipients` — IDs of subscribed users.
**Type**: Array of String
**Array type description:**
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `parameters` — **Type**: Object
- `schedule` — **Type**: Object
- `generation_date` — Formatted date: YYYY-MM-DD.
**Type**: String
**Min length**: 10
**Max length**: 10
**Pattern**: `\d{4}-\d{2}-\d{2}`
**Example**:
```json
{
"result_action": "send",
"recipients": [
"ca451758-b48a-45d9-9ae6-8f1059f67619",
"ab00e527-219b-481b-b01b-311b5be0ed3c"
],
"version": 2,
"id": "20dffb36-d77b-45c6-b2fa-39276e98d5fc",
"schedule": {
"type": "once",
"enabled": true
},
"generation_date": "2017-05-08",
"parameters": {
"tenant_id": "2a91a14d-ffd3-4ac1-9b4d-3990162c5acc",
"formats": [
"csv"
],
"show_skus": false,
"hide_zero_usage": true,
"kind": "usage_summary",
"period": {
"start": "2017-05-01",
"end": "2017-05-07"
},
"level": "accounts"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Fetch Stored Reports (GET /reports/{report_id}/stored)
Fetches all stored reports related to the usage report.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
* `urn:acronis.com::account-server::readonly_admin`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"size": 128,
"id": "d6bc3e2e-2378-4099-bb33-6a2603aca94d",
"status": "saved",
"created_at": "2017-01-01T12:07:53",
"report_format": "json_v1"
},
{
"size": 128,
"id": "db3acd0d-272e-4860-beca-fb2c2c4edd3e",
"status": "saved",
"created_at": "2017-01-01T12:07:53",
"report_format": "json_v1"
},
{
"size": 128,
"id": "e3f50d66-896c-4699-970f-0a8706fa5920",
"status": "saved",
"created_at": "2017-01-01T12:07:53",
"report_format": "json_v1"
}
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
### Download Stored Report (GET /reports/{report_id}/stored/{stored_report_id})
Downloads stored report data.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
* `urn:acronis.com::account-server::readonly_admin`
#### Request parameters
#### Responses
##### `200` — A file in the format that was used to generate the stored report.
**Media type**: `application/octet-stream`
- `schema` — **Type**: any
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
### Search (GET /search)
Searches for tenants and users.
Tenants are searched by `name`, `custom_id`, `first_name`, `last_name` and `email` from contact info.
Users are searched by `login`, `email`, `first_name` and `last_name`.
Search is case-insensitive.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `tenant` | (Required) An ID of the tenant where the search will be performed.
**Type**: String |
| `text` | (Required) Search in all available properties for the supplied text.
**Type**: String |
| `limit` | (Optional) Limit the number of found objects.
**Type**: Integer
**Default**: 10 |
| `allow_deleted` | (Optional) If true, deleted tenants and users may be returned.
**Type**: Boolean |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"first_name": null,
"name": "Example group",
"path": [
"my tenant",
"some child"
],
"parent_id": "bfe40b45-7d3f-4183-a655-afa62b59b383",
"id": "bfe40b45-7d3f-4183-a655-afa62b59b383",
"last_name": null,
"kind": "customer",
"obj_type": "tenant",
"deleted_at": null
},
{
"first_name": "Example",
"path": [
"my tenant",
"some child",
"Example group"
],
"parent_id": "1c234e69-5469-424a-a6d1-ff5658b387a6",
"id": "1c234e69-5469-424a-a6d1-ff5658b387a6",
"last_name": "Admin",
"login": "admin@example.com",
"obj_type": "user",
"deleted_at": "2022-08-10T00:00:00Z"
}
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Fetch Tenants Batch (GET /tenants)
Available in cloud version only.
Fetches details about multiple tenants specified by their UUIDs or about child tenants of a specific tenant specified by its UUID.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `uuids` | (Optional) A filter by comma-separated list of tenants' UUIDs. Maximum of 100 UUIDs.
Is mutually exclusive with `subtree_root_id` and `parent_id`.
**Type**: String
**Min length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}(,[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12})*` |
| `parent_id` | (Optional) The UUID of a tenant which child tenants will be fetched.
Is mutually exclusive with `subtree_root_id` and `uuids`.
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}` |
| `subtree_root_id` | (Optional) Filter to fetch tenants hierarchy starting from (including) the specified one. Sorting by tenant level is always assumed.
Is mutually exclusive with `uuids` and `parent_id`.
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}` |
| `updated_since` | (Optional) A filter by tenants that were updated after the specified RFC3339 timestamp in UTC time zone.
**Type**: DateTime |
| `limit` | (Optional) Number of elements to return in current offering items page of the response.
**Type**: Integer
**Minimum**: 1
**Default**: 5000 |
| `after` | (Optional) Cursor to fetch the next tenants page. The cursor encodes all the filtering and sorting arguments, thus client does not need to provide all them for the next page, only cursor should be provided. Client can get the cursor from `paging.cursors.after` field of the previous page response.
**Type**: String |
| `lod` | (Optional) A predefined level of details for the tenant object to return.
The following levels of details can be specified:
- `stamps` - includes `id`, `parent_id`, `version`, `created_at`, `updated_at`, `deleted_at`, `contacts`, `offering_items`.
- `basic` - includes all stamps fields plus `name`, `kind`, `enabled`.
- `full` - includes all basic fields plus `customer_type`, `customer_id`, `brand_id`, `brand_uuid`, `brand_enabled`, `barrier`, `internal_tag`, `language`, `owner_id`, `has_children`, `default_idp_id`, `update_lock`, `ancestral_access`, `mfa_status`, `pricing_mode`, `contact`, `external_operation_status`, `production_start_date`.
**Type**: String
**Allowed values**:
- `stamps`
- `basic`
- `full`
**Default**: full |
| `with_contacts` | (Optional) If true, all tenants' referencing contacts will be returned in the response.
**Type**: Boolean |
| `with_offering_items` | (Optional) If true, only tenants with count offering items will be returned in the response.
**Type**: Boolean |
| `with_infra_offering_items` | (Optional) If true, only tenants with infra offering items will be returned in the response.
**Type**: Boolean |
| `expand_offering_items` | (Optional) If true, all tenants' offering items will be returned in the response.
**Type**: Boolean |
| `include_relative_path` | (Optional) If true, fetches the hierarchy of tenants starting from (and including) the trustee tenant up to the tenants with the specified UUIDs. Only tenants in the path between the trustee and the target tenants will be returned.
Is mutually exclusive with `subtree_root_id` and `parent_id`.
**Type**: Boolean |
| `allow_deleted` | (Optional) If true, deleted tenants may be returned.
**Type**: Boolean |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `paging` — **Type**: Object
- `timestamp` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `items` — Array of tenant objects. The fields returned depend on the `lod` query parameter.
**Type**: Array of any
**Array type description:**
**Type**: any
**Examples**:
*`default`*:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"internal_tag": null,
"name": "The Qwerty Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"barrier": 0,
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "enabled",
"brand_id": 1,
"pricing_mode": "trial",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"fax": "123 Example Street",
"language": "en",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [],
"ancestral_access": true,
"version": 2,
"brand_enabled": true,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"language": "en",
"customer_type": "enterprise",
"default_idp_id": "e6f73a28-ff2e-4728-8f78-49eb74b20fce",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": false,
"owner_id": null
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"offering_items": [],
"production_start_date": null
},
{
"internal_tag": null,
"name": "The Another Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"barrier": 0,
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "disabled",
"brand_id": 1,
"pricing_mode": "production",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117bec",
"fax": "123 Example Street",
"language": "en",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal",
"technical"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [],
"ancestral_access": true,
"version": 2,
"brand_enabled": false,
"id": "5d92a310-0ee7-11e7-95e6-5f64824358de",
"language": "en",
"external_operation_status": "recovering",
"customer_type": "enterprise",
"default_idp_id": "e6f73a28-ff2e-4728-8f78-49eb74b20fce",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": false,
"owner_id": null
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"offering_items": [],
"production_start_date": null
}
]
}
```
*`lodStamps`*:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"contacts": [],
"version": 2,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"created_at": "2016-06-22T18:25:16",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"offering_items": []
},
{
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"contacts": [],
"version": 2,
"id": "5d92a310-0ee7-11e7-95e6-5f64824358de",
"created_at": "2016-06-22T18:25:16",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"offering_items": []
}
]
}
```
*`lodBasic`*:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"name": "The Dummy Tenant",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"enabled": true,
"contacts": [],
"version": 2,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"offering_items": []
},
{
"name": "The Another Tenant",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"enabled": true,
"contacts": [],
"version": 2,
"id": "5d92a310-0ee7-11e7-95e6-5f64824358de",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"offering_items": []
}
]
}
```
*`withContacts`*:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"internal_tag": null,
"name": "The Qwerty Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"barrier": 0,
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "enabled",
"brand_id": 1,
"pricing_mode": "trial",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"fax": "123 Example Street",
"language": "en",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:01",
"title": "",
"updated_at": "2020-05-19T11:50:01",
"types": [
"legal"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [
{
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"aan": "",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"user_id": null,
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"fax": "123 Example Street",
"language": "en",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:01",
"title": "",
"updated_at": "2020-05-19T11:50:01",
"types": [
"legal"
],
"email_confirmed": false,
"phone": "123456789"
},
{
"website": "www.mysite.com",
"city": "Rivertown",
"zipcode": "12345",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"aan": "",
"email": "primary@mysite.com",
"state": "CA",
"firstname": "Company",
"industry": "IT",
"country": "USA",
"address2": "",
"user_id": "1bfe361d-fcb8-43ff-8f43-9ecc29a08ea5",
"lastname": "Primary",
"organization_size": "50-100",
"id": "d8f70f4a-976a-4d66-a651-10d2b3d6e9dd",
"fax": "123 Example Street",
"language": "en",
"address1": "1440 River Drive #101",
"created_at": "2020-05-19T11:50:02",
"title": "Mr.",
"updated_at": "2020-05-19T11:50:02",
"types": [
"primary"
],
"email_confirmed": true,
"phone": "123456789"
}
],
"ancestral_access": true,
"version": 2,
"brand_enabled": true,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"language": "en",
"customer_type": "enterprise",
"default_idp_id": "e6f73a28-ff2e-4728-8f78-49eb74b20fce",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": false,
"owner_id": null
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"offering_items": [],
"production_start_date": null
},
{
"internal_tag": null,
"name": "The Another Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"barrier": 0,
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "disabled",
"brand_id": 1,
"pricing_mode": "production",
"contact": {
"website": "",
"city": "Tacoma",
"zipcode": "11111",
"aan": "",
"email": "me@mysite.com",
"state": "WA",
"firstname": "Kevin",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117bec",
"fax": "123 Example Street",
"language": "en",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal",
"technical"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [
{
"website": "",
"city": "Tacoma",
"zipcode": "11111",
"tenant_id": "5d92a310-0ee7-11e7-95e6-5f64824358de",
"aan": "",
"email": "me@mysite.com",
"state": "WE",
"firstname": "Kevin",
"industry": "",
"country": "USA",
"address2": "",
"user_id": null,
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117bec",
"fax": "123 Example Street",
"language": "en",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal",
"technical"
],
"email_confirmed": false,
"phone": "123456789"
}
],
"ancestral_access": true,
"version": 2,
"brand_enabled": false,
"id": "5d92a310-0ee7-11e7-95e6-5f64824358de",
"language": "en",
"customer_type": "enterprise",
"default_idp_id": "e6f73a28-ff2e-4728-8f78-49eb74b20fce",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": false,
"owner_id": null
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"offering_items": [],
"production_start_date": null
}
]
}
```
*`withOfferingItems`*:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"internal_tag": null,
"name": "The Qwerty Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"barrier": 0,
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "enabled",
"brand_id": 1,
"pricing_mode": "trial",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"external_id": "",
"created_at": "2020-05-19T11:50:01",
"title": "",
"updated_at": "2020-05-19T11:50:01",
"types": [
"legal"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [],
"ancestral_access": true,
"version": 2,
"brand_enabled": true,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"language": "en",
"customer_type": "enterprise",
"default_idp_id": "e6f73a28-ff2e-4728-8f78-49eb74b20fce",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": false,
"owner_id": null
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"offering_items": [
{
"name": "vms",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
},
"measurement_unit": "quantity",
"locked": true,
"edition": "standard",
"usage_name": "vms",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "dre_mobiles",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
},
"measurement_unit": "quantity",
"locked": false,
"edition": "disaster_recovery",
"usage_name": "mobiles",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "local_storage",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"measurement_unit": "n/a",
"edition": null,
"usage_name": "local_storage",
"status": 1,
"type": "feature",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "adv_storage",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 1000,
"overage": null,
"version": 1486479690324
},
"measurement_unit": "bytes",
"locked": true,
"edition": "advanced",
"usage_name": "storage",
"status": 1,
"infra_id": "ee978065-8caa-463d-82d7-47006376e7f2",
"type": "infra",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
}
],
"production_start_date": "2016-06-22T18:25:16"
},
{
"internal_tag": null,
"name": "The Another Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"barrier": 0,
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "disabled",
"brand_id": 1,
"pricing_mode": "production",
"contact": {
"website": "",
"city": "Tacoma",
"zipcode": "11111",
"email": "me@mysite.com",
"state": "WA",
"firstname": "Kevin",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117bec",
"address1": "1440 River Drive #100",
"external_id": "",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal",
"technical"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [],
"ancestral_access": true,
"version": 2,
"brand_enabled": false,
"id": "5d92a310-0ee7-11e7-95e6-5f64824358de",
"language": "en",
"customer_type": "enterprise",
"default_idp_id": "e6f73a28-ff2e-4728-8f78-49eb74b20fce",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": false,
"owner_id": null
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"offering_items": [
{
"name": "vms",
"tenant_id": "5d92a310-0ee7-11e7-95e6-5f64824358de",
"quota": {
"value": 5,
"overage": 5,
"version": 1087473394411
},
"measurement_unit": "quantity",
"locked": true,
"edition": "standard",
"usage_name": "vms",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
}
],
"production_start_date": null
}
]
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "Request body contains badly-formed JSON."
},
"message": "bad request"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Create Tenant (POST /tenants)
Creates a new tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `name` — Human-readable name that will be displayed to the users.
**Type**: String
- `parent_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `contact` — **Type**: Object
- `company_billing_contact` — **Type**: Object
- `enabled` — Flag, indicates whether the tenant is enabled or disabled.
**Type**: Boolean
- `customer_id` — ID from external system; for reporting purposes.
**Type**: String
- `internal_tag` — Internal tag. This field can have a null value.
**Type**: any
- `language` — Preferred locale.
**Type**: String
- `default_idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `update_lock` — **Type**: Object
- `ancestral_access` — Access to newly created tenant from ancestors.
**Type**: Boolean
- `settings` — **Type**: Object
**Example**:
```json
{
"internal_tag": null,
"name": "The Qwerty Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"contact": {
"email": "su@test.com",
"address1": "Home",
"phone": "123456789"
},
"language": "pt_BR",
"kind": "partner",
"settings": {
"enhanced_security": false
}
}
```
#### Responses
##### `201` — Tenant was successfully created.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `updated_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `deleted_at` — Soft deletion timestamp.
**Type**: any
- `production_start_date` — Tenant trial expiration date.
**Type**: any
- `name` — Human-readable name that will be displayed to the users.
**Type**: String
- `customer_type` — A type of the customer.
**Type**: String
**Allowed values**:
- `default`
- `enterprise`
- `consumer`
- `small_office`
- `ti_unified`
- `parent_id` — ID of parent tenant. For the real root tenant the parent_id is equal to its id
**Type**: String
- `kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `contact` — **Type**: Object
- `contacts` — Empty array by default. Will be populated with all referencing contacts if query param `with_contacts` is provided.
**Type**: Array of Object
**Array type description:**
**Type**: Object
**Min items**: 0
- `enabled` — Flag, indicates whether the tenant is enabled or disabled.
**Type**: Boolean
- `customer_id` — ID from external system; for reporting purposes. This field can have a null value.
**Type**: any
- `brand_id` — Brand id for API v1.
**Type**: any
- `brand_uuid` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `brand_enabled` — Flag, indicates whether the branding is enabled or disabled on tenant.
**Type**: Boolean
- `internal_tag` — Internal tag. This field can have a null value.
**Type**: any
- `language` — Tenant`s preferred language.
**Type**: String
- `owner_id` — Identifier of personal tenant owner user. This field can have a null value.
**Type**: any
- `has_children` — Flag, indicates if tenant has children.
**Type**: Boolean
- `default_idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `update_lock` — **Type**: Object
- `ancestral_access` — Indicates whether tenant's indirect ancestors have access to it.
**Type**: Boolean
- `mfa_status` — Multi-factor authentication status of the tenant.
**Type**: String
**Allowed values**:
- `disabled`
- `forcibly_disabled`
- `setup_required`
- `enabled`
- `pricing_mode` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `external_operation_status` — Indicates if some external operation in progress for this tenant.
**Type**: any
**Example**:
```json
{
"internal_tag": null,
"name": "The Qwerty Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "enabled",
"brand_id": 1,
"pricing_mode": "production",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [],
"ancestral_access": true,
"version": 2,
"brand_enabled": true,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"language": "en",
"customer_type": "enterprise",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": true,
"owner_id": "7decff12-ee1b-4f8d-b446-59610bfb9203"
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"production_start_date": null
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Fetch Tenants Applications Batch (GET /tenants/applications)
Fetches a batch of applications' UUIDs for the provided list of tenants.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `tenants` | (Required) A filter of applications by comma-separated list of tenants' UUIDs.
**Type**: String
**Min length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}(,[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12})*` |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"tenant": "2b5172d7-4374-40db-8e11-08decbc53878",
"applications": [
"8aaf366b-fe24-4f25-93b3-bd729c86cc95",
"aedde3dc-5954-448a-820a-0220cf32ecb1"
]
},
{
"tenant": "aedde3dc-5954-448a-820a-0220cf32ecb1",
"applications": [
"aedde3dc-5954-448a-820a-0220cf32ecb1"
]
}
]
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Fetch Tenant Offering Items Batch (GET /tenants/offering_items)
Fetches a batch of the offering items with their states and associated quotas.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `subtree_root_tenant_id` | (Required) A filter by tenants tree starting from the specified tenant ID. Sorting by tenant level is always assumed.
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}` |
| `usage_names` | (Optional) A filter of offering items by comma-separated list of usage names.
**Type**: String |
| `editions` | (Optional) A filter of offering items by comma-separated list of editions.
**Type**: String |
| `offering_items` | (Optional) A filter of offering items by comma-separated offering item names.
**Type**: String |
| `updated_since` | (Optional) A filter by offering items that were updated after the specified RFC3339 timestamp in UTC time zone.
**Type**: DateTime |
| `limit` | (Optional) Number of elements to return in current offering items page of the response.
**Type**: Integer
**Minimum**: 1
**Default**: 5000 |
| `after` | (Optional) Cursor to fetch the next offering items page. The cursor encodes all the filtering and sorting arguments, thus client does not need to provide all them for the next page, only cursor should be provided. Client can get the cursor from `paging.cursors.after` field of the previous page response.
**Type**: String |
| `allow_deleted` | (Optional) If true, deleted offering items may be returned.
**Type**: Boolean |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `paging` — **Type**: Object
- `timestamp` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"name": "vms",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
},
"measurement_unit": "quantity",
"locked": true,
"edition": "standard",
"usage_name": "vms",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "dre_mobiles",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
},
"measurement_unit": "quantity",
"locked": false,
"edition": "disaster_recovery",
"usage_name": "mobiles",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "local_storage",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"measurement_unit": "n/a",
"edition": null,
"usage_name": "local_storage",
"status": 1,
"type": "feature",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "adv_storage",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 1000,
"overage": null,
"version": 1486479690324
},
"measurement_unit": "bytes",
"locked": true,
"edition": "advanced",
"usage_name": "storage",
"status": 1,
"infra_id": "ee978065-8caa-463d-82d7-47006376e7f2",
"type": "infra",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
}
]
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Fetch Tenants Usages Batch (GET /tenants/usages)
Fetches a batch of usages of the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `tenants` | (Required) A filter of usages by comma-separated list of tenants' UUIDs.
**Type**: String
**Min length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}(,[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12})*` |
| `usage_names` | (Optional) A filter of usages by comma-separated list of usage names.
**Type**: String |
| `editions` | (Optional) A filter of usages by comma-separated list of editions.
**Type**: String |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"tenant": "2b5172d7-4374-40db-8e11-08decbc53878",
"usages": [
{
"name": "vms",
"measurement_unit": "quantity",
"range_start": "2017-06-01T00:00:00",
"edition": "standard",
"usage_name": "vms",
"absolute_value": 800,
"offering_item": {
"status": 1,
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
}
},
"type": "count",
"value": 800,
"application_id": "c6ab7fb4-b461-4214-9257-86fbad8efb85"
},
{
"name": "vm_storage",
"measurement_unit": "bytes",
"range_start": "2017-06-01T00:00:00",
"edition": "mixed",
"usage_name": "vm_storage",
"absolute_value": 100000,
"type": "infra",
"value": 100000,
"application_id": "c6ab7fb4-b461-4214-9257-86fbad8efb85"
}
]
},
{
"tenant": "aedde3dc-5954-448a-820a-0220cf32ecb1",
"usages": [
{
"name": "adv_vms",
"measurement_unit": "quantity",
"range_start": "2017-06-01T00:00:00",
"edition": "advanced",
"usage_name": "vms",
"absolute_value": 500,
"offering_item": {
"status": 1,
"quota": {
"value": 11,
"overage": 12,
"version": 1486479690324
}
},
"type": "count",
"value": 500,
"application_id": "c6ab7fb4-b461-4214-9257-86fbad8efb85"
},
{
"name": "vm_storage",
"measurement_unit": "bytes",
"range_start": "2017-06-01T00:00:00",
"edition": "mixed",
"usage_name": "vm_storage",
"absolute_value": 110000,
"type": "infra",
"value": 110000,
"application_id": "c6ab7fb4-b461-4214-9257-86fbad8efb85"
}
]
}
]
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Update Tenants Usages (PUT /tenants/usages)
Updates the values of the usages specified in `usage_type` or
associated with the offering items specified in `offering_item`.
Depending on the combination of provided fields, the usage may be
reported either per tenant or per resource. See the descriptions of
the fields for more details.
Trustee is restricted either to be registered within root tenant kind or to have configured
CyberApp (origin_id) with fully provisioned auth-consents through Application Manager
Account server applications (not to be confused with CyberApps) are restricted
to the enablement of offering items with nested usage types marked with the acc-app (origin_id)
In case of failure the response body will contain a not-empty "error" field for each failed item.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::accounts::licensing_admin`
* `urn:acronis.com::accounts::usage_reporter`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"tenant_id": "",
"resource_id": "",
"usage_type": "",
"offering_item": "",
"infra_id": "",
"usage_value": 0
}
]
}
```
#### Responses
##### `200`
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"tenant_id": "",
"resource_id": "",
"usage_type": "",
"offering_item": "",
"infra_id": "",
"error": {
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
}
]
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Delete Tenant (DELETE /tenants/{tenant_id})
Deletes a tenant by ID.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `version` | (Required) Growing number of object internal version.
**Type**: Integer |
#### Responses
##### `204` — Tenant was successfully deleted.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Update Tenant (PUT /tenants/{tenant_id})
Updates a tenant by ID.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `name` — Human-readable name that will be displayed to the users.
**Type**: String
- `customer_type` — A type of the customer.
**Type**: String
**Allowed values**:
- `default`
- `enterprise`
- `consumer`
- `small_office`
- `ti_unified`
- `parent_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `contact` — **Type**: Object
- `enabled` — Flag, indicates whether the tenant is enabled or disabled.
**Type**: Boolean
- `customer_id` — ID from external system; for reporting purposes. This field can have a null value.
**Type**: any
- `version` — Tenant`s version.
**Type**: Integer
- `brand_id` — Deprecated field. Brand cannot be changed using this.
**Type**: any
- `internal_tag` — Internal tag. This field can have a null value.
**Type**: any
- `language` — Tenant`s preferred language.
**Type**: String
- `default_idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `update_lock` — **Type**: Object
- `ancestral_access` — Indicates whether tenant's indirect ancestors have access to it.
**Type**: Boolean
- `external_operation_status` — External operation status.
**Type**: String
**Allowed values**:
- `no_operation`
- `deleting`
- `recovering`
**Example**:
```json
{
"internal_tag": null,
"name": "Renamed Tenant",
"customer_id": null,
"parent_id": "c4878582-6e14-451e-9bda-3ff899b3f700",
"brand_id": 1111,
"contact": {
"firstname": "New Name"
},
"version": 1,
"language": "en",
"kind": "folder"
}
```
#### Responses
##### `200` — Tenant was successfully updated.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `updated_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `deleted_at` — Soft deletion timestamp.
**Type**: any
- `production_start_date` — Tenant trial expiration date.
**Type**: any
- `name` — Human-readable name that will be displayed to the users.
**Type**: String
- `customer_type` — A type of the customer.
**Type**: String
**Allowed values**:
- `default`
- `enterprise`
- `consumer`
- `small_office`
- `ti_unified`
- `parent_id` — ID of parent tenant. For the real root tenant the parent_id is equal to its id
**Type**: String
- `kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `contact` — **Type**: Object
- `contacts` — Empty array by default. Will be populated with all referencing contacts if query param `with_contacts` is provided.
**Type**: Array of Object
**Array type description:**
**Type**: Object
**Min items**: 0
- `enabled` — Flag, indicates whether the tenant is enabled or disabled.
**Type**: Boolean
- `customer_id` — ID from external system; for reporting purposes. This field can have a null value.
**Type**: any
- `brand_id` — Brand id for API v1.
**Type**: any
- `brand_uuid` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `brand_enabled` — Flag, indicates whether the branding is enabled or disabled on tenant.
**Type**: Boolean
- `internal_tag` — Internal tag. This field can have a null value.
**Type**: any
- `language` — Tenant`s preferred language.
**Type**: String
- `owner_id` — Identifier of personal tenant owner user. This field can have a null value.
**Type**: any
- `has_children` — Flag, indicates if tenant has children.
**Type**: Boolean
- `default_idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `update_lock` — **Type**: Object
- `ancestral_access` — Indicates whether tenant's indirect ancestors have access to it.
**Type**: Boolean
- `mfa_status` — Multi-factor authentication status of the tenant.
**Type**: String
**Allowed values**:
- `disabled`
- `forcibly_disabled`
- `setup_required`
- `enabled`
- `pricing_mode` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `external_operation_status` — Indicates if some external operation in progress for this tenant.
**Type**: any
**Example**:
```json
{
"internal_tag": null,
"name": "The Qwerty Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "enabled",
"brand_id": 1,
"pricing_mode": "production",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [],
"ancestral_access": true,
"version": 2,
"brand_enabled": true,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"language": "en",
"customer_type": "enterprise",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": true,
"owner_id": "7decff12-ee1b-4f8d-b446-59610bfb9203"
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"production_start_date": null
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_5`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1010,
"details": {
"info": "user with specified login already exists in same tenant"
},
"message": "conflict"
}
}
```
### Fetch Tenant (GET /tenants/{tenant_id})
Fetches a tenant by ID.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `embed_path` | (Optional) If true, tenant path will be embedded in the result.
**Type**: Boolean |
| `allow_deleted` | (Optional) If true, deleted tenant may be returned.
**Type**: Boolean |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `updated_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `deleted_at` — Soft deletion timestamp.
**Type**: any
- `production_start_date` — Tenant trial expiration date.
**Type**: any
- `name` — Human-readable name that will be displayed to the users.
**Type**: String
- `customer_type` — A type of the customer.
**Type**: String
**Allowed values**:
- `default`
- `enterprise`
- `consumer`
- `small_office`
- `ti_unified`
- `parent_id` — ID of parent tenant. For the real root tenant the parent_id is equal to its id
**Type**: String
- `kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `contact` — **Type**: Object
- `contacts` — Empty array by default. Will be populated with all referencing contacts if query param `with_contacts` is provided.
**Type**: Array of Object
**Array type description:**
**Type**: Object
**Min items**: 0
- `enabled` — Flag, indicates whether the tenant is enabled or disabled.
**Type**: Boolean
- `customer_id` — ID from external system; for reporting purposes. This field can have a null value.
**Type**: any
- `brand_id` — Brand id for API v1.
**Type**: any
- `brand_uuid` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `brand_enabled` — Flag, indicates whether the branding is enabled or disabled on tenant.
**Type**: Boolean
- `internal_tag` — Internal tag. This field can have a null value.
**Type**: any
- `language` — Tenant`s preferred language.
**Type**: String
- `owner_id` — Identifier of personal tenant owner user. This field can have a null value.
**Type**: any
- `has_children` — Flag, indicates if tenant has children.
**Type**: Boolean
- `default_idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `update_lock` — **Type**: Object
- `ancestral_access` — Indicates whether tenant's indirect ancestors have access to it.
**Type**: Boolean
- `mfa_status` — Multi-factor authentication status of the tenant.
**Type**: String
**Allowed values**:
- `disabled`
- `forcibly_disabled`
- `setup_required`
- `enabled`
- `pricing_mode` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `external_operation_status` — Indicates if some external operation in progress for this tenant.
**Type**: any
**Example**:
```json
{
"internal_tag": null,
"name": "The Qwerty Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "enabled",
"brand_id": 1,
"pricing_mode": "production",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [],
"ancestral_access": true,
"version": 2,
"brand_enabled": true,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"language": "en",
"customer_type": "enterprise",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": true,
"owner_id": "7decff12-ee1b-4f8d-b446-59610bfb9203"
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"production_start_date": null
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Fetch Tenant Offering Items (GET /tenants/{tenant_id}/offering_items)
Fetches a list offering items with state and associated quotas.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `for_ui` | (Optional) If true, the list of offering items will be returned in a form that is appropriate for the UI. Currently, offering items on a grace period will be filtered out.
**Type**: Boolean |
| `edition` | (Optional) A filter of the offering items by edition.
If "*" is provided, all editions will be returned.
Offering items without an edition are not filtered out in any case.
**Type**: String
**Default**: standard |
| `usage_names` | (Optional) A filter by comma-separated list of usage names.
**Type**: String |
| `available_only` | (Optional) If true, return only infrastructures and offering items available for the enablement according to internal business rules.
**Type**: String |
| `type` | (Optional) A filter by offering item type.
**Type**: String
**Allowed values**:
- `count`
- `feature`
- `infra` |
| `status` | (Optional) A filter by offering item status.
1 - active
0 - not active
**Type**: Integer
**Allowed values**:
- `0`
- `1` |
| `infra_uuid` | (Optional) A filter by infrastructure UUID.
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}` |
| `include_secondary` | (Optional) If true, secondary offering items will be included in the response.
**Type**: Boolean |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `paging` — **Type**: Object
- `timestamp` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"name": "vms",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
},
"measurement_unit": "quantity",
"locked": true,
"edition": "standard",
"usage_name": "vms",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "dre_mobiles",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
},
"measurement_unit": "quantity",
"locked": false,
"edition": "disaster_recovery",
"usage_name": "mobiles",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "local_storage",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"measurement_unit": "n/a",
"edition": null,
"usage_name": "local_storage",
"status": 1,
"type": "feature",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "adv_storage",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 1000,
"overage": null,
"version": 1486479690324
},
"measurement_unit": "bytes",
"locked": true,
"edition": "advanced",
"usage_name": "storage",
"status": 1,
"infra_id": "ee978065-8caa-463d-82d7-47006376e7f2",
"type": "infra",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
}
]
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_5`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1010,
"details": {
"info": "user with specified login already exists in same tenant"
},
"message": "conflict"
}
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "Request body contains badly-formed JSON."
},
"message": "bad request"
}
}
```
##### `426` — Server refuses to fulfill the request using the current protocol
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_8`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1001,
"details": {
"info": "entity version mismatch, probably entity was updated in another session"
},
"message": "upgrade required"
}
}
```
### Set Tenant Offering Items (PUT /tenants/{tenant_id}/offering_items)
Sets the states and quotas of the offering items for specified applications of the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `offering_items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
- `check_usage` — If true, check whether offering items being turned off have no usage.
**Type**: Boolean
**Example**:
```json
{
"offering_items": [
{
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0",
"name": "vms",
"status": 1,
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
}
},
{
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0",
"name": "workstations",
"status": 0
},
{
"name": "storage",
"quota": {
"value": 10000,
"overage": 100000,
"version": 1486479690324
},
"status": 1,
"infra_id": "4a2cbe2d-b7ab-4b17-9cba-10c7eb55de01",
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "fc_storage",
"quota": {
"value": 100000,
"overage": 100000,
"version": 1486479690324
},
"status": 1,
"infra_id": "4fff10c4-1378-4bfc-877d-b66a0f8805ed",
"application_id": "71739a04-177f-4603-84ad-54a326ba76e4"
},
{
"application_id": "71739a04-177f-4603-84ad-54a326ba76e4",
"name": "fc_seats",
"status": 1
}
],
"check_usage": true
}
```
#### Responses
##### `200` — Offering Items states were successfully set.
**Media type**: `application/json`
- `paging` — **Type**: Object
- `timestamp` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"name": "vms",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
},
"measurement_unit": "quantity",
"locked": true,
"edition": "standard",
"usage_name": "vms",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "dre_mobiles",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
},
"measurement_unit": "quantity",
"locked": false,
"edition": "disaster_recovery",
"usage_name": "mobiles",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "local_storage",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"measurement_unit": "n/a",
"edition": null,
"usage_name": "local_storage",
"status": 1,
"type": "feature",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "adv_storage",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 1000,
"overage": null,
"version": 1486479690324
},
"measurement_unit": "bytes",
"locked": true,
"edition": "advanced",
"usage_name": "storage",
"status": 1,
"infra_id": "ee978065-8caa-463d-82d7-47006376e7f2",
"type": "infra",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
}
]
}
```
##### `400` — Offering items states were not successfully set.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_9`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"offering_items": [
{
"name": "adv_vms"
},
{
"name": "adv_storage",
"infra_id": "e45a9efb-deb5-4ffc-ab31-2f3c159f0351"
}
]
},
"code": 1049,
"details": {
"info": "It is not possible to disable the following offering items: adv_vms, adv_storage(infra_id=e45a9efb-deb5-4ffc-ab31-2f3c159f0351). The usages are being updated at the moment and their value might be more than zero.",
"addition": [
{
"offering_items": [
{
"name": "adv_vms"
},
{
"name": "adv_storage",
"infra_id": "e45a9efb-deb5-4ffc-ab31-2f3c159f0351"
}
]
}
]
},
"message": "It is not possible to disable the following offering items: adv_vms, adv_storage(infra_id=e45a9efb-deb5-4ffc-ab31-2f3c159f0351). The usages are being updated at the moment and their value might be more than zero."
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_5`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1010,
"details": {
"info": "user with specified login already exists in same tenant"
},
"message": "conflict"
}
}
```
### Fetch Offering Items Available For Tenant Child (GET /tenants/{tenant_id}/offering_items/available_for_child)
Fetches available offering items for a hypothetical child tenant with provided parameters.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `kind` | (Optional) A kind of hypothetical child tenant for which available offering items will be returned.
**Type**: String |
| `edition` | (Optional) A filter of the offering items by edition.
If "*" is provided, all editions will be returned.
Offering items without an edition are not filtered out in any case.
**Type**: String
**Default**: standard |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `paging` — **Type**: Object
- `timestamp` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"name": "vms",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
},
"measurement_unit": "quantity",
"locked": true,
"edition": "standard",
"usage_name": "vms",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "dre_mobiles",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
},
"measurement_unit": "quantity",
"locked": false,
"edition": "disaster_recovery",
"usage_name": "mobiles",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "local_storage",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"measurement_unit": "n/a",
"edition": null,
"usage_name": "local_storage",
"status": 1,
"type": "feature",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "adv_storage",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 1000,
"overage": null,
"version": 1486479690324
},
"measurement_unit": "bytes",
"locked": true,
"edition": "advanced",
"usage_name": "storage",
"status": 1,
"infra_id": "ee978065-8caa-463d-82d7-47006376e7f2",
"type": "infra",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
}
]
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
### Fetch Tenant Offering Items Prices (GET /tenants/{tenant_id}/offering_items/pricing)
Fetches a list of prices of the offering items for the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"name": "storage",
"price": "0.05",
"version": 1497533157730,
"infra_id": "05348371-d95e-4cab-af2a-8e2cadafc30d",
"application_id": "b037d1f6-25cf-4a9c-98f1-d3e41c100948"
},
{
"application_id": "b037d1f6-25cf-4a9c-98f1-d3e41c100948",
"name": "servers",
"price": "600",
"version": 1497533157730
}
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Update Tenant Offering Items Prices (PUT /tenants/{tenant_id}/offering_items/pricing)
Updates the prices of the offering items for the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"name": "storage",
"price": "0.05",
"version": 1497533157730,
"infra_id": "05348371-d95e-4cab-af2a-8e2cadafc30d",
"application_id": "b037d1f6-25cf-4a9c-98f1-d3e41c100948"
},
{
"application_id": "b037d1f6-25cf-4a9c-98f1-d3e41c100948",
"name": "servers",
"price": "600",
"version": 1497533157730
},
{
"application_id": "b037d1f6-25cf-4a9c-98f1-d3e41c100948",
"name": "vms",
"price": "0",
"version": 1497533157730
}
]
}
```
#### Responses
##### `200` — Prices were successfully updated.
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"name": "storage",
"price": "0.05",
"version": 1497533157730,
"infra_id": "05348371-d95e-4cab-af2a-8e2cadafc30d",
"application_id": "b037d1f6-25cf-4a9c-98f1-d3e41c100948"
},
{
"application_id": "b037d1f6-25cf-4a9c-98f1-d3e41c100948",
"name": "servers",
"price": "600",
"version": 1497533157730
}
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Perform Tenant Edition Switch Check (GET /tenants/{tenant_id}/edition)
Performs edition switching check for the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `target_edition` | (Required) A target edition to switch to.
**Type**: String |
| `application_id` | (Required) Application UUID.
**Type**: String |
#### Responses
##### `200` — Edition switch can be performed.
**Media type**: `application/json`
- `warnings` — Warning codes that should be displayed on edition switch.
**Type**: Array of String
**Array type description:**
**Type**: String
**Example**:
```json
{
"warnings": [
"OldFeaturesBecomeUnavailable",
"NewFeaturesBecomeAvailable",
"SomePlansWillStopWorking",
"AllDevicesWithBackupsPreserved",
"UsageStatisticsWillMigrate",
"AdvCyberProtectBecomeUnavailable"
]
}
```
##### `400` — Edition switch cannot be performed due to unavailable offering items.
List of these offering items will be returned in `error.context`.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_9`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"offering_items": [
{
"name": "adv_vms"
},
{
"name": "adv_storage",
"infra_id": "e45a9efb-deb5-4ffc-ab31-2f3c159f0351"
}
]
},
"code": 1048,
"details": {
"info": "Cannot switch edition. Following offering items cannot be turned on in the target edition: adv_vms, adv_storage(infra_id=e45a9efb-deb5-4ffc-ab31-2f3c159f0351)",
"addition": [
{
"offering_items": [
{
"name": "adv_vms"
},
{
"name": "adv_storage",
"infra_id": "e45a9efb-deb5-4ffc-ab31-2f3c159f0351"
}
]
}
]
},
"message": "Cannot switch edition. Following offering items cannot be turned on in the target edition: adv_vms, adv_storage(infra_id=e45a9efb-deb5-4ffc-ab31-2f3c159f0351)"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Switch Tenant Edition (PUT /tenants/{tenant_id}/edition)
Switches the edition for the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `target_edition` — Target edition to switch to.
**Type**: String
- `application_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
**Example**:
```json
{
"target_edition": "disaster_recovery",
"application_id": "c6ab7fb4-b461-4214-9257-86fbad8efb85"
}
```
#### Responses
##### `200` — Edition was successfully switched.
**Media type**: `application/json`
- `paging` — **Type**: Object
- `timestamp` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"name": "vms",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
},
"measurement_unit": "quantity",
"locked": true,
"edition": "standard",
"usage_name": "vms",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "dre_mobiles",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
},
"measurement_unit": "quantity",
"locked": false,
"edition": "disaster_recovery",
"usage_name": "mobiles",
"status": 1,
"type": "count",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "local_storage",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"measurement_unit": "n/a",
"edition": null,
"usage_name": "local_storage",
"status": 1,
"type": "feature",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
},
{
"name": "adv_storage",
"tenant_id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"quota": {
"value": 1000,
"overage": null,
"version": 1486479690324
},
"measurement_unit": "bytes",
"locked": true,
"edition": "advanced",
"usage_name": "storage",
"status": 1,
"infra_id": "ee978065-8caa-463d-82d7-47006376e7f2",
"type": "infra",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null,
"application_id": "a9fd8016-0e00-4ade-949e-6efe8672dac0"
}
]
}
```
##### `400` — Edition was not switched due to unavailable offering items.
List of these offering items will be returned in `error.context`.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_9`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"offering_items": [
{
"name": "adv_vms"
},
{
"name": "adv_storage",
"infra_id": "e45a9efb-deb5-4ffc-ab31-2f3c159f0351"
}
]
},
"code": 1048,
"details": {
"info": "Cannot switch edition. Following offering items cannot be turned on in the target edition: adv_vms, adv_storage(infra_id=e45a9efb-deb5-4ffc-ab31-2f3c159f0351)",
"addition": [
{
"offering_items": [
{
"name": "adv_vms"
},
{
"name": "adv_storage",
"infra_id": "e45a9efb-deb5-4ffc-ab31-2f3c159f0351"
}
]
}
]
},
"message": "Cannot switch edition. Following offering items cannot be turned on in the target edition: adv_vms, adv_storage(infra_id=e45a9efb-deb5-4ffc-ab31-2f3c159f0351)"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Create Registration Token (POST /tenants/{tenant_id}/registration_tokens)
Creates registration token for the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::oauth2_client_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `expires_in` — Token expiration time in seconds. Should be less than or equal to one year.
**Type**: Integer
- `scopes` — Access scopes that are applied to the registered resource. The following access scope patterns are available:
- `urn:acronis.com:tenant-id:{personal_tenant_id}:backup_agent_admin` - binds the resource to the user by personal tenant ID specified in `{personal_tenant_id}`.
- `urn:acronis.com::policy_management:{tenant_id}|{policy_id}:apply_revoke` - applies a protection plan to a resource by policy ID specified in `{policy_id}` from a resource owner tenant specified in `{tenant_id}`.
**Type**: Array of String
**Array type description:**
**Type**: String
**Example**:
```json
{
"expires_in": 3600,
"scopes": [
"urn:acronis.com:tenant-id:734fe814-748a-41cb-8a94-60e18fb3c442:backup_agent_admin",
"urn:acronis.com::policy_management:20435cc8-0b12-4b57-94c7-33afb28f0f34|10858a46-db9b-4725-aa60-fff6252841fd:apply_revoke"
]
}
```
#### Responses
##### `200` — Registration token was successfully created.
**Media type**: `application/json`
- `id` — Initial registration token unique identifier.
**Type**: Integer
- `token` — Initial registration token.
**Type**: String
**Pattern**: `[A-Z0-9]{4}-[A-Z0-9]{4}-[A-Z0-9]{4}`
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `expires_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `tenant_id` — Numeric identifier of the resource owner tenant.
**Type**: String
**Pattern**: `\d+`
- `tenant_uuid` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `scopes` — Access scopes that are applied to the registered resource. The following access scope patterns are available:
- `urn:acronis.com:tenant-id:{personal_tenant_id}:backup_agent_admin` - binds the resource to the user by personal tenant ID specified in `{personal_tenant_id}`.
- `urn:acronis.com::policy_management:{tenant_id}|{policy_id}:apply_revoke` - applies a protection plan to a resource by policy ID specified in `{policy_id}` from a resource owner tenant specified in `{tenant_id}`.
**Type**: Array of String
**Array type description:**
**Type**: String
**Example**:
```json
{
"tenant_uuid": "4b07e4a1-a49b-4d4e-b8f2-253f1fef98ad",
"tenant_id": "11",
"scopes": [
"urn:acronis.com:tenant-id:734fe814-748a-41cb-8a94-60e18fb3c442:backup_agent_admin",
"urn:acronis.com::policy_management:4b07e4a1-a49b-4d4e-b8f2-253f1fef98ad|10858a46-db9b-4725-aa60-fff6252841fd:apply_revoke"
],
"id": 2,
"expires_at": "2022-04-05T18:46:45Z",
"token": "27F9-5234-41C3",
"created_at": "2022-04-02T18:46:45Z"
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Fetch Available Tenant Applications (GET /tenants/{tenant_id}/applications)
Fetches a list of applications available to the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `for_ui` | (Optional) If true, the list of applications will be returned in a form that is appropriate for the UI.
Currently, applications on a grace period will be filtered out.
**Type**: Boolean |
#### Responses
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of String
**Array type description:**
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
**Example**:
```json
{
"items": [
"aa4f8923-8950-4804-8827-c6d78388e5b6",
"4eb7b320-48b4-4552-9bf8-f7482538da23"
]
}
```
### Fetch Tenant Users (GET /tenants/{tenant_id}/users)
Fetches a list of UUIDs of the tenant's users.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `include_grand_children` | (Optional) If true for a customer tenant, the UUIDs of the users from all nested unit tenants will be included in the response.
If true for a non customer tenant, the UUIDs of the users from all nested folder tenants will be included in the response.
**Type**: Boolean
**Default**: false |
| `include_hidden` | (Optional) If true, hidden users may be included in the response.
**Type**: Boolean
**Default**: false |
| `order` | (Optional) Orders the result by one of parameters: `as_is`, `login`, `status`, `name`, `roles`, `level`, `usage`, `mfa_status`, `contact_types`.
Reverse order can be performed using the `-` operator before the parameter.
To order by `usage`, the usage name should be specified after a dot, e.g. `usage.workstations`.
For storage-dependent usages, the storage UUID is not required.
Default value is `name` - order by first name and last name or login if names were not provided.
**Type**: String
**Default**: name |
| `allow_deleted` | (Optional) If true, deleted users may be returned.
**Type**: Boolean |
#### Responses
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of String
**Array type description:**
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
**Example**:
```json
{
"items": [
"aa4f8923-8950-4804-8827-c6d78388e5b6",
"4eb7b320-48b4-4552-9bf8-f7482538da23"
]
}
```
### Fetch Tenant Children (GET /tenants/{tenant_id}/children)
Fetches a list of UUIDs of the tenant's children.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `order` | (Optional) Orders the result by one of parameters: `as_is`, `name`, `status`, `usage`.
Reverse order can be performed using the `-` operator before the parameter.
For order by `usage`, the usage name should be specified after a dot, e.g. `usage.workstations`.
For storage-dependent usages, the storage UUID should be added after a dot, e.g. `usage.storage.c05d399b-ba6b-41e9-a638-cd7ffc7ec87a`.
**Type**: String
**Default**: name |
| `allow_deleted` | (Optional) If true, children may be returned.
**Type**: Boolean |
| `after` | (Optional) Cursor to fetch the next children page. The cursor encodes all the filtering and sorting arguments, thus client does not need to provide all them for the next page, only cursor should be provided. Client can get the cursor from `paging.cursors.after` field of the previous page response.
**Type**: String |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of String
**Array type description:**
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
**Example**:
```json
{
"items": [
"aa4f8923-8950-4804-8827-c6d78388e5b6",
"4eb7b320-48b4-4552-9bf8-f7482538da23"
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Fetch Tenant Reports (GET /tenants/{tenant_id}/reports)
Fetches a list of reports' UUIDs available to the tenant.
#### Security
The endpoint supports the following authorization methods: `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
* `urn:acronis.com::account-server::unit_admin`
* `urn:acronis.com::account-server::readonly_admin`
#### Request parameters
#### Responses
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of String
**Array type description:**
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
**Example**:
```json
{
"items": [
"aa4f8923-8950-4804-8827-c6d78388e5b6",
"4eb7b320-48b4-4552-9bf8-f7482538da23"
]
}
```
### Fetch Tenant Infrastructure Locations (GET /tenants/{tenant_id}/locations)
Fetches a list of infrastructure locations owned by the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `locations` — **Type**: Array of String
**Array type description:**
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
**Example**:
```json
{
"locations": [
"d9fd4cc3-4309-40a2-bd79-88da24a1c99d",
"7068976a-22c0-476e-ae3b-5f0469981ff1"
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Fetch Tenant Usages (GET /tenants/{tenant_id}/usages)
Fetches a list of common usage metrics of the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `usage_names` | (Optional) A filter by comma-separated list of usage names.
**Type**: String |
| `editions` | (Optional) A filter by comma-separated list of editions.
**Type**: String |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"items": [
{
"name": "adv_vms",
"measurement_unit": "quantity",
"range_start": "2017-06-01T00:00:00",
"edition": "advanced",
"usage_name": "vms",
"absolute_value": 800,
"offering_item": {
"status": 1,
"quota": {
"value": 10,
"overage": 10,
"version": 1486479690324
}
},
"type": "count",
"value": 800,
"application_id": "c6ab7fb4-b461-4214-9257-86fbad8efb85"
},
{
"name": "storage",
"measurement_unit": "bytes",
"range_start": "2017-06-22T00:00:00",
"edition": "standard",
"usage_name": "storage",
"infra_id": "df476eec-c470-40b0-9b10-37223b7f4a2b",
"absolute_value": 800,
"offering_item": {
"status": 1,
"quota": {
"value": 1000,
"overage": 2000,
"version": 1486479690324
}
},
"type": "infra",
"value": 800,
"application_id": "c6ab7fb4-b461-4214-9257-86fbad8efb85"
},
{
"name": "vm_storage",
"measurement_unit": "bytes",
"range_start": "2017-06-01T00:00:00",
"edition": "standard",
"usage_name": "vm_storage",
"absolute_value": 100000,
"type": "infra",
"value": 100000,
"application_id": "c6ab7fb4-b461-4214-9257-86fbad8efb85"
}
]
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Fetch Tenant Pricing Settings (GET /tenants/{tenant_id}/pricing)
Fetches pricing settings of the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `mode` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `currency` — Currency of all offering item prices for this tenant. This field can have a null value.
**Type**: any
- `version` — Auto-incremented entity version.
**Type**: Integer
- `production_start_date` — Production pricing mode start date (timestamp).
**Type**: any
**Example**:
```json
{
"version": 1497533157730,
"mode": "production",
"currency": "USD",
"production_start_date": "2020-05-19T00:00:00"
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Update Tenant Pricing Settings (PUT /tenants/{tenant_id}/pricing)
Updates pricing settings of the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `mode` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `currency` — Currency of all offering item prices for this tenant. This field can have a null value.
**Type**: any
- `version` — Auto-incremented entity version.
**Type**: Integer
**Example**:
```json
{
"version": 1497533157730,
"mode": "production",
"currency": "USD"
}
```
#### Responses
##### `200` — Pricing settings was successfully updated.
**Media type**: `application/json`
- `mode` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `currency` — Currency of all offering item prices for this tenant. This field can have a null value.
**Type**: any
- `version` — Auto-incremented entity version.
**Type**: Integer
- `production_start_date` — Production pricing mode start date (timestamp).
**Type**: any
**Example**:
```json
{
"version": 1497533157730,
"mode": "production",
"currency": "USD",
"production_start_date": "2020-05-19T00:00:00"
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Disable Custom Branding (DELETE /tenants/{tenant_id}/brand)
Disables custom branding for the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `version` | (Required) Growing number of object internal version.
**Type**: Integer |
#### Responses
##### `204` — Custom branding has been disabled.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `updated_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `deleted_at` — Soft deletion timestamp.
**Type**: any
- `production_start_date` — Tenant trial expiration date.
**Type**: any
- `name` — Human-readable name that will be displayed to the users.
**Type**: String
- `customer_type` — A type of the customer.
**Type**: String
**Allowed values**:
- `default`
- `enterprise`
- `consumer`
- `small_office`
- `ti_unified`
- `parent_id` — ID of parent tenant. For the real root tenant the parent_id is equal to its id
**Type**: String
- `kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `contact` — **Type**: Object
- `contacts` — Empty array by default. Will be populated with all referencing contacts if query param `with_contacts` is provided.
**Type**: Array of Object
**Array type description:**
**Type**: Object
**Min items**: 0
- `enabled` — Flag, indicates whether the tenant is enabled or disabled.
**Type**: Boolean
- `customer_id` — ID from external system; for reporting purposes. This field can have a null value.
**Type**: any
- `brand_id` — Brand id for API v1.
**Type**: any
- `brand_uuid` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `brand_enabled` — Flag, indicates whether the branding is enabled or disabled on tenant.
**Type**: Boolean
- `internal_tag` — Internal tag. This field can have a null value.
**Type**: any
- `language` — Tenant`s preferred language.
**Type**: String
- `owner_id` — Identifier of personal tenant owner user. This field can have a null value.
**Type**: any
- `has_children` — Flag, indicates if tenant has children.
**Type**: Boolean
- `default_idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `update_lock` — **Type**: Object
- `ancestral_access` — Indicates whether tenant's indirect ancestors have access to it.
**Type**: Boolean
- `mfa_status` — Multi-factor authentication status of the tenant.
**Type**: String
**Allowed values**:
- `disabled`
- `forcibly_disabled`
- `setup_required`
- `enabled`
- `pricing_mode` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `external_operation_status` — Indicates if some external operation in progress for this tenant.
**Type**: any
**Example**:
```json
{
"internal_tag": null,
"name": "The Qwerty Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "enabled",
"brand_id": 1,
"pricing_mode": "production",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [],
"ancestral_access": true,
"version": 2,
"brand_enabled": true,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"language": "en",
"customer_type": "enterprise",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": true,
"owner_id": "7decff12-ee1b-4f8d-b446-59610bfb9203"
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"production_start_date": null
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_6`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "conflict",
"details": {
"info": "Conflict"
},
"message": "Conflict"
}
}
```
### Fetch Custom Branding Options (GET /tenants/{tenant_id}/brand)
Fetches branding options of the tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `effective` | (Optional) If true, parent tenant's brand will be returned
**Type**: Integer
**Default**: 0 |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
**Example**:
```json
{
"smtp_encryption": "TLS",
"mobile_app_android_download_url": "www.mobile.com/download",
"backup_console_url": "mc-cloud.acronis.com/bc",
"smtp_user": "smtpuser",
"reg_server_url": "https://rs.custom-cloud.acronis.com",
"platform_terms_url": "terms.acronis.com",
"owns_custom_legal_docs": true,
"company_name": "acronis",
"smtp_port": 465,
"upsell_url": "www.partner.com/buy",
"smtp_server": "smtp.mycompany.com",
"privacy_policy_url": "https://www.acronis.com/company/privacy.html",
"user_guide_url": "guide.acronis.com",
"color": "FFFFFF",
"service_name": "myservice",
"help_url": "api/ams/links/help",
"knowledgebase_url": "kb.acronis.com/errorcode/",
"logotype": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"home_url": "www.acronis.com",
"color_scheme": "default",
"smtp_reply_address": "noreply@mycompany.com",
"support_phone": "+1 1111 1111111",
"white_labeled_agent": true,
"support_url": "support.acronis.com",
"hide_predefined": 1,
"agent_gateway_url": "https://agents.custom-cloud.acronis.com",
"smtp_password": "",
"mobile_app_ios_download_url": "www.mobile.com/download",
"terms_url": "terms.acronis.com",
"account_server_url": "mc-cloud.acronis.com",
"smtp_override": 1,
"router_url": "cloud.acronis.com"
}
```
### Enable Custom Branding (POST /tenants/{tenant_id}/brand)
Enables custom branding options for the tenant.
This operation cannot be performed on customer and unit tenants.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `version` | (Required) Growing number of object internal version.
**Type**: Integer |
#### Responses
##### `201` — Custom branding has been enabled.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `updated_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `deleted_at` — Soft deletion timestamp.
**Type**: any
- `production_start_date` — Tenant trial expiration date.
**Type**: any
- `name` — Human-readable name that will be displayed to the users.
**Type**: String
- `customer_type` — A type of the customer.
**Type**: String
**Allowed values**:
- `default`
- `enterprise`
- `consumer`
- `small_office`
- `ti_unified`
- `parent_id` — ID of parent tenant. For the real root tenant the parent_id is equal to its id
**Type**: String
- `kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `contact` — **Type**: Object
- `contacts` — Empty array by default. Will be populated with all referencing contacts if query param `with_contacts` is provided.
**Type**: Array of Object
**Array type description:**
**Type**: Object
**Min items**: 0
- `enabled` — Flag, indicates whether the tenant is enabled or disabled.
**Type**: Boolean
- `customer_id` — ID from external system; for reporting purposes. This field can have a null value.
**Type**: any
- `brand_id` — Brand id for API v1.
**Type**: any
- `brand_uuid` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `brand_enabled` — Flag, indicates whether the branding is enabled or disabled on tenant.
**Type**: Boolean
- `internal_tag` — Internal tag. This field can have a null value.
**Type**: any
- `language` — Tenant`s preferred language.
**Type**: String
- `owner_id` — Identifier of personal tenant owner user. This field can have a null value.
**Type**: any
- `has_children` — Flag, indicates if tenant has children.
**Type**: Boolean
- `default_idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `update_lock` — **Type**: Object
- `ancestral_access` — Indicates whether tenant's indirect ancestors have access to it.
**Type**: Boolean
- `mfa_status` — Multi-factor authentication status of the tenant.
**Type**: String
**Allowed values**:
- `disabled`
- `forcibly_disabled`
- `setup_required`
- `enabled`
- `pricing_mode` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `external_operation_status` — Indicates if some external operation in progress for this tenant.
**Type**: any
**Example**:
```json
{
"internal_tag": null,
"name": "The Qwerty Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "enabled",
"brand_id": 1,
"pricing_mode": "production",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [],
"ancestral_access": true,
"version": 2,
"brand_enabled": true,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"language": "en",
"customer_type": "enterprise",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": true,
"owner_id": "7decff12-ee1b-4f8d-b446-59610bfb9203"
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"production_start_date": null
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_6`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "conflict",
"details": {
"info": "Conflict"
},
"message": "Conflict"
}
}
```
### Modify Custom Branding (PUT /tenants/{tenant_id}/brand)
Modifies custom branding options.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `version` | (Required) Growing number of object internal version.
**Type**: Integer |
##### Request body
**Media type**: `application/json`
**Example**:
```json
{
"smtp_encryption": "TLS",
"mobile_app_android_download_url": "www.mobile.com/download",
"smtp_user": "smtpuser",
"reg_server_url": "https://rs.custom-cloud.acronis.com",
"platform_terms_url": "terms.acronis.com",
"owns_custom_legal_docs": false,
"company_name": "mycompany",
"smtp_port": 465,
"upsell_url": "www.partner.com/buy",
"smtp_server": "smtp.mycompany.com",
"privacy_policy_url": "https://www.acronis.com/company/privacy.html",
"user_guide_url": "guide.acronis.com",
"color": "FFFFFF",
"service_name": "myservice",
"help_url": "help.acronis.com",
"knowledgebase_url": "kb.acronis.com/errorcode/",
"logotype": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"home_url": "www.baas.com",
"color_scheme": "default",
"smtp_reply_address": "noreply@mycompany.com",
"support_phone": "+1 1111 1111111",
"white_labeled_agent": false,
"support_url": "support.acronis.com",
"agent_gateway_url": "https://agents.custom-cloud.acronis.com",
"smtp_password": "**********",
"mobile_app_ios_download_url": "www.mobile.com/download",
"terms_url": "terms.acronis.com",
"account_server_url": "mc-cloud.acronis.com",
"smtp_override": 1,
"router_url": "cloud.acronis.com"
}
```
#### Responses
##### `200` — Custom branding has been updated.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `updated_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `deleted_at` — Soft deletion timestamp.
**Type**: any
- `production_start_date` — Tenant trial expiration date.
**Type**: any
- `name` — Human-readable name that will be displayed to the users.
**Type**: String
- `customer_type` — A type of the customer.
**Type**: String
**Allowed values**:
- `default`
- `enterprise`
- `consumer`
- `small_office`
- `ti_unified`
- `parent_id` — ID of parent tenant. For the real root tenant the parent_id is equal to its id
**Type**: String
- `kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `contact` — **Type**: Object
- `contacts` — Empty array by default. Will be populated with all referencing contacts if query param `with_contacts` is provided.
**Type**: Array of Object
**Array type description:**
**Type**: Object
**Min items**: 0
- `enabled` — Flag, indicates whether the tenant is enabled or disabled.
**Type**: Boolean
- `customer_id` — ID from external system; for reporting purposes. This field can have a null value.
**Type**: any
- `brand_id` — Brand id for API v1.
**Type**: any
- `brand_uuid` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `brand_enabled` — Flag, indicates whether the branding is enabled or disabled on tenant.
**Type**: Boolean
- `internal_tag` — Internal tag. This field can have a null value.
**Type**: any
- `language` — Tenant`s preferred language.
**Type**: String
- `owner_id` — Identifier of personal tenant owner user. This field can have a null value.
**Type**: any
- `has_children` — Flag, indicates if tenant has children.
**Type**: Boolean
- `default_idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `update_lock` — **Type**: Object
- `ancestral_access` — Indicates whether tenant's indirect ancestors have access to it.
**Type**: Boolean
- `mfa_status` — Multi-factor authentication status of the tenant.
**Type**: String
**Allowed values**:
- `disabled`
- `forcibly_disabled`
- `setup_required`
- `enabled`
- `pricing_mode` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `external_operation_status` — Indicates if some external operation in progress for this tenant.
**Type**: any
**Example**:
```json
{
"internal_tag": null,
"name": "The Qwerty Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "enabled",
"brand_id": 1,
"pricing_mode": "production",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [],
"ancestral_access": true,
"version": 2,
"brand_enabled": true,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"language": "en",
"customer_type": "enterprise",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": true,
"owner_id": "7decff12-ee1b-4f8d-b446-59610bfb9203"
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"production_start_date": null
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_6`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "conflict",
"details": {
"info": "Conflict"
},
"message": "Conflict"
}
}
```
### Upload Tenant Brand Logo (POST /tenants/{tenant_id}/brand/logo)
Uploads a new tenant's brand logo.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
#### Request parameters
##### Headers
| Name | Description |
|------|-------------|
| `Content-Length` | (Required) **Type**: Integer |
##### Query parameters
| Name | Description |
|------|-------------|
| `version` | (Required) Growing number of object internal version.
**Type**: Integer |
##### Request body
**Media type**: `image/png`
- `schema` — **Type**: any
#### Responses
##### `201`
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `updated_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `deleted_at` — Soft deletion timestamp.
**Type**: any
- `production_start_date` — Tenant trial expiration date.
**Type**: any
- `name` — Human-readable name that will be displayed to the users.
**Type**: String
- `customer_type` — A type of the customer.
**Type**: String
**Allowed values**:
- `default`
- `enterprise`
- `consumer`
- `small_office`
- `ti_unified`
- `parent_id` — ID of parent tenant. For the real root tenant the parent_id is equal to its id
**Type**: String
- `kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `contact` — **Type**: Object
- `contacts` — Empty array by default. Will be populated with all referencing contacts if query param `with_contacts` is provided.
**Type**: Array of Object
**Array type description:**
**Type**: Object
**Min items**: 0
- `enabled` — Flag, indicates whether the tenant is enabled or disabled.
**Type**: Boolean
- `customer_id` — ID from external system; for reporting purposes. This field can have a null value.
**Type**: any
- `brand_id` — Brand id for API v1.
**Type**: any
- `brand_uuid` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `brand_enabled` — Flag, indicates whether the branding is enabled or disabled on tenant.
**Type**: Boolean
- `internal_tag` — Internal tag. This field can have a null value.
**Type**: any
- `language` — Tenant`s preferred language.
**Type**: String
- `owner_id` — Identifier of personal tenant owner user. This field can have a null value.
**Type**: any
- `has_children` — Flag, indicates if tenant has children.
**Type**: Boolean
- `default_idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `update_lock` — **Type**: Object
- `ancestral_access` — Indicates whether tenant's indirect ancestors have access to it.
**Type**: Boolean
- `mfa_status` — Multi-factor authentication status of the tenant.
**Type**: String
**Allowed values**:
- `disabled`
- `forcibly_disabled`
- `setup_required`
- `enabled`
- `pricing_mode` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `external_operation_status` — Indicates if some external operation in progress for this tenant.
**Type**: any
**Example**:
```json
{
"internal_tag": null,
"name": "The Qwerty Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "enabled",
"brand_id": 1,
"pricing_mode": "production",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [],
"ancestral_access": true,
"version": 2,
"brand_enabled": true,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"language": "en",
"customer_type": "enterprise",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": true,
"owner_id": "7decff12-ee1b-4f8d-b446-59610bfb9203"
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"production_start_date": null
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
### Manage Tenant MFA Status (PUT /tenants/{tenant_id}/mfa/status)
Toggles MFA status for the tenant.
This operation cannot be performed on folder and unit tenants.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::root_admin`
* `urn:acronis.com::account-server::partner_admin`
* `urn:acronis.com::account-server::company_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `enabled` — Status of MFA for tenant.
**Type**: Boolean
**Example**:
```json
{
"enabled": true
}
```
#### Responses
##### `200` — MFA status was successfully changed.
**Media type**: `application/json`
- `mfa_status` — Status of MFA for tenant.
**Type**: String
**Allowed values**:
- `disabled`
- `disable_in_progress`
- `enabled`
- `users` — Total number of active users in this tenant (including child folders or units of the same organization).
**Type**: Integer
- `users_with_totp_enabled` — Number of users in this tenant (including child folders or units of the same organization) with TOTP configured.
**Type**: Integer
- `update_allowed` — True if logged in user can change MFA status for this tenant.
**Type**: Boolean
- `users_count` — **Type**: any
- `users_with_totp_enabled_count` — **Type**: any
**Example**:
```json
{
"mfa_status": "enabled",
"users_count": 100,
"users_with_totp_enabled_count": 20,
"update_allowed": true
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
### Fetch Tenant MFA Status (GET /tenants/{tenant_id}/mfa/status)
Provides MFA status for tenant and progress of TOTP enablement by users.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `mfa_status` — Status of MFA for tenant.
**Type**: String
**Allowed values**:
- `disabled`
- `disable_in_progress`
- `enabled`
- `users` — Total number of active users in this tenant (including child folders or units of the same organization).
**Type**: Integer
- `users_with_totp_enabled` — Number of users in this tenant (including child folders or units of the same organization) with TOTP configured.
**Type**: Integer
- `update_allowed` — True if logged in user can change MFA status for this tenant.
**Type**: Boolean
- `users_count` — **Type**: any
- `users_with_totp_enabled_count` — **Type**: any
**Example**:
```json
{
"mfa_status": "enabled",
"users_count": 100,
"users_with_totp_enabled_count": 20,
"update_allowed": true
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Update Tenant Default Idp Id (PUT /tenants/{tenant_id}/default_idp)
Updates Tenant default_idp_id.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `version` — Tenant`s version.
**Type**: Integer
- `idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `apply_to_children` — If True - new default identity provider ID will be set to tenant's children as well
**Type**: Boolean
**Example**:
```json
{
"version": 1,
"idp_id": "c4878582-6e14-451e-9bda-3ff899b3f700",
"apply_to_children": true
}
```
#### Responses
##### `200` — Tenant default_idp_id successfully updated
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `updated_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `deleted_at` — Soft deletion timestamp.
**Type**: any
- `production_start_date` — Tenant trial expiration date.
**Type**: any
- `name` — Human-readable name that will be displayed to the users.
**Type**: String
- `customer_type` — A type of the customer.
**Type**: String
**Allowed values**:
- `default`
- `enterprise`
- `consumer`
- `small_office`
- `ti_unified`
- `parent_id` — ID of parent tenant. For the real root tenant the parent_id is equal to its id
**Type**: String
- `kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `contact` — **Type**: Object
- `contacts` — Empty array by default. Will be populated with all referencing contacts if query param `with_contacts` is provided.
**Type**: Array of Object
**Array type description:**
**Type**: Object
**Min items**: 0
- `enabled` — Flag, indicates whether the tenant is enabled or disabled.
**Type**: Boolean
- `customer_id` — ID from external system; for reporting purposes. This field can have a null value.
**Type**: any
- `brand_id` — Brand id for API v1.
**Type**: any
- `brand_uuid` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `brand_enabled` — Flag, indicates whether the branding is enabled or disabled on tenant.
**Type**: Boolean
- `internal_tag` — Internal tag. This field can have a null value.
**Type**: any
- `language` — Tenant`s preferred language.
**Type**: String
- `owner_id` — Identifier of personal tenant owner user. This field can have a null value.
**Type**: any
- `has_children` — Flag, indicates if tenant has children.
**Type**: Boolean
- `default_idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `update_lock` — **Type**: Object
- `ancestral_access` — Indicates whether tenant's indirect ancestors have access to it.
**Type**: Boolean
- `mfa_status` — Multi-factor authentication status of the tenant.
**Type**: String
**Allowed values**:
- `disabled`
- `forcibly_disabled`
- `setup_required`
- `enabled`
- `pricing_mode` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `external_operation_status` — Indicates if some external operation in progress for this tenant.
**Type**: any
**Example**:
```json
{
"internal_tag": null,
"name": "The Qwerty Tenant",
"customer_id": "123asd",
"parent_id": "fa6859a9-f5e1-4faf-a56c-5a0ae866dc4f",
"owner_id": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"enabled": true,
"mfa_status": "enabled",
"brand_id": 1,
"pricing_mode": "production",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [
"legal"
],
"email_confirmed": false,
"phone": "123456789"
},
"contacts": [],
"ancestral_access": true,
"version": 2,
"brand_enabled": true,
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0",
"language": "en",
"customer_type": "enterprise",
"created_at": "2016-06-22T18:25:16",
"kind": "partner",
"update_lock": {
"enabled": true,
"owner_id": "7decff12-ee1b-4f8d-b446-59610bfb9203"
},
"brand_uuid": "03fa8bf4-28f2-11e7-ba28-cbe99c3c450a",
"updated_at": "2016-06-22T18:25:16",
"has_children": true,
"deleted_at": null,
"production_start_date": null
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_6`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "conflict",
"details": {
"info": "Conflict"
},
"message": "Conflict"
}
}
```
### Restore Deleted Tenant (POST /tenants/{tenant_id}/restore)
Restores previously soft deleted tenant.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `force` | (Optional) Defines if tenant should be restored in in case of a conflict with another tenant or user who has taken the same name or login. In such a case restored tenant will have postfix added.
**Type**: Boolean |
#### Responses
##### `204` — Tenant was successfully restored.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_6`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "conflict",
"details": {
"info": "Conflict"
},
"message": "Conflict"
}
}
```
### Fetch Users Batch (GET /users)
Fetches a batch of users.
Available in cloud version only.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `uuids` | (Optional) A filter by comma-separated list of users' UUIDs. Maximum of 100 UUIDs.
Is mutually exclusive with `subtree_root_tenant_id`, `external_ids` and `tenant_id`.
**Type**: String
**Min length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}(,[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12})*` |
| `origin_id` | (Optional) A filter by specific origin ID
**Type**: String |
| `external_ids` | (Optional) A filter by comma-separated list of users' UUIDs in the external Identity Provider. Maximum of 100 UUIDs.
Is mutually exclusive with `subtree_root_tenant_id` and `uuids`.
**Type**: String |
| `tenant_id` | (Optional) A filter by specific tenant ID. Required when searching the users by `external_id`. Not used otherwise.
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}` |
| `subtree_root_tenant_id` | (Optional) A filter by tenants tree starting from the specified tenant ID. Is mutually exclusive with `uuids` and `tenant_id`.
**Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}` |
| `updated_since` | (Optional) A filter by users that were updated after the specified RFC3339 timestamp in UTC time zone.
**Type**: DateTime |
| `limit` | (Optional) Number of elements in current users page of the response.
**Type**: Integer
**Minimum**: 1
**Default**: 2000 |
| `after` | (Optional) Cursor to fetch the next users page. The cursor encodes all the filtering and sorting arguments, thus client does not need to provide all them for the next page, only cursor should be provided. Client can get the cursor from `paging.cursors.after` field of the previous page response.
**Type**: String |
| `lod` | (Optional) A predefined level of details for the user object to return.
The following levels of details can be specified:
- `stamps` - includes `id`, `version`, `tenant_id`, `created_at`, `updated_at`, `deleted_at`, `access_policies`, `origin_id`, `origin_external_id`, `disable_after`.
- `basic` - includes all stamps fields plus `personal_tenant_id`, `login`, `enabled`, `session_mfa_status`, `delivery_channel`.
- `full` - includes all basic fields plus `contact`, `activated`, `language`, `business_types`, `notifications`, `idp_id`, `external_id`, `mfa_status`, `external_operation_status`.
**Type**: String
**Allowed values**:
- `stamps`
- `basic`
- `full`
**Default**: full |
| `with_access_policies` | (Optional) If true, all users' access policies will be returned in the response.
**Type**: Boolean |
| `allow_deleted` | (Optional) If true, deleted users may be returned.
**Type**: Boolean |
| `inside_organization` | (Optional) If true, only users that belong to the same organization will be returned. It requires 'subtree_root_tenant_id' to be specified.
**Type**: Boolean |
| `access_policies` | (Optional) Users in access policies will be returned. It accepts a comma-separated list. It requires 'inside_organization' to be set.
**Type**: String |
| `tenant_kinds` | (Optional) Users in tenant kinds will be returned. It accepts a comma-separated list. It requires 'inside_organization' to be set.
**Type**: String |
| `target_tenant_id` | (Optional) Users within range starting from 'subtree_root_tenant_id' to the 'target_tenant_id' will be returned. It requires 'inside_organization' to be set.
**Type**: String |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `paging` — **Type**: Object
- `timestamp` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `items` — Array of user objects. The fields returned depend on the `lod` query parameter.
**Type**: Array of any
**Array type description:**
**Type**: any
**Examples**:
*`default`*:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"disable_after": "2017-06-22T18:25:16",
"activated": true,
"tenant_id": "7ea1cf00-0ef0-11e7-8741-bb83f58f591f",
"enabled": true,
"personal_tenant_id": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"fax": "123 Example Street",
"language": "en",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [],
"email_confirmed": false,
"phone": "123456789"
},
"version": 2,
"origin_id": "pillr.mdr",
"id": "fae84e50-0eef-11e7-bc3f-d39de3f5fe32",
"language": "en",
"access_policies": [],
"origin_external_id": "c66b1af2-2ac5-4764-8db6-97b054e7d27e",
"created_at": "2016-06-22T18:25:16",
"business_types": [],
"login": "some_login_1",
"updated_at": "2016-06-22T18:25:16",
"notifications": [
"maintenance",
"quota",
"reports",
"backup_error",
"backup_warning",
"backup_info",
"backup_daily_report",
"backup_critical",
"device_control_warning",
"certificate_management_error",
"certificate_management_warning",
"certificate_management_info"
],
"deleted_at": null
},
{
"disable_after": "2017-06-22T18:25:16",
"activated": true,
"tenant_id": "7ea1cf00-0ef0-11e7-8741-bb83f58f591f",
"enabled": true,
"personal_tenant_id": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Smith",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"fax": "123 Example Street",
"language": "en",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [],
"email_confirmed": false,
"phone": "123456789"
},
"version": 2,
"origin_id": "pillr.mdr",
"id": "76137b0e-0ef0-11e7-b5c2-1f8159df2571",
"language": "ru",
"access_policies": [],
"origin_external_id": "c66b1af2-2ac5-4764-8db6-97b054e7d27e",
"external_operation_status": "recovering",
"created_at": "2016-06-22T18:27:11",
"business_types": [
"buyer"
],
"login": "some_login_2",
"updated_at": "2016-06-22T18:25:16",
"notifications": [
"maintenance",
"quota",
"reports",
"backup_error",
"backup_warning",
"backup_info",
"backup_daily_report",
"backup_critical",
"device_control_warning"
],
"deleted_at": null
}
]
}
```
*`lodStamps`*:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"disable_after": "2017-06-22T18:25:16",
"tenant_id": "7ea1cf00-0ef0-11e7-8741-bb83f58f591f",
"version": 2,
"origin_id": "pillr.mdr",
"id": "fae84e50-0eef-11e7-bc3f-d39de3f5fe32",
"access_policies": [],
"origin_external_id": "c66b1af2-2ac5-4764-8db6-97b054e7d27e",
"created_at": "2016-06-22T18:25:16",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null
},
{
"disable_after": null,
"tenant_id": "7ea1cf00-0ef0-11e7-8741-bb83f58f591f",
"version": 2,
"origin_id": null,
"id": "76137b0e-0ef0-11e7-b5c2-1f8159df2571",
"access_policies": [],
"origin_external_id": null,
"created_at": "2016-06-22T18:27:11",
"updated_at": "2016-06-22T18:25:16",
"deleted_at": null
}
]
}
```
*`lodBasic`*:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"disable_after": "2017-06-22T18:25:16",
"tenant_id": "7ea1cf00-0ef0-11e7-8741-bb83f58f591f",
"enabled": true,
"personal_tenant_id": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"version": 2,
"origin_id": "pillr.mdr",
"id": "fae84e50-0eef-11e7-bc3f-d39de3f5fe32",
"access_policies": [],
"origin_external_id": "c66b1af2-2ac5-4764-8db6-97b054e7d27e",
"created_at": "2016-06-22T18:25:16",
"delivery_channel": "email",
"login": "some_login_1",
"updated_at": "2016-06-22T18:25:16",
"session_mfa_status": "passed_or_not_required",
"deleted_at": null
},
{
"disable_after": null,
"tenant_id": "7ea1cf00-0ef0-11e7-8741-bb83f58f591f",
"enabled": true,
"personal_tenant_id": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"version": 2,
"origin_id": null,
"id": "76137b0e-0ef0-11e7-b5c2-1f8159df2571",
"access_policies": [],
"origin_external_id": null,
"created_at": "2016-06-22T18:27:11",
"delivery_channel": null,
"login": "some_login_2",
"updated_at": "2016-06-22T18:25:16",
"session_mfa_status": "required",
"deleted_at": null
}
]
}
```
*`withAccessPolicies`*:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"disable_after": "2017-06-22T18:25:16",
"activated": true,
"tenant_id": "7ea1cf00-0ef0-11e7-8741-bb83f58f591f",
"enabled": true,
"personal_tenant_id": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"external_id": "111111",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [],
"email_confirmed": false,
"phone": "123456789"
},
"version": 2,
"origin_id": "pillr.mdr",
"id": "fae84e50-0eef-11e7-bc3f-d39de3f5fe32",
"language": "en",
"access_policies": [
{
"trustee_type": "user",
"trustee_id": "fae84e50-0eef-11e7-bc3f-d39de3f5fe32",
"tenant_id": "7ea1cf00-0ef0-11e7-8741-bb83f58f591f",
"role_id": "unit_admin",
"version": 1,
"id": "fb261178-06bc-4268-9337-9639e049e1c8",
"created_at": "2016-06-22T18:25:16",
"updated_at": "2016-06-22T18:25:16",
"issuer_id": "48ef84eb-b0dc-4ade-83d1-0662c8b54f6d",
"deleted_at": null
}
],
"origin_external_id": "c66b1af2-2ac5-4764-8db6-97b054e7d27e",
"created_at": "2016-06-22T18:25:16",
"business_types": [],
"login": "some_login_1",
"updated_at": "2016-06-22T18:25:16",
"notifications": [
"maintenance",
"quota",
"reports",
"backup_error",
"backup_warning",
"backup_info",
"backup_daily_report",
"backup_critical"
],
"deleted_at": null
},
{
"disable_after": "2017-06-22T18:25:16",
"activated": true,
"tenant_id": "7ea1cf00-0ef0-11e7-8741-bb83f58f591f",
"enabled": true,
"personal_tenant_id": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Smith",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"external_id": "111111",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [],
"email_confirmed": false,
"phone": "123456789"
},
"version": 2,
"origin_id": "pillr.mdr",
"id": "76137b0e-0ef0-11e7-b5c2-1f8159df2571",
"language": "ru",
"access_policies": [
{
"trustee_type": "user",
"trustee_id": "76137b0e-0ef0-11e7-b5c2-1f8159df2571",
"tenant_id": "7ea1cf00-0ef0-11e7-8741-bb83f58f591f",
"role_id": "unit_admin",
"version": 1,
"id": "fb261178-06bc-4268-9337-9639e049e1c8",
"created_at": "2016-06-22T18:25:16",
"updated_at": "2016-06-22T18:25:16",
"issuer_id": "48ef84eb-b0dc-4ade-83d1-0662c8b54f6d",
"deleted_at": null
}
],
"origin_external_id": "c66b1af2-2ac5-4764-8db6-97b054e7d27e",
"created_at": "2016-06-22T18:27:11",
"business_types": [
"buyer"
],
"login": "some_login_2",
"updated_at": "2016-06-22T18:25:16",
"notifications": [
"maintenance",
"quota",
"reports",
"backup_error",
"backup_warning",
"backup_info",
"backup_daily_report",
"backup_critical"
],
"deleted_at": null
}
]
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "Request body contains badly-formed JSON."
},
"message": "bad request"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Create User (POST /users)
Creates a new user.
If the user is created in a customer tenant and below - a personal tenant will be created and attached to it.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `tenant_id` — ID of tenant this user belongs to.
**Type**: String
- `login` — User's login.
**Type**: String
- `external_id` — User's ID in external identity provider (e.g. SID in AD).
**Type**: String
- `idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `contact` — **Type**: Object
- `enabled` — Flag, indicates whether the user is enabled or disabled.
**Type**: Boolean
- `language` — Preferred locale.
**Type**: String
- `business_types` — Business types.
**Type**: Array of String
**Array type description:**
**Type**: String
**Allowed values**:
- `buyer`
- `notifications` — User notifications.
**Type**: Array of String
**Array type description:**
**Type**: String
**Allowed values**:
- `maintenance`
- `quota`
- `reports`
- `backup_error`
- `backup_warning`
- `backup_info`
- `backup_daily_report`
- `backup_critical`
- `device_control_warning`
- `certificate_management_error`
- `certificate_management_warning`
- `certificate_management_info`
- `use_existing_identity` — Use existing identity (user with same login already exists).
**Type**: Boolean
- `origin_id` — User's origin ID, for example, ID of a Cyber Application responsible for creating this user.
**Type**: String
- `origin_external_id` — User's external origin ID.
**Type**: String
- `disable_after` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
**Example**:
```json
{
"disable_after": "2017-06-22T18:25:16",
"tenant_id": "0ef03214-6e47-4e50-87f2-a5955ba6095c",
"enabled": true,
"contact": {
"city": "Rivertown",
"zipcode": "12345",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"country": "USA",
"address2": "",
"lastname": "Doe",
"address1": "1440 River Drive #100",
"phone": "123456789"
},
"origin_id": "pillr.mdr",
"language": "ru",
"origin_external_id": "c66b1af2-2ac5-4764-8db6-97b054e7d27e",
"business_types": [
"buyer"
],
"login": "mylogin",
"notifications": [
"maintenance",
"quota",
"reports",
"backup_error",
"backup_warning",
"backup_info",
"backup_daily_report",
"backup_critical",
"device_control_warning",
"certificate_management_error",
"certificate_management_warning",
"certificate_management_info"
]
}
```
#### Responses
##### `200` — User was successfully created.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `login` — User's login.
**Type**: String
- `contact` — **Type**: Object
- `activated` — Flag, indicates whether the user has been activated or not.
**Type**: Boolean
- `enabled` — Flag, indicates whether the user is enabled or disabled.
**Type**: Boolean
- `access_policies` — Will be returned with all user access policies if query param `with_access_policies` is provided.
**Type**: Array of Object
**Array type description:**
**Type**: Object
**Min items**: 0
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `updated_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `deleted_at` — Soft deletion timestamp.
**Type**: any
- `language` — Preferred locale.
**Type**: String
- `idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `external_id` — User's ID in external identity provider (e.g. SID in AD).
**Type**: String
- `origin_id` — User's origin ID, for example, ID of a Cyber Application responsible for creating this user.
**Type**: String
- `origin_external_id` — User's external origin ID.
**Type**: String
- `disable_after` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `personal_tenant_id` — UUID of user's personal tenant. This field can have a null value.
**Type**: any
- `business_types` — Business types.
**Type**: Array of String
**Array type description:**
**Type**: String
**Allowed values**:
- `buyer`
- `notifications` — User notifications.
**Type**: Array of String
**Array type description:**
**Type**: String
**Allowed values**:
- `maintenance`
- `quota`
- `reports`
- `backup_error`
- `backup_warning`
- `backup_info`
- `backup_daily_report`
- `backup_critical`
- `device_control_warning`
- `certificate_management_error`
- `certificate_management_warning`
- `certificate_management_info`
- `mfa_status` — Multi-factor authentication status of the user.
**Type**: String
**Allowed values**:
- `disabled`
- `forcibly_disabled`
- `setup_required`
- `enabled`
- `session_mfa_status` — Multi-factor authentication status of the user session.
**Type**: String
**Allowed values**:
- `passed_or_not_required`
- `passed_as_trusted`
- `required`
- `external_operation_status` — Indicates if some external operation in progress for this user (his personal tenant).
**Type**: any
- `terms_accepted` — Flag that defines if this user has accepted EULA.
**Type**: Boolean
- `login_totp_time` — The time when the user in the current session passed TOTP verification.
**Type**: any
- `tenant_kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `tenant_pricing_model` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `brand_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
**Example**:
```json
{
"disable_after": "2017-06-22T18:25:16",
"idp_id": "e6f73a28-ff2e-4728-8f78-49eb74b20fce",
"activated": true,
"tenant_id": "0ef03214-6e47-4e50-87f2-a5955ba6095c",
"enabled": true,
"mfa_status": "setup_required",
"personal_tenant_id": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"brand_id": "a77b1af2-3ac5-576d-1db3-27b054e7d2aa",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [],
"deleted_at": "2020-05-19T11:50:00",
"email_confirmed": false,
"phone": "123456789"
},
"terms_accepted": true,
"version": 2,
"origin_id": "pillr.mdr",
"id": "948efcf2-b740-4c40-bb2d-4e4a46adfd87",
"language": "ru",
"tenant_kind": "partner",
"origin_external_id": "c66b1af2-2ac5-4764-8db6-97b054e7d27e",
"external_id": "S-1-5-21-917267712-1342860078-1792151419-500",
"created_at": "2016-06-22T18:25:16",
"business_types": [],
"login": "mylogin",
"updated_at": "2016-06-22T18:25:16",
"notifications": [
"maintenance",
"quota",
"reports",
"backup_error",
"backup_warning",
"backup_info",
"backup_daily_report",
"backup_critical",
"device_control_warning",
"certificate_management_error",
"certificate_management_warning",
"certificate_management_info"
],
"session_mfa_status": "required",
"deleted_at": null,
"tenant_pricing_model": "trial"
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Check Login Name Availability (GET /users/check_login)
Checks whether the login name (username) is available or already taken.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `username` | (Required) A login name to check.
**Type**: String |
#### Responses
##### `204` — Login name is available.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `406` — Provided arguments are not acceptable.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_10`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "not_acceptable",
"details": {
"info": "Not acceptable"
},
"message": "Not acceptable"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_6`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "conflict",
"details": {
"info": "Conflict"
},
"message": "Conflict"
}
}
```
### Check Password (POST /users/check_password)
Checks whether a password was previously exposed in data breaches.
#### Security
The endpoint does not require authorization.
#### Request parameters
##### Request body
**Media type**: `application/json`
- `password` — Password (SHA-1 hash) to check.
**Type**: String
**Example**:
```json
{
"password": "970C2D1A9869F18291D85BC389B33F0739496DE9"
}
```
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `compromised` — Flag that specifies whether the password was previously exposed in data breaches. True if the password was exposed; false otherwise.
**Type**: Boolean
**Example**:
```json
{
"compromised": true
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
### Fetch Current User Info (GET /users/me)
Fetches information about the currently authenticated user.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `userMe` — User object returned for /users/me endpoint. Includes all full fields plus terms_accepted, login_totp_time, tenant_kind, tenant_pricing_model, brand_id.
**Type**: any
**Example**:
```json
{
"disable_after": "2017-06-22T18:25:16",
"idp_id": "e6f73a28-ff2e-4728-8f78-49eb74b20fce",
"activated": true,
"tenant_id": "0ef03214-6e47-4e50-87f2-a5955ba6095c",
"login_totp_time": null,
"enabled": true,
"mfa_status": "setup_required",
"personal_tenant_id": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"brand_id": "a77b1af2-3ac5-576d-1db3-27b054e7d2aa",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"language": "en",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [],
"email_confirmed": false,
"phone": "123456789"
},
"terms_accepted": true,
"version": 2,
"origin_id": "pillr.mdr",
"id": "948efcf2-b740-4c40-bb2d-4e4a46adfd87",
"language": "ru",
"tenant_kind": "partner",
"access_policies": [],
"origin_external_id": "c66b1af2-2ac5-4764-8db6-97b054e7d27e",
"external_operation_status": null,
"external_id": "S-1-5-21-917267712-1342860078-1792151419-500",
"created_at": "2016-06-22T18:25:16",
"delivery_channel": "email",
"business_types": [],
"login": "mylogin",
"updated_at": "2016-06-22T18:25:16",
"notifications": [
"maintenance",
"quota",
"reports",
"backup_error",
"backup_warning",
"backup_info",
"backup_daily_report",
"backup_critical"
],
"session_mfa_status": "passed_or_not_required",
"deleted_at": null,
"tenant_pricing_model": "trial"
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
### Delete User (DELETE /users/{user_id})
Deletes a user by ID.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `version` | (Required) Growing number of object internal version.
**Type**: Integer |
#### Responses
##### `204` — User was successfully deleted.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
### Update User (PUT /users/{user_id})
Updates a user by ID.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `login` — User's login.
**Type**: String
- `external_id` — User's ID in external identity provider (e.g. SID in AD).
**Type**: String
- `idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `contact` — **Type**: Object
- `enabled` — Flag, indicates whether the user is enabled or disabled.
**Type**: Boolean
- `language` — Preferred locale.
**Type**: String
- `notifications` — User notifications.
**Type**: Array of String
**Array type description:**
**Type**: String
**Allowed values**:
- `maintenance`
- `quota`
- `reports`
- `backup_error`
- `backup_warning`
- `backup_info`
- `backup_daily_report`
- `backup_critical`
- `device_control_warning`
- `certificate_management_error`
- `certificate_management_warning`
- `certificate_management_info`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `disable_after` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
**Example**:
```json
{
"contact": {
"firstname": "John"
},
"notifications": [],
"disable_after": "2017-06-22T18:25:16",
"version": 2
}
```
#### Responses
##### `200` — User was successfully updated.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `login` — User's login.
**Type**: String
- `contact` — **Type**: Object
- `activated` — Flag, indicates whether the user has been activated or not.
**Type**: Boolean
- `enabled` — Flag, indicates whether the user is enabled or disabled.
**Type**: Boolean
- `access_policies` — Will be returned with all user access policies if query param `with_access_policies` is provided.
**Type**: Array of Object
**Array type description:**
**Type**: Object
**Min items**: 0
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `updated_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `deleted_at` — Soft deletion timestamp.
**Type**: any
- `language` — Preferred locale.
**Type**: String
- `idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `external_id` — User's ID in external identity provider (e.g. SID in AD).
**Type**: String
- `origin_id` — User's origin ID, for example, ID of a Cyber Application responsible for creating this user.
**Type**: String
- `origin_external_id` — User's external origin ID.
**Type**: String
- `disable_after` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `personal_tenant_id` — UUID of user's personal tenant. This field can have a null value.
**Type**: any
- `business_types` — Business types.
**Type**: Array of String
**Array type description:**
**Type**: String
**Allowed values**:
- `buyer`
- `notifications` — User notifications.
**Type**: Array of String
**Array type description:**
**Type**: String
**Allowed values**:
- `maintenance`
- `quota`
- `reports`
- `backup_error`
- `backup_warning`
- `backup_info`
- `backup_daily_report`
- `backup_critical`
- `device_control_warning`
- `certificate_management_error`
- `certificate_management_warning`
- `certificate_management_info`
- `mfa_status` — Multi-factor authentication status of the user.
**Type**: String
**Allowed values**:
- `disabled`
- `forcibly_disabled`
- `setup_required`
- `enabled`
- `session_mfa_status` — Multi-factor authentication status of the user session.
**Type**: String
**Allowed values**:
- `passed_or_not_required`
- `passed_as_trusted`
- `required`
- `external_operation_status` — Indicates if some external operation in progress for this user (his personal tenant).
**Type**: any
- `terms_accepted` — Flag that defines if this user has accepted EULA.
**Type**: Boolean
- `login_totp_time` — The time when the user in the current session passed TOTP verification.
**Type**: any
- `tenant_kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `tenant_pricing_model` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `brand_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
**Example**:
```json
{
"disable_after": "2017-06-22T18:25:16",
"idp_id": "e6f73a28-ff2e-4728-8f78-49eb74b20fce",
"activated": true,
"tenant_id": "0ef03214-6e47-4e50-87f2-a5955ba6095c",
"enabled": true,
"mfa_status": "setup_required",
"personal_tenant_id": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"brand_id": "a77b1af2-3ac5-576d-1db3-27b054e7d2aa",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [],
"deleted_at": "2020-05-19T11:50:00",
"email_confirmed": false,
"phone": "123456789"
},
"terms_accepted": true,
"version": 2,
"origin_id": "pillr.mdr",
"id": "948efcf2-b740-4c40-bb2d-4e4a46adfd87",
"language": "ru",
"tenant_kind": "partner",
"origin_external_id": "c66b1af2-2ac5-4764-8db6-97b054e7d27e",
"external_id": "S-1-5-21-917267712-1342860078-1792151419-500",
"created_at": "2016-06-22T18:25:16",
"business_types": [],
"login": "mylogin",
"updated_at": "2016-06-22T18:25:16",
"notifications": [
"maintenance",
"quota",
"reports",
"backup_error",
"backup_warning",
"backup_info",
"backup_daily_report",
"backup_critical",
"device_control_warning",
"certificate_management_error",
"certificate_management_warning",
"certificate_management_info"
],
"session_mfa_status": "required",
"deleted_at": null,
"tenant_pricing_model": "trial"
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_6`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "conflict",
"details": {
"info": "Conflict"
},
"message": "Conflict"
}
}
```
### Fetch User (GET /users/{user_id})
Fetches a user by ID.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `allow_deleted` | (Optional) If true, deleted users may be returned.
**Type**: Boolean
**Default**: false |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `version` — Auto-incremented entity version.
**Type**: Integer
- `tenant_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `login` — User's login.
**Type**: String
- `contact` — **Type**: Object
- `activated` — Flag, indicates whether the user has been activated or not.
**Type**: Boolean
- `enabled` — Flag, indicates whether the user is enabled or disabled.
**Type**: Boolean
- `access_policies` — Will be returned with all user access policies if query param `with_access_policies` is provided.
**Type**: Array of Object
**Array type description:**
**Type**: Object
**Min items**: 0
- `created_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `updated_at` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `deleted_at` — Soft deletion timestamp.
**Type**: any
- `language` — Preferred locale.
**Type**: String
- `idp_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
- `external_id` — User's ID in external identity provider (e.g. SID in AD).
**Type**: String
- `origin_id` — User's origin ID, for example, ID of a Cyber Application responsible for creating this user.
**Type**: String
- `origin_external_id` — User's external origin ID.
**Type**: String
- `disable_after` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `personal_tenant_id` — UUID of user's personal tenant. This field can have a null value.
**Type**: any
- `business_types` — Business types.
**Type**: Array of String
**Array type description:**
**Type**: String
**Allowed values**:
- `buyer`
- `notifications` — User notifications.
**Type**: Array of String
**Array type description:**
**Type**: String
**Allowed values**:
- `maintenance`
- `quota`
- `reports`
- `backup_error`
- `backup_warning`
- `backup_info`
- `backup_daily_report`
- `backup_critical`
- `device_control_warning`
- `certificate_management_error`
- `certificate_management_warning`
- `certificate_management_info`
- `mfa_status` — Multi-factor authentication status of the user.
**Type**: String
**Allowed values**:
- `disabled`
- `forcibly_disabled`
- `setup_required`
- `enabled`
- `session_mfa_status` — Multi-factor authentication status of the user session.
**Type**: String
**Allowed values**:
- `passed_or_not_required`
- `passed_as_trusted`
- `required`
- `external_operation_status` — Indicates if some external operation in progress for this user (his personal tenant).
**Type**: any
- `terms_accepted` — Flag that defines if this user has accepted EULA.
**Type**: Boolean
- `login_totp_time` — The time when the user in the current session passed TOTP verification.
**Type**: any
- `tenant_kind` — A tenant kind.
**Type**: String
**Allowed values**:
- `root`
- `partner`
- `folder`
- `customer`
- `unit`
- `tenant_pricing_model` — Mode of tenant's pricing.
**Type**: String
**Allowed values**:
- `trial`
- `production`
- `suspended`
- `brand_id` — **Type**: String
**Min length**: 36
**Max length**: 36
**Pattern**: `[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}`
**Example**:
```json
{
"disable_after": "2017-06-22T18:25:16",
"idp_id": "e6f73a28-ff2e-4728-8f78-49eb74b20fce",
"activated": true,
"tenant_id": "0ef03214-6e47-4e50-87f2-a5955ba6095c",
"enabled": true,
"mfa_status": "setup_required",
"personal_tenant_id": "2f8ad2e2-28f2-11e7-aad1-5ffe2ad47151",
"brand_id": "a77b1af2-3ac5-576d-1db3-27b054e7d2aa",
"contact": {
"website": "",
"city": "Rivertown",
"zipcode": "12345",
"aan": "111111",
"email": "me@mysite.com",
"state": "CA",
"firstname": "John",
"industry": "",
"country": "USA",
"address2": "",
"lastname": "Doe",
"organization_size": "",
"id": "27f6f164-63dd-47df-b5b6-83a0fd117beb",
"address1": "1440 River Drive #100",
"created_at": "2020-05-19T11:50:00",
"title": "",
"updated_at": "2020-05-19T11:50:00",
"types": [],
"deleted_at": "2020-05-19T11:50:00",
"email_confirmed": false,
"phone": "123456789"
},
"terms_accepted": true,
"version": 2,
"origin_id": "pillr.mdr",
"id": "948efcf2-b740-4c40-bb2d-4e4a46adfd87",
"language": "ru",
"tenant_kind": "partner",
"origin_external_id": "c66b1af2-2ac5-4764-8db6-97b054e7d27e",
"external_id": "S-1-5-21-917267712-1342860078-1792151419-500",
"created_at": "2016-06-22T18:25:16",
"business_types": [],
"login": "mylogin",
"updated_at": "2016-06-22T18:25:16",
"notifications": [
"maintenance",
"quota",
"reports",
"backup_error",
"backup_warning",
"backup_info",
"backup_daily_report",
"backup_critical",
"device_control_warning",
"certificate_management_error",
"certificate_management_warning",
"certificate_management_info"
],
"session_mfa_status": "required",
"deleted_at": null,
"tenant_pricing_model": "trial"
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Fetch User Access Policies (GET /users/{user_id}/access_policies)
Fetches a list of user's access policies.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_viewer`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `includeUserGroupPolicies` | (Optional) If set true, security group policies will be included in response.
**Type**: Boolean |
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `paging` — **Type**: Object
- `timestamp` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"trustee_type": "user",
"trustee_id": "2a0402b8-3867-4578-8ebc-e874a2864e79",
"tenant_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"resource_namespace": "hci",
"resource_path": "res1",
"role_id": "hci_admin",
"resource_server_id": "53a2a450-8e4e-11e7-96dd-f45c89947331",
"version": 0,
"id": "00000000-0000-0000-0000-000000000005",
"created_at": "1970-01-01T00:00:00Z",
"updated_at": "2022-03-22T21:45:47Z",
"issuer_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"deleted_at": null
},
{
"trustee_type": "user",
"trustee_id": "2a0402b8-3867-4578-8ebc-e874a2864e79",
"tenant_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"resource_namespace": "notary",
"resource_path": "res4/res5",
"role_id": "notary_admin",
"resource_server_id": "53a2a450-8e4e-11e7-96dd-f45c89947331",
"version": 0,
"id": "00000000-0000-0000-0000-000000000004",
"created_at": "1970-01-01T00:00:00Z",
"updated_at": "2022-03-22T21:45:47Z",
"issuer_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"deleted_at": null
},
{
"trustee_type": "user",
"trustee_id": "2a0402b8-3867-4578-8ebc-e874a2864e79",
"tenant_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"resource_namespace": "physical_data_shipping",
"resource_path": "res4/res5",
"role_id": "pds_operator",
"resource_server_id": "53a2a450-8e4e-11e7-96dd-f45c89947331",
"version": 0,
"id": "00000000-0000-0000-0000-000000000002",
"created_at": "1970-01-01T00:00:00Z",
"updated_at": "2022-03-22T21:45:47Z",
"issuer_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"deleted_at": null
},
{
"trustee_type": "user",
"trustee_id": "2a0402b8-3867-4578-8ebc-e874a2864e79",
"tenant_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"resource_namespace": "physical_data_shipping",
"resource_path": "res4/res5",
"role_id": "pds_support",
"resource_server_id": "53a2a450-8e4e-11e7-96dd-f45c89947331",
"version": 0,
"id": "00000000-0000-0000-0000-000000000003",
"created_at": "1970-01-01T00:00:00Z",
"updated_at": "2022-03-22T21:45:47Z",
"issuer_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"deleted_at": null
}
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Update User Access Policies (PUT /users/{user_id}/access_policies)
Rewrites user's access policies.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::user_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `paging` — **Type**: Object
- `timestamp` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"trustee_type": "user",
"trustee_id": "2a0402b8-3867-4578-8ebc-e874a2864e79",
"tenant_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"resource_namespace": "hci",
"resource_path": "res1",
"role_id": "hci_admin",
"resource_server_id": "53a2a450-8e4e-11e7-96dd-f45c89947331",
"version": 0,
"id": "00000000-0000-0000-0000-000000000005",
"created_at": "1970-01-01T00:00:00Z",
"updated_at": "2022-03-22T21:45:47Z",
"issuer_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"deleted_at": null
},
{
"trustee_type": "user",
"trustee_id": "2a0402b8-3867-4578-8ebc-e874a2864e79",
"tenant_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"resource_namespace": "notary",
"resource_path": "res4/res5",
"role_id": "notary_admin",
"resource_server_id": "53a2a450-8e4e-11e7-96dd-f45c89947331",
"version": 0,
"id": "00000000-0000-0000-0000-000000000004",
"created_at": "1970-01-01T00:00:00Z",
"updated_at": "2022-03-22T21:45:47Z",
"issuer_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"deleted_at": null
},
{
"trustee_type": "user",
"trustee_id": "2a0402b8-3867-4578-8ebc-e874a2864e79",
"tenant_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"resource_namespace": "physical_data_shipping",
"resource_path": "res4/res5",
"role_id": "pds_operator",
"resource_server_id": "53a2a450-8e4e-11e7-96dd-f45c89947331",
"version": 0,
"id": "00000000-0000-0000-0000-000000000002",
"created_at": "1970-01-01T00:00:00Z",
"updated_at": "2022-03-22T21:45:47Z",
"issuer_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"deleted_at": null
},
{
"trustee_type": "user",
"trustee_id": "2a0402b8-3867-4578-8ebc-e874a2864e79",
"tenant_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"resource_namespace": "physical_data_shipping",
"resource_path": "res4/res5",
"role_id": "pds_support",
"resource_server_id": "53a2a450-8e4e-11e7-96dd-f45c89947331",
"version": 0,
"id": "00000000-0000-0000-0000-000000000003",
"created_at": "1970-01-01T00:00:00Z",
"updated_at": "2022-03-22T21:45:47Z",
"issuer_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"deleted_at": null
}
]
}
```
#### Responses
##### `200` — The request was successful.
**Media type**: `application/json`
- `paging` — **Type**: Object
- `timestamp` — RFC3339 Formatted date.
**Type**: String
**Min length**: 19
**Max length**: 32
**Pattern**: `\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?([\+\-]\d{2}\:\d{2})?`
- `items` — **Type**: Array of Object
**Array type description:**
**Type**: Object
**Example**:
```json
{
"timestamp": "2016-06-22T18:25:16",
"items": [
{
"trustee_type": "user",
"trustee_id": "2a0402b8-3867-4578-8ebc-e874a2864e79",
"tenant_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"resource_namespace": "hci",
"resource_path": "res1",
"role_id": "hci_admin",
"resource_server_id": "53a2a450-8e4e-11e7-96dd-f45c89947331",
"version": 0,
"id": "00000000-0000-0000-0000-000000000005",
"created_at": "1970-01-01T00:00:00Z",
"updated_at": "2022-03-22T21:45:47Z",
"issuer_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"deleted_at": null
},
{
"trustee_type": "user",
"trustee_id": "2a0402b8-3867-4578-8ebc-e874a2864e79",
"tenant_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"resource_namespace": "notary",
"resource_path": "res4/res5",
"role_id": "notary_admin",
"resource_server_id": "53a2a450-8e4e-11e7-96dd-f45c89947331",
"version": 0,
"id": "00000000-0000-0000-0000-000000000004",
"created_at": "1970-01-01T00:00:00Z",
"updated_at": "2022-03-22T21:45:47Z",
"issuer_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"deleted_at": null
},
{
"trustee_type": "user",
"trustee_id": "2a0402b8-3867-4578-8ebc-e874a2864e79",
"tenant_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"resource_namespace": "physical_data_shipping",
"resource_path": "res4/res5",
"role_id": "pds_operator",
"resource_server_id": "53a2a450-8e4e-11e7-96dd-f45c89947331",
"version": 0,
"id": "00000000-0000-0000-0000-000000000002",
"created_at": "1970-01-01T00:00:00Z",
"updated_at": "2022-03-22T21:45:47Z",
"issuer_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"deleted_at": null
},
{
"trustee_type": "user",
"trustee_id": "2a0402b8-3867-4578-8ebc-e874a2864e79",
"tenant_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"resource_namespace": "physical_data_shipping",
"resource_path": "res4/res5",
"role_id": "pds_support",
"resource_server_id": "53a2a450-8e4e-11e7-96dd-f45c89947331",
"version": 0,
"id": "00000000-0000-0000-0000-000000000003",
"created_at": "1970-01-01T00:00:00Z",
"updated_at": "2022-03-22T21:45:47Z",
"issuer_id": "b7028817-d180-44c1-ae3d-b99f4b3f844a",
"deleted_at": null
}
]
}
```
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `415` — Requested type in the `Accept` request header is not supported.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_4`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": "invalid_content_type",
"details": {
"info": "Content must be JSON"
},
"message": "Content must be JSON"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_5`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1010,
"details": {
"info": "user with specified login already exists in same tenant"
},
"message": "conflict"
}
}
```
### Manage User MFA Status (PUT /users/{user_id}/mfa/status)
Manages MFA status for the user.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `enabled` — Status of MFA for user.
**Type**: Boolean
**Example**:
```json
{
"enabled": true
}
```
#### Responses
##### `200` — MFA settings status was successfully changed.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_0`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "unauthorized",
"details": {
"info": "Authentication is required"
},
"message": "Authentication is required"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": "access_denied",
"details": {
"info": "Access is denied"
},
"message": "Access is denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {
"id": "f313ecf6-9256-4afd-9d47-72e032ee81d0"
},
"code": "application_not_found",
"details": {
"info": "Application f313ecf6-9256-4afd-9d47-72e032ee81d0 was not found"
},
"message": "Application was not found"
}
}
```
##### `400` — Bad request.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_3`*:
```json
{
"error": {
"domain": "PlatformAccountServer",
"context": {},
"code": 400,
"details": {
"info": "Bad Request"
},
"message": "Bad Request"
}
}
```
### Set User Password (POST /users/{user_id}/password)
This method can be accessed only by OAuth 2.0 / OpenID Connect client.
Sets user's password.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::user_admin`
#### Request parameters
##### Request body
**Media type**: `application/json`
- `password` — Password.
**Type**: String
**Example**:
```json
{
"password": "testSECRETpassword123"
}
```
#### Responses
##### `204` — Password was successfully set.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
### Restore Deleted User (POST /users/{user_id}/restore)
Restores previously soft-deleted user.
#### Security
The endpoint supports the following authorization methods: `x-api-key`, `Basic Authentication`, `OAuth 2.0`
For OAuth2 authorization method, one of the following scopes is required by the endpoint:
* `urn:acronis.com::account-server::tenant_admin`
#### Request parameters
##### Query parameters
| Name | Description |
|------|-------------|
| `force` | (Optional) Defines if the user should be restored in case of a conflict with another user who has taken the same login.
In such a case restored user will have a postfix added.
**Type**: Boolean |
| `enable` | (Optional) Defines if the user should be re-enabled.
**Type**: Boolean |
#### Responses
##### `204` — User was successfully restored.
##### `401` — Method required an authenticated user.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1000,
"details": {
"info": "cannot switch session to user with different identity"
},
"message": "unauthorized"
}
}
```
##### `403` — Current user is not authorized to access this endpoint or its method.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_1`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1002,
"details": {
"info": "can not change access policies for self"
},
"message": "access denied"
}
}
```
##### `404` — Not Found.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_2`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1104,
"details": {
"info": "could not resolve target tenant: not found"
},
"message": "could not resolve target tenant"
}
}
```
##### `409` — Another object of the same type already exists.
**Media type**: `application/json`
- `error` — **Type**: Object
**Example**:
*`example_5`*:
```json
{
"error": {
"domain": "ApplicationAccountServer",
"context": {},
"code": 1010,
"details": {
"info": "user with specified login already exists in same tenant"
},
"message": "conflict"
}
}
```