---
title: "Export table definition"
method: GET
path: "/tables/export_definition/{dbId}/{tableId}"
tags: ["Table Management"]
---

# Export table definition

`GET /tables/export_definition/{dbId}/{tableId}`

Export complete table definition including metadata and all field definitions as JSON. Downloads as a file.

## Path parameters

- `dbId` string, required
- `tableId` string, required

## Response `200`

successful operation - JSON file download

- object
  - `status` string
  - `definition` object
    - `version` string
    - `exported_at` string, date-time
    - `table_metadata` object
      - `db_id` string
      - `table_id` string
      - `title` string
      - `description` string
      - `created_at` string, date-time
      - `updated_at` string, date-time
    - `fields` FieldDefinition[]
      - `name` string, required — Field name (required)
      - `label` string — Field label/display name
      - `description` string — Field description
      - `data_type` 'string' | 'integer' | 'float' | 'double' | 'date' | 'boolean' | 'datetime' | 'array' | 'object' | 'null' — Data type (string, integer, float, double, date, boolean, datetime, array, object, null)
      - `column_type` 'dimension' | 'time_period' | 'measure' | 'attribute' | 'indicator_id' | 'indicator_name' | 'geography' | 'observation_value' | 'periodicity' — Semantic column type
      - `field_order` integer — Display order of the field
      - `unit_of_measurement` string — Unit of measurement
      - `format` string — Format specification
      - `time_period_format` string — Time period format (e.g., YYYY, YYYY-MM)
      - `code_list` object[] — Inline code list values
        - `code` union — Code value
          - string
          - number
        - `label` string — Code label
        - `description` string — Code description
      - `code_list_reference` object — External code list reference
        - `id` string — Code list ID
        - `name` string — Code list name
        - `version` string — Code list version
        - `uri` string — Code list URI
        - `note` string — Additional notes
      - `created_at` string, date-time — Creation timestamp
      - `updated_at` string, date-time — Last update timestamp
    - `indexes` object — Collection indexes

## Changes

- **2025-12-01** `c9fac12336ea` — 1 info
  - endpoint added
- **2023-12-21** `1451f79c7f04` — 1 breaking
  - api path removed without deprecation

[Change history](https://skmtc.dev/ihsn/apis/data-tables/changes/tables/export_definition/:dbId/:tableId/get.md)

---

[API](https://skmtc.dev/ihsn/apis/data-tables.md) · [All operations](https://skmtc.dev/ihsn/apis/data-tables/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/ihsn/data-tables/revisions/6fb7730a430d/schema)
