Getting Started
Kliqs API lets you create shortlinks from your own app, website, bot, or backend system.
Official Kliqs domains
api.kliqs.me— official API endpoint.kliqs.me— public shortlinks & Bio Pages.home.kliqs.me— marketing website.dash.kliqs.me— dashboard.docs.kliqs.me— documentation.
- Create a Kliqs account.
- Open Dashboard → Settings → API Keys.
- Create an API key.
- Copy the API key once — it won't be shown again.
- Send requests to
POST https://api.kliqs.me/api/v1/linksusing Bearer authentication.
Create API Key
- Sign in to your Kliqs account.
- Open Dashboard → Settings → API Keys.
- Click Create API Key and give it a name (e.g. "production-server").
- Copy the key shown — it is displayed only once.
- Store the key in your backend environment variable (never in the frontend).
- Revoke the key anytime from the same page if leaked or unused.
Before connecting your own backend, you can test your API key from Dashboard → Settings → API Keys → API Self-Test.
Authentication
Include your API key in the Authorization header on every request.
Authorization: Bearer YOUR_API_KEYcurl -X POST "https://api.kliqs.me/api/v1/links" \
-H "Authorization: Bearer kliqs_sk_live_xxxxxxxxx" \
-H "Content-Type: application/json" \
-d '{"url":"https://marketku.id/products/8f3f4f3f-1231-1231-1231"}'Do not expose your API key in frontend, browser, or public apps. Use your API key from your backend/server. Revoke leaked API keys immediately.
Create Shortlink
POST
https://api.kliqs.me/api/v1/links{
"url": "https://marketku.id/products/8f3f4f3f-1231-1231-1231",
"slug": "vps-murah",
"title": "VPS Murah",
"description": "Product link from Marketku"
}Node.js / JavaScript
const response = await fetch("https://api.kliqs.me/api/v1/links", {
method: "POST",
headers: {
"Authorization": "Bearer kliqs_sk_live_xxxxxxxxx",
"Content-Type": "application/json"
},
body: JSON.stringify({
url: "https://marketku.id/products/8f3f4f3f-1231-1231-1231",
slug: "vps-murah",
title: "VPS Murah"
})
});
const result = await response.json();
if (result.success) {
console.log("Short URL:", result.data.short_url);
} else {
console.error(result.error, result.message);
}PHP
$ch = curl_init("https://api.kliqs.me/api/v1/links");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"Authorization: Bearer kliqs_sk_live_xxxxxxxxx",
"Content-Type: application/json"
]);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode([
"url" => "https://marketku.id/products/8f3f4f3f-1231-1231-1231",
"slug" => "vps-murah",
"title" => "VPS Murah"
]));
$response = curl_exec($ch);
curl_close($ch);
$result = json_decode($response, true);
if ($result["success"]) {
echo $result["data"]["short_url"];
}Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| url | string | Yes | Destination URL (http/https). |
| slug | string | Optional | Custom slug. Random if empty. |
| title | string | Optional | Link title. |
| description | string | Optional | Link description. |
| expires_at | ISO datetime | Optional | Expiry timestamp (must be in the future). |
| password | string | Optional | Password-protect the link (stored hashed). |
Response Format
{
"success": true,
"data": {
"id": "link_uuid",
"short_code": "vps-murah",
"short_url": "https://kliqs.me/vps-murah",
"destination_url": "https://marketku.id/products/8f3f4f3f-1231-1231-1231",
"title": "VPS Murah",
"created_at": "2026-06-07T00:00:00Z"
}
}Error Codes
| Status | Error | Description |
|---|---|---|
| 401 | UNAUTHORIZED | Missing Authorization header. |
| 401 | INVALID_API_KEY | API key is invalid. |
| 401 | REVOKED_API_KEY | API key has been revoked. |
| 400 | INVALID_URL | URL is not valid. |
| 400 | RESERVED_SLUG | Slug is reserved. |
| 409 | SLUG_ALREADY_EXISTS | Slug already taken. |
| 403 | SHORTLINK_LIMIT_REACHED | Plan shortlink limit reached. |
| 429 | API_LIMIT_REACHED | Monthly API request limit reached. |
| 500 | INTERNAL_ERROR | Server error. |
Rate Limits
| Plan | Requests / month | Max shortlinks |
|---|---|---|
| Free | 30 | 5 |
| Starter | 1.000 | 50 |
| Pro | 10.000 | 200 |
| Business | 30.000 | 500 |
- Usage resets at the start of each month (UTC).
- Requests rejected for invalid API keys do not count.
- Successful requests count toward the monthly limit.
- When the limit is reached, the API returns HTTP 429.
E-commerce Integration
When a new product is created in your e-commerce system, call the Kliqs API from your backend and store the returned short URL.
- Product created.
- Backend builds the long product URL.
- Backend sends the URL to the Kliqs API.
- Kliqs returns the short_url.
- Backend stores short_url on the product record.
- WhatsApp bot sends the product update with the short_url.
{
"url": "https://marketku.id/products/PRODUCT_UUID",
"slug": "produk-sepatu-001",
"title": "Produk Sepatu"
}WhatsApp Bot Flow
After receiving the short URL, your WhatsApp bot can send a cleaner product update message.
New product available:
VPS Murah
https://kliqs.me/vps-murahBest Practices
- Always call the API from your backend, not the frontend.
- Keep your API key secret.
- Use a custom slug only when needed.
- Handle 409 slug conflict errors.
- Store the returned short_url in your database.
- Retry safely only for 5xx errors.
- Do not spam API requests.
- Revoke leaked keys immediately.
FAQ
Can the Free plan use the API?
Yes. Free plan gets 30 API requests per month.
Can I see my API key again after creating it?
No. The API key is shown only once at creation. Create a new one if you lose it.
Do API-created links appear in the dashboard?
Yes. Links are stored in the same table and appear under Dashboard → Links.