Treasure Data Tables API

Manage tables within databases

OpenAPI Specification

treasure-data-tables-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: Treasure Data TD Bulk Import Tables API
  description: 'Core REST API for managing databases, tables, jobs, bulk imports, connectors, and users within the Treasure Data Customer Data Platform. Supports Presto and Hive query execution on big data warehouses.

    '
  version: v3
  contact:
    url: https://docs.treasure.ai/apis/td-api
  license:
    name: Treasure Data Terms of Service
    url: https://www.treasure.ai/
servers:
- url: https://api.treasuredata.com/v3
  description: Treasure Data API v3
security:
- TDAuth: []
tags:
- name: Tables
  description: Manage tables within databases
paths:
  /table/list/{database_name}:
    get:
      operationId: listTables
      summary: List tables in a database
      description: Returns a list of all tables within the specified database.
      tags:
      - Tables
      parameters:
      - name: database_name
        in: path
        required: true
        schema:
          type: string
        description: Name of the database
      responses:
        '200':
          description: List of tables
          content:
            application/json:
              schema:
                type: object
                properties:
                  tables:
                    type: array
                    items:
                      $ref: '#/components/schemas/Table'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
components:
  responses:
    NotFound:
      description: Resource not found
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
                example: Resource not found
    Unauthorized:
      description: Authentication required or API key invalid
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
  schemas:
    Table:
      type: object
      properties:
        name:
          type: string
        type:
          type: string
        count:
          type: integer
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
        estimated_storage_size:
          type: integer
  securitySchemes:
    TDAuth:
      type: apiKey
      in: header
      name: Authorization
      description: 'Treasure Data API key authentication. Set header value to "TD1 <your-api-key>".

        '