Help Center
Choose product document...
Veeam Availability Orchestrator 2.0
REST API Reference

Getting Authorization Tokens

VAO REST API authorization with Swagger UI involves the following procedures:

  1. Obtain a pair of tokens:
  1. On the Veeam Availability Orchestrator REST API page, expand the Accounts resource and click POST /v2/Token.
  2. From the grant_type drop-down list, select password (default).
  3. In the username and password fields, specify the credentials of an account with the VAO Administrator or Plan Author privileges.
  4. Click Try it out.

Getting Authorization Token

Wait for the response from the server. A successfully completed operation returns the 200 Success response code. In the response body, VAO returns an access token, a refresh token and a client ID.

Getting Authorization Token - Server Response

  1. Save the refresh token and client ID locally for further use.

Getting Authorization Tokens Tip:

If you lose the refresh token, you can log in again under the same user account and get a new pair of tokens. In this case, the client ID will remain the same and you will be able to continue working under the same client account.

  1. Make sure that the access token is automatically inserted in the api_key field at the top of the page.
  2. At the top of the page, in the api_key field, click Explore.

Using Authorization Token

  1. [Applies only if a dedicated child client account is required]

Generate a child client account:

  1. On the Veeam Availability Orchestrator REST API page, expand the Accounts resource and click POST /v2/Clients.
  2. Click Try it out.

Getting Child Client

Wait for the response from the server. A successfully completed operation returns the 200 Success response code. In the response body, VAO returns a child client ID and client secret.

  1. Save the child client ID and client secret locally for further use.

Getting Authorization Tokens Note:

If you lose the client secret, you will have to create a new child client account. The child client whose client secret was lost become useless and can be deleted by the root client.

  1. [Applies only if a dedicated child client account is required]

Obtain an access under the child client account:

  1. On the Veeam Availability Orchestrator REST API page, expand the Accounts resource and click POST /v2/Token.
  2. From the grant_type drop-down list, select client_credentials.
  3. In the client_id and client_secret fields, specify the credentials of the child client account.
  4. Click Try it out.

Getting Tokens for Child Client

Wait for the response from the server. A successfully completed operation returns the 200 Success response code. In the response body, VAO returns access and refresh tokens.

  1. Save the refresh token locally for further use.

Getting Authorization Tokens Tip:

If you lose the refresh token, you can log in again under the same client ID and client secret. In this case, you will get a new pair of tokens.

  1. Make sure that the access token is automatically inserted in the api_key field at the top of the page.
  2. At the top of the page, in the api_key field, click Explore.
  1. When the access token expires, use the refresh token:
  1. On the Veeam Availability Orchestrator REST API page, expand the Accounts resource and click POST /v2/Token.
  2. From the grant_type drop-down list, select refresh_token.
  3. In the client_id field, insert the ID of the client whose token has expired.
  4. In the refresh_token field, insert the refresh token saved locally.
  5. Click Try it out.

Using Refresh Token

Wait for the response from the server. A successfully completed operation returns the 200 Success response code and a new pair of tokens in the response body.

  1. Get the root client ID and all child client IDs related to this root client account:
  1. On the Veeam Availability Orchestrator REST API page, expand the Accounts resource and click GET /v2/Clients.
  2. Click Try it out.

Getting Client IDs

прапро

Getting Authorization Tokens Note:

A child client account can get only its own ID.

  1. When the client finishes working with VAO REST API, the client account can be deleted:
  1. On the Veeam Availability Orchestrator REST API page, expand the Accounts resource and click DELETE /v2/Clients.
  1. In the client_id field, insert the ID of the client that you want to delete.
  1. Click Try it out.

Deleting Client

Wait for the response from the server. A successfully completed operation returns the 200 Success response code.

Related Topics

Authorization and Security

Veeam Large Logo

User Guide

Deployment Guide

Group Management Guide

REST API Reference