Validate an invite
Check whether an invite code is live before letting someone redeem it. Use this to build your own join page: look up the code, then show the invited email or a specific message for why it can't be used.
GET /sdk/v1/waitlist/invites/{code}
- Auth: None — public.
- Always returns
200when the code is well-formed, so you can render a precise message per outcome. Use thevalidfield to gate redemption.
Path parameters
| Parameter | Type | Description |
|---|---|---|
code | string | The invite code (1–200 chars), typically from an invite link. |
Response
| Field | Type | Description |
|---|---|---|
valid | boolean | Whether the code can be redeemed right now. |
reason | string? | Why it's invalid, when valid is false: not_found, expired, accepted, or revoked. |
email | string? | The invited email, when valid. |
waitlist | object? | { id, name } of the waitlist, when valid. |
expiresAt | string? | ISO 8601 expiry timestamp, when set. |
Valid
json
{
"valid": true,
"email": "ada@example.com",
"waitlist": { "id": "wl_launch", "name": "Launch waitlist" },
"expiresAt": "2026-08-01T00:00:00.000Z"
}Invalid
json
{ "valid": false, "reason": "expired" }Example
bash
curl https://api.uselucerna.app/sdk/v1/waitlist/invites/INV-7Q2K9Fts
const res = await fetch(
`https://api.uselucerna.app/sdk/v1/waitlist/invites/${code}`,
);
const invite = await res.json();
if (invite.valid) {
showJoinScreen(invite.email, invite.waitlist.name);
} else {
showReason(invite.reason); // "expired" | "revoked" | "accepted" | "not_found"
}Errors
| Status | code | When |
|---|---|---|
400 | invalid_request | The code is empty or longer than 200 characters. |
A code that simply doesn't exist is not an error — it returns 200 with { "valid": false, "reason": "not_found" }.
Next: Accept an invite →