Skip to main content

GET /registration/countries

Use this method to return a list of country and region codes that can be used during the registration process.

Note
This REST API requires Lenovo XClarity Administrator v3.4.0 or later.

Authentication

Authentication with username and password is required.

Request URL

GET https://{management_server_IP}/registration/countries

Query parameters

None

Request body

None

Response codes

CodeDescriptionComments
200OKThe request completed successfully.
400Bad RequestA query parameter or request attribute is missing or not valid, or the operation is not supported. A descriptive error message is returned in the response body.
500Internal Server ErrorAn internal error occurred. A descriptive error message is returned in the response body.

Response body

AttributesTypeDescription
messageStringResults of the request. This can be one of the following values.
  • success. The request completed successfully.
  • failure. The request failed. A descriptive error message was returned.
bodyArray of objectsInformation about each country or region
 TextStringCountry or region name
 ValueStringTwo-letter ISO 3166 code for the country or region
The following example is returned if the request is successful.
{
"message": "succeed",
"body": [{
"Text": "ANGOLA",
"Value": "AO"
},
{
"Text": "ARGENTINA",
"Value": "AR"
},
...,
{
"Text": "ZAMBIA",
"Value": "ZM"
},
{
"Text": "ZIMBABWE",
"Value": "ZW"
}]
}