Shorten URLs, fetch analytics and manage links from any code. REST, JSON, one bearer token.
API access ships with the Full Stack plan. Head to the dashboard, scroll to the "Developer API" section, name your key, and click Generate. Your full key is shown once — copy it immediately.
POST to /api/links. target_url is required; everything else is optional. Plan limits apply.
curl -X POST https://fluxly.uk/api/links \
-H "Authorization: Bearer fluxly_live_xxxxxxxxxxxxxxxxxxxxxxxxx" \
-H "Content-Type: application/json" \
-d '{
"target_url": "https://example.com/very/long/path",
"custom_slug": "my-link",
"expires_at": "2026-12-31T23:59:00Z",
"password": "optional-passphrase"
}'{
"link_id": "lnk_abcdef123456",
"slug": "my-link",
"target_url": "https://example.com/very/long/path",
"has_password": true,
"expires_at": "2026-12-31T23:59:00+00:00",
"click_count": 0
}curl https://fluxly.uk/api/links \
-H "Authorization: Bearer fluxly_live_xxxxxxxxxxxxxxxxxxxxxxxxx"curl https://fluxly.uk/api/links/lnk_abcdef123456/analytics \
-H "Authorization: Bearer fluxly_live_xxxxxxxxxxxxxxxxxxxxxxxxx"curl -X DELETE https://fluxly.uk/api/links/lnk_abcdef123456 \
-H "Authorization: Bearer fluxly_live_xxxxxxxxxxxxxxxxxxxxxxxxx"// Node.js (no SDK needed — just fetch)
const res = await fetch("https://fluxly.uk/api/links", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.FLUXLY_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
target_url: "https://example.com/long-url",
custom_slug: "launch-day",
}),
});
const link = await res.json();
console.log("Short URL:", `https://fluxly.uk/r/${link.slug}`);# Python (with requests)
import os, requests
r = requests.post(
"https://fluxly.uk/api/links",
headers={"Authorization": f"Bearer {os.environ['FLUXLY_API_KEY']}"},
json={"target_url": "https://example.com/long-url", "custom_slug": "launch-day"},
)
link = r.json()
print("Short URL:", f"https://fluxly.uk/r/{link['slug']}")