6.2

Table Of Contents
Example: Example: curl Command
The following example command deletes a reservation policy with an ID of 8adafb54-4c85-4478-86f0-
b6ae80ab5ca4.
curl –X “Delete” --insecure -H "Accept:application/json"
-H "Authorization: Bearer $token"
https://$host/reservation-service/api/reservations/policies/8adafb54-4c85-4478-86f0-b6ae80ab5ca4
Example: Example: JSON Output
If the command is successful, the HTTP response body is empty except for a 204 No Content status
statement.
Working with Key Pairs
You can work with the keyValuePair data element of the REST API workitem service to list, create, and
update key pairs.
For information about using the vRealize Automation application user interface to work with key pairs, see
the IaaS Configuration documentation.
Get a Key Pair List
You can use the vRealize Automation REST API to get a list of valid key pairs.
Prerequisites
n
Log in to vRealize Automation as a tenant administrator.
n
Verify that the host name and fully qualified domain name of the vRealize Automation instance are
available.
n
If you are not using the API Explorer, verify that you have a valid HTTP bearer token that matches
your login credentials. See Chapter 2 REST API Authentication.
Procedure
u
Use the following sample command to list all available reservation policies.
curl --insecure -H "Accept:application/json"
-H "Authorization: Bearer $token"
https://$host/iaas-proxy-provider/api/keyPairs
The following JSON output is returned based on your command input.
{
"links": [
],
"content": [
{
Programming Guide
VMware, Inc. 314