UpCloud

Object Storage Labels

Labels are key-value pairs that help you organize and categorize object storage services. Use labels to filter services, apply policies, or track resources across your infrastructure.


GET/1.3/object-storage-2/{service_uuid}/labels

List labels

Returns a list of all labels for an object storage service.

Request

GET
/1.3/object-storage-2/{service_uuid}/labels
curl -X GET https://api.upcloud.com/1.3/object-storage-2/06e1bf60-2a3b-4c5d-9e7f-8a1b2c3d4e5f/labels \
  -u your_username:your_password

GET/1.3/object-storage-2/{service_uuid}/labels/{key}

Get label details

Returns details of a specific label.

Request

GET
/1.3/object-storage-2/{service_uuid}/labels/{key}
curl -X GET https://api.upcloud.com/1.3/object-storage-2/06e1bf60-2a3b-4c5d-9e7f-8a1b2c3d4e5f/labels/environment \
  -u your_username:your_password

POST/1.3/object-storage-2/{service_uuid}/labels

Create label

Creates a new label for an object storage service.

Attributes

  • Name
    key
    Type
    string
    Description

    Label key (1-255 chars, alphanumeric with - and _).

  • Name
    value
    Type
    string
    Description

    Label value (1-255 chars).

Request

POST
/1.3/object-storage-2/{service_uuid}/labels
curl -X POST https://api.upcloud.com/1.3/object-storage-2/06e1bf60-2a3b-4c5d-9e7f-8a1b2c3d4e5f/labels \
  -u your_username:your_password \
  -H "Content-Type: application/json" \
  -d '{
    "key": "project",
    "value": "analytics"
  }'

PATCH/1.3/object-storage-2/{service_uuid}/labels/{key}

Modify label

Modifies an existing label's value.

Attributes

  • Name
    value
    Type
    string
    Description

    Updated label value.

Request

PATCH
/1.3/object-storage-2/{service_uuid}/labels/{key}
curl -X PATCH https://api.upcloud.com/1.3/object-storage-2/06e1bf60-2a3b-4c5d-9e7f-8a1b2c3d4e5f/labels/environment \
  -u your_username:your_password \
  -H "Content-Type: application/json" \
  -d '{
    "value": "staging"
  }'

DELETE/1.3/object-storage-2/{service_uuid}/labels/{key}

Delete label

Deletes a label from an object storage service.

Request

DELETE
/1.3/object-storage-2/{service_uuid}/labels/{key}
curl -X DELETE https://api.upcloud.com/1.3/object-storage-2/06e1bf60-2a3b-4c5d-9e7f-8a1b2c3d4e5f/labels/project \
  -u your_username:your_password