> ## Documentation Index
> Fetch the complete documentation index at: https://anaconda.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Create a new table in the vector database



## OpenAPI

````yaml /api-reference/ai-navigator-api.json post /api/vector-db/tables
openapi: 3.0.0
info:
  title: AI Navigator API
  version: 1.0.0
  description: API documentation for AI Navigator
servers: []
security:
  - bearerAuth: []
tags: []
paths:
  /api/vector-db/tables:
    post:
      tags:
        - VectorDB
      summary: Create a new table in the vector database
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateTableRequest'
      responses:
        '200':
          description: Table created successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/CreateTableResponse'
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '409':
          description: Table already exists
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    CreateTableRequest:
      type: object
      required:
        - name
      properties:
        name:
          type: string
          description: Name of the table to create
        schema:
          type: object
          description: Schema definition for the table
          properties:
            columns:
              type: array
              items:
                type: object
                properties:
                  name:
                    type: string
                    description: Column name
                  type:
                    type: string
                    description: Column data type
                  constraints:
                    type: array
                    items:
                      type: string
                    description: Column constraints
        data:
          type: array
          items:
            type: object
          description: Initial data to insert into the table
    CreateTableResponse:
      type: object
      required:
        - name
        - schema
        - numRows
      properties:
        name:
          type: string
          description: Name of the created table
        schema:
          type: object
          description: Schema of the created table
          properties:
            columns:
              type: array
              items:
                type: object
                properties:
                  name:
                    type: string
                    description: Column name
                  type:
                    type: string
                    description: Column data type
                  constraints:
                    type: array
                    items:
                      type: string
                    description: Column constraints
        numRows:
          type: integer
          description: Number of rows inserted
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - INVALID_REQUEST
                - DATABASE_NOT_RUNNING
                - INTERNAL_SERVER_ERROR
                - INVALID_SERVER_ID
                - SERVER_NOT_RUNNING
                - SERVER_RUNNING
                - INTERNAL_SERVER_ERROR
            message:
              type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: UUID
      description: Enter your API key here

````