Bind a Tag to DCC
Last Updated:2020-09-29
Bind a Tag to a DCC
Description
It is used to bind the same tag to a DCC and its all sub-instances.
Request structure
PUT /v{version}/dedicatedHost/{dccId}/tag?bind
Host: dcc.bj.baidubce.com
Authorization authorization string
Request Body
{
"changeTags": [
{
"tagKey": "aaa",
"tagValue": "111"
},
{
"tagKey": "bbb",
"tagValue": "222"
}
]
}
Request header field
No other special header fields are available, except for common header fields.
Request parameters
Parameter Name | Type | Required | Parameter position | Description |
---|---|---|---|---|
version | String | Yes | URI parameter | API version number |
dccId | String | Yes | URI parameter | Specified DCC id |
changeTags | Array | Yes | Request Body parameter | An array of tags, each of which is composed of the tagKey and tagValue |
Return header field
No other special header fields are available, except for common header fields.
Request example
PUT /v1/dedicatedHost/d-fkIthUMd/tag?bind=%22%22&clientToken=4ec448dc595635ead81b3ac467a3dee4 HTTP/1.1
Host: dcc.bj.baidubce.com
ContentType: application/json
Authorization bce-auth-v1/4e69d28643af46dea51fef90e221eb17/2019-02-12T08:48:37Z/1800/host;x-bce-date/c64a8863b70d0f5c105b41200bfacdbae78dded2509777056c1a4677b635d63d
{
"changeTags" : [
{
"tagKey" : "aaa",
"tagValue" : "111"
},
{
"tagKey" : "bbb",
"tagValue" : "222"
}
]
}
Return example
HTTP/1.1 200 OK
x-bce-request-id: 4a05201c-f585-48c9-8656-186e7cfccab4