Want a guided walkthrough? Schedule a 15-min call.

Getting Started with Tables

This guide will walk you through working with tables using the Extruct API. Tables are a core component of the Extruct platform, allowing you to organize company data and run AI research agents.

Authentication

Before working with tables, ensure you have an API token. Follow steps in the Authentication.

Create a Table

It is much easier to create a table via the Extruct AI Dashboard, and append / read data via API.

Simply go to the Dashboard and create a new table, either from scratch, from a template, or by using “Suggest with AI” feature.

Add Companies to a Table

All tables have input column, which is the “company identifier” column you must provide. It can be a company website, name, a mix of both, or any other unique identifier.

Here is a sample request to add companies to a table:

curl -X POST "https://api.extruct.ai/v1/tables/{table_id}/rows" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -d '{
    "rows": [
      {
        "data": {
          "input": "Extruct AI (https://extruct.ai)"
        }
      },
      {
        "data": {
          "input": "OpenAI (https://openai.com)",
        }
      }
    ],
    "run": true
  }'

Flag run is optional and defaults to false. If set to true, it will trigger AI research agents to enrich the data in the table.

Alternatively, you can trigger the enrichment process later using the Run Enrichment endpoint.

Check Table Status

You can check the status of the table using the GET /v1/tables/ endpoint.

curl -X GET "https://api.extruct.ai/v1/tables/{table_id}" \
  -H "Authorization: Bearer YOUR_API_TOKEN"

Sample response:

{
  "id": "<string>",
  "created_at": "2023-11-07T05:31:56Z",
  "name": "<string>",
  "description": "<string>",
  "tags": [
    "<string>"
  ],
  "kind": "generic",
  "columns": [
    {
      "id": "<string>",
      "created_at": "2023-11-07T05:31:56Z",
      "config": {
        "kind": "<string>",
        "name": "<string>",
        "key": "<string>"
      }
    }
  ],
  "owner": {
    "id": "<string>",
    "email": "<string>"
  },
  "status": {
    "num_rows": 123,
    "num_output_columns": 123,
    "num_input_columns": 123,
    "num_cells_completed": 123,
    "num_cells_in_progress": 123,
    "num_columns": 123,
    "run_status": "running"
  }
}

The field run_status indicates the current status of the table. It can be running (enrichment in progress) or idle (enrichment completed).

Get Table Data

Once the table enrichment is complete, you can access the data using the Get Table Data endpoint.

The final data will be stored in rows field of the response.