getDatabases

Prev Next

Available in VPC

Get the list of databases in a catalog.

Request

This section describes the request format. The method and URI are as follows:

Method URI
GET /api/v1/catalogs/{catalogId}/databases

Request headers

For information about the headers common to all Data Catalog APIs, see Data Catalog request headers.

Request path parameters

You can use the following path parameters with your request:

Field Type Required Description
catalogId Integer Required Catalog ID

Request query parameters

You can use the following query parameters with your request:

Field Type Required Description
pageNo Integer Optional Page number
  • 1-N (default: 1)
pageSize Integer Optional Page output count
  • 1-200 (default: 20)
searchValue String Optional Search keyword
  • Search by database name.

Request example

The request example is as follows:

curl --location --request GET 'https://datacatalog.apigw.ntruss.com/api/v1/catalogs/4**/databases?pageNo=1&pageSize=20' \
--header 'x-ncp-apigw-timestamp: {Timestamp}' \
--header 'x-ncp-iam-access-key: {Access Key}' \
--header 'x-ncp-apigw-signature-v2: {API Gateway Signature}'

Response

This section describes the response format.

Response body

The response body includes the following data:

Field Type Required Description
pageNo Integer - Page number
pageSize Integer - Page output count
totalCount Integer - Number of response results
requestId String - ID for the request
  • UUID format
databaseResponseList Array - Database list

databaseResponseList

The following describes databaseResponseList.

Field Type Required Description
catalogId Integer - Catalog ID
name String - Database name
description String - Database description
createTime String - Database creation date and time
  • ISO 8601 format

Response status codes

For response status codes common to all Data Catalog APIs, see Data Catalog response status codes.

Response example

The response example is as follows:

{
    "pageNo": 1,
    "pageSize": 20,
    "totalCount": 2,
    "requestId": "aff80286-****-****-****-6ac1d306b14a",
    "databaseResponseList": [
        {
            "catalogId": 4**,
            "name": "my_database",
            "description": "my database",
            "createTime": "2025-03-17T16:30:08+0900"
        },
        {
            "catalogId": 4**,
            "name": "default",
            "description": "Default Data Catalog database for test",
            "createTime": "2025-03-17T14:30:26+0900"
        }
    ]
}