Pages and page links
Every route for pages and their links, each with a request example and the response returned. A page is referred to by its id or by its custom address (slug).
- GET
/v1/pagesList pages - POST
/v1/pagesCreate a page - GET
/v1/pages/{id}Read a page - PATCH
/v1/pages/{id}Edit a page - DELETE
/v1/pages/{id}Delete a page - GET
/v1/pages/{id}/linksList a page's links - POST
/v1/pages/{id}/linksAdd a link - GET
/v1/pages/{id}/links/{lien}Read a link - PATCH
/v1/pages/{id}/links/{lien}Edit a link - DELETE
/v1/pages/{id}/links/{lien}Delete a link
List pages
GET/v1/pages
The environment's pages, newest first. Read scope.
?search=— searches the name, the custom address and the id?tag=— a tag id: only the pages that carry it?page=and?per_page=— pagination, 50 per page by default, 100 at most
curl "https://api.tinylink.fr/v1/pages?per_page=2" \
-H "Authorization: Bearer tl_your_token"
const response = await fetch('https://api.tinylink.fr/v1/pages?per_page=2', {
headers: { Authorization: 'Bearer tl_your_token' },
});
const data = await response.json();
$ch = curl_init('https://api.tinylink.fr/v1/pages?per_page=2');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer tl_your_token'],
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
import requests
response = requests.get(
'https://api.tinylink.fr/v1/pages?per_page=2',
headers={'Authorization': 'Bearer tl_your_token'},
)
data = response.json()
Possible responses
{
"data": [
{
"id": "P6ac40109381964",
"type": "page",
"name": "My page",
"description": "All my links in one place.",
"slug": "my-page",
"url": "https://tnylnk.fr/my-page",
"status": "active",
"password_protected": false,
"restricted": false,
"tags": [],
"qr_code": null,
"created_at": "2026-10-05T21:56:57+02:00",
"edit_url": "https://app.tinylink.fr/page-edit?id=P6ac40109381964"
}
],
"pagination": {
"page": 1,
"per_page": 2,
"total": 1,
"total_pages": 1
}
} No token in the request
{
"error": {
"code": "missing_token",
"message": "Send your token in the header: Authorization: Bearer tl_…"
}
} Unknown or revoked token
{
"error": {
"code": "invalid_token",
"message": "This token does not exist or has been revoked."
}
} The owner's plan does not include the API
{
"error": {
"code": "plan_required",
"message": "The TinyLink API is included in the Pro and Business plans. Upgrade the plan of this environment's owner to use it."
}
} The token does not carry the Read scope
{
"error": {
"code": "insufficient_scope",
"message": "This token does not have the \"read\" scope.",
"details": {
"required_scope": "read"
}
}
} More than 120 requests within the minute
{
"error": {
"code": "rate_limited",
"message": "Too many requests: 120 per minute per token."
}
} Create a page
POST/v1/pages
name is required. The response is the page created, with its links. Write scope.
name— the page's name, 100 characters at mostdescription— 2,000 characters at mostslug— the custom address: letters, digits,-,_and., 40 characters at mostpassword— protects the page with a passwordtags— a list of tag ids from the environmentqr_code—truefor the classic QR code, or a template idlinks— links to add in one go (100 at most), described as in "Add a link"
curl -X POST https://api.tinylink.fr/v1/pages \
-H "Authorization: Bearer tl_your_token" \
-H "Content-Type: application/json" \
-d '{
"name": "My page",
"slug": "my-page",
"links": [
{
"title": "My website",
"url": "https://example.com"
},
{
"title": "Contact",
"url": "hello@example.com"
}
]
}'
const response = await fetch('https://api.tinylink.fr/v1/pages', {
method: 'POST',
headers: {
Authorization: 'Bearer tl_your_token',
'Content-Type': 'application/json',
},
body: JSON.stringify({
name: 'My page',
slug: 'my-page',
links: [
{ title: 'My website', url: 'https://example.com' },
{ title: 'Contact', url: 'hello@example.com' },
],
}),
});
const data = await response.json();
$ch = curl_init('https://api.tinylink.fr/v1/pages');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer tl_your_token', 'Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode([
'name' => 'My page',
'slug' => 'my-page',
'links' => [
['title' => 'My website', 'url' => 'https://example.com'],
['title' => 'Contact', 'url' => 'hello@example.com'],
],
]),
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
import requests
response = requests.post(
'https://api.tinylink.fr/v1/pages',
headers={'Authorization': 'Bearer tl_your_token'},
json={
'name': 'My page',
'slug': 'my-page',
'links': [
{'title': 'My website', 'url': 'https://example.com'},
{'title': 'Contact', 'url': 'hello@example.com'},
],
},
)
data = response.json()
Possible responses
{
"id": "P6ac40109381964",
"type": "page",
"name": "My page",
"description": "",
"slug": "my-page",
"url": "https://tnylnk.fr/my-page",
"status": "active",
"password_protected": false,
"restricted": false,
"tags": [],
"qr_code": null,
"created_at": "2026-10-05T21:56:57+02:00",
"edit_url": "https://app.tinylink.fr/page-edit?id=P6ac40109381964",
"links": [
{
"id": "L6ac4011edb7c6",
"title": "My website",
"description": "",
"url": "https://example.com",
"type": "url",
"format": "LIST",
"size": "FULL",
"visible": true,
"archived": false,
"position": 1,
"status": "active",
"image": null,
"created_at": "2026-10-05T21:57:18+02:00"
},
{
"id": "L6ac4011ee9fab",
"title": "Contact",
"description": "",
"url": "hello@example.com",
"type": "email",
"format": "LIST",
"size": "FULL",
"visible": true,
"archived": false,
"position": 2,
"status": "active",
"image": null,
"created_at": "2026-10-05T21:57:18+02:00"
}
]
} The body is not a JSON object
{
"error": {
"code": "invalid_json",
"message": "The request body must be a JSON object."
}
} No token in the request
{
"error": {
"code": "missing_token",
"message": "Send your token in the header: Authorization: Bearer tl_…"
}
} Unknown or revoked token
{
"error": {
"code": "invalid_token",
"message": "This token does not exist or has been revoked."
}
} The plan's number of pages is reached
{
"error": {
"code": "plan_limit_reached",
"message": "The page limit of the plan has been reached."
}
} The owner's plan does not include the API
{
"error": {
"code": "plan_required",
"message": "The TinyLink API is included in the Pro and Business plans. Upgrade the plan of this environment's owner to use it."
}
} The token does not carry the Write scope
{
"error": {
"code": "insufficient_scope",
"message": "This token does not have the \"write\" scope.",
"details": {
"required_scope": "write"
}
}
} Custom address already used by a page or a link
{
"error": {
"code": "slug_taken",
"message": "This slug is already taken.",
"details": {
"field": "slug"
}
}
} Required field missing or empty
{
"error": {
"code": "validation_failed",
"message": "The \"name\" field is required.",
"details": {
"field": "name"
}
}
} More than 120 requests within the minute
{
"error": {
"code": "rate_limited",
"message": "Too many requests: 120 per minute per token."
}
} Read a page
GET/v1/pages/{id}
The page and its links, in display order; archived links come last. Read scope.
curl https://api.tinylink.fr/v1/pages/my-page \
-H "Authorization: Bearer tl_your_token"
const response = await fetch('https://api.tinylink.fr/v1/pages/my-page', {
headers: { Authorization: 'Bearer tl_your_token' },
});
const data = await response.json();
$ch = curl_init('https://api.tinylink.fr/v1/pages/my-page');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer tl_your_token'],
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
import requests
response = requests.get(
'https://api.tinylink.fr/v1/pages/my-page',
headers={'Authorization': 'Bearer tl_your_token'},
)
data = response.json()
Possible responses
{
"id": "P6ac40109381964",
"type": "page",
"name": "My page",
"description": "All my links in one place.",
"slug": "my-page",
"url": "https://tnylnk.fr/my-page",
"status": "active",
"password_protected": false,
"restricted": false,
"tags": [],
"qr_code": null,
"created_at": "2026-10-05T21:56:57+02:00",
"edit_url": "https://app.tinylink.fr/page-edit?id=P6ac40109381964",
"links": [
{
"id": "L6ac4011edb7c6",
"title": "My website",
"description": "",
"url": "https://example.com",
"type": "url",
"format": "LIST",
"size": "FULL",
"visible": true,
"archived": false,
"position": 1,
"status": "active",
"image": null,
"created_at": "2026-10-05T21:57:18+02:00"
},
{
"id": "L6ac4011ee9fab",
"title": "Contact",
"description": "",
"url": "hello@example.com",
"type": "email",
"format": "LIST",
"size": "FULL",
"visible": true,
"archived": false,
"position": 2,
"status": "active",
"image": null,
"created_at": "2026-10-05T21:57:18+02:00"
}
]
} No token in the request
{
"error": {
"code": "missing_token",
"message": "Send your token in the header: Authorization: Bearer tl_…"
}
} Unknown or revoked token
{
"error": {
"code": "invalid_token",
"message": "This token does not exist or has been revoked."
}
} The owner's plan does not include the API
{
"error": {
"code": "plan_required",
"message": "The TinyLink API is included in the Pro and Business plans. Upgrade the plan of this environment's owner to use it."
}
} The token does not carry the Read scope
{
"error": {
"code": "insufficient_scope",
"message": "This token does not have the \"read\" scope.",
"details": {
"required_scope": "read"
}
}
} No page with this id or slug in the environment
{
"error": {
"code": "not_found",
"message": "Page not found in this environment."
}
} More than 120 requests within the minute
{
"error": {
"code": "rate_limited",
"message": "Too many requests: 120 per minute per token."
}
} Edit a page
PATCH/v1/pages/{id}
Only send the fields to change: name, description, slug, password. null removes the custom address or the password. The response is the updated page. Write scope.
curl -X PATCH https://api.tinylink.fr/v1/pages/P6ac40109381964 \
-H "Authorization: Bearer tl_your_token" \
-H "Content-Type: application/json" \
-d '{"description":"All my links in one place.","password":null}'
const response = await fetch('https://api.tinylink.fr/v1/pages/P6ac40109381964', {
method: 'PATCH',
headers: {
Authorization: 'Bearer tl_your_token',
'Content-Type': 'application/json',
},
body: JSON.stringify({ description: 'All my links in one place.', password: null }),
});
const data = await response.json();
$ch = curl_init('https://api.tinylink.fr/v1/pages/P6ac40109381964');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'PATCH',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer tl_your_token', 'Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode([
'description' => 'All my links in one place.',
'password' => null,
]),
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
import requests
response = requests.patch(
'https://api.tinylink.fr/v1/pages/P6ac40109381964',
headers={'Authorization': 'Bearer tl_your_token'},
json={'description': 'All my links in one place.', 'password': None},
)
data = response.json()
Possible responses
{
"id": "P6ac40109381964",
"type": "page",
"name": "My page",
"description": "All my links in one place.",
"slug": "my-page",
"url": "https://tnylnk.fr/my-page",
"status": "active",
"password_protected": false,
"restricted": false,
"tags": [],
"qr_code": null,
"created_at": "2026-10-05T21:56:57+02:00",
"edit_url": "https://app.tinylink.fr/page-edit?id=P6ac40109381964",
"links": [
{
"id": "L6ac4011edb7c6",
"title": "My website",
"description": "",
"url": "https://example.com",
"type": "url",
"format": "LIST",
"size": "FULL",
"visible": true,
"archived": false,
"position": 1,
"status": "active",
"image": null,
"created_at": "2026-10-05T21:57:18+02:00"
},
{
"id": "L6ac4011ee9fab",
"title": "Contact",
"description": "",
"url": "hello@example.com",
"type": "email",
"format": "LIST",
"size": "FULL",
"visible": true,
"archived": false,
"position": 2,
"status": "active",
"image": null,
"created_at": "2026-10-05T21:57:18+02:00"
}
]
} The body is not a JSON object
{
"error": {
"code": "invalid_json",
"message": "The request body must be a JSON object."
}
} No token in the request
{
"error": {
"code": "missing_token",
"message": "Send your token in the header: Authorization: Bearer tl_…"
}
} Unknown or revoked token
{
"error": {
"code": "invalid_token",
"message": "This token does not exist or has been revoked."
}
} The owner's plan does not include the API
{
"error": {
"code": "plan_required",
"message": "The TinyLink API is included in the Pro and Business plans. Upgrade the plan of this environment's owner to use it."
}
} The token does not carry the Write scope
{
"error": {
"code": "insufficient_scope",
"message": "This token does not have the \"write\" scope.",
"details": {
"required_scope": "write"
}
}
} No page with this id or slug in the environment
{
"error": {
"code": "not_found",
"message": "Page not found in this environment."
}
} Custom address already used by a page or a link
{
"error": {
"code": "slug_taken",
"message": "This slug is already taken.",
"details": {
"field": "slug"
}
}
} No editable field in the body
{
"error": {
"code": "validation_failed",
"message": "Nothing to update. Accepted fields: name, description, slug, password."
}
} Element blocked by moderation
{
"error": {
"code": "element_blocked",
"message": "This element is blocked by moderation and can no longer be modified."
}
} More than 120 requests within the minute
{
"error": {
"code": "rate_limited",
"message": "Too many requests: 120 per minute per token."
}
} Delete a page
DELETE/v1/pages/{id}
Deletes the page, its links and its statistics. This cannot be undone. Delete scope.
curl -X DELETE https://api.tinylink.fr/v1/pages/P6ac40109381964 \
-H "Authorization: Bearer tl_your_token"
const response = await fetch('https://api.tinylink.fr/v1/pages/P6ac40109381964', {
method: 'DELETE',
headers: { Authorization: 'Bearer tl_your_token' },
});
console.log(response.status); // 204
$ch = curl_init('https://api.tinylink.fr/v1/pages/P6ac40109381964');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'DELETE',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer tl_your_token'],
]);
curl_exec($ch);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE); // 204
curl_close($ch);
import requests
response = requests.delete(
'https://api.tinylink.fr/v1/pages/P6ac40109381964',
headers={'Authorization': 'Bearer tl_your_token'},
)
print(response.status_code) # 204
Possible responses
No content
No token in the request
{
"error": {
"code": "missing_token",
"message": "Send your token in the header: Authorization: Bearer tl_…"
}
} Unknown or revoked token
{
"error": {
"code": "invalid_token",
"message": "This token does not exist or has been revoked."
}
} The owner's plan does not include the API
{
"error": {
"code": "plan_required",
"message": "The TinyLink API is included in the Pro and Business plans. Upgrade the plan of this environment's owner to use it."
}
} The token does not carry the Delete scope
{
"error": {
"code": "insufficient_scope",
"message": "This token does not have the \"delete\" scope.",
"details": {
"required_scope": "delete"
}
}
} No page with this id or slug in the environment
{
"error": {
"code": "not_found",
"message": "Page not found in this environment."
}
} More than 120 requests within the minute
{
"error": {
"code": "rate_limited",
"message": "Too many requests: 120 per minute per token."
}
} List a page's links
GET/v1/pages/{id}/links
The page's links, in display order. type is url, email, tel or title; status is active, pending_review or blocked. Read scope.
curl https://api.tinylink.fr/v1/pages/P6ac40109381964/links \
-H "Authorization: Bearer tl_your_token"
const response = await fetch('https://api.tinylink.fr/v1/pages/P6ac40109381964/links', {
headers: { Authorization: 'Bearer tl_your_token' },
});
const data = await response.json();
$ch = curl_init('https://api.tinylink.fr/v1/pages/P6ac40109381964/links');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer tl_your_token'],
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
import requests
response = requests.get(
'https://api.tinylink.fr/v1/pages/P6ac40109381964/links',
headers={'Authorization': 'Bearer tl_your_token'},
)
data = response.json()
Possible responses
{
"data": [
{
"id": "L6ac4011edb7c6",
"title": "My website",
"description": "",
"url": "https://example.com",
"type": "url",
"format": "LIST",
"size": "FULL",
"visible": true,
"archived": false,
"position": 1,
"status": "active",
"image": null,
"created_at": "2026-10-05T21:57:18+02:00"
},
{
"id": "L6ac4011eeb074",
"title": "My socials",
"description": "",
"url": null,
"type": "title",
"format": "TITLE",
"size": "FULL",
"visible": true,
"archived": false,
"position": 2,
"status": "active",
"image": null,
"created_at": "2026-10-05T21:57:18+02:00"
}
]
} No token in the request
{
"error": {
"code": "missing_token",
"message": "Send your token in the header: Authorization: Bearer tl_…"
}
} Unknown or revoked token
{
"error": {
"code": "invalid_token",
"message": "This token does not exist or has been revoked."
}
} The owner's plan does not include the API
{
"error": {
"code": "plan_required",
"message": "The TinyLink API is included in the Pro and Business plans. Upgrade the plan of this environment's owner to use it."
}
} The token does not carry the Read scope
{
"error": {
"code": "insufficient_scope",
"message": "This token does not have the \"read\" scope.",
"details": {
"required_scope": "read"
}
}
} No page with this id or slug in the environment
{
"error": {
"code": "not_found",
"message": "Page not found in this environment."
}
} More than 120 requests within the minute
{
"error": {
"code": "rate_limited",
"message": "Too many requests: 120 per minute per token."
}
} Add a link
POST/v1/pages/{id}/links
Adds a link at the bottom of the page, or several with {"links": [ … ]} (100 at most): the response is then {"data": [ … ]}. Your plan's link limits apply as in the app. Write scope.
title— required, except for theSOCIALformat; 100 characters at mosturl— a web address, an e-mail or a phone number, with or withoutmailto:/tel:; not needed for aTITLEdescription— 1,000 characters at mostformat—LIST(default),BANNER,SQUARE,SOCIAL, orTITLEfor a section titlesize—FULL(default) orHALF, forLIST,BANNERandSQUAREvisible—falseto add it hiddenposition— rank in the page, 1 = top
curl -X POST https://api.tinylink.fr/v1/pages/P6ac40109381964/links \
-H "Authorization: Bearer tl_your_token" \
-H "Content-Type: application/json" \
-d '{"title":"My website","url":"https://example.com"}'
const response = await fetch('https://api.tinylink.fr/v1/pages/P6ac40109381964/links', {
method: 'POST',
headers: {
Authorization: 'Bearer tl_your_token',
'Content-Type': 'application/json',
},
body: JSON.stringify({ title: 'My website', url: 'https://example.com' }),
});
const data = await response.json();
$ch = curl_init('https://api.tinylink.fr/v1/pages/P6ac40109381964/links');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer tl_your_token', 'Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode(['title' => 'My website', 'url' => 'https://example.com']),
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
import requests
response = requests.post(
'https://api.tinylink.fr/v1/pages/P6ac40109381964/links',
headers={'Authorization': 'Bearer tl_your_token'},
json={'title': 'My website', 'url': 'https://example.com'},
)
data = response.json()
Possible responses
{
"id": "L6ac4011edb7c6",
"title": "My website",
"description": "",
"url": "https://example.com",
"type": "url",
"format": "LIST",
"size": "FULL",
"visible": true,
"archived": false,
"position": 1,
"status": "active",
"image": null,
"created_at": "2026-10-05T21:57:18+02:00"
} The body is not a JSON object
{
"error": {
"code": "invalid_json",
"message": "The request body must be a JSON object."
}
} No token in the request
{
"error": {
"code": "missing_token",
"message": "Send your token in the header: Authorization: Bearer tl_…"
}
} Unknown or revoked token
{
"error": {
"code": "invalid_token",
"message": "This token does not exist or has been revoked."
}
} The plan's number of links per page is reached
{
"error": {
"code": "plan_limit_reached",
"message": "The plan allows 50 links per page (50 already used).",
"details": {
"max": 50,
"used": 50
}
}
} The owner's plan does not include the API
{
"error": {
"code": "plan_required",
"message": "The TinyLink API is included in the Pro and Business plans. Upgrade the plan of this environment's owner to use it."
}
} The token does not carry the Write scope
{
"error": {
"code": "insufficient_scope",
"message": "This token does not have the \"write\" scope.",
"details": {
"required_scope": "write"
}
}
} No page with this id or slug in the environment
{
"error": {
"code": "not_found",
"message": "Page not found in this environment."
}
} Required field missing or empty
{
"error": {
"code": "validation_failed",
"message": "The \"title\" field is required.",
"details": {
"field": "title"
}
}
} Neither a web address, nor an e-mail, nor a phone number
{
"error": {
"code": "invalid_url",
"message": "This is not a valid web address, e-mail address or phone number.",
"details": {
"field": "url"
}
}
} Domain flagged as suspicious
{
"error": {
"code": "suspicious_url",
"message": "This address is on our list of suspicious domains and cannot be used.",
"details": {
"field": "url"
}
}
} Element blocked by moderation
{
"error": {
"code": "element_blocked",
"message": "This element is blocked by moderation and can no longer be modified."
}
} More than 120 requests within the minute
{
"error": {
"code": "rate_limited",
"message": "Too many requests: 120 per minute per token."
}
} Read a link
GET/v1/pages/{id}/links/{lien}
A single link of the page, by its id. Read scope.
curl https://api.tinylink.fr/v1/pages/P6ac40109381964/links/L6ac4011edb7c6 \
-H "Authorization: Bearer tl_your_token"
const response = await fetch('https://api.tinylink.fr/v1/pages/P6ac40109381964/links/L6ac4011edb7c6', {
headers: { Authorization: 'Bearer tl_your_token' },
});
const data = await response.json();
$ch = curl_init('https://api.tinylink.fr/v1/pages/P6ac40109381964/links/L6ac4011edb7c6');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer tl_your_token'],
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
import requests
response = requests.get(
'https://api.tinylink.fr/v1/pages/P6ac40109381964/links/L6ac4011edb7c6',
headers={'Authorization': 'Bearer tl_your_token'},
)
data = response.json()
Possible responses
{
"id": "L6ac4011edb7c6",
"title": "My website",
"description": "",
"url": "https://example.com",
"type": "url",
"format": "LIST",
"size": "FULL",
"visible": true,
"archived": false,
"position": 1,
"status": "active",
"image": null,
"created_at": "2026-10-05T21:57:18+02:00"
} No token in the request
{
"error": {
"code": "missing_token",
"message": "Send your token in the header: Authorization: Bearer tl_…"
}
} Unknown or revoked token
{
"error": {
"code": "invalid_token",
"message": "This token does not exist or has been revoked."
}
} The owner's plan does not include the API
{
"error": {
"code": "plan_required",
"message": "The TinyLink API is included in the Pro and Business plans. Upgrade the plan of this environment's owner to use it."
}
} The token does not carry the Read scope
{
"error": {
"code": "insufficient_scope",
"message": "This token does not have the \"read\" scope.",
"details": {
"required_scope": "read"
}
}
} No page with this id or slug in the environment
{
"error": {
"code": "not_found",
"message": "Page not found in this environment."
}
} No link with this id on the page
{
"error": {
"code": "not_found",
"message": "Link not found on this page."
}
} More than 120 requests within the minute
{
"error": {
"code": "rate_limited",
"message": "Too many requests: 120 per minute per token."
}
} Edit a link
PATCH/v1/pages/{id}/links/{lien}
Only send the fields to change: title, description, url, format, size, visible (hide or show), archived (archive or unarchive) and position (move). A component or an integration block can only be hidden, archived or moved. Write scope.
curl -X PATCH https://api.tinylink.fr/v1/pages/P6ac40109381964/links/L6ac4011edb7c6 \
-H "Authorization: Bearer tl_your_token" \
-H "Content-Type: application/json" \
-d '{"title":"My new website","position":2,"visible":false}'
const response = await fetch('https://api.tinylink.fr/v1/pages/P6ac40109381964/links/L6ac4011edb7c6', {
method: 'PATCH',
headers: {
Authorization: 'Bearer tl_your_token',
'Content-Type': 'application/json',
},
body: JSON.stringify({ title: 'My new website', position: 2, visible: false }),
});
const data = await response.json();
$ch = curl_init('https://api.tinylink.fr/v1/pages/P6ac40109381964/links/L6ac4011edb7c6');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'PATCH',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer tl_your_token', 'Content-Type: application/json'],
CURLOPT_POSTFIELDS => json_encode([
'title' => 'My new website',
'position' => 2,
'visible' => false,
]),
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
import requests
response = requests.patch(
'https://api.tinylink.fr/v1/pages/P6ac40109381964/links/L6ac4011edb7c6',
headers={'Authorization': 'Bearer tl_your_token'},
json={'title': 'My new website', 'position': 2, 'visible': False},
)
data = response.json()
Possible responses
{
"id": "L6ac4011edb7c6",
"title": "My new website",
"description": "",
"url": "https://example.com",
"type": "url",
"format": "LIST",
"size": "FULL",
"visible": false,
"archived": false,
"position": 2,
"status": "active",
"image": null,
"created_at": "2026-10-05T21:57:18+02:00"
} The body is not a JSON object
{
"error": {
"code": "invalid_json",
"message": "The request body must be a JSON object."
}
} No token in the request
{
"error": {
"code": "missing_token",
"message": "Send your token in the header: Authorization: Bearer tl_…"
}
} Unknown or revoked token
{
"error": {
"code": "invalid_token",
"message": "This token does not exist or has been revoked."
}
} The owner's plan does not include the API
{
"error": {
"code": "plan_required",
"message": "The TinyLink API is included in the Pro and Business plans. Upgrade the plan of this environment's owner to use it."
}
} The token does not carry the Write scope
{
"error": {
"code": "insufficient_scope",
"message": "This token does not have the \"write\" scope.",
"details": {
"required_scope": "write"
}
}
} No page with this id or slug in the environment
{
"error": {
"code": "not_found",
"message": "Page not found in this environment."
}
} No link with this id on the page
{
"error": {
"code": "not_found",
"message": "Link not found on this page."
}
} No editable field in the body
{
"error": {
"code": "validation_failed",
"message": "Nothing to update. Accepted fields: title, description, url, format, size, visible, archived, position."
}
} Neither a web address, nor an e-mail, nor a phone number
{
"error": {
"code": "invalid_url",
"message": "This is not a valid web address, e-mail address or phone number.",
"details": {
"field": "url"
}
}
} Element blocked by moderation
{
"error": {
"code": "element_blocked",
"message": "This element is blocked by moderation and can no longer be modified."
}
} More than 120 requests within the minute
{
"error": {
"code": "rate_limited",
"message": "Too many requests: 120 per minute per token."
}
} Delete a link
DELETE/v1/pages/{id}/links/{lien}
Deletes the link, its image and its statistics, then renumbers the following ones. Delete scope.
curl -X DELETE https://api.tinylink.fr/v1/pages/P6ac40109381964/links/L6ac4011edb7c6 \
-H "Authorization: Bearer tl_your_token"
const response = await fetch('https://api.tinylink.fr/v1/pages/P6ac40109381964/links/L6ac4011edb7c6', {
method: 'DELETE',
headers: { Authorization: 'Bearer tl_your_token' },
});
console.log(response.status); // 204
$ch = curl_init('https://api.tinylink.fr/v1/pages/P6ac40109381964/links/L6ac4011edb7c6');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'DELETE',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer tl_your_token'],
]);
curl_exec($ch);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE); // 204
curl_close($ch);
import requests
response = requests.delete(
'https://api.tinylink.fr/v1/pages/P6ac40109381964/links/L6ac4011edb7c6',
headers={'Authorization': 'Bearer tl_your_token'},
)
print(response.status_code) # 204
Possible responses
No content
No token in the request
{
"error": {
"code": "missing_token",
"message": "Send your token in the header: Authorization: Bearer tl_…"
}
} Unknown or revoked token
{
"error": {
"code": "invalid_token",
"message": "This token does not exist or has been revoked."
}
} The owner's plan does not include the API
{
"error": {
"code": "plan_required",
"message": "The TinyLink API is included in the Pro and Business plans. Upgrade the plan of this environment's owner to use it."
}
} The token does not carry the Delete scope
{
"error": {
"code": "insufficient_scope",
"message": "This token does not have the \"delete\" scope.",
"details": {
"required_scope": "delete"
}
}
} No page with this id or slug in the environment
{
"error": {
"code": "not_found",
"message": "Page not found in this environment."
}
} No link with this id on the page
{
"error": {
"code": "not_found",
"message": "Link not found on this page."
}
} More than 120 requests within the minute
{
"error": {
"code": "rate_limited",
"message": "Too many requests: 120 per minute per token."
}
}