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

# Preview a Google Sheet's columns

> Reads a Google Sheet anyone with the link can view and returns its columns (A, B, C… with their headers) and how many rows sit under the header row. Pass the sheet's link as `url`, and a tab name as `sheet` (default: the tab the link opens, else the first). Nothing is saved.

**Scopes:** `knowledge:read`



## OpenAPI

````yaml /api-reference/openapi.json get /v1/knowledge/sheet-columns
openapi: 3.1.0
info:
  title: Kallabot API
  version: '2026-11-07'
  description: >
    The Kallabot API lets you build and run AI agents that answer and make phone
    calls and reply on

    WhatsApp, Messenger, Instagram and website chat.


    - **Base URL:** `https://api.kallabot.com`

    - **Auth:** `Authorization: Bearer kb_live_…` (create a key in the dashboard
    under Settings → API keys).
      Each operation lists the scopes its key needs. A workspace key (`kb_live_…`) belongs to the workspace;
      a personal key (`kbp_live_…`) acts as the person who made it, within their role, and is logged under
      their name. Operations marked **Needs a personal key** need someone behind them, so only a personal
      key works there. The browser side of a web call is the exception: its
      `/client` operations take only the session's `X-Webcall-Grant`, so your key never reaches the page.
    - **Errors:** every error is `application/problem+json` with a stable `code`
    ([error reference](https://docs.kallabot.com/developers/errors)).

    - **Retries:** send an `Idempotency-Key` on creates and control actions; a
    retry with the same key never runs twice.

    - **Rate limits:** every response carries `RateLimit-Limit`,
    `RateLimit-Remaining` and `RateLimit-Reset`;
      a `429` carries `Retry-After`.
    - **Versions:** the API is versioned by date. Send `Kallabot-Version:
    2026-11-07` to pin the version
      you built against; without it you get the current version (`2026-11-07`). Every response names the
      version that answered in `Kallabot-Version`, and an unknown version is refused with 400
      `unsupported_api_version`.
    - **Lists:** every list takes `limit` and `cursor` and answers `{data,
    next_cursor, has_more}`. Pass
      `next_cursor` back as `cursor` for the next page; cursors are opaque.
    - **Concurrency:** reads of versioned objects carry an `ETag` (the revision
    in quotes, e.g. `"7"`); send it back as
      `If-Match` and a stale write is refused with 412. Where `If-Match` is marked required, a write without it gets 428.
    - **SDKs:** the official SDKs send `X-Kallabot-SDK`. A deprecated release
    gets a `Kallabot-SDK-Warning` header;
      a release that has been switched off is refused with 426 `sdk_version_unsupported` and must upgrade.
    - **Webhooks:** every event Kallabot sends is listed under Webhooks with its
    payload, signed with
      [Standard Webhooks](https://docs.kallabot.com/developers/webhooks) headers.
  contact:
    name: Kallabot support
    email: contact@kallabot.com
    url: https://docs.kallabot.com
  termsOfService: https://kallabot.com/terms
servers:
  - url: https://api.kallabot.com
    description: Production
security:
  - apiKey: []
tags:
  - name: Agents
    description: >-
      Create, version, publish and archive the AI agents that answer and make
      calls and chats.
  - name: Calls
    description: >-
      Place phone calls, read them back with transcripts, recordings and
      timings, and control live calls.
  - name: Scheduled calls
    description: >-
      Book an outbound call for later; Kallabot dials at the right time in the
      callee's time zone.
  - name: Web calls
    description: Start a voice call from a browser (WebRTC) with a short-lived grant.
  - name: Tools
    description: >-
      Give agents actions: HTTP API tools, MCP servers, and the secrets they
      use.
  - name: Knowledge
    description: Index websites, files and catalogs so agents answer from your own facts.
  - name: Numbers
    description: >-
      Search, buy and configure phone numbers, port numbers in, and choose
      caller IDs.
  - name: SIP trunks
    description: Bring your own carrier over SIP and attach its numbers to agents.
  - name: Inbox
    description: >-
      Read chat threads from WhatsApp, Messenger, Instagram and web chat, and
      manage their state.
  - name: Web chat
    description: Create and publish website chat widgets.
  - name: Webhooks
    description: >-
      Receive signed events when calls end, messages arrive and more; inspect
      and replay deliveries.
  - name: Minutes
    description: Read the workspace's minutes and move them between the pool and people.
  - name: Billing
    description: >-
      See the plan, prices and invoices; open Checkout or the billing portal,
      sync seats and set auto top-up. Money is integer minor units plus
      `currency`.
paths:
  /v1/knowledge/sheet-columns:
    get:
      tags:
        - Knowledge
      summary: Preview a Google Sheet's columns
      description: >-
        Reads a Google Sheet anyone with the link can view and returns its
        columns (A, B, C… with their headers) and how many rows sit under the
        header row. Pass the sheet's link as `url`, and a tab name as `sheet`
        (default: the tab the link opens, else the first). Nothing is saved.


        **Scopes:** `knowledge:read`
      operationId: getKnowledgeSheetColumns
      parameters:
        - name: url
          in: query
          required: false
          schema:
            type: string
            maxLength: 2000
            default: ''
            title: Url
        - name: sheet
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                maxLength: 200
              - type: 'null'
            title: Sheet
        - name: Kallabot-Version
          in: header
          required: false
          description: >-
            The API version to answer as, a date (`YYYY-MM-DD`). Leave it out
            for the current version (`2026-11-07`). An unknown version is
            refused with 400 `unsupported_api_version`.
          schema:
            type: string
            enum:
              - '2026-11-07'
            example: '2026-11-07'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SheetColumns'
          headers:
            RateLimit-Limit:
              description: Requests allowed per minute for this credential.
              schema:
                type: integer
            RateLimit-Remaining:
              description: Requests left in the current window.
              schema:
                type: integer
            RateLimit-Reset:
              description: Seconds until the window is full again.
              schema:
                type: integer
            X-Request-Id:
              description: Quote this when contacting support.
              schema:
                type: string
            Kallabot-Version:
              description: The API version that answered this request.
              schema:
                type: string
                example: '2026-11-07'
            Kallabot-SDK-Warning:
              description: >-
                Sent when the SDK release that made the request is deprecated:
                what to upgrade to. The SDKs log it once.
              schema:
                type: string
        '400':
          $ref: '#/components/responses/UnsupportedApiVersion'
        '401':
          $ref: '#/components/responses/Unauthenticated'
        '403':
          $ref: '#/components/responses/Forbidden'
        '422':
          $ref: '#/components/responses/InvalidRequest'
        '426':
          $ref: '#/components/responses/SdkVersionUnsupported'
        '429':
          $ref: '#/components/responses/RateLimited'
        '500':
          $ref: '#/components/responses/InternalError'
      security:
        - apiKey: []
components:
  schemas:
    SheetColumns:
      properties:
        spreadsheet_id:
          type: string
          title: Spreadsheet Id
        sheet:
          anyOf:
            - type: string
            - type: 'null'
          title: Sheet
        title:
          anyOf:
            - type: string
            - type: 'null'
          title: Title
        columns:
          items:
            $ref: '#/components/schemas/SheetColumn'
          type: array
          title: Columns
        rows:
          type: integer
          title: Rows
      type: object
      required:
        - spreadsheet_id
        - sheet
        - title
        - columns
        - rows
      title: SheetColumns
    SheetColumn:
      properties:
        letter:
          type: string
          title: Letter
        header:
          type: string
          title: Header
      type: object
      required:
        - letter
        - header
      title: SheetColumn
    Problem:
      type: object
      description: >-
        An RFC 9457 problem. `code` is the stable contract; `title` and `detail`
        are for people.
      required:
        - type
        - title
        - status
        - code
        - retryable
      properties:
        type:
          type: string
          format: uri
          example: https://docs.kallabot.com/errors/not_found
        title:
          type: string
          example: Agent not found
        status:
          type: integer
          example: 404
        code:
          type: string
          example: not_found
        detail:
          type: string
          example: Agent does not exist, or you do not have access to it.
        retryable:
          type: boolean
          example: false
        field_problems:
          type: array
          items:
            type: object
            properties:
              path:
                type: string
                description: JSON Pointer to the field.
                example: /to
              code:
                type: string
                example: missing
              message:
                type: string
                example: Field required
        request_id:
          type: string
          example: req_01HZX3K9Q2
  responses:
    UnsupportedApiVersion:
      description: Kallabot-Version names a version this API doesn't have
      headers:
        X-Request-Id:
          description: Quote this when contacting support.
          schema:
            type: string
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
          example:
            type: https://docs.kallabot.com/errors/unsupported_api_version
            title: Kallabot-Version names a version this API doesn't have
            status: 400
            code: unsupported_api_version
            retryable: false
    Unauthenticated:
      description: Missing or invalid API key
      headers:
        X-Request-Id:
          description: Quote this when contacting support.
          schema:
            type: string
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
          example:
            type: https://docs.kallabot.com/errors/unauthenticated
            title: Missing or invalid API key
            status: 401
            code: unauthenticated
            retryable: false
    Forbidden:
      description: The key lacks a required scope
      headers:
        X-Request-Id:
          description: Quote this when contacting support.
          schema:
            type: string
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
          example:
            type: https://docs.kallabot.com/errors/insufficient_scope
            title: The key lacks a required scope
            status: 403
            code: insufficient_scope
            retryable: false
    InvalidRequest:
      description: One or more fields are not valid
      headers:
        X-Request-Id:
          description: Quote this when contacting support.
          schema:
            type: string
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
          example:
            type: https://docs.kallabot.com/errors/invalid_request
            title: One or more fields are not valid
            status: 422
            code: invalid_request
            retryable: false
    SdkVersionUnsupported:
      description: 'This SDK release is switched off: upgrade the SDK'
      headers:
        X-Request-Id:
          description: Quote this when contacting support.
          schema:
            type: string
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
          example:
            type: https://docs.kallabot.com/errors/sdk_version_unsupported
            title: 'This SDK release is switched off: upgrade the SDK'
            status: 426
            code: sdk_version_unsupported
            retryable: false
    RateLimited:
      description: Too many requests
      headers:
        X-Request-Id:
          description: Quote this when contacting support.
          schema:
            type: string
        Retry-After:
          description: Seconds to wait before retrying.
          schema:
            type: integer
        RateLimit-Limit:
          description: Requests allowed per minute for this credential.
          schema:
            type: integer
        RateLimit-Remaining:
          description: Requests left in the current window.
          schema:
            type: integer
        RateLimit-Reset:
          description: Seconds until the window is full again.
          schema:
            type: integer
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
          example:
            type: https://docs.kallabot.com/errors/rate_limited
            title: Too many requests
            status: 429
            code: rate_limited
            retryable: true
    InternalError:
      description: Something went wrong on our side
      headers:
        X-Request-Id:
          description: Quote this when contacting support.
          schema:
            type: string
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'
          example:
            type: https://docs.kallabot.com/errors/internal_error
            title: Something went wrong on our side
            status: 500
            code: internal_error
            retryable: true
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      bearerFormat: kb_live_<lookup>_<secret> | kbp_live_<lookup>_<secret>
      description: >-
        An API key from Settings → API keys, sent as `Authorization: Bearer
        kb_live_…`. A workspace key starts `kb_`; a personal key starts `kbp_`
        and acts as its owner.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.