Responses: 200 The calling key and its organization, 401 Missing, invalid, expired or revoked key, 429 Too many requests. Wait the number of seconds in Retry-After.
Links
Create, read, edit, pause, archive and delete short links, one at a time or up to 25 per request.
GET/linksList links with filters and a cursor
Requires links:read. Stable order by creation time and ID unless another supported sort is chosen (API-05). Pass `meta.next_cursor` back as `cursor` for the next page.
Parameter
In
Description
q
query
Search in slug, title and destination.
state
query
One of: active, paused, archived.
tag
query
campaign
query
created_from
query
RFC 3339 time or YYYY-MM-DD, inclusive.
created_to
query
RFC 3339 time or YYYY-MM-DD, exclusive.
sort
query
One of: created_at, -created_at, updated_at, -updated_at.
limit
query
cursor
query
Opaque next_cursor from the previous page. Bound to the organization and filters, valid for 24 hours.
Responses: 200 One page of links, 400 Error envelope with a stable code, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
POST/linksCreate one link
Requires links:write. Only destination_url is required. Omitted fields take their defaults, which are a random seven-character slug, no metadata, no schedule, no password, the primary domain and no query forwarding (API-10).
Parameter
In
Description
Idempotency-Key
header
16 to 128 visible ASCII characters, unique per intended change. An identical retry within 24 hours returns the original result, or a compact form of it with the same identifiers when the full result did not fit the stored budget; a changed payload answers 409 (API-06). At most 20 unexpired keys per organization.
Responses: 201 Created. Location names the new link and ETag carries its version, 400 Error envelope with a stable code, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 409 Error envelope with a stable code, 413 Error envelope with a stable code, 415 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After, 507 Error envelope with a stable code.
POST/links/bulkCreate or change up to 25 links with a result per item
Each item is applied on its own and never partially (LNK-11). Requires the scope of the operation. `create` items take the fields of Create one link; `pause`, `activate` and `archive` items take `id` and `expected_version`; `tag` items also take `tags` and `mode` (add, remove or replace).
Parameter
In
Description
Idempotency-Key
header
16 to 128 visible ASCII characters, unique per intended change. An identical retry within 24 hours returns the original result, or a compact form of it with the same identifiers when the full result did not fit the stored budget; a changed payload answers 409 (API-06). At most 20 unexpired keys per organization.
Responses: 200 Per-item results with stable indexes, 400 Error envelope with a stable code, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 409 Error envelope with a stable code, 413 Error envelope with a stable code, 415 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
GET/links/{id}Read one link
Requires links:read. Never includes the password or its hash; `password_protected` says whether one is set.
Responses: 200 The link. ETag carries its version for If-Match, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 404 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
PATCH/links/{id}Edit mutable fields or the lifecycle state
Requires links:write and If-Match with the current version (API-07). Omitted fields are kept, null clears a nullable field and arrays replace the whole array. The slug and short URL never change.
Parameter
In
Description
idrequired
path
If-Matchrequired
header
The current integer version, for example "3", as returned in ETag. Missing answers 428, stale answers 412 (API-07).
Responses: 200 The updated link with its new version, 400 Error envelope with a stable code, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 404 Error envelope with a stable code, 412 Error envelope with a stable code, 413 Error envelope with a stable code, 415 Error envelope with a stable code, 422 Error envelope with a stable code, 428 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
DELETE/links/{id}Erase the link and keep its short key reserved
Requires links:delete and If-Match. The link and its analytics are erased; the slug can never be reused (LNK-05).
Parameter
In
Description
idrequired
path
If-Matchrequired
header
The current integer version, for example "3", as returned in ETag. Missing answers 428, stale answers 412 (API-07).
Responses: 200 The erased link's identifiers, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 404 Error envelope with a stable code, 412 Error envelope with a stable code, 428 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
GET/links/{id}/qrSVG QR code of the short URL
Requires links:read. Error correction level M with a four-module quiet zone (LNK-10). The SVG contains only the code.
Responses: 200 SVG image, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 404 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
Analytics
Recorded requests per day and dimension, with coverage and estimate labels. Counts are served redirects, not people.
GET/links/{id}/analyticsDaily and lifetime recorded requests of one link
Requires analytics:read. Link daily figures are kept for seven UTC days; lifetime totals until the analytics are purged or the link is deleted.
Parameter
In
Description
idrequired
path
from
query
ISO 8601 UTC date, inclusive. With `to` at most 30 days apart; both omitted select the last seven days.
Responses: 200 Link analytics with interval, retained interval, coverage and unique estimate labels (ANA-08), 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 404 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After, 503 Error envelope with a stable code.
GET/analyticsOrganization daily totals and dimensions
Requires analytics:read. The same figures as the Analytics page for equal filters (ANA-09). Without from and to it covers the last seven UTC days.
Parameter
In
Description
from
query
ISO 8601 UTC date, inclusive. With `to` at most 30 days apart; both omitted select the last seven days.
Responses: 200 Organization analytics, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After, 503 Error envelope with a stable code.
DELETE/analyticsPurge all or selected-link analytics
Requires analytics:delete. Cannot be undone (ANA-10). Removes counters, sketches and dimensions in bounded batches. When the answer has done false, send the same request with the returned started_at until done is true. Link IDs outside the organization answer 404.
Responses: 200 Progress of the purge, 400 Error envelope with a stable code, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 404 Error envelope with a stable code, 413 Error envelope with a stable code, 415 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After, 503 Error envelope with a stable code.
Events
A bounded change feed for keeping another system in sync.
GET/eventsPoll the change feed after a cursor
Requires events:read. Events come in increasing ID order, at most 100 per page.
The feed keeps at most 100 events per organization and seven days. A cursor
older than the retained history answers 410 cursor_expired; take a fresh
snapshot and poll again without a cursor. Deduplicate by event ID (EVT-02).
Parameter
In
Description
limit
query
cursor
query
Opaque next_cursor from the previous page. Bound to the organization and filters, valid for 24 hours.
Responses: 200 One page of events and the cursor to poll with next, 400 Error envelope with a stable code, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 410 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
Import and export
Chunked link import with validation receipts, and streamed exports of links and analytics.
POST/imports/validateCheck one import chunk without writing anything
Requires links:write. At most 25 rows and 65,536 bytes (IO-02). Returns every row as ok or with its error, and a receipt valid for ten minutes that is bound to the organization, the caller and the SHA-256 of the rows. Fields other than the listed ones, including password, fail their row.
Responses: 200 Row results and the receipt, 400 Error envelope with a stable code, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 413 Error envelope with a stable code, 415 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
POST/imports/applyCreate the rows of a validated chunk
Requires links:write and an Idempotency-Key. Send the validated rows unchanged with their receipt (IO-03). Each row is created in its own transaction with authorization, quota, capacity and slug checked again; existing links are never changed. A retry with the same key returns the first result. An expired or mismatched receipt answers 409; validate the chunk again.
Parameter
In
Description
Idempotency-Key
header
16 to 128 visible ASCII characters, unique per intended change. An identical retry within 24 hours returns the original result, or a compact form of it with the same identifiers when the full result did not fit the stored budget; a changed payload answers 409 (API-06). At most 20 unexpired keys per organization.
Responses: 200 Created and failed rows by row number, 400 Error envelope with a stable code, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 409 Error envelope with a stable code, 413 Error envelope with a stable code, 415 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
GET/exports/linksStream the link configuration as CSV or versioned JSON
Requires exports:read. Read in batches and streamed; no copy stays on the server and no password material is included (IO-01). CSV cells that begin with =, +, -, @, a tab or a carriage return get one leading apostrophe, removed again on import. The last CSV record is "#end" with the record count.
Responses: 200 The export as a download named in Content-Disposition, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
GET/exports/analyticsStream retained analytics as CSV or versioned JSON
Requires exports:read and analytics:read. Daily totals, per-link days, dimension buckets, lifetime totals, collection gaps and coverage notes, streamed (IO-01).
Responses: 200 The export as a download named in Content-Disposition, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After, 503 Error envelope with a stable code.
Members
Invitation links, roles and removal of organization members.
GET/membersActive members, owners first, with pending invitations in meta
Requires members:manage. Invitation links are never listed again.
Responses: 200 Members; meta.pending_invitations lists open invitations without their links, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
POST/membersCreate a single-use invitation link for a new member
Requires members:manage. People join only by opening an invitation link (TEN-04); C1K sends no mail. The link is returned once and works for 72 hours. A key acts as an administrator, so it cannot invite an owner. An optional email binds the invitation to that account.
Responses: 201 The invitation with its link, shown only now, 400 Error envelope with a stable code, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 413 Error envelope with a stable code, 415 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
PATCH/members/{user_id}Change a member's role within the caller's authority
Requires members:manage. Administrators and keys cannot change owners or assign the owner role.
Responses: 200 The member after the change, 400 Error envelope with a stable code, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 404 Error envelope with a stable code, 409 Error envelope with a stable code, 413 Error envelope with a stable code, 415 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
DELETE/members/{user_id}End a membership
Requires members:manage. The member's sessions and delegated access end on their next request. The last owner cannot be removed (409), and keys cannot remove owners.
Responses: 200 The membership is revoked, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 404 Error envelope with a stable code, 409 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
Integrations
Service accounts and their REST and MCP keys.
GET/service-accountsService accounts of the organization
Responses: 200 Service accounts, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
POST/service-accountsCreate a service account
Requires integrations:manage. At most two active service accounts per organization.
Responses: 201 Created, 400 Error envelope with a stable code, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 409 Error envelope with a stable code, 413 Error envelope with a stable code, 415 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
DELETE/service-accounts/{id}Revoke a service account and every key it holds
Requires integrations:manage. Its keys stop working on their next request.
Responses: 200 Revoked, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 404 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
GET/credentialsKeys of the organization without their secrets
Responses: 200 Keys with name, audience, scopes, last use, expiry and status, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
POST/credentialsCreate a key; the secret is returned once
Requires integrations:manage. A key may create keys only with a subset of its own scopes; an owner can grant more on the Integrations page. At most four live keys per organization. Audience rest makes a REST key, audience mcp an MCP token.
Responses: 201 Created. `data.token` is shown only in this response, 400 Error envelope with a stable code, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 404 Error envelope with a stable code, 409 Error envelope with a stable code, 413 Error envelope with a stable code, 415 Error envelope with a stable code, 422 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.
DELETE/credentials/{id}Revoke a key immediately
Requires integrations:manage. The key stops working on its next request.
Responses: 200 Revoked, 401 Missing, invalid, expired or revoked key, 403 Error envelope with a stable code, 404 Error envelope with a stable code, 429 Too many requests. Wait the number of seconds in Retry-After.