Traqly API
Create short links, list your links, and read their click counts directly from your own apps and scripts — no dashboard needed. The API is available on the Business plan; generate a key under Settings → API.
Authentication
Every request must include your API key as a Bearer token in theAuthorizationheader:
Authorization: Bearer YOUR_API_KEYKeep your API key secret — treat it like a password. Anyone with it can create links on your account. You can revoke a key any time in Settings → API.
Base URL
https://traqly.vercel.app/api/v1Endpoints
/api/v1/linksCreate a short link in your workspace.
Body parameters
urlrequired — the destination URL.slugoptional — your custom slug (letters, numbers, hyphens). Auto-generated if omitted.titleoptional — a label for the link.
curl -X POST https://traqly.vercel.app/api/v1/links \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"url": "https://example.com", "slug": "my-link"}'{
"id": "clx9a1b2c3...",
"slug": "my-link",
"shortUrl": "https://traqly.vercel.app/my-link",
"url": "https://example.com",
"title": null,
"clicks": 0,
"createdAt": "2026-05-31T12:00:00.000Z"
}/api/v1/linksList your workspace's links, newest first, each with its total click count.
Query parameters
limitoptional — 1–100, default 50.
curl https://traqly.vercel.app/api/v1/links?limit=50 \
-H "Authorization: Bearer YOUR_API_KEY"{
"links": [
{
"id": "clx9a1b2c3...",
"slug": "my-link",
"shortUrl": "https://traqly.vercel.app/my-link",
"url": "https://example.com",
"title": null,
"clicks": 142,
"createdAt": "2026-05-31T12:00:00.000Z"
}
]
}Rate limits
There is no hard rate limit today. Please keep requests reasonable (a few per second); published per-key limits are coming. Each call increments your key's request counter, visible in Settings → API.
Errors
Errors return the appropriate HTTP status with a JSON body:
{ "error": "This slug is already taken." }| Code | Meaning |
|---|---|
| 400 | Bad request — invalid JSON, missing/invalid url, or bad slug. |
| 401 | Missing or invalid API key (or the key was revoked). |
| 409 | The requested slug is already taken. |
| 500 | Something went wrong on our side — retry shortly. |