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

# Sonar API overview

> Read and write your organization's Sonar CRM: the companies, contacts and deals it builds from your team's conversations, and the record of every change.

Sonar is the CRM that writes itself. It reads your team's connected accounts (Telegram, Slack, mail, calendars, calls, signatures and wallets), turns what it sees into organizations, contacts, deals, tasks and documents, and keeps a record of every change with the evidence behind it. The Sonar API is the API the Sonar dashboard runs on: read the pipeline, sync what changed, or write to it.

If you already have a key and want a first call, go straight to the [Sonar quickstart](https://docs.turtle.xyz/sdk/sonar/quickstart.md). For Turtle's other products, see the [API overview](https://docs.turtle.xyz/sdk/overview.md).

## Base URL

```text theme={null}
https://sonar.turtle.xyz/v1
```

Every path is under `/organization/{organizationId}`, the Turtle organization whose Sonar you address. These pages write paths relative to it: `/engagements` means `https://sonar.turtle.xyz/v1/organization/{organizationId}/engagements`.

Each organization's Sonar is its own silo. Nothing in it is shared with another organization.

## Get access

You need three things before your first call.

1. **Sonar on your organization.** The Turtle team enables Sonar per organization. A key for an organization without it gets `403`. Ask your Turtle contact, or reach out on [Discord](https://discord.turtle.xyz).
2. **A secret API key.** A personal key from your account page, or an organization key from the organization's settings. See [Authentication](https://docs.turtle.xyz/sdk/sonar/authentication.md).
3. **Your organization ID.** It is the ID in the dashboard's address bar while you are in the organization: `dashboard.turtle.xyz/organizations/<organizationId>/...`.

## What the API covers

The API names a few things differently from the dashboard: an **engagement** is a deal, a **thread** is a storyline, and a **pipeline** is a board.

| Resource | Path | What it holds |
| - | - | - |
| Organizations | `/organizations` | The companies you deal with, your own included. |
| Contacts | `/contacts` | People, and the roles they hold at organizations. |
| Engagements | `/engagements` | Deals on your boards. |
| Threads | `/threads` | Storylines: the events one topic is made of. |
| Tasks | `/tasks` | Follow-ups with owners and due dates. |
| Documents | `/documents` | Paperwork held with a counterparty. Sonar records where a document lives, not the file. |
| Wallets | `/wallets` | On-chain addresses an organization is known by. |
| Reports | `/reports` | A deal's changes between two reviews. |
| Events | `/events` | What the sensors read. Events never change, and writes cite them as evidence. |
| Meetings | `/meetings` | The schedule, from the calendars Sonar reads. |
| Messages | `/messages` | The conversation with Sonar's agent: questions, answers and notes. |
| Mutations | `/mutations` | The change log: every write, the drafts waiting for a person, and undo. |
| Pipelines | `/pipelines` | Boards, their stages, and the card each deal on them carries. |
| Entity cards | `/entity-cards` | The custom fields every other kind of record carries. |
| Rules | `/rules` | Rules your workspace runs on incoming events. |
| Permissions | `/permissions` | What the agent may do without a person. |
| Sensing scope | `/integrations/{integrationId}/scope` | What each connected account may read. |
| Webhook deliveries | `/webhooks/deliveries` | What your inbound webhooks received. |
| Data | `/data` | What Sonar holds for you, its retention, and deletion. |

Every endpoint has its own page under **API reference**, generated from the OpenAPI spec.

## How it behaves

* **Easy to sync.** Cursor paging, shared sort names, repeatable filters, and `updatedAfter` to fetch only what changed. See [Reading](https://docs.turtle.xyz/sdk/sonar/conventions.md#reading).
* **Every write is logged.** Each write is a row in the change log that says who made it and why. A write made as an agent also quotes the events it rests on.
* **The same approval rules as Sonar's agent.** A write made as an agent passes the permissions your workspace set, and one they hold comes back as a draft for a person. See [Writing](https://docs.turtle.xyz/sdk/sonar/conventions.md#writing).
* **Safe to repeat.** A write that changes nothing answers `applied: false` and logs nothing new.
* **Webhooks in.** Give a form or a tool a URL, and each delivery becomes an event Sonar reads. See [Inbound webhooks](https://docs.turtle.xyz/sdk/sonar/webhooks.md).

## Spec and versioning

The machine-readable spec is public: `https://sonar.turtle.xyz/v1/openapi.json` (OpenAPI 3.1). Load it into Postman or Insomnia, or point a client generator at it.

v1 is stable: within v1, changes are additive only, and an operation is retired only after at least 90 days' notice. See [Versioning and deprecation](https://docs.turtle.xyz/sdk/sonar/conventions.md#versioning-and-deprecation).

## What's next

* **[Quickstart](https://docs.turtle.xyz/sdk/sonar/quickstart.md)** - Make a first read, then keep a copy in sync.
* **[Authentication](https://docs.turtle.xyz/sdk/sonar/authentication.md)** - Personal and organization keys, and what each may read and write.
* **[Conventions](https://docs.turtle.xyz/sdk/sonar/conventions.md)** - Lists, filters, writes, approvals, errors and limits.
* **[Inbound webhooks](https://docs.turtle.xyz/sdk/sonar/webhooks.md)** - Send a form, a zap or your backend's events into Sonar.


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