7.3

Table Of Contents
If the credentials supplied in the Authorization header are invalid, the response includes status code 401
as in the following output.
<!DOCTYPE html><html><head><title>Error report</title></head><body><h1>HTTP Status 401 -
Authentication required</h1></body></html>
Syntax for Requesting an HTTP Bearer Token
An HTTP bearer token is required by the REST client to use the vRealize Automation REST API. You
obtain a bearer token by authenticating to the identity service.
Input
Use the supported input parameters to control the command output.
Parameter Description
URL https://$vRA/identity/api/tokens
$vRA appliance name.domain name of the vRealize Automation server.
usrname Tenant administrator user name.
passwd Tenant administrator password.
tenantURLtoken Tenant URL token determined by the system administrator when creating the tenant such
as, support.
Output
The following information is displayed as a result of your HTTP bearer token request.
Parameter Description
expires Contains the ISO 8601 timestamp indicating when the token expires.
id Contains the HTTP bearer token to use in Authorization header in subsequent requests.
tenant Displays the tenant ID associated with the token.
Response Status Codes
One of the following codes are displayed as a result of your HTTP bearer token request.
Status Code Description
200 OK Your request succeeded and the resource was updated. The
response body contains the full representation of the resource.
400 BAD REQUEST The data you provided in the POST failed validation. Inspect the
response body for details.
401 UNAUTHORIZED The request could not authenticate the user or authentication
credentials required.
Programming Guide
VMware, Inc. 16