All Products
Search
Document Center

Drive and Photo Service:UpdateDrive

Last Updated:Mar 26, 2026

Modifies a drive.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request syntax

POST /v2/drive/update HTTP/1.1

Request parameters

Parameter

Type

Required

Description

Example

body

object

No

The request parameters.

drive_id

string

Yes

The drive ID.

1

drive_name

string

No

The name of the drive. The name can be up to 128 characters in length.

My personal space

description

string

No

The description of the drive. The description can be up to 1,024 characters in length.

VIP space

status

string

No

The state of the drive. Valid values:

enabled and disabled.

Valid values:

  • disabled :

    Disabled

  • enabled :

    Enabled

enabled

total_size

integer

No

The total size of the drive. Unit: bytes. A value of -1 specifies that the size is unlimited.

10240

owner

string

No

The owner of the drive. Note: You can modify the owner of a personal drive only by using an AccessKey pair.

user1

Response elements

Element

Type

Description

Example

Drive

The response parameters.

Examples

Success response

JSON format

{
  "domain_id": "bj1",
  "drive_id": "1",
  "drive_name": "drv1",
  "description": "vipdrive",
  "owner": "c9b7a5aa04d14ae3867fdc886fa01da4",
  "owner_type": "user",
  "drive_type": "normal",
  "status": "enabled",
  "used_size": 20480,
  "total_size": 204800,
  "created_at": "2019-08-20T06:51:27.292Z",
  "creator": "c9b7a5aa04d14ae3867fdc886fa01da4"
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.