apiKey).
What is verificationToken?
A short-lived JWT (~15 minutes) returned when a second step is required. It is not the API key.
Full flow for agents
First account and first workspace
The first workspace is created automatically on phone verification — not onregister.
Second workspace
workspace:create (or empty scopes during onboarding).
Login with workspaceId
- Optional
workspaceId: defaults to most recent OWNER workspace. - Only workspaces where you are OWNER or ADMIN accept a new key via login.
createApiKey: false→ onlysessionToken.
2FA login
Step A — email + password →requiresSecondFactor + verificationToken.
Step B — same endpoint with that token + totpCode (+ optional createApiKey, workspaceId).
Register / verify / login summary
Next: Quick start · Workspaces

