Recommendation: Use the interactive Swagger UI for full API reference, live request testing, and schema exploration. Open Swagger UI →
Every request must carry your API token in the X-API-Token header.
X-API-Token: <your_api_token>
Generate and manage tokens from your profile page.
| Plan | Calls per minute |
|---|---|
| Free | 6 |
| Starter | 30 |
| Pro | 120 |
/api/v1/shorten
Description: Shorten a single URL. Optionally provide a custom alias code.
Request body (JSON):
{ "long_url": "https://example.com/long/path", "custom_code": "my-alias" }
Success response (201):
{
"short_url": "https://stu.cm/my-alias",
"long_url": "https://example.com/long/path",
"code": "my-alias"
}
/api/v1/shorten/bulk
Description: Shorten up to 100 URLs in a single call.
{ "urls": ["https://a.com/path1", "https://b.com/path2"] }
/api/v1/shorten/<code>/stats
Description: Retrieve total and unique click statistics for a link you own.
{
"code": "AbCdEf",
"total_clicks": 142,
"unique_clicks": 98
}
/api/v1/links
Description: List all links belonging to the authenticated token owner. Paginated.
/api/v1/shorten/<code>
Description: Update title, destination URL, expiry date or active status of an existing link. (Starter plan)
{ "long_url": "https://new-destination.com", "is_active": true }
/api/v1/shorten/<code>
Description: Permanently delete a short link. Only the owner can delete.
/api/v1/check/<code>
No token required
Description: Publicly check the destination and safety status of any ShortU link. No authentication needed.
Get your API token from your profile and start making requests today.