WorkOS
WorkOS provides enterprise identity and user management APIs for organizations, directory sync, connections, invitations, and users.
Verdict
Common use cases
- Provision new enterprise customers in AuthKit
- Audit active organization memberships
- Troubleshoot SSO connection configuration
- Automate user onboarding workflows
- Inspect Directory Sync status for tenants
Integration
- Vendor
- WorkOS
- Category
- other
- Auth
- API_KEY
- Tools
- 29
- Composio slug
workos
Tools
- Create Organization
Create a WorkOS organization in the connected environment.
- Create Organization Membership
Grant an AuthKit user active membership in an organization. An existing inactive membership for the same user and organization is reactivated.
- Create User
Create a passwordless AuthKit user record in the connected WorkOS environment. This tool does not accept plaintext or hashed passwords.
- Delete Organizationdestructive
Permanently delete a WorkOS organization. This cannot be undone and should only target a confirmed organization ID.
- Delete Organization Membershipdestructive
Permanently remove an organization membership and its access. Prefer deactivation when access may need to be restored.
- Delete Userdestructive
Permanently delete an AuthKit user. This cannot be undone and may remove the user's access.
- Get Connection
Get one WorkOS connection by ID.
- Get Directory
Get one WorkOS Directory Sync directory by ID.
- Get Directory Group
Get one WorkOS Directory Sync group by its exact group ID.
- Get Directory User
Get one WorkOS Directory Sync user by exact ID, including identity-provider attributes, roles, and any groups returned by WorkOS. For complete group memberships, use List Directory Groups filtered by this directory user ID.
- Get Invitation
Get WorkOS AuthKit invitation status and metadata by invitation ID without exposing acceptance credentials.
- Get Organization
Get one WorkOS organization by its WorkOS ID or external ID.
- Get Organization Membership
Get one WorkOS AuthKit organization membership by ID.
- Get User
Get one WorkOS AuthKit user by WorkOS ID or external ID.
- List Connections
List one page of WorkOS SSO and OAuth connections, optionally filtered by connection type, domain, organization, or name.
- List Directories
List one page of WorkOS Directory Sync directories, optionally filtered by organization, directory name, or domain.
- List Directory Groups
List one page of WorkOS Directory Sync groups for a directory, a directory user, or both.
- List Directory Users
List one page of WorkOS Directory Sync users for a directory or group, optionally filtering a directory by exact identity-provider ID or primary email. WorkOS limits this endpoint to 4 requests per second per directory; on HTTP 429, honor R
- List Invitations
List one page of WorkOS AuthKit invitations by organization or exact recipient email without exposing acceptance credentials.
- List Organization Memberships
List one page of WorkOS AuthKit organization memberships for a specific organization or user, optionally including inactive or pending memberships.
- List Organizations
List one page of WorkOS organizations, optionally filtered by domain or organization name.
- List Users
List one page of WorkOS AuthKit users, optionally filtered by organization or exact email address.
- Resend Invitation
Send another real invitation email to the existing recipient of a pending WorkOS AuthKit invitation. This externally visible email delivery cannot be undone. The response excludes the invitation token and acceptance URL.
- Revoke Invitationdestructive
Revoke a pending AuthKit invitation so it can no longer be accepted.
- Send Invitation
Create an AuthKit invitation and immediately send a real invitation email to the recipient. This externally visible email delivery cannot be undone. Use only when the recipient and delivery are intentional. The output omits the sensitive ac
- Set Organization Membership Status
Activate or deactivate a WorkOS organization membership without deleting it. Deactivation removes access but can be reversed by setting the status to active.
- Update Organization
Update selected properties of an existing WorkOS organization.
- Update Organization Membership Roles
Replace the role assignment on an existing WorkOS organization membership.
- Update User
Update selected profile fields on an AuthKit user without invoking email delivery flows.
Setup
Setup guide
- 11. In Switchy, open your workspace settings and navigate to the Integrations tab. 2. Click 'Add Integration', search for WorkOS, and select it from the list. 3. You'll be prompted to enter a WorkOS API key — generate one in your WorkOS dashboard under API Keys with scopes for the resources you need (organizations, users, connections, directories). 4. Paste the key into Switchy and click 'Connect'. 5. Switchy will validate the key and confirm the connection. 6. Open any Project, type '@WorkOS' in the chat, and ask it to list your organizations or retrieve a specific connection by ID to confirm the integration works. 7. If the test fails, check that your API key has not expired and that the scopes match the tools you're trying to invoke.
What teammates see: by default, memories from WorkOS are scoped to the Project (PROJECT visibility) - you can mark any memory PRIVATE or share it ORG-wide.
Works well with
Top models
Compatibility data appears once enough Projects have used this MCP together with a given model.
How Switchy teams use it
Starter prompts
Create New Organization
@WorkOS create an organization named 'Acme Corp' with the domain 'acme.com'.
Grant User Membership
@WorkOS grant user ID user_01H8QZ9X3Y2K5N6P7R8T9V0W1X membership in organization org_01H8QZ9X3Y2K5N6P7R8T9V0W1X.
List All Connections
@WorkOS show me all active SSO connections in this environment.
Create Passwordless User
@WorkOS create a passwordless user with email 'jane@example.com' and first name 'Jane'.
Inspect Directory Sync
@WorkOS get the directory with ID directory_01H8QZ9X3Y2K5N6P7R8T9V0W1X and show me its sync status.
Example outputs
Illustrative - representative of the model's voice and quality, not literal recordings.
@workos list all active organization memberships for user@example.com and show which organizations they belong to
Found 3 active memberships for user@example.com: 1. Acme Corp (org_01HZXYZ) — Role: member, Status: active, Created: 2024-01-15 2. Beta Industries (org_01HZABC) — Role: admin, Status: active, Created: 2024-02-03 3. Gamma LLC (org_01HZDEF) — Role: member, Status: active, Created: 2024-03-12 This user has admin privileges in one organization and standard member access in two others. All memberships are currently active and grant AuthKit access to their respective environments.
This example demonstrates WorkOS's multi-tenancy model where users can belong to multiple organizations with different roles. Requires read access to both users and organization_memberships scopes. The MCP returns structured membership data but cannot infer business logic about what each role permits — that's defined in your application's authorization layer.
@workos create a new organization called 'Delta Systems' and immediately add admin@deltasystems.com as an admin member
Organization created successfully: • Organization ID: org_01HZGHI • Name: Delta Systems • Status: active Admin membership created: • User: admin@deltasystems.com (user_01HZJKL) • Role: admin • Status: active • Membership ID: om_01HZMNO The organization is now live in your WorkOS environment and the admin user has full access. You'll need to configure SSO or Directory Sync connections separately if this organization requires enterprise authentication.
This write-heavy example shows how WorkOS structures tenant provisioning. The MCP creates both resources but does not automatically configure authentication methods — SSO connections and directory sync must be set up through additional tools or the WorkOS dashboard. Be cautious: these are production changes that immediately affect your AuthKit environment.
@workos check all Directory Sync directories and summarize which ones have sync errors or are inactive, then recommend next steps
Analyzed 5 Directory Sync directories: ✓ 3 directories syncing successfully (Acme Corp SCIM, Beta Okta, Gamma Azure AD) ⚠️ 2 directories need attention: 1. Epsilon Corp (dir_01HZPQR) — Status: invalid_credentials — Last sync failed 6 hours ago. The SCIM bearer token appears expired. 2. Zeta Inc (dir_01HZSTU) — Status: inactive — No sync activity in 14 days. Directory may have been disabled on the IdP side. Recommended actions: Re-authenticate Epsilon's SCIM connection through the WorkOS dashboard, and contact Zeta's IT team to verify their IdP configuration is still active.
This synthesis example pairs WorkOS's directory state with AI reasoning to surface operational issues. The MCP provides raw directory status but the AI interprets patterns and suggests fixes. Useful for monitoring enterprise SSO health, but remember that directory sync errors often require coordination with customer IT teams — the MCP cannot fix IdP misconfigurations on its own.
Use-case deep-dives
When WorkOS MCP handles new customer org setup
A 6-person SaaS startup onboards 3-5 enterprise customers per month, each needing a dedicated organization with SSO and directory sync. The WorkOS MCP wins here because it automates the full provisioning chain—create the org, attach the connection, grant the first admin membership—without leaving the AI workspace. Your support engineer describes the new customer in chat, Switchy calls Create Organization and Create Organization Membership in sequence, and the customer's SSO is live in under two minutes. The threshold: if you're onboarding fewer than 2 orgs per month, the manual WorkOS dashboard is faster than teaching the AI your naming conventions. Above that frequency, this MCP pays for itself in the first week.
WorkOS MCP for quarterly access reviews
A 12-person fintech team runs quarterly SOC 2 access reviews, checking which users belong to which organizations and whether any memberships should be deactivated. The WorkOS MCP is the right call because it surfaces membership and directory data in conversational queries—your compliance lead asks 'show me all users in the Acme org with admin roles' and Switchy returns the list without writing a script. The 29 tools include Get Directory and membership lookups, so you can cross-reference SCIM-synced users against active memberships. The trade-off: if your review process requires bulk CSV exports or historical snapshots, the MCP's read-only queries won't replace your data warehouse. For live spot-checks and triage, it's the fastest path from question to answer.
When to use WorkOS MCP for churned account teardown
A 4-person B2B team churns 1-2 customers per quarter and needs to deprovision their organizations, memberships, and SSO connections without leaving orphaned records. The WorkOS MCP handles this cleanly: your account manager confirms the org ID in chat, Switchy calls Delete Organization Membership for each user, then Delete Organization to remove the parent entity. The API_KEY auth means no OAuth dance, and the destructive tools (Delete User, Delete Organization) require explicit confirmation, so you won't accidentally nuke the wrong account. The boundary: if your offboarding checklist spans multiple systems (Stripe, Zendesk, your own DB), the MCP only covers the WorkOS slice. For pure identity and access cleanup, it's the safest way to script teardown without writing throwaway code.
Frequently asked
What does the WorkOS MCP do in Switchy?
It lets your team manage WorkOS AuthKit users, organizations, and memberships directly from Switchy's AI workspace. You can create passwordless users, grant org access, delete memberships, and inspect Directory Sync setups without opening the WorkOS dashboard. Useful when onboarding flows or access audits are part of your team's daily workflow.
Do I need a WorkOS admin API key to connect this MCP?
Yes. The MCP uses API_KEY auth, so you'll need a WorkOS API key with write permissions for User Management, Organizations, and Directory Sync. Read-only keys won't work because most tools create or delete resources. Generate the key in your WorkOS dashboard under API Keys and paste it into Switchy during setup.
Can the WorkOS MCP set user passwords or import existing hashed credentials?
No. The Create User tool only supports passwordless AuthKit users—it explicitly rejects plaintext or hashed passwords. If you need password-based accounts, use WorkOS's dashboard or a separate API client. This MCP is built for magic-link and SSO workflows, not legacy password migrations.
Should I use this MCP or just call the WorkOS API directly?
Use the MCP when your team asks questions like "who has access to org X" or "create a test user for staging" in Switchy's chat. Use the API directly for high-volume automation or when you need endpoints this MCP doesn't expose. The MCP covers 29 common admin tasks; it's not a complete API wrapper.
Who on my team should connect the WorkOS MCP in Switchy?
Whoever manages user provisioning or customer onboarding in WorkOS—typically a backend engineer or ops lead. Because the API key grants delete permissions, don't share the connection with support reps or contractors unless they need to permanently remove users. Switchy logs all tool calls for audit trails.