Querying a Specified API Version
Function
This API is used to query a specified API version of OMS.
Debugging
You can debug this API in API Explorer.
URI
GET /{version}
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| version | Yes | String | Specifies the API version. Minimum length: 1 character Maximum length: 10 characters |
Request
None
Response
Status code: 200
| Parameter | Type | Description |
|---|---|---|
| id | String | Specifies the API version, for example, v1. |
| links | Array of Link objects | Specifies the link address. |
| status | String | Specifies the version status. CURRENT: indicates a widely used version. SUPPORTED: indicates an earlier version which is still supported. DEPRECATED: indicates a deprecated version which may be deleted later. Value options are as follows:
|
| updated | String | Specifies the time when the version is updated. The format is yyyy-mm-ddThh:mm:ssZ. T is the separator between the calendar and the hourly notation of time. Z indicates the UTC. Minimum length: 0 characters Maximum length: 32 characters |
| Parameter | Type | Description |
|---|---|---|
| href | String | Specifies the link address. |
| rel | String | Its value is self, indicating that href is a local link. |
Status code: 403
| Parameter | Type | Description |
|---|---|---|
| error_msg | String | Specifies the error message. |
| error_code | String | Specifies the error code. |
Example Request
Obtain version information.
GET https://{endpoint}/v2
{
"version" : {
"links" : [ {
"rel" : "self",
"href" : "https://oms.cn-north-1.myhuaweicloud.com/v1/"
} ],
"id" : "v2",
"updated" : "2020-04-01T12:00:00Z",
"status" : "SUPPORTED"
}
} Example Response
Status code: 200
Version information
{
"links" : [ {
"rel" : "self",
"href" : "https://oms.cn-north-1.myhuaweicloud.com/v1/"
} ],
"id" : "v2",
"updated" : "2020-04-01T12:00:00Z",
"status" : "SUPPORTED"
} Status Codes
| Status Code | Description |
|---|---|
| 200 | Version information |
| 403 | Forbidden |
Error Codes
See Error Codes.
Last Article: Querying All API Versions
Next Article: Migration Task Management
Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.