Profiles API
API endpoints for managing bio profiles
Create and manage bio profiles programmatically.
Create Profile
Create a new bio profile.
POST /v1/profiles
Request Body
| Parameter | Type | Required | Description |
|---|---|---|---|
displayName | string | Yes | Display name shown on the profile |
slug | string | Yes | Unique URL slug for the profile |
bio | string | No | Short biography text |
avatar | string | No | Avatar image URL |
Example Request
curl -X POST "https://api.linked.is/v1/profiles" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"displayName": "John Doe",
"slug": "johndoe",
"bio": "Developer & Creator",
"avatar": "https://example.com/avatar.jpg"
}'
<script setup lang="ts">
const createProfile = async () => {
const response = await fetch("https://api.linked.is/v1/profiles", {
method: "POST",
headers: {
Authorization: "Bearer YOUR_API_TOKEN",
"Content-Type": "application/json",
},
body: JSON.stringify({
displayName: "John Doe",
slug: "johndoe",
bio: "Developer & Creator",
avatar: "https://example.com/avatar.jpg"
}),
});
const data = await response.json();
console.log(data);
return data;
};
</script>
<template>
<div>
<button @click="createProfile">Create Profile</button>
</div>
</template>
Example Response
<script setup lang="ts">
const profileResponse = {
success: true,
data: {
id: "prof_123456",
displayName: "John Doe",
slug: "johndoe",
bio: "Developer & Creator",
avatar: "https://example.com/avatar.jpg",
profileUrl: "https://linked.is/johndoe",
views: 0,
createdAt: "2024-01-15T10:30:00Z"
}
};
</script>
<template>
<pre>{{ JSON.stringify(profileResponse, null, 2) }}</pre>
</template>
Get Profile
Retrieve a specific profile by ID.
GET /v1/profiles/:id
Example Request
curl -X GET "https://api.linked.is/v1/profiles/prof_123456" \
-H "Authorization: Bearer YOUR_API_TOKEN"
<script setup lang="ts">
const getProfile = async () => {
const response = await fetch("https://api.linked.is/v1/profiles/prof_123456", {
headers: {
Authorization: "Bearer YOUR_API_TOKEN",
},
});
const data = await response.json();
console.log(data);
return data;
};
</script>
<template>
<div>
<button @click="getProfile">Get Profile</button>
</div>
</template>
Example Response
<script setup lang="ts">
const profileResponse = {
success: true,
data: {
id: "prof_123456",
displayName: "John Doe",
slug: "johndoe",
bio: "Developer & Creator",
avatar: "https://example.com/avatar.jpg",
profileUrl: "https://linked.is/johndoe",
views: 1250,
createdAt: "2024-01-15T10:30:00Z",
blocks: [
{
id: "block_1",
type: "link",
label: "My Website",
content: "https://example.com",
order: 0,
isVisible: true
}
]
}
};
</script>
<template>
<pre>{{ JSON.stringify(profileResponse, null, 2) }}</pre>
</template>
Update Profile
Update an existing profile.
PATCH /v1/profiles/:id
Request Body
| Parameter | Type | Description |
|---|---|---|
displayName | string | Display name |
slug | string | URL slug |
bio | string | Biography text |
avatar | string | Avatar URL |
Example Request
curl -X PATCH "https://api.linked.is/v1/profiles/prof_123456" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"bio": "Updated bio text"
}'
<script setup lang="ts">
const updateProfile = async () => {
const response = await fetch("https://api.linked.is/v1/profiles/prof_123456", {
method: "PATCH",
headers: {
Authorization: "Bearer YOUR_API_TOKEN",
"Content-Type": "application/json",
},
body: JSON.stringify({
bio: "Updated bio text"
}),
});
const data = await response.json();
console.log(data);
return data;
};
</script>
<template>
<div>
<button @click="updateProfile">Update Profile</button>
</div>
</template>
Delete Profile
Delete a profile permanently.
DELETE /v1/profiles/:id
Example Request
curl -X DELETE "https://api.linked.is/v1/profiles/prof_123456" \
-H "Authorization: Bearer YOUR_API_TOKEN"
<script setup lang="ts">
const deleteProfile = async () => {
const response = await fetch("https://api.linked.is/v1/profiles/prof_123456", {
method: "DELETE",
headers: {
Authorization: "Bearer YOUR_API_TOKEN",
},
});
const data = await response.json();
console.log(data);
return data;
};
</script>
<template>
<div>
<button @click="deleteProfile" class="danger">Delete Profile</button>
</div>
</template>
List Profiles
Get all your profiles.
GET /v1/profiles
Example Response
<script setup lang="ts">
const listProfilesResponse = {
success: true,
data: {
items: [
{
id: "prof_123456",
displayName: "John Doe",
slug: "johndoe",
profileUrl: "https://linked.is/johndoe",
views: 1250,
createdAt: "2024-01-15T10:30:00Z"
}
]
}
};
</script>
<template>
<pre>{{ JSON.stringify(listProfilesResponse, null, 2) }}</pre>
</template>
Profile Blocks
Add Block
Add a new block to a profile.
POST /v1/profiles/:id/blocks
Request Body
| Parameter | Type | Required | Description |
|---|---|---|---|
type | string | Yes | Block type (link, heading, paragraph, etc.) |
label | string | No | Block label/title |
content | string | No | Block content (URL for links, text for others) |
icon | string | No | Icon name |
settings | object | No | Additional settings |
Example Request
curl -X POST "https://api.linked.is/v1/profiles/prof_123456/blocks" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"type": "link",
"label": "My GitHub",
"content": "https://github.com/johndoe",
"icon": "i-simple-icons-github"
}'
<script setup lang="ts">
const addBlock = async () => {
const response = await fetch("https://api.linked.is/v1/profiles/prof_123456/blocks", {
method: "POST",
headers: {
Authorization: "Bearer YOUR_API_TOKEN",
"Content-Type": "application/json",
},
body: JSON.stringify({
type: "link",
label: "My GitHub",
content: "https://github.com/johndoe",
icon: "i-simple-icons-github"
}),
});
const data = await response.json();
console.log(data);
return data;
};
</script>
<template>
<div>
<button @click="addBlock">Add Block</button>
</div>
</template>
Update Block
PATCH /v1/profiles/:profileId/blocks/:blockId
Delete Block
DELETE /v1/profiles/:profileId/blocks/:blockId
Reorder Blocks
PUT /v1/profiles/:id/blocks/reorder
<script setup lang="ts">
const reorderBlocks = async () => {
const response = await fetch("https://api.linked.is/v1/profiles/prof_123456/blocks/reorder", {
method: "PUT",
headers: {
Authorization: "Bearer YOUR_API_TOKEN",
"Content-Type": "application/json",
},
body: JSON.stringify({
blocks: [
{ id: "block_1", order: 0 },
{ id: "block_2", order: 1 },
{ id: "block_3", order: 2 }
]
}),
});
const data = await response.json();
console.log(data);
return data;
};
</script>
<template>
<div>
<button @click="reorderBlocks">Reorder Blocks</button>
</div>
</template>
Block Types
| Type | Description |
|---|---|
link | Clickable link button |
heading | Text heading |
paragraph | Text paragraph |
divider | Visual separator |
spacer | Empty space |
socials | Social media icons |
image | Image display |
youtube | YouTube video embed |
spotify | Spotify embed |
Error Codes
| Code | Description |
|---|---|
PROFILE_NOT_FOUND | The specified profile does not exist |
SLUG_TAKEN | The slug is already in use |
BLOCK_NOT_FOUND | The specified block does not exist |
INVALID_BLOCK_TYPE | The block type is not supported |