Developer documentation

LinkLab for developers,in a real documentation format.

Generate an API key from LinkLab Settings, create short links from your backend, and fetch owner-scoped analytics with the same plan limits shown in your dashboard.

Real API quickstart

Generate one API key from Settings, create one short link, and reuse the returned link ID for analytics requests.

Current endpoint surface

The docs now describe the actual endpoints available today: API key management, link creation, and owner-scoped analytics.

Plan-aware automation

API requests automatically inherit the owner account’s pricing plan, monthly limits, and analytics access controls.

Overview

LinkLab exposes a practical REST API on the same application domain you already use in the dashboard. Logged-in users can generate one API key, and that key automatically inherits the current pricing plan, monthly shortening allowance, and analytics access of the owning account.

POST/api/links
Create a short link

Create a short link with an optional alias, expiration date, and saved QR style using either a session or API key.

GET/api/links/{id}/analytics
Read link analytics

Fetch clicks, devices, browsers, countries, referrers, and timeline insights for a link you own.

POST/api/developers/api-key
Generate your API key

Create or rotate one API key from the dashboard. The key automatically inherits your current pricing plan.

Quickstart

The shortest path to integration is intentionally simple: generate one API key, create one link, store the returned `link.id`, and use that identifier for analytics.

1

Log in to LinkLab and open Settings → API access.

2

Generate one API key and store it safely — it is only shown once.

3

Send the API key in `Authorization: Bearer <key>` or `x-api-key`.

4

Create links with `POST /api/links` and store the returned `link.id` for analytics requests.

Authentication

API keys are owned by one account and are not scoped separately from the account’s current plan. If the plan changes, the API key immediately inherits the updated monthly limit and access behavior.

Preferred header
Authorization: Bearer ll_live_xxxxxxxxxxxxxxxxx
Alternative header
x-api-key: ll_live_xxxxxxxxxxxxxxxxx
Key management endpoints
GET /api/developers/api-key
POST /api/developers/api-key
DELETE /api/developers/api-key

These management endpoints require a logged-in dashboard session. They are intended for the LinkLab UI, not for third-party public use.

Analytics

Use the `link.id` returned from link creation with `GET /api/links/{id}/analytics` to fetch performance data. Analytics access is restricted to links owned by the authenticated account behind the API key.

Request example
curl -X GET https://www.linklab.in/api/links/67fd9e4f2aa4a7e1d763e101/analytics \
  -H "x-api-key: ll_live_xxxxxxxxxxxxxxxxx"
Response example
{
  "analytics": {
    "selectedCode": "spring-launch",
    "metrics": [
      { "title": "Total Clicks", "value": "128", "subtitle": "84 in the last 7 days" },
      { "title": "Unique Visitors", "value": "91", "subtitle": "63 unique visitors this week" }
    ],
    "timeline": [
      { "date": "04/01", "clicks": 12, "uniqueVisitors": 9 },
      { "date": "04/02", "clicks": 18, "uniqueVisitors": 14 }
    ],
    "linkDetails": {
      "originalUrl": "https://example.com/campaigns/spring-launch?utm_source=api",
      "shortUrl": "https://www.linklab.in/spring-launch",
      "shortCode": "spring-launch",
      "createdDate": "4/5/2026",
      "status": "active",
      "qrCodeDataUrl": "data:image/png;base64,..."
    }
  }
}

Plan Limits

The API key does not have its own separate quota bucket. It shares the same monthly shortening allowance already shown in the dashboard and settings UI.

Free
5 links / month

Session or API key requests count against the same account quota once you are logged in.

Launch
500 links / month

Best for small products, internal tools, and lightweight automations.

Growth
5,000 links / month

Built for campaign automation and recurring analytics pulls.

Scale
25,000 links / month

Supports larger teams and high-volume link provisioning workflows.

Errors

LinkLab uses simple JSON error payloads with a `message` field. Link creation may also return a `quota` snapshot when the current plan limit has been reached.

Error codes
400Invalid payload, malformed URL, or unsupported alias format.
401Missing session or invalid API key.
402Monthly shortening quota reached for the current pricing plan.
404Requested link was not found for the authenticated owner.
500Unexpected platform issue. Safe to retry with backoff.
Operational notes
Invalid API keys return `401` and do not fall back to guest mode.
When quota is exhausted, the create endpoint returns `402` with the latest usage snapshot so clients can prompt for an upgrade.
Analytics access is owner-scoped, so an API key can only read links created by the same LinkLab account.
Start in under 60 seconds

Your URL shortener should do more than shorten
better links, QR codes, and analytics

Join teams using LinkLab to shorten URLs, create branded links, track campaign clicks, manage custom domains, and scale link workflows without switching platforms.

No credit card required
Free forever plan
5-minute setup