Responses

Last updated:2021-05-27 17:52:42

API responses use the HTTP response format where a 200 status code indicates a successful call and a 4xx or 5xx status code indicates a failed call.

The responses for Kingsoft Cloud Billing Center API operations can be returned in either the XML or JSON format. The default response format is XML. You can change the response format to JSON by setting the HTTP header Accept=application/json.

Sample success responses

  • XML format

<API operation name+Response>
    <RequestId>4C467B38-3910-447D-87BC-AC049166F216</RequestId>
    
</API operation name+Response>
  • JSON format
{
    "RequestId": "4C467B38-3910-447D-87BC-AC049166F216"
    /*Return result data*/
}

Sample error responses

If an API operation fails to be called, no result data is returned. Instead, a 4xx or 5xx HTTP status code is returned. The returned HTTP response body contains the specific error code and error message, and the request ID. If you cannot locate the error cause, contact Kingsoft Cloud customer service and provide the request ID for help.

  • XML format

<ErrorResponse> 
    <RequestId>e1eac1b3-1f35-44ba-abd4-7c4b7a9859f3</RequestId>
    
    <Error>
        
        <Type>Sender</Type>
        
        <code>InvalidParameterValue</code>
        
        <Message>An invalid or out-of-range value was supplied for the input parameter PathPrefix.</Message>
    </Error>
<ErrorResponse>
  • JSON format
{    
    "RequestId": "68093a99-2f63-4f39-8f70-3047ab8ecb5b",
    "Error": {
        "Code": "InvalidParameterValue",
        "Message": "An invalid or out-of-range value was supplied for the input parameter PathPrefix."    
    }
}

Did you find the above information helpful?

Unhelpful
Mostly Unhelpful
A little helpful
Helpful
Very helpful

What might be the problems?

Insufficient
Outdated
Unclear or awkward
Redundant or clumsy
Lack of context for the complex system or functionality

More suggestions

0/200

Please give us your feedback.

Submitted

Thank you for your feedback.

问题反馈