Query the source database table

Paginated queries for the current identity can be used to create published source database tables.

HTTP
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

Shell
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

source_database_id

string

Yes

Source database ID.

Query parameters

Field

Type

Required

Description

page

integer

No

Page number.

page_size

integer

No

Quantity per page.

Successful response

JSON
{
  "code": "OK",
  "msg": "OK",
  "data": {
    "list": [
      {
        "id": "101",
        "name": "orders"
      }
    ],
    "total": 1,
    "page": 1,
    "page_size": 20
  }
}

Field

Type

Description

code

string

OK on success.

msg

string

OK on success.

data

object

response data.

data.list

array of object

Tables that can be published on the current page.

data.total

integer

The total number of matching tables.

data.page

integer

Current page number.

data.page_size

integer

Quantity per page.

data.list[].id

string

uint64 rel_id of the OmniFabric physical table, returned as a decimal string. Different from Catalog table_id.

data.list[].name

string

Table name.

Error response

JSON
{
  "code": "ErrParamInvalid",
  "msg": "请求参数无效",
  "data": null
}

Field

Type

Description

code

string

error code.

msg

string

Error description.

data

null

Empty on error.

Common HTTP errors

HTTP status

Error code

Common cause

Recommended action

400

ErrWorkspaceRequired, ErrParamInvalid

Invalid request field, workspace, or operation precondition.

Fix the request parameters and submit again.

403

ErrPermissionDenied

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

ErrSourceNotFound

The target object or required reference was not found.

Verify the object identifier, workspace, and current status.

500

ErrServer

Internal processing failed; write operations may have been partially applied.

Retain request and trace details, and verify the current state before retrying.

503

ErrServiceUnavailable

A business, runtime, or authorization dependency is temporarily unavailable.

After the dependency recovers, check existing results first instead of blindly repeating writes.

Last updated on