# SourceLoop API

Read your attribution data, write conversions back from your backend, and automate reporting. 24 endpoints across 12 resources, one bearer token.

Source: https://sourceloop.ai/help/api/
OpenAPI specification: https://sourceloop.ai/help/api/openapi.json
Base URL: `https://app.sourceloop.ai/api/v1`

---

## Authentication

Send a SourceLoop API key as a bearer token: `Authorization: Bearer slk_live_...`.
Details: https://sourceloop.ai/help/api/authentication.md

## Endpoints

### Workspace

Check what a key can do, list the websites it covers, and read the semantic layer of metrics and dimensions.

| Endpoint | Method | Path | Permission |
| --- | --- | --- | --- |
| Get key info | GET | `/v1/me` | any key |
| Get schema | GET | `/v1/schema` | any key |
| List websites | GET | `/v1/websites` | any key |

Full reference: https://sourceloop.ai/help/api/workspace.md

### Metrics

Aggregated metrics, breakdowns and timeseries across any dimension, with the attribution model you choose.

| Endpoint | Method | Path | Permission |
| --- | --- | --- | --- |
| Get metrics | GET | `/v1/metrics` | `metrics:read` |

Full reference: https://sourceloop.ai/help/api/metrics.md

### Contacts

The lead ledger: list contacts with their first and last touch, read one, and pull the full visitor journey behind it.

| Endpoint | Method | Path | Permission |
| --- | --- | --- | --- |
| List contacts | GET | `/v1/contacts` | `conversions:read` |
| Get contact | GET | `/v1/contacts/{id}` | `conversions:read` |
| Update contact | PATCH | `/v1/contacts/{id}` | `conversions:write` |
| Get contact journey | GET | `/v1/contacts/{id}/journey` | `conversions:read` |

Full reference: https://sourceloop.ai/help/api/contacts.md

### Companies

Company records with firmographics, pipeline rollups and attribution, whether or not a CRM is connected.

| Endpoint | Method | Path | Permission |
| --- | --- | --- | --- |
| List companies | GET | `/v1/companies` | `companies:read` |
| Get company | GET | `/v1/companies/{id}` | `companies:read` |
| Update company | PATCH | `/v1/companies/{id}` | `companies:write` |
| Get company journey | GET | `/v1/companies/{id}/journey` | `companies:read` |

Full reference: https://sourceloop.ai/help/api/companies.md

### Deals

CRM deals and the pipelines they move through, including values, stages and write-back.

| Endpoint | Method | Path | Permission |
| --- | --- | --- | --- |
| List deals | GET | `/v1/deals` | `deals:read` |
| List pipelines | GET | `/v1/pipelines` | `deals:read` |
| Get deal | GET | `/v1/deals/{id}` | `deals:read` |
| Update deal | PATCH | `/v1/deals/{id}` | `deals:write` |
| Get deal journey | GET | `/v1/deals/{id}/journey` | `deals:read` |

Full reference: https://sourceloop.ai/help/api/deals.md

### Events

Send server-side events for anything the browser cannot see: OAuth callbacks, payment webhooks, queue workers.

| Endpoint | Method | Path | Permission |
| --- | --- | --- | --- |
| Send events | POST | `/v1/events` | `events:write` |

Full reference: https://sourceloop.ai/help/api/events.md

### Ads

Spend, impressions and clicks from the connected ad platforms, joined to the conversions they produced.

| Endpoint | Method | Path | Permission |
| --- | --- | --- | --- |
| Get ad performance | GET | `/v1/ads/performance` | `metrics:read` |

Full reference: https://sourceloop.ai/help/api/ads.md

### Attribution

How much of your converted traffic carries usable attribution, and where the gaps are.

| Endpoint | Method | Path | Permission |
| --- | --- | --- | --- |
| Get attribution coverage | GET | `/v1/attribution/coverage` | `metrics:read` |

Full reference: https://sourceloop.ai/help/api/attribution.md

### Funnels

Step-by-step conversion funnels with drop-off between stages.

| Endpoint | Method | Path | Permission |
| --- | --- | --- | --- |
| Get funnel | GET | `/v1/funnels` | `metrics:read` |

Full reference: https://sourceloop.ai/help/api/funnels.md

### Paths

The touch sequences visitors take before they convert.

| Endpoint | Method | Path | Permission |
| --- | --- | --- | --- |
| Get paths | GET | `/v1/paths` | `metrics:read` |

Full reference: https://sourceloop.ai/help/api/paths.md

### Products

Revenue and conversions broken down by product or plan.

| Endpoint | Method | Path | Permission |
| --- | --- | --- | --- |
| Get products | GET | `/v1/products` | `metrics:read` |

Full reference: https://sourceloop.ai/help/api/products.md

### Changes

What changed since your last run. The incremental endpoint automations poll instead of refetching a window.

| Endpoint | Method | Path | Permission |
| --- | --- | --- | --- |
| List changes | GET | `/v1/changes` | `conversions:read` |

Full reference: https://sourceloop.ai/help/api/changes.md

## Guides

- Send server-side conversions: https://sourceloop.ai/help/api/server-side-conversions.md
- Sync data incrementally: https://sourceloop.ai/help/api/incremental-sync.md
- Automate client reporting: https://sourceloop.ai/help/api/agency-reporting.md
- Errors and rate limits: https://sourceloop.ai/help/api/errors.md
- Pagination and versioning: https://sourceloop.ai/help/api/pagination.md
- Data provenance and PII: https://sourceloop.ai/help/api/provenance.md

## MCP server

Ask questions of the same data from Claude, ChatGPT or Cursor: https://sourceloop.ai/help/mcp.md
