Admin API
Identity
Resolve accounts for display in admin tools.
const TOKEN = "hv_..."; // your API key
const headers = { Authorization: `Bearer ${TOKEN}` };Resolve a handle or DID
GET /admin/identity/resolve?identifier=<handle-or-did>Requires authentication. No specific permission is needed.
interface ResolvedIdentity {
did: string;
handle: string | null;
}
const params = new URLSearchParams({ identifier: "alice.bsky.social" });
const response = await fetch(
`http://127.0.0.1:3000/admin/identity/resolve?${params}`,
{ headers },
);
const data: ResolvedIdentity = await response.json();| Parameter | Type | Required | Description |
|---|---|---|---|
identifier | string | yes | A handle (a leading @ is allowed) or a DID |
Response: 200 OK
{
"did": "did:plc:abc123",
"handle": "alice.bsky.social"
}handle is null unless the DID document lists the handle in alsoKnownAs and the handle resolves to the same DID.
Returns 400 for malformed input, a handle that cannot be resolved, a DID whose document cannot be fetched, or a resolution that takes longer than 10 seconds. The error names the identifier and a general reason, never the underlying network error.