API reference
Base URL: https://pico-ya5y.onrender.com
| Method | Path | Description | Response |
|---|---|---|---|
| POST | /v1/links | Create a new short link. | 201 |
| GET | /v1/links | List all links for the authenticated user. | 200 |
| GET | /v1/links/:id | Get details for a specific link. | 200 |
| PATCH | /v1/links/:id | Update a link (long_url, tags, expiry). | 200 |
| DELETE | /v1/links/:id | Permanently remove a link and its analytics. | 204 |
| GET | /v1/links/:id/analytics | Per-link analytics breakdown. | 200 |
| GET | /v1/analytics/summary | Account-level analytics overview. | 200 |
| GET | /v1/links/:id/qrcode | QR code PNG for a short link. | 200 (image/png) |
Common attributes
idstringUnique Snowflake IDshort_codestringBase62 short code (7 chars)long_urlstringOriginal URLclick_countintegerTotal click countcreated_atISO 8601Creation timestampexpires_atISO 8601 | nullExpiry timestampdisabled_atISO 8601 | nullDisabled timestamptagsstring[]User-defined tagsErrors
The API returns conventional HTTP status codes. Errors include a JSON body with details:
{
"detail": "Link not found",
"status": 404
}400Bad request — invalid input
401Unauthorized — missing or invalid API key
404Not found — resource does not exist
409Conflict — resource already exists
429Rate limit exceeded — slow down
500Server error — try again later
Next: Code examples
See the API in action with curl, Python, and JavaScript.