---
title: Quickstart
description: Create a table, extract a file into it and read the rows.
url: https://anyrow.ai/docs/quickstart
canonical_url: https://anyrow.ai/docs/quickstart
last_updated: '2026-10-11'
---

# Quickstart

You need a project and one of its API keys. In the app, open the project, then **API keys**, and
create a key. Keep it in an environment variable, with the project's id:

```bash
export ANYROW_API_KEY="ak_..."
export PROJECT_ID="proj_..."
```

### 1. Create a table

A table is the shape of what you want back: each column has an `id`, a `name` and a `type`.

```bash title="cURL"
curl -X POST "https://api.anyrow.ai/v1/projects/$PROJECT_ID/tables" \
  -H "Authorization: ApiKey $ANYROW_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Invoices",
    "columns_json": [
      { "id": "vendor", "name": "Vendor" },
      { "id": "total", "name": "Total", "type": "currency" },
      { "id": "due", "name": "Due date", "type": "date" }
    ]
  }'
```

```ts title="Node.js"
import { AnyrowSDK } from "@anyrow/sdk"

const anyrow = new AnyrowSDK({
  baseURL: "https://api.anyrow.ai",
  headers: { Authorization: `ApiKey ${process.env.ANYROW_API_KEY}` },
})

const { data: table, error } = await anyrow.table.create({
  params: { project_id: process.env.PROJECT_ID! },
  json: {
    name: "Invoices",
    columns_json: [
      { id: "vendor", name: "Vendor" },
      { id: "total", name: "Total", type: "currency" },
      { id: "due", name: "Due date", type: "date" },
    ],
  },
})
```

```python title="Python"
import os, requests

table = requests.post(
    f"https://api.anyrow.ai/v1/projects/{os.environ['PROJECT_ID']}/tables",
    headers={"Authorization": f"ApiKey {os.environ['ANYROW_API_KEY']}"},
    json={
        "name": "Invoices",
        "columns_json": [
            {"id": "vendor", "name": "Vendor"},
            {"id": "total", "name": "Total", "type": "currency"},
            {"id": "due", "name": "Due date", "type": "date"},
        ],
    },
).json()
```

The response is the table, with its `id`.

### 2. Extract a file into it

Send the file as multipart form data. The response describes the finished batch: its
`batch_id`, `status`, how many rows it wrote (`total_rows`) and the extracted `result`.

```bash title="cURL"
curl -X POST "https://api.anyrow.ai/v1/projects/$PROJECT_ID/tables/$TABLE_ID/extract" \
  -H "Authorization: ApiKey $ANYROW_API_KEY" \
  -F "file=@./invoice.pdf"
```

```ts title="Node.js"
import { openAsBlob } from "node:fs"

const { data: batch } = await anyrow.extract.table.once({
  params: { project_id: process.env.PROJECT_ID!, table_id: table.id },
  form: { file: await openAsBlob("./invoice.pdf") },
})
```

```python title="Python"
batch = requests.post(
    f"https://api.anyrow.ai/v1/projects/{os.environ['PROJECT_ID']}/tables/{table['id']}/extract",
    headers={"Authorization": f"ApiKey {os.environ['ANYROW_API_KEY']}"},
    files={"file": open("./invoice.pdf", "rb")},
).json()
```

> [!NOTE]
> A long document takes a while. The streaming endpoint
> ([`extract-stream`](/docs/api/extract/table-stream)) sends progress and rows as server-sent
> events instead of one response at the end.

### 3. Read the rows

Rows come back 20 per page by default; follow `nextCursor` for more
(see [Pagination](/docs/pagination)).

```bash title="cURL"
curl "https://api.anyrow.ai/v1/projects/$PROJECT_ID/tables/$TABLE_ID/rows?limit=50" \
  -H "Authorization: ApiKey $ANYROW_API_KEY"
```

```ts title="Node.js"
const { data: page } = await anyrow.row.list({
  params: { project_id: process.env.PROJECT_ID!, table_id: table.id },
  search: { limit: 50 },
})
console.log(page.rows, page.hasMore, page.nextCursor)
```

```python title="Python"
page = requests.get(
    f"https://api.anyrow.ai/v1/projects/{os.environ['PROJECT_ID']}/tables/{table['id']}/rows",
    headers={"Authorization": f"ApiKey {os.environ['ANYROW_API_KEY']}"},
    params={"limit": 50},
).json()
```

## What's next

- [Get told when a batch finishes](/docs/webhooks): Webhooks post an event when an extraction completes or fails.
- [Rows in the API reference](/docs/api/rows): Filter, aggregate, edit and bulk-write rows.
