Programmatically create, manage and query short links and custom domains.
curl -X POST "http://app.shrinkly.in/api/v1/shrink" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{"url":"https://example.com","title":"Example"}'
YOUR_API_TOKEN with the token from your dashboard.
{
"success": false,
"code": "SOME_CODE",
"message": "Human readable message"
}
code for programmatic handling and message for UI display.
http://app.shrinkly.in/api/v1/shrinkAuthorization: Bearer YOUR_API_TOKEN
Content-Type: application/json
| Field | Type | Required | Description |
|---|---|---|---|
url | string | Yes | Destination URL. |
slug | string | No | Custom short code (must be unique). |
title | string | No | Optional link title. |
custom_domain_id | int | No | Your verified domain id (from /domains). |
is_protected_link | 0/1 | No | Enable password protection. |
password | string | If protected | Password (min 8 chars, letter+number+special). |
password_confirm | string | If protected | Confirm password. |
{
"url": "https://example.com",
"slug": "my-custom-slug",
"title": "My link title",
"custom_domain_id": 12,
"is_protected_link": 1,
"password": "Pass@1234",
"password_confirm": "Pass@1234"
}
{
"success": true,
"data": {
"id": 123,
"short_url": "https://s.shrinkly.in/my-custom-slug",
"domain": "s.shrinkly.in",
"slug": "my-custom-slug",
"destination": "https://example.com",
"title": "My link title",
"is_protected_link": 1
}
}
id or short_code/short_url.GET http://app.shrinkly.in/api/v1/info?id=123
Authorization: Bearer YOUR_API_TOKEN
{
"success": true,
"data": {
"id": 123,
"short_url": "https://s.shrinkly.in/abc123",
"domain": "s.shrinkly.in",
"slug": "abc123",
"destination": "https://example.com",
"clicks": 10,
"is_active": 1,
"created_at": "2026-02-15 10:22:00",
"updated_at": null,
"title": "My link"
}
}
id OR short_url/short_code.{
"id": 123
}
{
"success": true,
"data": {
"deleted": true,
"id": 123
}
}
{
"id": 123,
"new_url": "https://new-example.com"
}
{
"success": true,
"data": {
"id": 123,
"changed": true,
"old_url": "https://example.com",
"new_url": "https://new-example.com"
}
}
{
"items": [
{ "url": "https://a.com", "title": "A", "slug": "" },
{ "url": "https://b.com", "title": "B", "slug": "custom-b" }
]
}
| Param | Type | Default | Description |
|---|---|---|---|
verified | int | -1 | 1 verified only, 0 unverified only, -1 all |
page | int | 1 | Page number |
per_page | int | 50 | Items per page (max 200) |
GET http://app.shrinkly.in/api/v1/domains?verified=1&page=1&per_page=50
Authorization: Bearer YOUR_API_TOKEN
{
"success": true,
"data": {
"items": [
{
"id": 12,
"domain": "links.example.com",
"is_verified": 1,
"ssl_status": "active",
"is_default": 0,
"created_at": "2026-02-15 10:00:00"
}
],
"pagination": {
"page": 1,
"per_page": 50,
"total": 1,
"has_more": false
}
}
}