Docs
Everything the dashboard does, the API does. Create links, read analytics, manage domains and QR codes — 32 operations, and a key you can issue yourself.
Full API referenceBase URL
https://trimly-api.fly.dev/api/v1Every path below is relative to it. Only HTTPS is served.
Authentication
Create a key in the dashboard under Settings → API and send it on every request:
curl https://trimly-api.fly.dev/api/v1/links \
-H "X-API-Key: trm_live_xxxxxxxxxxxx"A key belongs to one workspace and carries that workspace's permissions. It is shown once, when created — store it somewhere you can retrieve it, because it cannot be read back afterwards.
The dashboard authenticates differently, with a short-lived bearer token and an httpOnly refresh cookie. That path is not intended for machine clients.
Your first link
curl -X POST https://trimly-api.fly.dev/api/v1/links \
-H "X-API-Key: trm_live_xxxxxxxxxxxx" \
-H "Content-Type: application/json" \
-d '{"destinationUrl":"https://example.com/a-long-url"}'Everything but destinationUrl is optional. Pass slug for a custom alias, domainId to serve it from one of your own domains, or password, expiresAt and clickLimit to restrict it.
Responses and errors
Every response has the same shape. Failures carry a code and a request id:
{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "Validation failed",
"requestId": "98a9b9dc-a27e-4672-8271-b6e33a65d448"
}
}Quote the request id when reporting a problem — it is logged server-side and identifies the exact request.
Rate limits
Every response carries the current state of your limit:
RateLimit-Limit: 120
RateLimit-Remaining: 118
RateLimit-Reset: 42Exceeding it returns 429. Authentication endpoints are limited far more tightly than the rest.
What you can call
| Group | Operations |
|---|---|
| Links | list, create, read, update, delete, bulk delete, export, import |
| Analytics | overview, top links, export |
| QR codes | list, create, download |
| Domains | list, add, verify |
| Organization | collections, tags |
| Workspace | members, activity |
| Developer | API keys, webhooks |
| Billing | plans, usage |
Each one, with its parameters, request bodies and response schemas, is in the reference, which you can call directly from the page once you paste in a key. The OpenAPI document itself is at /openapi.json if you would rather generate a client.
Webhooks
Rather than polling, register a webhook and receive events as they happen — a link created, a domain verified, a member joining. Deliveries are retried and logged, and the log is kept for 30 days.
Limits and support
Rate limits and quotas depend on your plan; the numbers are on the pricing page. Security issues go to the address on the security page.