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

# Track

> Reference for the track event: a named custom event with your own properties, from a website, a game or a backend.

A `track` event records an action that matters to you, such as `signup_completed`, `purchase` or `level_complete`. Use custom events in funnels, retention, user paths, filters, alerts and dashboards.

## Send a custom event

```ts Web SDK theme={null}
analytics.track('signup_completed', { plan: 'pro' });
```

```gdscript Godot theme={null}
UntitledAnalytics.track("level_complete", {"level": 3, "attempt": 1, "score": 1200})
```

```bash Server theme={null}
curl -sS https://YOUR_COLLECTOR_ENDPOINT/v0/events \
  -H 'Authorization: Bearer YOUR_SECRET_KEY' \
  -H 'Content-Type: application/json' \
  -d '{"events":[{"channel":"server","type":"track","event":"subscription_renewed","user_id":"user_123","properties":{"plan":"pro"}}]}'
```

## Fields

| Field | Required | Description |
| - | - | - |
| `type` | Yes | `track` |
| `event` | Yes | The event name, 1 to 128 characters |
| `properties` | No | A flat object. Values are strings (at most 1024 characters), numbers, booleans or `null`. |

See [common fields](https://docs.manalens.dev/data/events/common.md) for the envelope fields.

## Special properties

| Property | Effect |
| - | - |
| `revenue` | A number. Reports sum it as event revenue on the Overview and by source. See [metrics](https://docs.manalens.dev/data/metrics.md#revenue-events). |

## Naming

* Use snake\_case names in the past tense: `signup_completed`, `trial_started`.
* Put variable values in properties, not in the name: `level_complete` with `{ "level": 3 }`, not `level_3_complete`.
* Do not send personal data in names or properties unless you need it.

Games have reserved event names. See [game events](https://docs.manalens.dev/data/events/game.md).

## Example

```json theme={null}
{
  "type": "track",
  "event": "purchase",
  "message_id": "0f4b0c39-4a77-4f3c-a5e2-6f5c1f2b7d10",
  "channel": "web",
  "version": "0.1.0",
  "original_timestamp": "2026-11-09T10:05:00.000Z",
  "anonymous_id": "3f0c5c1e-8a8e-4c1b-9d7e-2b1f4e6a9c10",
  "session_id": "1762682400000",
  "user_id": "user_123",
  "context": {
    "page": { "path": "/checkout", "title": "Checkout", "url": "https://example.com/checkout" },
    "referrer": ""
  },
  "properties": { "revenue": 49, "plan": "pro" }
}
```


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