Delete table¶
Delete the specified table and its data.
POST $CLOUDSIGMA_API_BASE/catalog/table/delete
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 confirm the target table ID, and check the actual associated objects and business users. Prepare the personal access token, target workspace ID, and table ID that can access the target workspace. This operation deletes the table and its data irreversibly.
The query table reference currently returns an empty list and cannot be used as a basis for unused or safe deletion.
Request body¶
curl -X POST "$CLOUDSIGMA_API_BASE/catalog/table/delete" \
-H "X-API-Key: $CLOUDSIGMA_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID" \
-H 'Content-Type: application/json' \
-d '{
"id": '"$TABLE_ID"'
}'
Field |
Type |
Required |
Description |
|---|---|---|---|
|
integer |
Yes |
Table ID. |
Successful response¶
{
"code": "OK",
"msg": "OK",
"data": null
}
Field |
Type |
Description |
|---|---|---|
|
string |
|
|
string |
|
|
null |
When the deletion is successful, it is fixed to |
Error response¶
{
"code": "ErrReadonlySystemDatabase",
"msg": "数据库不可写"
}
Field |
Type |
Description |
|---|---|---|
|
string |
error code. |
|
string |
error message. |