Browse catalogs, databases, volumes and tables¶
Returns hierarchical navigation data of catalogs, databases, volumes, and tables accessible in the current workspace.
POST $CLOUDSIGMA_API_BASE/catalog/tree
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. Prepare a personal access token and target workspace ID that can access the target workspace.
Request body¶
curl -X POST "$CLOUDSIGMA_API_BASE/catalog/tree" \
-H "X-API-Key: $CLOUDSIGMA_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID" \
-H 'Content-Type: application/json' \
-d '{
"include_table_leaves": true
}'
Field |
Type |
Required |
Description |
|---|---|---|---|
|
boolean |
No |
Whether to include table leaf nodes in the tree. If omitted or |
Successful response¶
{
"code": "OK",
"msg": "OK",
"data": {
"tree": [
{
"id": "1",
"type": "catalog",
"name": "sales",
"display_name": "sales",
"description": "销售数据",
"reserved": false,
"node_list": [
{
"id": "2",
"type": "database",
"name": "orders",
"description": "",
"reserved": false,
"node_list": []
}
],
"allowed_actions": ["catalog.read"]
}
]
}
}
Field |
Type |
Description |
|---|---|---|
|
string |
|
|
string |
|
|
array of object |
List of root nodes. An empty array when there are no readable resources. |
|
string |
Node ID. |
|
string |
Node type: |
|
string |
Node name. |
|
string |
Node display name. Returned if there is a value. |
|
string |
Node description. |
|
string |
Node display description. Returned if there is a value. |
|
boolean |
Whether it is a reserved node. |
|
boolean |
Whether it is a publishing node. Return when applicable. |
|
boolean |
Whether it is a subscribing node. Return when applicable. |
|
array of object |
Child nodes have the same fields as the parent node. |
|
array of string |
The operations that the current identity can perform on this node. |
|
object |
Binding information of volumes and workflow triggers. Returned if there is a value. |
|
boolean |
Whether trigger binding exists. |
|
string |
Trigger ID. |
|
string |
Associate workflow ID. |
|
string |
Associated workflow name. |
|
string |
Associated workflow version ID. |
Error response¶
{
"code": "ErrParamInvalid",
"msg": "Bad Request"
}
Field |
Type |
Description |
|---|---|---|
|
string |
error code. |
|
string |
error message. |