Create or update image metadata item
Method | URI | Description |
---|---|---|
PUT | /v2/{tenant_id}/images/{image_id}/metadata/{key} | Creates or updates the metadata items (identified by key) of the specified image. |
An overLimit (413) fault might be thrown if the operation causes the quota for metadata items to be exceeded.
Normal response codes: 200
CAUTION:
Metadata cannot be changed for images that do not have a checksum set. Refer to "Update an image" for details on how to change the metadata for images that do not have a checksum set.
Request
This table shows the URI parameters for the create or update image metadata item
Name | Type | Description |
---|---|---|
{tenant_id} | UUID | Project ID |
{image_id} | UUID | The UUID for the image. |
{key} | Image Metadata Key |
A string. Maximum length is 255 characters. |
Example. Create or update image metadata item: JSON request
{
"meta": {
"auto_disk_config": "True",
"Label": "Changed"
}
}
Response
Example. Create or update image metadata item: JSON response
{
"meta": {
"Label": "Changed",
"auto_disk_config": "True"
}
}