Get UUIDs

A UUID (Universally Unique IDentifier) is a unique ID for a component in your system. Some maintenance and configuration tasks for Private Cloud require you to use the UUID of a component.

This section shows multiple methods you can use to get UUIDs of Private Cloud components.

Use the management API

To get the UUID for Private Cloud components with the management API, use the following API calls:

Component API call
Router
curl http://router_IP:8081/v1/servers/self
Message Processor
curl http://mp_IP:8082/v1/servers/self
Qpid
curl http://qp_IP:8083/v1/servers/self
Postgres
curl http://pg_IP:8084/v1/servers/self

Note that the port numbers are different, depending on which component you call.

If you call the API from the machine itself, then you do not need to specify a username and password. If you call the API remotely, you must specify the Edge administrator's username and password, as the following example shows:

curl http://10.1.1.0:8081/v1/servers/self -u user@example.com:abcd1234 \
  -H "Accept:application/xml"

Each of these calls returns a JSON object that contains details about the service. The uUID property specifies the service's UUID, as the following example shows:

{
  "buildInfo" : {
    ...
  },
  ...
  "tags" : {
    ...
  },
  "type" : [ "router" ],
  "uUID" : "71ad42fb-abd1-4242-b795-3ef29342fc42"
}

You can optionally set the Accept header to application/xml to instruct apigee-adminapi.sh to return XML rather than JSON. For example:

/opt/apigee/apigee-adminapi/bin/apigee-adminapi.sh servers list --admin user@example.com \
  --pwd abcd1234 --host localhost -H "Accept:application/xml"

Use apigee-adminapi.sh

You can get the UUIDs of some components by using the servers list option of the apigee-adminapi.sh utility. To get UUIDs with apigee-adminapi.sh, use the following syntax:

/opt/apigee/apigee-adminapi/bin/apigee-adminapi.sh servers list \
  --admin admin_email_address --pwd admin_password --host edge_server

Where:

  • admin_email_address is the email address of the Edge administrator.
  • admin_password is the Edge administrator's password.
  • edge_server is the IP address of the server from which you want a list. If you are logged into the server, you can use localhost.

For example:

/opt/apigee/apigee-adminapi/bin/apigee-adminapi.sh servers list --admin user@example.com --pwd abcd1234 --host localhost

This command returns a complex JSON object that specifies the same properties for each service as the management API calls.

As with the management API calls, you can optionally set the Accept header to application/xml to instruct apigee-adminapi.sh to return XML rather than JSON. For example:

/opt/apigee/apigee-adminapi/bin/apigee-adminapi.sh servers list --admin user@example.com \
  --pwd abcd1234 --host localhost -H "Accept:application/xml"