开通资源中心。
下表仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数。
const columns = [
{
width: '20%',
title: '参数',
dataIndex: 'Name',
className: 'openapi-doc-parameter-table-name'
},
{
width: 130,
title: '类型',
dataIndex: 'DataType',
className: 'openapi-doc-parameter-table-type'
},
{
width: 90,
title: '是否必填',
dataIndex: 'IsRequired',
className: 'openapi-doc-parameter-table-required'
},
{
width: '20%',
title: '示例值',
dataIndex: 'Example',
className: 'openapi-doc-parameter-table-example'
},
{
title: '描述',
dataIndex: 'Description',
className: 'openapi-doc-parameter-table-description'
},
];
const data = [
{
rowKey: '->Action',
Name: 'Action',
DataType: 'String',
IsRequired: '是',
Example: <RenderMd content={"EnableResourceCenter"} />,
Description: <RenderMd content={"要执行的操作,取值:EnableResourceCenter。"} />,
children: [
]
},
{
rowKey: '->Version',
Name: 'Version',
DataType: 'String',
IsRequired: '是',
Example: <RenderMd content={"2023-06-01"} />,
Description: <RenderMd content={"API的版本,取值:2023-06-01。"} />,
children: [
]
},
];
return (<Table
rowKey="rowKey"
className="openapi-doc-parameter-table"
columns={columns}
data={data}
border={ { cell: true, wrapper: true } }
scroll={ { x: "auto" } }
pagination={false}
/>);
本接口无特有的返回参数。更多信息请见返回结构。
GET /?Action=EnableResourceCenter&Version=2023-06-01 HTTP/1.1
Host: resourcecenter.volcengineapi.com
X-Date: 20240614T040318Z
Authorization: HMAC-SHA256 Credential=Adfks******wekfwe/20240614/cn-beijing/resourcecenter/request, SignedHeaders=host;x-date, Signature=47a7d934ff7b37c03938******cd7b8278a40a1057690c401e92246a0e41085f
{
"ResponseMetadata": {
"RequestId": "2024061412033612AA6B68D16DA612B048",
"Action": "EnableResourceCenter",
"Version": "2023-06-01",
"Service": "resourcecenter",
"Region": "cn-beijing"
}
}
下表为您列举了该接口与业务逻辑相关的错误码。公共错误码请参见公共错误码文档。
const columns = [
{
title: '状态码',
dataIndex: 'HttpCode',
width: '12%',
className: 'openapi-doc-errorcode-table-httpcode'
},
{
title: '错误码',
dataIndex: 'ErrorCode',
width: '22%',
className: 'openapi-doc-errorcode-table-errorcode'
},
{
title: '错误信息',
dataIndex: 'ErrorMessage',
width: '33%',
className: 'openapi-doc-errorcode-table-errormessage'
},
{
title: '说明',
dataIndex: 'Description',
width: '33%',
className: 'openapi-doc-errorcode-table-description'
},
];
const data = [
{
HttpCode: 404,
ErrorCode: 'RoleNotExist',
ErrorMessage: <RenderMd content={"Role '{{.Role}}' does not exist."} />,
Description: <RenderMd content={""} />,
},
{
HttpCode: 500,
ErrorCode: 'InternalError',
ErrorMessage: <RenderMd content={"The request has failed due to an unknown error."} />,
Description: <RenderMd content={"内部服务错误,请稍后重试"} />,
},
];
return (<Table
columns={columns}
data={data}
border={ { cell: true, wrapper: true } }
scroll={ { x: "auto" } }
pagination={false}
/>);