Query the full path of the volume

Get the hierarchical path consisting of the target volume and its superior volumes. This path does not include catalog and database hierarchies.

HTTP
POST $CLOUDSIGMA_API_BASE/catalog/volume/full_path

Before you call

Configure the CloudSigma regional endpoint and authentication before calling. The endpoint, credentials, workspace, and resource IDs must belong to the same region. First query the object in the database to obtain the target volume ID. Prepare the personal access token, target workspace ID, and volume ID that can access the target workspace.

Request body

Shell
curl -X POST "$CLOUDSIGMA_API_BASE/catalog/volume/full_path" \
  -H "X-API-Key: $CLOUDSIGMA_API_KEY" \
  -H "X-Workspace-ID: $WORKSPACE_ID" \
  -H 'Content-Type: application/json' \
  -d '{
    "id": '"$VOLUME_ID"'
  }'

Field

Type

Required

Description

id

integer

Yes

Volume ID.

Successful response

JSON
{
  "code": "OK",
  "msg": "OK",
  "data": {
    "path": "sales/catalog_a/db_a/sales_files"
  }
}

Field

Type

Description

code

string

OK on success.

msg

string

OK on success.

data.path

string

Volume level name path. Names may be localized. The maximum traceback level is 100, and will be truncated when exceeded. Please use the volume ID for positioning and permission determination.

Error response

JSON
{
  "code": "ErrParamInvalid",
  "msg": "id 无效"
}

Field

Type

Description

code

string

error code.

msg

string

error message.

Last updated on