• Native OpenStack API

noa
  1. Help Center
  2. Native OpenStack API
  3. API Reference
  4. Cinder V3 Interfaces
  5. Snapshot
  6. Update Snapshot Metadata

Update Snapshot Metadata

Function Description

This interface is used to update metadata of a snapshot.

In cascading scenarios, metadata of a snapshot is delivered by cinder-proxy to the cascaded layer and updated.

Interface Format

Method

URI

Description

PUT

/v3/{project_id}/snapshots/{snapshot_id}/metadata

Updates metadata of a snapshot.

Restrictions

N/A

Expanded Interface

N/A

Request Parameter

Parameter

Type

Mandatory

Remarks

metadata

Dict

Yes

Specifies the volume metadata. Ensure that key and value in the metadata contain fewer than 255 characters.

Response Parameter

Parameter

Type

Mandatory

Remarks

metadata

Dict

Yes

Metadata of a volume

Request Example

PUT https://volume.localdomain.com:8776/v3/5f13ecc9281d4c34bd740f277620bdee/snapshots/d23a846b-0c0c-427a-a490-84331c33c52f/metadata/d23a846b-0c0c-427a-a490-84331c33c52f/metadata
{
"metadata": {
           "testkey1": "testvalue1", 
           "testkey2": "testvalue2"
          }
}

Response Example

{
"metadata": {
           "testkey1": "testvalue1", 
           "testkey2": "testvalue2",
           }
}

Error Code

See section Processing Return Code.