| 开发者 | bordoni |
|---|---|
| 更新时间 | 2026年5月13日 03:17 |
| 捐献地址: | 去捐款 |
| PHP版本: | 7.4 及以上 |
| WordPress版本: | 6.9 |
| 版权: | GPL-2.0-or-later |
| 版权网址: | 版权信息 |
[workos:login]), and a dedicated /workos/login/{profile} route./members, /team/login) on top of the canonical /workos/login/{profile} rewrite. When the default profile owns a custom path, /wp-login.php 302s to it (preserving every inbound query arg). Reserved core paths can't be claimed.forward_query_args per-profile toggle — opt-in passing of marketing/analytics query args (utm_*, ref, etc.) onto the post-login destination. WP and plugin internals are always stripped.mfa.enforce (never/if_required/always) and factor allowlist are applied at login time.default falls back to the Site Icon then a bundled WP logo, custom uses the chosen image, none hides the logo).WORKOS_RADAR_SITE_KEY.redirect_to, referrer host, or user role.authenticate filter for custom login forms.?fallback=1 when WorkOS is unavailable.Sign up at workos.com and find your API Key and Client ID in the dashboard.
Yes, if "Password Fallback" is enabled in settings. Users can access the standard login form via ?fallback=1.
Add the "WorkOS Login" Gutenberg block or use the "WorkOS Login" classic widget. Both render a styled login button that redirects to WorkOS AuthKit.
Use [workos:login profile="your-profile-slug"] or link to /workos/login/{profile}. Both mount the same React shell. The reserved default Login Profile automatically takes over wp-login.php.
Yes. Each Login Profile (WorkOS → Login Profiles) picks its own set of enabled methods (password, magic code, any subset of social providers, passkey), pins an organization, and sets its own MFA policy and branding. Reference a profile by slug in the shortcode or URL.
/members?Yes. Edit any profile and tick Use a custom URL path, then fill in the path (e.g. members or team/login). The plugin registers an extra rewrite rule that mounts the same React shell at https://yoursite.com/members/. The canonical /workos/login/{slug} URL keeps working too. Reserved core paths (wp-admin, wp-includes, wp-content, wp-json, workos, feed, etc.) are blocked at save time. If you set a custom path on the default profile, /wp-login.php?action=login 302s to it for everyone (with all redirect_to / interim-login / language / nonce args preserved).
Users can bypass the WorkOS redirect by appending ?fallback=1 to the login URL (e.g., wp-login.php?fallback=1). This loads the standard WordPress login form with native password authentication.
Yes. The Entitlement Gate feature restricts login to users who belong to the configured WorkOS organization. Users without a membership are denied access with a customizable error message.
Use the Onboarding Wizard (Settings > WorkOS > Onboarding) for a guided walkthrough, or use the WP-CLI command wp workos sync push to bulk-push users to WorkOS.
Yes. Organizations can be mapped to specific sites in a multisite network, and the plugin stores organization-to-site mappings in a dedicated table.
Go to Tools > WorkOS Diagnostics in the WordPress admin. The diagnostics page checks API connectivity, configuration completeness, database schema status, and other health indicators.
organization_selection_required. When the Login Profile has an organization pinned (with Config::get_organization_id() as a fallback), the plugin re-authenticates via the organization-selection grant instead of surfacing "The user must choose an organization to finish their authentication." to the user.user_id. Membership creation and the entity_already_exists short-circuit are logged via workos_log() (visible under WP_DEBUG / WORKOS_DEBUG). Strangers and ambiguous lookups still get a clean pinned_org_mismatch error — no email-lookup guessing./workos/callback now routes through LoginCompleter, so it shares the same organization_selection_required recovery, MFA gating, and post-login bookkeeping as the AuthKit REST endpoints. The callback no longer short-circuits on the WorkOS error and discards the OAuth code. Legacy AuthKit-redirect callbacks (no profile slug in state) keep their original redirect contract — the state-supplied redirect_to still wins over the default profile's post_login_redirect.wp_authenticate() to cover users whose passwords were never synced to WorkOS, then link the user to WorkOS and (by default) write the password through so future logins authenticate directly. A new "Require Email Confirmation on Fallback" setting switches the post-fallback step to a magic-code email instead of syncing the plaintext password. Gated by the existing allow_password_fallback toggle.WORKOS_* (or env-scoped WORKOS_{PRODUCTION|STAGING}_*) constants now seeds those values into the database on boot, so the admin UI reflects them. Covers string credentials, the new boolean toggles, and WORKOS_REDIRECT_URLS arrays. Hash-skipped when nothing has changed — one autoloaded option read per request in steady state./wp-json/workos/v1/auth/* now read the nonce from X-WorkOS-Nonce instead of X-WP-Nonce to avoid a header collision with WordPress core and other plugins. The bundled React shell is updated; external clients hitting these endpoints directly must rename the header.?refresh=1 query parameter on GET /wp-json/workos/v1/admin/profiles/organizations to drop the shared transient before fetching.org_name input. The Create Organization modal is now rendered at admin_footer so its inner <form> is no longer nested inside the settings form.workos_active_environment while the runtime auth flow read from workos_global['active_environment'], so picking "Production" still loaded staging credentials and redirected to the staging AuthKit. The runtime now reads/writes the standalone option, with a one-time migration (db_version 2 → 3) that moves any legacy value out of workos_global.[workos:login] shortcode, and /workos/login/{profile} route./members, /team/login) on top of the canonical /workos/login/{slug} rewrite. The default profile can claim a custom path so /wp-login.php bounces to it. Reserved core paths are blocked.forward_query_args toggle to pass marketing/analytics args onto the post-login destination (internals always stripped).[workos:login profile="…"] shortcode.default falls back to Site Icon → bundled WP logo, custom uses the chosen attachment, none hides the logo).workos.authkit.belowCard, which renders standard wp-login.php links by default) for plugins to inject React elements into the login UI.WORKOS_RADAR_SITE_KEY)./wp-json/workos/v1/auth/* with profile-scoped nonces, per-IP/per-email rate limits, and signature-verified tokens.@wordpress/i18n with the integration-workos text domain and wp_set_script_translations() wiring.
Base platform:
?fallback=1 for native WordPress login when WorkOS is unavailable.