Query the source database table¶
Paginated queries for the current identity can be used to create published source database tables.
GET $CLOUDSIGMA_API_BASE/data-share/source-databases/{source_database_id}/tables
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 database list to obtain the source database ID. Prepare the personal access token, target workspace ID, and source database ID that can access the target workspace.
Request parameters¶
curl "$CLOUDSIGMA_API_BASE/data-share/source-databases/$SOURCE_DATABASE_ID/tables?page=1&page_size=20" \
-H "X-API-Key: $CLOUDSIGMA_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID"
Path parameters
Field |
Type |
Required |
Description |
|---|---|---|---|
|
string |
Yes |
Source database ID. |
Query parameters
Field |
Type |
Required |
Description |
|---|---|---|---|
|
integer |
No |
Page number. |
|
integer |
No |
Quantity per page. |
Successful response¶
{
"code": "OK",
"msg": "OK",
"data": {
"list": [
{
"id": "101",
"name": "orders"
}
],
"total": 1,
"page": 1,
"page_size": 20
}
}
Field |
Type |
Description |
|---|---|---|
|
string |
|
|
string |
|
|
object |
response data. |
|
array of object |
Tables that can be published on the current page. |
|
integer |
The total number of matching tables. |
|
integer |
Current page number. |
|
integer |
Quantity per page. |
|
string |
uint64 rel_id of the OmniFabric physical table, returned as a decimal string. Different from Catalog table_id. |
|
string |
Table name. |
Error response¶
{
"code": "ErrParamInvalid",
"msg": "请求参数无效",
"data": null
}
Field |
Type |
Description |
|---|---|---|
|
string |
error code. |
|
string |
Error description. |
|
null |
Empty on error. |
Common HTTP errors¶
HTTP status |
Error code |
Common cause |
Recommended action |
|---|---|---|---|
400 |
|
Invalid request field, workspace, or operation precondition. |
Fix the request parameters and submit again. |
403 |
|
The current identity or active role does not have permission for this operation. |
Use an authorized identity or contact an administrator to grant access. |
404 |
|
The target object or required reference was not found. |
Verify the object identifier, workspace, and current status. |
500 |
|
Internal processing failed; write operations may have been partially applied. |
Retain request and trace details, and verify the current state before retrying. |
503 |
|
A business, runtime, or authorization dependency is temporarily unavailable. |
After the dependency recovers, check existing results first instead of blindly repeating writes. |