Skip to content

Labelers

Manage external labeler subscriptions. See the Labelers guide for background.

const TOKEN = "hv_..."; // your API key
const headers = { Authorization: `Bearer ${TOKEN}` };
POST /admin/labelers

Requires labelers:create permission.

const response = await fetch("http://127.0.0.1:3000/admin/labelers", {
method: "POST",
headers: {
...headers,
"Content-Type": "application/json",
},
body: JSON.stringify({ did: "did:plc:ar7c4by46qjdydhdevvrndac" }),
});
FieldTypeRequiredDescription
didstringyesThe labeler’s atproto DID

Response: 201 Created (empty body)

GET /admin/labelers

Requires labelers:read permission.

interface Labeler {
did: string;
status: string;
cursor: number | null;
created_at: string;
updated_at: string;
declared: boolean;
}
const response = await fetch("http://127.0.0.1:3000/admin/labelers", {
headers,
});
const data: Labeler[] = await response.json();

Response: 200 OK

[
{
"did": "did:plc:ar7c4by46qjdydhdevvrndac",
"status": "active",
"cursor": 1234,
"created_at": "2026-03-15T00:00:00Z",
"updated_at": "2026-03-15T00:00:00Z"
}
]
FieldTypeDescription
didstringThe labeler’s DID
statusstringactive or paused
cursornumber|nullLast processed event cursor (null if never synced)
created_atstringISO 8601 creation timestamp
updated_atstringISO 8601 last-updated timestamp
PATCH /admin/labelers/{did}

Requires labelers:create permission.

const response = await fetch(
"http://127.0.0.1:3000/admin/labelers/did:plc:ar7c4by46qjdydhdevvrndac",
{
method: "PATCH",
headers: {
...headers,
"Content-Type": "application/json",
},
body: JSON.stringify({ status: "paused" }),
},
);
FieldTypeRequiredDescription
statusstringyesNew status: active or paused

Response: 200 OK

DELETE /admin/labelers/{did}

Requires labelers:delete permission. Removes the subscription and all labels emitted by this labeler.

declared is true for a labeler the project’s happyview.toml subscribes to under [labels] subscribe. Deleting one returns 409 Conflict; remove it from the file instead.

const response = await fetch(
"http://127.0.0.1:3000/admin/labelers/did:plc:ar7c4by46qjdydhdevvrndac",
{
method: "DELETE",
headers,
},
);

Response: 204 No Content