Skip to main content

Domains

A custom domain serves your short links from your own host, such as go.example.com. With an API key you can list domains, to get the domain_id you set on a link. Adding and verifying domains happens in the app. The Custom domains guide walks through the DNS setup.

The domain object​

FieldTypeDescription
idstringUnique id. Set it as domain_id on a link.
hoststringThe host, for example go.example.com.
verifiedbooleantrue once the DNS check passed. Only verified domains can serve links.
verification_tokenstringThe TXT record value, linklane-verify=….
owner_idstringThe user who added it.
created_atstringISO 8601.
verified_atstring | nullWhen verification passed.

List domains​

GET/api/domains
Auth
API key or session · links:read
Plan
All plans

Returns the custom domains you added, up to 100.

curl https://api.linklane.io/api/domains \
-H "Authorization: Bearer $LINKLANE_API_KEY"
Response · 200 OK
[
{
"id": "9a3e5c71-2b4d-4f60-8e1a-7d2c3b4a5f60",
"host": "go.example.com",
"verified": true,
"verification_token": "linklane-verify=Qm9vS2t3ZXJ0eTEyMw",
"owner_id": "4e2f0c1a-9b7d-4d3e-a1f2-5c6b7a8d9e0f",
"created_at": "2026-10-12T15:20:00+00:00",
"verified_at": "2026-10-12T15:31:44+00:00"
}
]

Send that id as domain_id when you create a link. The link's short_url then uses your host. An unverified domain returns 400 Domain not verified.

Dashboard-only domain endpoints​

These need a dashboard session and the admin or owner role.

POST/api/domains
Auth
Dashboard session only
Plan
All plans

Adds a domain. Body: { "host": "go.example.com" }. Returns the domain with its verification_token. Your plan sets how many domains you can add: Free 1, Pro 5, Growth 10, Enterprise no limit. Over the limit returns 402. A host another account claimed returns 409. An unverified domain is removed after 7 days.

POST/api/domains/{domain_id}/verify
Auth
Dashboard session only
Plan
All plans

Checks public DNS for a TXT record at the host or at _linklane.<host> that holds the verification_token. Returns the domain with verified: true, or 400 if the record isn't there yet.

DELETE/api/domains/{domain_id}
Auth
Dashboard session only
Plan
All plans

Removes the domain. Its links move back to the default short host.