Creating Resource Locations

Troubleshooting

An unsuccessful API request will return the following information in the response body:

  • Type: A link to the standard HTTP response code.
  • Details: A brief description of the error.
  • Parameters: An optional JSON object to provide extra error information.

Sample API error response

{
    "type": "404",
    "detail": "resource not found",
    "parameters":
    {
    "name": "entityType",
    "value": "the request URL"
    }
}
<!--NeedCopy-->

Response codes

The following section lists the response codes for the APIs with examples.

200 OK

  • GET/ resourcelocations

Resource locations retrieved successfully

{
  "items": [
    {
      "id": "074a22f3-428a-4094-b827-0e58b724ec83",
      "name": "ResourceLocation1",
      "internalOnly": true,
      "timeZone": "GMT Standard Time",
      "readOnly": false
    },
    {
      "id": "09651fe0-06e1-4ba8-94ce-e20f2973e32f",
      "name": "ResourceLocation2",
      "internalOnly": false,
      "timeZone": "GMT Standard Time",
      "readOnly": false
    },
    ...
  ]
}
<!--NeedCopy-->

401 Unauthorized

  • GET/ resourcelocations

Case 1: If the authorization header is empty or missing, the ‘value’ in the ‘parameters’ subschema is ‘missing’

{
    "type": "https://errors-api.cloud.com/common/authentication",
    "detail": "Missing or invalid authentication details",
    "parameters": [
        {
            "name": "reason",
            "value": "missing"
        }
    ]
}
<!--NeedCopy-->

Case 2: If the Authorization header is invalid the reason mentioned in the parameters value is invalid

{
    "type": "https://errors-api.cloud.com/common/authentication",
    "detail": "Missing or invalid authentication details",
    "parameters": [
        {
            "name": "reason",
            "value": "invalid"
        }
    ]
}
<!--NeedCopy-->

403 Forbidden

If the Authorization details are provided incorrectly in the header then following error occurs:

  • GET/ resourcelocations

Case 1: Customer (bearer token) details are not correct

{
    "type": "https://errors-api.cloud.com/common/authorization",
    "detail": "Access denied"
}
<!--NeedCopy-->

404 Not Found

  • GET/ resourcelocations

Case 1: In case the URL does not match the OpenAPI Specification

{
    "type": "https://errors-api.cloud.com/resourcelocations/notFound",
    "detail": "resource not found",
    "parameters": [
        {
            "name": "entityType",
            "value": "/resourcelocations"
        }
    ]
}
<!--NeedCopy-->

500 Internal Server Error

Report these errors directly to the engineering team to help resolve the issues. Take a note of the customer ID and Transaction ID from the customer to troubleshoot further.

  • GET/ resourcelocations

Case 1: Server Errors

{
    "type": "https://errors-api.cloud.com/resourcelocations/internalerror",
    "detail": "There was a internal issue"
}
<!--NeedCopy-->
Resources
Creating Resource Locations OpenAPI Specification
Copy Download
Troubleshooting