OAuth
Create organization during OAuth onboarding
Creates a new organization for users who don’t have one during the OAuth consent flow. The session must have needsOrgCreation=true. After creation, the session is updated with the new organization context.
POST
Create organization during OAuth onboarding
Authorizations
WorkOS JWT token. Obtain via WorkOS AuthKit authentication flow. The token must include organization_id claim for organization-scoped endpoints.
Body
application/json
Response
OK
List of authorized domains
CSRF token for consent form submission
Whether user needs to create an organization before continuing
Suggested organization name from email domain
Warning message (e.g., org context failed to load)
Create organization during OAuth onboarding

