Creates a drive.
Debugging
Authorization information
Request syntax
POST /v2/drive/create HTTP/1.1
Request parameters
Parameter | Type | Required | Description | Example |
---|
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
body | object | No | The request parameters. | |
drive_name | string | Yes | The name of the drive. The name can be up to 128 characters in length. | test_drive |
owner | string | Yes | The owner of the drive. | 3b3d7245c159488da17d081ad6c64687 |
owner_type | string | Yes | The type of the owner. Valid values: user and group. | user |
description | string | No | The description of the drive. The description can be up to 1,024 characters in length. | drive for test |
drive_type | string | No | The type of the drive. Set the value to normal. | normal |
status | string | No | The state of the drive. Valid values: enabled and disabled. Default value: enabled. | enabled |
total_size | long | No | The total size of the drive. Unit: bytes. By default, the size is unlimited. | 1024 |
default | boolean | No | Specifies whether the drive is the default drive. Default value: false. | true |
Response parameters
Examples
Sample success responses
JSON
format
{
"domain_id": "bj1",
"drive_id": "1"
}
Error codes
For a list of error codes, visit the Service error codes.