Integrations (n8n, Make, Zapier)

Automation tools such as n8n, Make, Zapier, Activepieces and Pipedream can read and write the data tables of a space through OpenThink's REST API, and get a webhook whenever rows change.

The space owner manages integrations from the space's **⋯ → Integrations** menu (`openthink.app/spaces/<id>/integrations`). There's no ready-made OpenThink app in those tools' catalogs yet — use their generic HTTP step: **HTTP Request** in n8n, the **HTTP** module in Make, or **Webhooks by Zapier**.

API keys

- A key (`thk_…`) belongs to **one space**, and only the space owner can create one.

- Choose **Read only** or **Read and write**, and an expiry: none, 30 days, 90 days or 1 year.

- The key is shown **once**, when you create it. OpenThink keeps only a hash of it.

- Send it with every request in the header `Authorization: Bearer thk_…`. A key only opens the API — not pages or MCP.

- Revoke a key on the Integrations screen: it stops working at once, and webhooks it registered are removed.

- Rows written with a key show the key's name (for example "n8n" or "Zapier") as their creator.

REST API

The base address is `https://openthink.app/api/v1`.

| Request | Does |

|---|---|

| `GET /me` | Checks the key: its space and whether it can `read` or `write` |

| `GET /tables` | Lists the space's tables with their columns and row counts |

| `GET /tables/:id` | One table |

| `GET /tables/:id/rows` | Rows, as `{ rows, total, nextOffset }` |

| `POST /tables/:id/rows` | Adds one row (`{ "values": { … } }`) or up to 500 (`{ "rows": [ … ] }`) |

| `GET`, `PATCH`, `DELETE /tables/:id/rows/:rowId` | Reads, updates or deletes one row. `PATCH` merges the values you send; `null` clears a cell |

| `POST /sql` | Runs SQLite over the space's tables, like `think.executeSql`: `{ "sql": "…", "params": [ … ] }` |

Options for listing rows: `limit` (1–500, default 100), `offset`, `order` (`position`, `created` or `updated`) with `dir` (`asc` or `desc`), `since=<ISO time>` for rows created or changed after a moment — handy for polling triggers — and `ids=a,b`.

`INSERT`, `UPDATE` and `DELETE` through `/sql` need a **Read and write** key. Errors always come back as `{ "error": "…" }`: 401 for a wrong, expired or revoked key, 403 for a read-only key, 404 when something isn't found, 400 for bad data.

A row

```json

{

"id": "62e757cc63f9",

"url": "https://openthink.app/n/<table>?row=62e757cc63f9",

"createdAt": "2026-11-27T03:01:12.575Z",

"updatedAt": "2026-11-27T03:01:12.575Z",

"createdBy": { "id": "…", "name": "n8n" },

"values": { "Name": "An", "Score": 8.5, "Status": "Done", "Tags": ["A"], "Submitted": true, "Date": "2026-11-27" }

}

```

Values are keyed by **column name**: a Select is the option name, a Multi-select is a list of names, a Checkbox is `true` or `false`, a Date is `yyyy-mm-dd`, and an empty cell is `null`. Writing uses the same shapes, and a new option name adds the option.

Webhooks

Get a POST request whenever a row is added, changed or deleted.

- Create a webhook on the Integrations screen, or with `POST /webhooks` and `{ "url", "table", "events" }` — leave out `table` for every table; events are `row.added`, `row.updated` and `row.deleted`. The response includes a signing secret (`whsec_…`), shown once.

- Manage them with `GET /webhooks`, `GET`, `PATCH { active }` and `DELETE /webhooks/:id`, and send a test `ping` with `POST /webhooks/:id/test`. A space can have up to 20.

- The address must be `https://`. To run your own code when a table changes, use a [function](https://openthink.app/n/0535ef448521) with a table trigger instead.

- Each changed row is one POST with `{ id, event, createdAt, space, table, row, webhook }`. `row` is the row **as it was when the event happened**: the new row, the row right after the change, or the row right before it was deleted.

**Check that it's really from OpenThink.** Each request carries `X-Think-Event`, `X-Think-Delivery` (the event id — the same on retries, so use it to skip duplicates), `X-Think-Webhook` and `X-Think-Signature: t=<seconds>,v1=<hex>`. Compute HMAC-SHA256 of `<t>.<body>` with your signing secret, compare it to `v1`, and reject requests whose `t` is more than 5 minutes old.

**Retries.** Reply with a 2xx status within 15 seconds. After a timeout, 408, 429 or 5xx, OpenThink retries after 30 seconds, then 1, 2, 4… minutes (up to an hour apart), at most 10 times. Other 4xx replies aren't retried, and 410 turns the webhook off (that's how Zapier unsubscribes). After 20 failures in a row the webhook turns itself off; turn it back on from the Integrations screen, which also shows the last 50 deliveries.

Related

- [Functions](https://openthink.app/n/0535ef448521) — code that runs on OpenThink's servers, with schedules, webhooks and table triggers

- [Data tables](https://openthink.app/n/e4a246ac3902)

- [SQL queries & charts](https://openthink.app/n/08d0ba345c4a)