错误说明
字段说明
字段 | 类型 | 说明 |
---|---|---|
code | integer | 错误码 |
message | string | 错误信息 |
details | array | 错误细节 |
其中 details
中每个元素的字段如下:
字段 | 类型 | 说明 |
---|---|---|
@type | string | 序列化消息的类型 |
reason | string | 错误具体原因 |
- 错误响应示例:
{
"code": 5,
"message": "sandbox not found",
"details": [
{
"@type": "type.googleapis.com/google.rpc.ErrorInfo",
"reason": "sandbox not found: bd14c488-6db8-42ba-8dde-789a64a85b3b",
"domain": "",
"metadata": {}
}
]
}
错误码信息
code | http code | 错误说明 |
---|---|---|
1 | 408 | 用户主动取消。 |
| 3 | 400 | 参数错误。 |
| 4 | 504 | 服务返回超时。 |
| 5 | 404 | 资源不存在。 |
| 6 | 409 | 资源已存在。 |
| 7 | 403 | 鉴权错误。 |
| 13 | 500 | 内部错误。 |
| 16 | 401 | 认证错误。 |