当前位置: 首页 > Skill >

Auth0

Auth0

Auth0

用于在任何应用中添加、修复或改进身份验证 — 登录、注销、注册、路由保护、JWT/访问令牌验证、刷新令牌轮换...

2.0.1 2026.11.27 479
获取Skill文件查看使用说明
作 者:陈安 许可证: 更新时间:2026.11.27
本文目录展开

Auth0

Detect intent → detect framework → detect tooling → load 2–3 reference files.

Step 1: Detect intent

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 feature:mfa). The Intent you pick is a lookup key: in Step 4 it appears verbatim as a section heading (### feature:mfa) listing which reference files to load.

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
Serve the login page from your own web address (e.g. login.example.com, auth.company.com) instead of the default Auth0 URL. Auth0: custom domain. 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
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
Use the Auth0 CLI directly — "create an app/API with the auth0 CLI", script tenant setup, or automate Auth0 config in CI — with no application framework in play. Auth0: CLI / tooling-only. tooling

Step 2: Detect framework

Skip this step for the tooling intent — 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.

Work top-down. Stop at the first tier that yields a framework.

Tier 1 — Auth0 SDK already installed (strongest signal)

Read the project files. Stop at the first match.

Node.js / JavaScript / TypeScript — check package.json → dependencies

Rows are most-specific first — an Ionic/Capacitor project also carries @auth0/auth0-angular (etc.), so check the @capacitor/browser rows first.

Package Framework
@capacitor/browser + @auth0/auth0-angular ionic-angular
@capacitor/browser + @auth0/auth0-react ionic-react
@capacitor/browser + @auth0/auth0-vue ionic-vue
@auth0/nextjs-auth0 nextjs
@auth0/auth0-nuxt nuxt
@auth0/auth0-react react
@auth0/auth0-vue vue
@auth0/auth0-angular angular
@auth0/auth0-spa-js spa-js
express-openid-connect express
@auth0/auth0-fastify fastify
@auth0/auth0-fastify-api fastify-api
express-oauth2-jwt-bearer express-jwt
react-native-auth0 + app.json or app.config.js present expo
react-native-auth0 (no Expo files) react-native

Python — check requirements.txt or pyproject.toml

Package Framework
auth0-server-python flask
auth0-fastapi-api fastapi-api

Java / Kotlin — check build.gradle or pom.xml

Dependency Framework
mvc-auth-commons (com.auth0:mvc-auth-commons) java-mvc
spring-security-oauth2-resource-server springboot-api

.NET — check *.csproj or NuGet.Config

Package Framework
Auth0.AspNetCore.Authentication (no .Api suffix) aspnetcore-auth
Auth0.AspNetCore.Authentication.Api aspnetcore-api
Auth0.OidcClient.MAUI maui
Auth0.OidcClient.AndroidX net-android
Auth0.OidcClient.iOS net-ios
Auth0.OidcClient.WinForms winforms
Auth0.OidcClient.WPF wpf

PHP — check composer.json

auth0/auth0-php powers both PHP web apps and APIs; the mode is set via SdkConfiguration's strategy. The STRATEGY_API row is more specific — check it first.

Package Framework
auth0/auth0-php + SdkConfiguration::STRATEGY_API (or strategy: 'api') php-api
auth0/auth0-php (no STRATEGY_API / STRATEGY_REGULAR or strategy: 'webapp') php
auth0/login (laravel, no AuthorizationGuard) laravel
auth0/login + AuthorizationGuard laravel-api

If auth0/auth0-php is installed but no SdkConfiguration strategy is set yet (fresh project), fall through to variant disambiguation below (intent: building/protecting an API → php-api, else php).

Go — check go.mod

Module Framework
github.com/auth0/go-jwt-middleware go

Mobile (native)

Signal Framework
Package.swift or .xcodeproj + Auth0.swift swift
build.gradle + com.auth0.android:auth0 android
pubspec.yaml + auth0_flutter + flutter.web: false flutter-native
pubspec.yaml + auth0_flutter + web enabled flutter-web

Tier 2 — Framework from non-Auth0 workspace dependencies

If no Auth0 SDK matched, detect the framework from ordinary (non-Auth0) dependencies. Stop at the first match. For a web-vs-API split, the base is chosen here; the variant is resolved in "Variant disambiguation" below. Rows are most-specific first — an Ionic project also carries @angular/core / vue / react, so check the @ionic/* rows first (as in Tier 1).

Signal Base framework
next in package.json nextjs
nuxt in package.json nuxt
@ionic/* + @angular/core ionic-angular
@ionic/* + react ionic-react
@ionic/* + vue ionic-vue
@angular/core in package.json angular
vue in package.json (no nuxt) vue
expo in package.json expo
react-native (no expo) react-native
react (no meta-framework above) react (SPA) — see note
express in package.json express (variant below)
fastify in package.json fastify (variant below)
flask in requirements.txt/pyproject.toml flask
fastapi in requirements.txt/pyproject.toml fastapi-api
spring-boot in pom.xml/build.gradle springboot-api
laravel/framework in composer.json laravel (variant below)
composer.json present (no Laravel) php (variant below)
go.mod present + HTTP server/router go
Package.swift or .xcodeproj swift
pubspec.yaml (Flutter, web disabled) flutter-native
pubspec.yaml (Flutter, web enabled) flutter-web
*.csproj referencing MAUI maui
*.csproj (WinForms) winforms
*.csproj (WPF) wpf
*.csproj ASP.NET (web app or API) aspnetcore (variant below)

react note: a plain React project maps to react for an SPA using the React SDK, or spa-js if the app is framework-agnostic vanilla JS. If unclear, ask before loading.

Tier 3 — Framework from the prompt

If no workspace signal matched, read the developer's request for a framework or language name and map it here. Stop at the first match.

Developer mentions... Framework
Next.js / next nextjs
Nuxt nuxt
Angular (not Ionic) angular
Vue (not Nuxt/Ionic) vue
React SPA (not Next.js) react
vanilla JS / plain JS / no framework SPA spa-js
Express (web app / server-rendered) express
Express API / protect API routes express-jwt
Fastify (web) / Fastify API fastify / fastify-api
Flask flask
FastAPI fastapi-api
Spring Boot springboot-api
Java MVC / servlet java-mvc
ASP.NET Core web app / API aspnetcore-auth / aspnetcore-api
MAUI / WinForms / WPF maui / winforms / wpf
PHP web app / PHP API php / php-api
Laravel web app / Laravel API laravel / laravel-api
Go / Golang API go
Swift / iOS swift
Android / Kotlin android
Flutter (native / web) flutter-native / flutter-web
React Native / Expo react-native / expo
Ionic (Angular/React/Vue) ionic-angular / ionic-react / ionic-vue

Variant disambiguation (web app 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 express express-jwt protecting API routes / validating JWTs, no server-rendered UI
fastify fastify fastify-api resource server / JWT validation only
php php php-api building/protecting a PHP API, no web UI
laravel laravel laravel-api API-only (token guard), no Blade UI
aspnetcore aspnetcore-auth aspnetcore-api 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.

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 package.json has no next), state the conflict and ask rather than silently picking. Workspace signals outrank the prompt when both are present and consistent.

Step 3: Detect tooling

Read the project file tree. This is a project-context decision, not a product preference.

Project has... Load
terraform/ directory OR any *.tf files tooling-terraform.md
Auth0 MCP server active in this agent session tooling-mcp.md
Anything else (default) tooling-cli.md

Step 4: Load reference files

Find the section below whose heading matches the Intent you picked in Step 1, then read the reference files it lists.

integrate

Read: references/framework-{framework}.md
Read: references/tooling-{tooling}.md
Follow the integration workflow in framework-{framework}.md.
Use tooling-{tooling}.md for all Auth0 tenant configuration steps.

feature:mfa

Read: references/feature-mfa.md
Read: references/tooling-{tooling}.md
If framework detected: Read references/framework-{framework}.md (for SDK-side step-up trigger)

feature:organizations

Read: references/feature-organizations.md
Read: references/tooling-{tooling}.md
If framework detected: Read references/framework-{framework}.md
If multi-tenant architecture / B2B SaaS design question: also Read references/pattern-multi-tenant.md

feature:custom-domains

Read: references/feature-custom-domains.md
Read: references/tooling-{tooling}.md

feature:acul

Read: references/feature-acul.md
Read: references/tooling-{tooling}.md

feature:branding

Read: references/feature-branding.md
Read: references/tooling-{tooling}.md

feature:dpop

Read: references/feature-dpop.md
Read: references/tooling-{tooling}.md
If a SPA framework is detected (vue/react/angular/spa-js): Read references/framework-{framework}.md
DPoP is SPA-only (no SSR: Next.js/Nuxt) — feature-dpop.md states the exclusion.

guidance

Read: references/pattern-security.md
If framework detected: Read references/framework-{framework}.md (for SDK-specific guidance — token storage, session handling, route protection)
If token handling / JWT vs opaque / storage: Read references/pattern-token-handling.md
If multi-tenant / B2B architecture: Read references/pattern-multi-tenant.md + references/feature-organizations.md

debug

Read: references/pattern-common-errors.md
If framework detected: Read references/framework-{framework}.md

debug:rate-limit

Read: references/pattern-rate-limiting.md

migrate

Read: references/feature-migration.md
Read: references/tooling-{tooling}.md
If framework detected: Read references/framework-{framework}.md

upgrade-sdk

Read: references/framework-{framework}.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.md.
If no framework is detected: ask which Auth0 SDK the developer is upgrading.

tooling

Read: references/tooling-{tooling}.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.

推荐文章

更多
PHP时间戳与日期字符串相互转换方法详解

本文介绍PHP中时间数值(Unix时间戳)与日期字符串之间的相互转换方法。通过strtotime和date函数,实现将当前时间、指定日期转换为时间戳,以及将时间戳格式化为可读的日期时间字符串,并提供相关在线计算工具推荐。

2025.11.30 1,034
PHP日期转时间戳时区偏差怎么解决

在 PHP 中将日期字符串转换为时间戳时,若未显式指定时区,默认使用脚本配置的 date.timezone 或系统时区。当服务器时区与业务逻辑预期(如 UTC )不一致时,会产生偏差。解决核心是确保输入字符串携带明确时区信息,或在转换前统一设置时区上下文。

2026.10.24 1,031
PHP跨域配置:怎么安全地允许指定域名而非使用通配符

在 PHP 中安全地允许指定域名跨域,核心是解析请求头中的 Origin ,验证其是否在白名单内,然后动态设置 Access-Control-Allow-Origin 响应头。不要使用通配符 * ,也不要硬编码单一域名。

2025.03.29 1,019
JavaScript中利用replace结合正则实现replaceAll效果

JavaScript原生仅支持replace()进行单次或全局替换,缺乏类似Java的replaceAll()便捷方法。本文总结四种在JS中实现全量替换的方案:使用带g标志的正则、带gm标志的正则、扩展String原型以及split后join。通过对比代码示例,展示各方法的实现细节与适用场景,帮助开发者根据需求选择最优解。

2025.04.29 1,017
PHP实现基础文件上传:HTML表单与$_FILES处理流程

在 HTML 表单中设置 enctype="multipart/form-data" ,并在 PHP 后端通过 $_FILES 数组接收文件,调用 move_uploaded_file() 将临时文件移动到目标目录即可完成上传。

2026.09.07 1,014
OpenAI的Jalapeno芯片未落地,教你分辨300兆瓦算力消息

OpenAI计划在SB Energy租赁的数据中心部署约300兆瓦自研Jalapeno推理芯片,但目前双方仍处于洽谈阶段,交易细节与上线时间表均未公布。本文带你按报道原文核实项目所处阶段,厘清芯片发布、电力功率与实际推理算力的边界,并将融资意向与签约、开工、投运节点分开追踪,避免误将规划容量计入现有算力。

2026.12.02 1,013
Skill 文件
  • SKILL.md
    • Auth0
    • Step 1: Detect intent
    • Step 2: Detect framework
      • Tier 1 — Auth0 SDK already installed (strongest signal)
      • Node.js / JavaScript / TypeScript — check package.json → dependencies
      • Python — check requirements.txt or pyproject.toml
      • Java / Kotlin — check build.gradle or pom.xml
      • .NET — check *.csproj or NuGet.Config
      • PHP — check composer.json
      • Go — check go.mod
      • Mobile (native)
      • Tier 2 — Framework from non-Auth0 workspace dependencies
      • Tier 3 — Framework from the prompt
      • Variant disambiguation (web app vs API)
      • If nothing matched
      • Conflicts
    • Step 3: Detect tooling
    • Step 4: Load reference files
      • integrate
      • feature:mfa
      • feature:organizations
      • feature:custom-domains
      • feature:acul
      • feature:branding
      • feature:dpop
      • guidance
      • debug
      • debug:rate-limit
      • migrate
      • upgrade-sdk
      • tooling
  • 项目或源文件

相关 Skill

更多
service-qa-coach service-qa-coach Review support quality for chat, email, phone, social DM, or marketplace service teams. Use when a team needs a QA scorecard, failure-mode analysis, coaching plan, calibration checklist, or service-improvement brief without live ticketing, CRM, or contact-center system access.
高中数学作业批改助手 高中数学作业批改助手 >图片识别 直接读取学生手写作答照片,识别公式、符号、步骤 🧮 自动推导 根据题目自动生成参考答案和评分细则,无需教师预设 📊 逐步给分 每个关键步骤独立评分,体现过程分 📝 结构化报告 输出含识别内容、参考答案、逐步评分、改进建议的完整报告 🗂 批量批改 支持一次性批改多道题,最终汇总得分表
Vibration Analysis Vibration Analysis 分析来自CMS趋势、RMS/峰值、频谱及SCADA报警的风机传动链(主轴、齿轮箱、发电机)振动数据。
Traditional Bone Tool Making Basics Traditional Bone Tool Making Basics Use when you need custom, durable, repairable tools like awls, needles, scrapers, harpoons, or fishing hooks made from local animal bones or antlers and comm...
音频混音工具 音频混音工具 名称:Sound Mixing Tool(标识 sound-mixing-tool) 短简介(≤60字):音乐/音效响度精确对齐 + 融合混音工作流:用 ffmpeg 两段式 loudnorm 把多组素材 LUFS 偏差压到 <0.10,再最小干预融合、导出可进引擎的独立分轨。 标签/关键词:音频混音 响度匹配 LUFS ffmpeg 游戏音频 音效设计 Wwise FMOD 分轨导出 后期处理 触发词:混音 · 响度匹配 · LUFS 对齐 · MIX 版本 · 音乐音效分轨 · 融合 · 不打架 · 不能盖住 适用场景 :游戏音频集成、影视短视频配乐、播客后期