auth0
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseAuth0
Auth0
Detect intent → detect framework → detect tooling → load 2–3 reference files.
识别意图 → 检测框架 → 检测工具 → 加载2–3份参考文件。
Step 1: Detect intent
步骤1:识别意图
Match the request against the What the developer wants column — it describes
the goal in plain language, not just the Auth0 term (someone who says "make
users confirm with a code from their phone" lands on ). The
Intent you pick is a lookup key: in Step 4 it appears verbatim as a
section heading () listing which reference files to load.
feature:mfa### feature:mfa| What the developer wants (plain language + Auth0 term) | Intent |
|---|---|
| Add login, signup, sign-in, or "let users log in / create accounts" to an app | integrate |
| Require a second step after the password — a one-time code, SMS or email code, authenticator app, passkey, fingerprint/face (biometric), or security key; or re-confirm identity before a sensitive action. Auth0: multi-factor authentication (MFA), two-factor (2FA), two-step verification, step-up authentication. | feature:mfa |
| Let separate companies, teams, workspaces, or tenants each have their own users, members, roles, and login — typically a product sold to businesses. Auth0: Organizations, multi-org, B2B SaaS. | feature:organizations |
| Deploy a hosted self-service portal for profile, passkeys, MFA, or organization details instead of building a “My Account” or “My Organization” UI. Auth0: Universal Portals, My Account portal, My Organization portal. | feature:universal-portals |
Serve the login page from your own web address (e.g. | feature:custom-domains |
| Build fully custom login/signup screens with your own code or framework, beyond what theme settings allow. Auth0: Advanced Customization for Universal Login (ACUL). | feature:acul |
| Change how the login page looks — logo, colors, fonts, background, overall theme. Auth0: branding, Universal Login customization. | feature:branding |
| Bind tokens to the client so a stolen or leaked token can't be reused/replayed from another machine. Auth0: DPoP (Demonstrating Proof-of-Possession), sender-constrained tokens. | feature:dpop |
| Audit a tenant for security/config issues, report, then optionally fix findings. Auth0: tenant audit, CheckMate. | audit |
| Check if a tenant is healthy and on the right plan — two scores + a recommendation. Auth0: health check. | healthcheck |
| Ask for best practices, "is this secure?", how to handle tokens safely, "how should I do X". Auth0: guidance / security. | guidance |
| Hit an error: 401 Unauthorized, 403 Forbidden, CORS, callback URL mismatch, redirect loop. Auth0: debugging. | debug |
| Hit rate limiting: 429 Too Many Requests, quota exceeded. Auth0: rate limits. | debug:rate-limit |
| Move an existing app off Clerk, NextAuth.js, Firebase, Cognito, Okta, Supabase, Passport.js, or another auth provider. Auth0: provider migration. | migrate |
| Upgrade the Auth0 SDK itself to a new major version (e.g. Auth0.swift v2→v3, Auth0.Android v3→v4) — breaking changes, deprecated APIs, "update to the latest SDK". Auth0: SDK major-version upgrade. | upgrade-sdk |
| Install Auth0's Vercel Marketplace integration, connect Auth0 to a Vercel project, or sync Auth0 configuration into a Vercel-hosted Next.js app. Auth0: Vercel native integration. | integrate |
Use the Auth0 CLI directly — "create an app/API with the | tooling |
将请求与开发者需求列匹配——该列用通俗语言描述目标,而非仅使用Auth0术语(例如用户说*"让用户通过手机验证码确认身份"*,对应)。你选择的意图是一个查找键:在步骤4中,它会作为章节标题()原样出现,列出需要加载的参考文件。
feature:mfa### feature:mfa| 开发者需求(通俗表述 + Auth0术语) | 意图 |
|---|---|
| 为应用添加登录、注册功能,或实现“让用户登录/创建账户”的需求 | integrate |
| 要求在输入密码后进行第二步验证——包括一次性验证码、短信或邮件验证码、认证器应用、通行密钥、指纹/面部(生物识别)或安全密钥;或在执行敏感操作前重新确认身份。Auth0术语:多因素认证(MFA)、双因素认证(2FA)、两步验证、进阶身份验证。 | feature:mfa |
| 让不同公司、团队、工作区或租户各自拥有独立的用户、成员、角色和登录体系——通常面向企业客户的产品。Auth0术语:Organizations、多租户、B2B SaaS。 | feature:organizations |
| 部署托管式自助门户,用于管理个人资料、通行密钥、MFA或组织详情,而非自行构建“我的账户”或“我的组织”界面。Auth0术语:Universal Portals、我的账户门户、我的组织门户。 | feature:universal-portals |
使用自有域名(例如 | feature:custom-domains |
| 使用自有代码或框架构建完全自定义的登录/注册界面,超出主题设置的限制。Auth0术语:Universal Login高级自定义(ACUL)。 | feature:acul |
| 修改登录页面外观——包括logo、颜色、字体、背景、整体主题。Auth0术语:品牌定制、Universal Login自定义。 | feature:branding |
| 将令牌与客户端绑定,防止被盗或泄露的令牌在其他设备上重复使用/重放。Auth0术语:DPoP(持有证明)、发送方约束令牌。 | feature:dpop |
| 审计租户的安全/配置问题,生成报告,可选修复发现的问题。Auth0术语:租户审计、CheckMate。 | audit |
| 检查租户是否健康以及是否适配当前方案——包含两个评分和一项建议。Auth0术语:健康检查。 | healthcheck |
| 咨询最佳实践、“这样安全吗?”、如何安全处理令牌、“我应该如何实现X功能”等问题。Auth0术语:指导/安全。 | guidance |
| 遇到错误:401未授权、403禁止访问、CORS、回调URL不匹配、重定向循环。Auth0术语:调试。 | debug |
| 遇到速率限制:429请求过多、配额超限。Auth0术语:速率限制。 | debug:rate-limit |
| 将现有应用从Clerk、NextAuth.js、Firebase、Cognito、Okta、Supabase、Passport.js或其他身份认证提供商迁移过来。Auth0术语:提供商迁移。 | migrate |
| 将Auth0 SDK本身升级到新的主版本(例如Auth0.swift v2→v3、Auth0.Android v3→v4)——涉及破坏性变更、废弃API、“升级到最新SDK”。Auth0术语:SDK主版本升级。 | upgrade-sdk |
| 安装Auth0的Vercel Marketplace集成、将Auth0连接到Vercel项目,或把Auth0配置同步到Vercel托管的Next.js应用中。Auth0术语:Vercel原生集成。 | integrate |
直接使用Auth0 CLI——“用 | tooling |
Step 2: Detect framework
步骤2:检测框架
Skip this step for theintent — a CLI-first request has no framework. Go to Step 3, load the tooling reference; only ask about a framework if the developer later pivots to integrating auth into an app.tooling
Work top-down. Stop at the first tier that yields a framework.
对于意图,跳过此步骤——仅使用CLI的请求无需框架。直接进入步骤3,加载工具参考文件;只有当开发者后续转向将身份认证集成到应用中时,才询问框架相关信息。tooling
从上到下检测。在第一个匹配到框架的层级停止。
Tier 1 — Auth0 SDK already installed (strongest signal)
层级1 — 已安装Auth0 SDK(最强信号)
Node.js / JavaScript / TypeScript — check package.json
→ dependencies
package.jsondependenciesNode.js / JavaScript / TypeScript — 检查package.json
→ dependencies
package.jsondependenciesRows are most-specific first: an Ionic/Capacitor project also carries the base
SDK, so check the rows before it.
@capacitor/browser| Package | Framework |
|---|---|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
行按特异性从高到低排列:Ionic/Capacitor项目也包含基础SDK,因此先检查相关行。
@capacitor/browser| 包 | 框架 |
|---|---|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
Python — check requirements.txt
or pyproject.toml
requirements.txtpyproject.tomlPython — 检查requirements.txt
或pyproject.toml
requirements.txtpyproject.toml| Package | Framework |
|---|---|
| |
| |
| 包 | 框架 |
|---|---|
| |
| |
Java / Kotlin — check build.gradle
or pom.xml
build.gradlepom.xmlJava / Kotlin — 检查build.gradle
或pom.xml
build.gradlepom.xml| Dependency | Framework |
|---|---|
| |
| |
| 依赖 | 框架 |
|---|---|
| |
| |
.NET — check *.csproj
or NuGet.Config
*.csprojNuGet.Config.NET — 检查*.csproj
或NuGet.Config
*.csprojNuGet.Config| Package | Framework |
|---|---|
| |
| |
| |
| |
| |
| |
| |
| 包 | 框架 |
|---|---|
| |
| |
| |
| |
| |
| |
| |
PHP — check composer.json
composer.jsonPHP — 检查composer.json
composer.jsonauth0/auth0-phpSdkConfigurationstrategySTRATEGY_API| Package | Framework |
|---|---|
| |
| |
| |
| |
Ifis installed but noauth0/auth0-phpstrategy is set yet (fresh project), fall through to variant disambiguation below.SdkConfiguration
auth0/auth0-phpSdkConfigurationstrategySTRATEGY_API| 包 | 框架 |
|---|---|
| |
| |
| |
| |
如果已安装但尚未设置auth0/auth0-php策略(新项目),则进入下方的变体区分步骤。SdkConfiguration
Go — check go.mod
go.modGo — 检查go.mod
go.mod| Module | Framework |
|---|---|
| |
| 模块 | 框架 |
|---|---|
| |
Mobile (native)
移动端(原生)
| Signal | Framework |
|---|---|
| |
| |
| |
| |
| 信号 | 框架 |
|---|---|
| |
| |
| |
| |
Tier 2 — Framework from non-Auth0 workspace dependencies
层级2 — 从非Auth0工作区依赖检测框架
If no Auth0 SDK matched, detect the framework from ordinary (non-Auth0)
dependencies. Stop at the first match. This picks the base; any web-vs-API
variant is resolved in "Variant disambiguation" below. As in Tier 1, check the
rows before their base framework.
@ionic/*| Signal | Base framework |
|---|---|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
note: a plain React project maps toreactfor an SPA using the React SDK, orreactif the app is framework-agnostic vanilla JS. If unclear, ask before loading.spa-js
如果未匹配到Auth0 SDK,则从普通(非Auth0)依赖中检测框架。在第一个匹配项停止。这会识别基础框架;Web应用与API的变体将在“变体区分”步骤中解决。与层级1相同,先检查相关行,再检查其基础框架。
@ionic/*| 信号 | 基础框架 |
|---|---|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
存在 | |
存在 | |
| |
| |
| |
| |
| |
| |
| |
备注: 纯React项目,如果是使用React SDK的SPA则对应react,如果是无框架的原生JS应用则对应react。如果不确定,加载前询问开发者。spa-js
Tier 3 — Framework from the prompt
层级3 — 从请求中检测框架
If no workspace signal matched, map the framework or language named in the
request. Stop at the first match.
| Developer mentions... | Framework |
|---|---|
Next.js / | |
| Nuxt | |
| Angular (not Ionic) | |
| Vue (not Nuxt/Ionic) | |
| React SPA (not Next.js) | |
| vanilla JS / plain JS / no framework SPA | |
| Express (web app / server-rendered) | |
| Express API / protect API routes | |
| Fastify (web) / Fastify API | |
| Flask | |
| FastAPI | |
| Spring Boot | |
| Java MVC / servlet | |
| ASP.NET Core web app / API | |
| MAUI / WinForms / WPF | |
| PHP web app / PHP API | |
| Laravel web app / Laravel API | |
| Go / Golang API | |
| Swift / iOS | |
| Android / Kotlin | |
| Flutter (native / web) | |
| React Native / Expo | |
| Ionic (Angular/React/Vue) | |
如果未匹配到工作区信号,则根据请求中提到的框架或语言进行映射。在第一个匹配项停止。
| 开发者提及... | 框架 |
|---|---|
Next.js / | |
| Nuxt | |
| Angular(非Ionic) | |
| Vue(非Nuxt/Ionic) | |
| React SPA(非Next.js) | |
| 原生JS / 纯JS / 无框架SPA | |
| Express(Web应用 / 服务端渲染) | |
| Express API / 防护API路由 | |
| Fastify(Web) / Fastify API | |
| Flask | |
| FastAPI | |
| Spring Boot | |
| Java MVC / Servlet | |
| ASP.NET Core Web应用 / API | |
| MAUI / WinForms / WPF | |
| PHP Web应用 / PHP API | |
| Laravel Web应用 / Laravel API | |
| Go / Golang API | |
| Swift / iOS | |
| Android / Kotlin | |
| Flutter(原生 / Web) | |
| React Native / Expo | |
| Ionic(Angular/React/Vue) | |
Variant disambiguation (web app vs API)
变体区分(Web应用 vs API)
Some frameworks have separate web-app and API references. When Tier 1 did not
pin the variant, choose intent-first:
| Base | Web-app variant | API variant | Choose API when… |
|---|---|---|---|
| express | | | protecting API routes / validating JWTs, no server-rendered UI |
| fastify | | | resource server / JWT validation only |
| php | | | building/protecting a PHP API, no web UI |
| laravel | | | API-only (token guard), no Blade UI |
| aspnetcore | | | Web API / JWT bearer, no cookie login UI |
If intent is still ambiguous (both a UI and protected endpoints, or unclear),
state what you detected and ask the developer web app vs API before loading.
部分框架有独立的Web应用和API参考文件。当层级1未明确变体时,优先根据意图选择:
| 基础框架 | Web应用变体 | API变体 | 选择API变体的场景… |
|---|---|---|---|
| express | | | 防护API路由 / 验证JWT,无服务端渲染UI |
| fastify | | | 资源服务器 / 仅JWT验证 |
| php | | | 构建/防护PHP API,无Web UI |
| laravel | | | 仅API(令牌守卫),无Blade UI |
| aspnetcore | | | Web API / JWT承载,无Cookie登录UI |
如果意图仍不明确(同时存在UI和受防护的端点,或无法确定),说明检测到的内容并询问开发者是Web应用还是API后再加载。
If nothing matched
无匹配项
Ask the developer what framework/language they are using. Do not guess.
询问开发者正在使用的框架/语言。请勿猜测。
Conflicts
冲突情况
If Tier 2 (workspace) and Tier 3 (prompt) disagree materially (e.g. the prompt
says "Next.js" but has no ), state the conflict and ask
rather than silently picking. Workspace signals outrank the prompt when both are
present and consistent.
package.jsonnext如果层级2(工作区)和层级3(请求)存在实质性冲突(例如请求说“Next.js”但中无),说明冲突并询问,而非默默选择。当两者都存在且一致时,工作区信号优先级高于请求。
package.jsonnextStep 3: Detect tooling
步骤3:检测工具
Read the project file tree and the request — a project-context decision, not a product preference.
| Project has... | Load |
|---|---|
| |
| Auth0 MCP server active in this agent session | |
| A request for the Auth0 Vercel Marketplace/native integration, or to connect Auth0 to a Vercel project | |
| Anything else (default) | |
查看项目文件树和请求——这是基于项目上下文的决策,而非产品偏好。
| 项目包含... | 加载 |
|---|---|
| |
| 此Agent会话中Auth0 MCP服务器处于活动状态 | |
| 请求涉及Auth0 Vercel Marketplace/原生集成,或将Auth0连接到Vercel项目 | |
| 其他情况(默认) | |
Step 4: Load reference files
步骤4:加载参考文件
Find the section below whose heading matches the Intent you picked in
Step 1, then read the reference files it lists.
找到标题与你在步骤1中选择的意图匹配的章节,然后读取其中列出的参考文件。
integrate
integrate
Read: references/framework-{framework}/index.md
Read: references/tooling-{tooling}/index.md
Follow the integration workflow in references/framework-{framework}/index.md.
Use references/tooling-{tooling}/index.md for all Auth0 tenant configuration steps.Read: references/framework-{framework}/index.md
Read: references/tooling-{tooling}/index.md
Follow the integration workflow in references/framework-{framework}/index.md.
Use references/tooling-{tooling}/index.md for all Auth0 tenant configuration steps.feature:mfa
feature:mfa
Read: references/feature-mfa/index.md
Read: references/tooling-{tooling}/index.md
If framework detected: Read references/framework-{framework}/index.md (for SDK-side step-up trigger)Read: references/feature-mfa/index.md
Read: references/tooling-{tooling}/index.md
If framework detected: Read references/framework-{framework}/index.md (for SDK-side step-up trigger)feature:organizations
feature:organizations
Read: references/feature-organizations/index.md
Read: references/tooling-{tooling}/index.md
If framework detected: Read references/framework-{framework}/index.md
If multi-tenant architecture / B2B SaaS design question: also Read references/pattern-multi-tenant/index.mdRead: references/feature-organizations/index.md
Read: references/tooling-{tooling}/index.md
If framework detected: Read references/framework-{framework}/index.md
If multi-tenant architecture / B2B SaaS design question: also Read references/pattern-multi-tenant/index.mdfeature:universal-portals
feature:universal-portals
Read: references/feature-universal-portals/index.md
Read: references/tooling-{tooling}/index.mdRead: references/feature-universal-portals/index.md
Read: references/tooling-{tooling}/index.mdfeature:custom-domains
feature:custom-domains
Read: references/feature-custom-domains/index.md
Read: references/tooling-{tooling}/index.mdRead: references/feature-custom-domains/index.md
Read: references/tooling-{tooling}/index.mdfeature:acul
feature:acul
Read: references/feature-acul/index.md
Read: references/tooling-{tooling}/index.mdRead: references/feature-acul/index.md
Read: references/tooling-{tooling}/index.mdfeature:branding
feature:branding
Read: references/feature-branding/index.md
Read: references/tooling-{tooling}/index.mdRead: references/feature-branding/index.md
Read: references/tooling-{tooling}/index.mdfeature:dpop
feature:dpop
Read: references/feature-dpop/index.md
Read: references/tooling-{tooling}/index.md
If a SPA framework is detected (vue/react/angular/spa-js): Read references/framework-{framework}/index.md
DPoP is SPA-only (no SSR: Next.js/Nuxt) — feature-dpop/index.md states the exclusion.Read: references/feature-dpop/index.md
Read: references/tooling-{tooling}/index.md
If a SPA framework is detected (vue/react/angular/spa-js): Read references/framework-{framework}/index.md
DPoP is SPA-only (no SSR: Next.js/Nuxt) — feature-dpop/index.md states the exclusion.guidance
guidance
Read: references/pattern-security/index.md
If framework detected: Read references/framework-{framework}/index.md (for SDK-specific guidance — token storage, session handling, route protection)
If token handling / JWT vs opaque / storage: Read references/pattern-token-handling/index.md
If multi-tenant / B2B architecture: Read references/pattern-multi-tenant/index.md + references/feature-organizations/index.mdRead: references/pattern-security/index.md
If framework detected: Read references/framework-{framework}/index.md (for SDK-specific guidance — token storage, session handling, route protection)
If token handling / JWT vs opaque / storage: Read references/pattern-token-handling/index.md
If multi-tenant / B2B architecture: Read references/pattern-multi-tenant/index.md + references/feature-organizations/index.mddebug
debug
Read: references/pattern-common-errors/index.md
If framework detected: Read references/framework-{framework}/index.mdRead: references/pattern-common-errors/index.md
If framework detected: Read references/framework-{framework}/index.mddebug:rate-limit
debug:rate-limit
Read: references/pattern-rate-limiting/index.mdRead: references/pattern-rate-limiting/index.mdmigrate
migrate
Read: references/feature-migration/index.md
Read: references/tooling-{tooling}/index.md
If framework detected: Read references/framework-{framework}/index.mdRead: references/feature-migration/index.md
Read: references/tooling-{tooling}/index.md
If framework detected: Read references/framework-{framework}/index.mdaudit
audit
Read: references/feature-audit/index.md
Read: references/feature-audit-pricing/index.md
Read: references/feature-audit-remediation/index.md
Read: references/tooling-{tooling}/index.md
Apply findings only with per-command confirmation; verify each change by re-fetch.Read: references/feature-audit/index.md
Read: references/feature-audit-pricing/index.md
Read: references/feature-audit-remediation/index.md
Read: references/tooling-{tooling}/index.md
Apply findings only with per-command confirmation; verify each change by re-fetch.healthcheck
healthcheck
Read: references/feature-healthcheck/index.md
Read: references/feature-audit/index.md
Read: references/feature-audit-pricing/index.md
Read: references/feature-audit-remediation/index.md
Read: references/tooling-{tooling}/index.md
If a scan can run, do the audit workflow first, then score and recommend a plan. If not, score capability fit and recommend anyway. Never quote Enterprise pricing.Read: references/feature-healthcheck/index.md
Read: references/feature-audit/index.md
Read: references/feature-audit-pricing/index.md
Read: references/feature-audit-remediation/index.md
Read: references/tooling-{tooling}/index.md
If a scan can run, do the audit workflow first, then score and recommend a plan. If not, score capability fit and recommend anyway. Never quote Enterprise pricing.upgrade-sdk
upgrade-sdk
Read: references/framework-{framework}/index.md
Follow its "Major Version Migration" section (e.g. Auth0.swift v3, Auth0.Android v4).
This is an Auth0 SDK version bump — NOT a provider migration. Do not load feature-migration/index.md.
If no framework is detected: ask which Auth0 SDK the developer is upgrading.Read: references/framework-{framework}/index.md
Follow its "Major Version Migration" section (e.g. Auth0.swift v3, Auth0.Android v4).
This is an Auth0 SDK version bump — NOT a provider migration. Do not load feature-migration/index.md.
If no framework is detected: ask which Auth0 SDK the developer is upgrading.tooling
tooling
Read: references/tooling-{tooling}/index.md
No framework file — this is a CLI/tooling-only task (create apps/APIs, script
tenant setup, automate config in CI). If the developer then wants to integrate
auth into an app, return to Step 1 with the integrate intent.Read: references/tooling-{tooling}/index.md
No framework file — this is a CLI/tooling-only task (create apps/APIs, script
tenant setup, automate config in CI). If the developer then wants to integrate
auth into an app, return to Step 1 with the integrate intent.