Documentation
How to use shortn — manually and via API. Simple, predictable, no bloat.
Web usage
- Go to shortn.pages.dev
- Paste a long URL (http/https)
- Optional: set a custom slug (3–32, a–z 0–9 _ -)
- Click Shorten → copy/share/QR
API
POST /api/create
curl -X POST https://shortn.pages.dev/api/create \
-H "Content-Type: application/json" \
-d '{"url":"https://example.com/long","custom":"demo"}'
Response 201:
{
"shortUrl": "https://shortn.pages.dev/demo",
"slug": "demo",
"clicks": 0
}
GET /api/links
curl https://shortn.pages.dev/api/links
GET /api/stats
curl https://shortn.pages.dev/api/stats
GET /api/check?slug=...
curl "https://shortn.pages.dev/api/check?slug=demo"
Rate limits
- POST /api/create: 10 requests/min per IP
- GET /api/links: 30/min
- GET /api/stats: 60/min
Notes
Redirects are 302. Clicks increment on each visit. Slugs are lowercase. Reserved paths are blocked.