getTableTags

Prev Next

Available in VPC

Get the list of tags in a table.

Request

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

Method URI
GET /api/v1/catalogs/{catalogId}/databases/{databaseName}/tables/{tableName}/tags

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
databaseName String Required Database name
tableName String Required Table name

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)

Request example

The request example is as follows:

curl --location --request GET 'https://datacatalog.apigw.ntruss.com/api/v1/catalogs/4**/databases/log_database/tables/log_table_1/tags?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
tagKeyTypeValueList Array - Tag list
catalogId Integer - Catalog ID
tableName String - Table name
databaseName String - Database name

tagKeyTypeValueList

The following describes tagKeyTypeValueList.

Field Type Required Description
tagKey String - Tag key
tagType String - Tag data format
tagValue String - Tag value
tagTemplateTagId Integer - Tag ID
  • Unique tag numbers stored in tag template
  • If not saved in the tag template: 0

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": 4,
    "tagKeyTypeValueList": [
        {
            "tagKey": "data source",
            "tagType": "STRING",
            "tagValue": "server01",
            "tagTemplateTagId": 468
        },
        {
            "tagKey": "num_rows",
            "tagType": "DOUBLE",
            "tagValue": "3600",
            "tagTemplateTagId": 469
        },
        {
            "tagKey": "ifchecked",
            "tagType": "BOOLEAN",
            "tagValue": "true",
            "tagTemplateTagId": 470
        },
        {
            "tagKey": "event_starttime",
            "tagType": "DATETIME",
            "tagValue": "2025-03-18 10:00:00",
            "tagTemplateTagId": 0
        }
    ],
    "catalogId": 4**,
    "tableName": "log_table_1",
    "databaseName": "log_database"
}