Documentation Index
Fetch the complete documentation index at: https://docs.linkutm.com/llms.txt
Use this file to discover all available pages before exploring further.
Overview
API keys let server-side integrations authenticate against the linkutm API without a user JWT. Endpoints live under/api/v1/api-keys.
A key:
- Is workspace-scoped. It is created against one workspace and only ever acts within that workspace.
- Has the format
lk_live_<48 hex characters>, for examplelk_live_3f1c.... The hex portion is 24 random bytes. - Authenticates the Links API. Pass it on Links requests instead of a user JWT.
Management endpoints require a JWT
The three endpoints below - create, list, and revoke - manage keys and are themselves protected by a JWT bearer token, not by an API key. The API key is what you then use to call the Links API. You also pass thex-workspace-id header so the server knows which workspace the keys belong to.
Create an API key
lk_live_ key for the workspace in x-workspace-id. The key is owned by the authenticated user and scoped to that workspace.
Headers
| Header | Required | Notes |
|---|---|---|
Authorization: Bearer <jwt> | Yes | |
x-workspace-id: <uuid_or_slug> | Yes | Target workspace, by UUID or slug |
Content-Type: application/json | Yes |
Body
A label for the key, so you can identify it later (for example
production-server or zapier).ISO 8601 date or datetime. After this moment the key stops validating. Omit it for a key that does not expire.
Example request
Example response
The
key field holds the value you use to authenticate the Links API. This is the only response that returns it as part of a fresh generation, so capture it now.List API keys
x-workspace-id, ordered newest first.
Headers
| Header | Required | Notes |
|---|---|---|
Authorization: Bearer <jwt> | Yes | |
x-workspace-id: <uuid_or_slug> | Yes | Target workspace, by UUID or slug |
Example request
Example response
lastUsedAt is updated each time the key successfully authenticates a request. It is null until the key is first used.
Revoke an API key
x-workspace-id. Once deleted, the key no longer authenticates any request.
Headers
| Header | Required | Notes |
|---|---|---|
Authorization: Bearer <jwt> | Yes | |
x-workspace-id: <uuid_or_slug> | Yes | Target workspace, by UUID or slug |
Example request
Example response
Returns the deleted API key record.Key expiration
A key withexpiresAt set in the past is treated as invalid and fails authentication, even though the record still exists. Revoke keys you no longer need rather than relying on expiry alone.
API key endpoint scope
An API key covers only the Links module. The table below is the authoritative list of what the key can and cannot reach.| Endpoint | API key supported |
|---|---|
GET /links | Yes |
GET /links/stats | Yes |
GET /links/ids | Yes |
GET /links/:id | Yes |
POST /links | Yes |
PATCH /links/:id | Yes |
DELETE /links/:id | Yes |
POST /links/bulk-delete | Yes |
POST /links/bulk-archive | Yes |
POST /links/bulk-move | Yes |
POST /links/bulk-tag | Yes |
POST /links/bulk-create | Yes |
POST /links/check-shortcodes | Yes |
POST /links/import/* | Yes |
GET /links/:id/analytics | No — returns 401 |
GET /links/:id/tags | No — route not registered |
GET /links/:id/pixels | No — returns 401 |
GET /analytics | No — returns 401 |
GET /templates | No — returns 401 |
GET /folders | No — returns 401 |
GET /tags | No — returns 401 |
GET /utm-rules | No — returns 401 |
POST /pixels | No — returns 401 |
| All other modules | No — returns 401 |
Errors
| Code | When |
|---|---|
400 | Missing name, or expiresAt is not a valid ISO 8601 date string |
401 | Missing or invalid JWT |
404 | API key not found, or it does not belong to the workspace in x-workspace-id |
429 | Rate limit exceeded (100 requests/minute per IP) |