Toolszu Biolink API

Create, update and track short links on myzu.link from your own apps, sites and scripts. A simple JSON REST API with API keys.

Version 1 · Base address https://toolszu.com/biolink/api/v1

Getting started

  1. The API is part of the Pro and Business plans.
  2. Open Dashboard → Settings → API keys, create a key and copy it — it is shown only once.
  3. Send it with every request. Your first call:
curl https://toolszu.com/biolink/api/v1/me \
  -H "Authorization: Bearer tzb_YOUR_KEY"

Every answer is JSON (UTF-8). Times are UTC in ISO 8601 (2026-12-31T23:59:00Z); click days are counted in India time (Asia/Kolkata), as in your dashboard.

Authentication

Send your key in the Authorization header as a bearer token. If your platform removes that header, use X-API-Key: tzb_… instead. Keys in the address (?key=) are not accepted, so they never end up in logs.

  • Read and write keys can do everything. Read only keys can only use GET.
  • Up to 5 active keys per account. Revoke a key any time — it stops at once. We email you whenever a key is created.
  • Requests must use HTTPS. Plain HTTP is refused.

Limits

PlanCalls a minuteCalls a day
Pro605,000
Business12020,000

Limits count all keys of an account together. Each answer has X-RateLimit-Limit and X-RateLimit-Remaining (per minute). Over the limit you get 429 with a Retry-After header (seconds). Creating links also follows your plan’s short-link limit. Request bodies can be up to 16 KB.

Errors

Errors use HTTP status codes and the same JSON shape. field is added when one input is wrong.

{
  "error": {
    "code": "validation_failed",
    "message": "This name is already taken on this domain.",
    "field": "slug"
  }
}
400invalid_jsonThe body is not a JSON object.
401unauthorizedMissing, wrong or revoked key.
403plan_required · read_only_key · account_unavailable · https_required · not_allowedNot allowed for this key, plan, account or link.
404not_foundNo such address, or the link isn’t in your account.
405method_not_allowedWrong method for this address.
409not_allowedA flagged or removed link can’t be paused or resumed.
413 · 415payload_too_large · unsupported_media_typeBody over 16 KB, or not sent as application/json.
422validation_failedAn input is wrong — see message and field.
429rate_limited · too_many_failed_attemptsToo many calls (or too many wrong keys from your IP). Wait for Retry-After.
500server_errorOur side. Try again; if it repeats, contact support.

Account

GET/me

Your plan, short-link and call limits, and which key you used.

GET/domains

Domains you can make short links on (default: true is used when you don’t pick one).

{ "data": [ { "domain": "myzu.link", "default": true } ] }
GET/links

Your links, newest first. Query: page (1…), per_page (1–100, default 25), q (search name, title or address), status (active, paused, flagged, banned, expired), domain, sort (newest, clicks, name).

curl "https://toolszu.com/biolink/api/v1/links?per_page=10&sort=clicks" \
  -H "Authorization: Bearer tzb_YOUR_KEY"

A link looks like this:

{
  "id": 482,
  "short_url": "https://myzu.link/summer-sale",
  "domain": "myzu.link",
  "slug": "summer-sale",
  "url": "https://example.com/products?utm_source=instagram",
  "title": "Summer sale",
  "ios_url": null,
  "android_url": null,
  "expires_at": "2026-12-31T18:29:00Z",
  "expired_url": "https://example.com/sale-ended",
  "splash": { "enabled": false, "timer": 5, "message": "" },
  "status": "active",
  "clicks": 1204,
  "last_click_at": "2026-11-19T10:12:44Z",
  "created_at": "2026-11-01T08:00:00Z",
  "updated_at": "2026-11-18T12:30:00Z"
}

Lists answer { "data": [ …links ], "meta": { "page", "per_page", "total", "pages" } }; one link answers { "data": { …link } }.

GET/links/{id}

One link.

GET/links/check?slug=summer-sale&domain=myzu.link

Is a name free? Answers { "available": true, "slug": "summer-sale", "domain": "myzu.link", "message": "Available" }.

POST/links/{id}/pausewrite key

Stop a link for now (visitors see “link paused”). /resume starts it again.

DELETE/links/{id}write key

Delete a link and its clicks for good. Answers { "deleted": true, "id": 482 }.

Create a link

POST/linkswrite key

Send JSON. Only url is required; an empty slug gets a random 6-character name. Answers 201 with the new link.

FieldTypeWhat it does
urlstring, requiredThe address the short link opens (http or https). Links from other shorteners are expanded first; unsafe sites are refused.
domainstringOne of /domains. Default: the default domain.
slugstringThe name after the domain: letters, digits, - and _. Empty = random.
titlestring ≤ 120Your own label, shown in your dashboard.
ios_url · android_urlstringDifferent address for iPhone / Android visitors (e.g. app stores).
expires_atISO 8601 or nullWhen the link stops (e.g. 2026-12-31T23:59:00Z). null removes it.
expired_urlstringWhere visitors go after expires_at.
splashobject{ "enabled": bool, "timer": 0|3|5|10, "message": "≤ 200" }. Turning it off needs a plan that allows it.

curl

curl -X POST https://toolszu.com/biolink/api/v1/links \
  -H "Authorization: Bearer tzb_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://example.com/products", "slug": "summer-sale", "title": "Summer sale"}'

PHP

<?php
$ch = curl_init('https://toolszu.com/biolink/api/v1/links');
curl_setopt_array($ch, [
    CURLOPT_POST           => true,
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER     => [
        'Authorization: Bearer ' . getenv('TOOLSZU_API_KEY'),   // keep the key out of your code
        'Content-Type: application/json',
    ],
    CURLOPT_POSTFIELDS     => json_encode(['url' => 'https://example.com/products', 'slug' => 'summer-sale']),
]);
$res = json_decode(curl_exec($ch), true);
echo $res['data']['short_url'] ?? $res['error']['message'];

JavaScript (Node.js 18+)

const res = await fetch("https://toolszu.com/biolink/api/v1/links", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.TOOLSZU_API_KEY}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({ url: "https://example.com/products", slug: "summer-sale" }),
});
const json = await res.json();
console.log(res.ok ? json.data.short_url : json.error.message);

Update a link

PATCH/links/{id}write key

Send only the fields to change — the same fields as Create. Changing url checks the new address again.

curl -X PATCH https://toolszu.com/biolink/api/v1/links/482 \
  -H "Authorization: Bearer tzb_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"title": "Winter sale", "expires_at": null}'

Click stats

GET/links/{id}/stats

Clicks of one link.

GET/stats

Clicks of all your links together.

Query: from and to (dates like 2026-11-01; default the last 30 days, never older than your plan’s analytics history) and any filter: country (US, IN …), region, city, continent, device, os, browser, lang, source, campaign.

{
  "link_id": 482,
  "from": "2026-11-01", "to": "2026-11-19", "oldest_available": "2025-11-20", "timezone": "Asia/Kolkata",
  "totals": { "clicks": 1204, "unique": 980, "qr": 85, "previous_period": 870 },
  "days": [ { "day": "2026-11-01", "clicks": 42, "unique": 37 } ],
  "breakdown": {
    "country": [ { "value": "US", "clicks": 410 } ],
    "device":  [ { "value": "mobile", "clicks": 902 } ],
    "source":  [ { "value": "instagram", "clicks": 512 } ]
  }
}

Bots are not counted. We never store visitors’ IP addresses.

Security

  • Keep keys secret. Put them on your server or in your app’s secure storage (environment variables, secret managers) — never in web pages, front-end JavaScript or public repositories. The API sends no CORS headers, so other websites can’t call it from a visitor’s browser.
  • One key per app. If one leaks, revoke just that one in your dashboard; the others keep working.
  • Least access. Use a read-only key for apps that only show links or stats.
  • We store only a one-way fingerprint of each key, so nobody — not even us — can read it back. Every call is logged for 30 days with the time, address and a shortened IP, and you can see each key’s last use in your dashboard.
  • Links made through the API pass the same safety checks as the dashboard. Abuse of the API (spam, phishing, malware) ends the account.
  • Found a security problem? Email [email protected] with “Security” in the subject.

Version 1 · We add fields without notice (ignore ones you don’t know); anything that breaks existing apps goes into a new version.