HTTP details
The Cloud Manager platform REST APIs are based on the HTTP protocol as well as JSON for content exchange. This section describes the details of how HTTP is used.
Request
HTTP methods
The HTTP methods supported by the Cloud Manager platform REST APIs are shown in the following table. Not all HTTP methods are available at each of the REST endpoints. For more information, see the reference documentation for the specific API you are using.
HTTP method | Description |
---|---|
GET |
Retrieves object properties for a resource instance or collection of resources. |
POST |
Creates a new resource instance based on the supplied input values. |
PUT |
Updates an existing resource instance based on the supplied input values. |
PATCH |
Updates specific fields of an existing resource instance based on the supplied input values. |
DELETE |
Deletes an existing resource instance. |
Request headers
The common HTTP request headers are described below.
Request header | Description |
---|---|
Authorization |
This header contains a bearer token used to access the Cloud Manager server. |
x-agent-id |
The agent identifier is based on the client ID and is used to identify the user agent. |
Content-Type |
This representation header is used to indicate the original media type of the resource. |
Accept |
The server automatically returns content in JSON format if Accept header is not specified. |
Response
HTTP status codes
The common HTTP status codes are described below.
Status code | Reason Phrase | Description |
---|---|---|
200 |
OK |
The request was completed successfully. |
202 |
Accepted |
The request was accepted and is currently in process. Cloud Manager returns this code when the API call operates asynchronously. For example, the |
204 |
No Content |
The operation was completed successfully and the server did not send a response message. |
400 |
Bad Request |
The request input is not recognized or is inappropriate. An error response explains the reason. |
401 |
Unauthorized |
The user has not authenticated. |
403 |
Forbidden |
This operation is not allowed for the current authenticated user. |
409 |
Conflict |
The operation failed because another operation is already in progress. |
420 |
--- |
Cloud Manager has not been set up. You must set up Cloud Manager using the API call /occm/setup/init |
5xx |
--- |
An unexpected error occurred within the Cloud Manager server which has prevented it from fulfilling the request. |