API Reference
Complete API reference for linked.is REST API
The linked.is API allows you to programmatically manage your short links, bio profiles, and access analytics data.
Base URL
All API requests should be made to:
https://api.linked.is/v1
Authentication
All API requests require authentication using an API token. You can generate an API token from your account settings.
Include your API token in the Authorization header:
curl -X GET "https://api.linked.is/v1/links" \
-H "Authorization: Bearer YOUR_API_TOKEN"
<script setup lang="ts">
const authenticatedApiCall = async () => {
const response = await fetch("https://api.linked.is/v1/links", {
method: "GET",
headers: {
Authorization: "Bearer YOUR_API_TOKEN",
},
});
const data = await response.json();
console.log(data);
return data;
};
</script>
<template>
<div>
<button @click="authenticatedApiCall">Call Authenticated API</button>
</div>
</template>
Response Format
All responses are returned in JSON format:
<script setup lang="ts">
const successResponse = {
success: true,
data: { /* ... */ }
};
const errorResponse = {
success: false,
error: {
code: "INVALID_REQUEST",
message: "Description of the error"
}
};
</script>
<template>
<div>
<h3>Success Response:</h3>
<pre>{{ JSON.stringify(successResponse, null, 2) }}</pre>
<h3>Error Response:</h3>
<pre>{{ JSON.stringify(errorResponse, null, 2) }}</pre>
</div>
</template>
HTTP Status Codes
| Code | Description |
|---|---|
200 | Success |
201 | Created |
400 | Bad Request |
401 | Unauthorized |
403 | Forbidden |
404 | Not Found |
429 | Rate Limit Exceeded |
500 | Internal Server Error |
Rate Limits
API requests are rate limited based on your plan:
| Plan | Requests per minute |
|---|---|
| Free | 60 |
| Pro | 300 |
| Enterprise | Unlimited |
Rate limit information is included in response headers:
<script setup lang="ts">
const rateLimitHeaders = {
"X-RateLimit-Limit": 60,
"X-RateLimit-Remaining": 59,
"X-RateLimit-Reset": 1640000000
};
</script>
<template>
<div>
<h3>Rate Limit Headers:</h3>
<pre>{{ JSON.stringify(rateLimitHeaders, null, 2) }}</pre>
</div>
</template>