---
title: "Record where a web signup came from (first touch only)"
method: POST
path: "/v1/attribution"
tags: ["events"]
---

# Record where a web signup came from (first touch only)

`POST /v1/attribution`

## Request

- Base URL: `https://api.slideforge.dev`
- URL: `https://api.slideforge.dev/v1/attribution`
- Auth: one of:
  - HTTP bearer
  - API key in header `X-API-Key`

Writes the landing path, referrer host and UTM values captured in the browser on the visitor's first page view. First-touch and immutable: it fills `users.acquisition_meta` only while that column is still NULL, so a later visit can never rewrite where someone originally came from. No billing charge.

## Request body

- AttributionRequest: Where a web signup came from, captured in the browser on first touch. Deliberately not a URL and not a query string: `landing_path` is the path only and `referrer_host` the hostname only, so nothing a search engine or a user put in a query can arrive here. UTM values are the five standard ones, length-capped.
  - `landing_path` string, required
  - `referrer_host` string, nullable
  - `utm_source` string, nullable
  - `utm_medium` string, nullable
  - `utm_campaign` string, nullable
  - `utm_term` string, nullable
  - `utm_content` string, nullable
  - `gclid` string, nullable

## Response `202`

Accepted (written, or ignored because attribution already exists)

- unknown

## Other responses

- `401`: Authentication required
- `422`: Validation Error

---

[API](https://skmtc.dev/slideforge/apis/slideforge-api.md) · [All operations](https://skmtc.dev/slideforge/apis/slideforge-api/llms.txt) · [OpenAPI document](https://skmtc.dev/slideforge/apis/slideforge-api/revisions/ae698e3d3c00?raw)
