Shorten any
link. No questions asked.
Paste a URL. Get a short one. That's it.
recent
api reference
POST
/api/shorten
create a short link
Request
// customSlug is optional { "url": "https://example.com/long-url", "customSlug": "my-link" }
Response 200
{
"shortUrl": "https://b0x.nz/ab3x",
"slug": "ab3x",
"url": "https://example.com/long-url",
"truth": "..."
}
curl example
curl -X POST https://b0x.nz/api/shorten \ -H "Content-Type: application/json" \ -d '{"url":"https://example.com"}'
POST
/api/lookup
fetch link metadata
Add Authorization: Bearer <ADMIN_KEY> to also receive
ip and userAgent.
Request — single
{ "slug": "ab3x" }
Request — batch (max 50)
{ "slugs": ["ab3x", "yz9q"] }
Response 200 — single
{
"slug": "ab3x",
"shortUrl": "https://b0x.nz/ab3x",
"url": "https://example.com/long-url",
"createdAt": "2025-01-01T00:00:00.000Z",
"country": "NZ"
}
Response 200 — batch
{
"results": [ /* array of records */ ],
"notFound": ["yz9q"],
"count": 1
}
curl example
curl -X POST https://b0x.nz/api/lookup \ -H "Content-Type: application/json" \ -d '{"slug":"ab3x"}'
GET
/api/admin
list all links
Requires Authorization: Bearer <ADMIN_KEY>
curl example
curl https://b0x.nz/api/admin \
-H "Authorization: Bearer <key>"
DELETE
/api/admin
delete one or purge all
Requires Authorization: Bearer <ADMIN_KEY>
Delete one
curl -X DELETE https://b0x.nz/api/admin \ -H "Authorization: Bearer <key>" \ -H "Content-Type: application/json" \ -d '{"slug":"ab3x"}'
Purge all
curl -X DELETE https://b0x.nz/api/admin \ -H "Authorization: Bearer <key>" \ -H "Content-Type: application/json" \ -d '{"purgeAll":true}'