Skip to main content
Discovery allows members to authenticate and see all organizations they can access - whether they’re existing members, have pending invites, or are eligible to join via email domain or SSO configuration. Members can then select an organization to authenticate into or create a new one.

Discovery flow

1

Authenticate with discovery

Use any discovery authentication method (Email Magic Link, Email OTP, OAuth, or Password) to get an intermediate_session_token:Example with Email Magic Link:
After the member clicks the magic link, extract the discovery_magic_links_token from the callback URL and authenticate:
Response:
2

List discovered organizations

Get all organizations the member can access using the List Organizations endpoint:
Response includes organizations where the member:
  • active_member - Already a member
  • pending_member - Has a pending invite
  • invited_member - Has been invited
  • eligible_to_join_by_email_domain - Email domain matches organization’s allowed domains
  • eligible_to_join_by_oauth_tenant - OAuth tenant matches organization’s allowed tenants
3

Join organization or create new

The member can now choose to join an existing organization or create a new one:
Exchange the intermediate session for a full member session using the Exchange Intermediate Session endpoint:
Response:
If the organization requires MFA, the response will have member_authenticated: false and include a new intermediate_session_token to complete the MFA challenge.

Discovery vs Organization-specific login

Discovery

  • Member authenticates without specifying organization
  • Sees all organizations they can access
  • Can create new organizations
  • Uses discovery_ auth endpoints
  • Returns intermediate_session_token

Organization-specific

  • Member authenticates to a specific organization
  • Typically uses organization slug in URL
  • Direct login to known organization
  • Uses standard auth endpoints with organization_id
  • Returns full session_token

Learn more

Core flows

Learn about Discovery and organization switching

Discovered Organization object

Object reference for discovered organizations