Skip to main content

Agent bootstrap

Create a user + organization and return a developer API key in one call for agent-first onboarding.

POST/api/auth/agent-bootstrap
HTTP referenceScope none (public endpoint)Updated September 27, 2026

This page documents the canonical HTTP contract for this endpoint.

This is an unauthenticated signup route. It rate-limits attempts by request IP and normalized email; configured thresholds use SIGNUP_RATE_LIMIT_PER_IP_PER_MINUTE and SIGNUP_RATE_LIMIT_PER_EMAIL_PER_HOUR; failures currently pass through the route's generic 500 handler.

Omitting scopes, or supplying no recognized scopes, selects the default key scopes: tables:read, tables:write, columns:write, columns:run, and jobs:read. Unsupported scope strings are discarded. The raw apiKey is returned in this response; store it securely.

Signup creates the user, organization, and developer key; it starts registration-sync work and sends confirmation email for an unconfirmed account. If AGENT_BOOTSTRAP_WEBHOOK_URL is configured, webhook delivery is started asynchronously. Credit values come from created records and are not fixed in the response contract.

Body parameters

  • first_namerequired

    string

    User first name.

  • last_namerequired

    string

    User last name.

  • emailrequired

    email string

    Signup email parsed as an email address; stored lowercase.

  • passwordrequired

    string

    User password. The request model declares no length constraint.

  • organization_namerequired

    string

    Organization display name.

  • keyName · optional

    string

    Developer key label; defaults to "Agent bootstrap key". The model also accepts key_name.

  • scopes · optional

    string[]

    Optional developer-key scopes. Unsupported entries are discarded; an empty recognized set falls back to default scopes.

  • expiresAt · optional

    datetime

    Optional ISO datetime for API key expiry; the model also accepts expires_at.

  • utm_source · optional

    string

    Optional signup attribution.

  • utm_medium · optional

    string

    Optional signup attribution.

  • utm_campaign · optional

    string

    Optional signup attribution.

  • utm_term · optional

    string

    Optional signup attribution.

  • utm_content · optional

    string

    Optional signup attribution.

Errors

StatusMeaning
400Registration validation failed, such as a blocked disposable email domain.
422Request body validation failed.
409User already exists for this email.
500Internal server error.

Docs