Updated on 2025-12-09 GMT+08:00

Querying Available Publications for a DB Instance

Function

This API is used to query available publications for an RDS for SQL Server instance.

Authorization Information

Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions.
  • If you are using role/policy-based authorization, see Permissions and Supported Actions for details on the required permissions.
  • If you are using identity policy-based authorization, the following identity policy-based permissions are required.

Action

Access Level

Resource Type (*: required)

Condition Key

Alias

Dependencies

rds:instance:update

write

-

-

rds:instance:modify

-

URI

  • URI format

    POST /v3/{project_id}/instances/{instance_id}/replication/publication-candidates

  • Parameter description
    Table 1 Parameters

    Parameter

    Mandatory

    Description

    project_id

    Yes

    Definition

    Project ID of a tenant in a region.

    To obtain the value, see Obtaining a Project ID.

    Constraints

    The value cannot be empty.

    Range

    N/A

    Default Value

    N/A

    instance_id

    Yes

    Definition

    Instance ID.

    Constraints

    The value cannot be empty.

    Range

    N/A

    Default Value

    N/A

Request Parameters

Table 2 Parameters

Parameter

Mandatory

Type

Description

publication_instance_id

No

String

Definition

Publisher instance ID. If this parameter is not left blank, the publications of this instance are preferentially queried.

Constraints

N/A

Range

N/A

Default Value

N/A

publication_instance_name

No

String

Definition

Publisher instance name (fuzzy match).

Constraints

N/A

Range

N/A

Default Value

N/A

publication_name

No

String

Definition

Publication name (fuzzy match).

Constraints

N/A

Range

N/A

Default Value

N/A

offset

No

Integer

Definition

Index offset. The query starts from the next piece of data indexed by this parameter.

Constraints

N/A

Range

The value must be a non-negative number.

Default Value

0: The query starts from the first data record.

limit

No

Integer

Definition

Number of records returned by a query.

Constraints

N/A

Range

1–1000

Default Value

10

Example Request

Query available publications for an RDS for SQL Server instance.

POST https://{Endpoint}/v3/0483b6b16e954cb88930a360d2c4e663/instances/72ee4cc4607347049df9ad50f615bbd8in04/replication/publication-candidates

{
    "limit": 1000,
    "offset": 0,
    "publication_instance_name": "rds"
}

Response

  • Normal response
    Table 3 Parameters

    Parameter

    Type

    Description

    instance_publications

    Array of objects

    Definition

    List of instance publications.

    For details, see Table 4.

    Range

    N/A

    total_count

    Integer

    Definition

    Total number of publications.

    Range

    N/A

    Table 4 instance_publications element structure description

    Parameter

    Type

    Description

    instance_id

    String

    Definition

    Instance ID.

    Range

    N/A

    instance_name

    String

    Definition

    Instance name.

    Range

    N/A

    publication_id

    String

    Definition

    Publication ID.

    Range

    N/A

    publication_name

    String

    Definition

    Publication name.

    Range

    N/A

  • Example normal response
    {
        "instance_publications": [
            {
                "instance_id": "422dc09255994da0b40ead6d74af017ein04",
                "instance_name": "rds-7941",
                "publication_id": "959d6fd2-c32f-47fe-a209-7fb6b261a6bb",
                "publication_name": "pub01"
            }
        ],
        "total_count": 1
    }

Status Code

Error Code

For details, see Error Codes.