moai-platform-auth

Implements authentication and authorization with Auth0, Clerk, and Firebase Auth platforms.

2|Updated May 27, 2026
One-click install
npx skills add https://github.com/yekinya/moai-novel --skill moai-platform-auth-yekinya
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: moai-platform-auth
Source: https://github.com/yekinya/moai-novel/tree/main/moai-novel/.claude/skills/moai-platform-auth
Command: npx skills add https://github.com/yekinya/moai-novel --skill moai-platform-auth-yekinya

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Choosing and correctly implementing authentication is error-prone: developers must compare platforms, configure MFA, secure tokens, and meet compliance requirements without introducing vulnerabilities like token theft or weak session handling. ## Core Features & Use Cases - Platform Selection Guidance: Compares Auth0 (enterprise security, FAPI compliance), Clerk (pre-built React UI, passkeys), and Firebase Auth (mobile-first, Google ecosystem) with decision matrices and pricing breakdowns. - Implementation References: Provides detailed guides for attack protection, MFA enrollment, WebAuthn/passkeys, social login, phone authentication, custom claims, and organization management per platform. - Security Best Practices: Covers token storage rules, sender constraining (DPoP/mTLS), session management, and verification checklists to avoid common vulnerabilities. - Use Case: A team building a Next.js B2B SaaS can use this Skill to pick Clerk for its organization management, then follow the reference to configure middleware route protection and WebAuthn passkeys. ## Quick Start Ask the agent to help you choose between Auth0, Clerk, and Firebase Auth for your application and implement the sign-in flow with MFA.

Frequently Asked Questions about moai-platform-auth

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I choose between Auth0, Clerk, and Firebase Auth?

Choose Auth0 for enterprise security and compliance (FAPI, HIPAA, attack protection), Clerk for modern Next.js apps needing pre-built UI and passkeys, and Firebase Auth for mobile-first apps using the Google ecosystem. The comparison reference includes a feature matrix and pricing breakdown.

How do I implement passkeys and WebAuthn authentication?

Clerk provides native passkey support through its SignIn and SignUp components with no extra server code. Auth0 supports WebAuthn with FIDO security keys as an MFA factor. Firebase Auth has limited WebAuthn support.

Does Firebase Auth support multi-factor authentication?

Firebase Auth supports phone-based MFA via SMS verification and TOTP for enterprise tiers. Enrollment uses multiFactor(user).enroll() with a PhoneAuthProvider credential, and sign-in handles the auth/multi-factor-auth-required error with a resolver.

Where should I store authentication tokens in a web app?

Never store tokens in localStorage due to XSS risk. Use httpOnly secure cookies when possible, or in-memory storage with refresh token rotation for SPAs. Mobile apps should use Keychain on iOS and Keystore on Android.

How do I migrate from Clerk Core 1 to Core 2?

Run npx @clerk/upgrade --from=core-1 to automate most changes, then manually replace CLERK_FRONTEND_API with NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY, switch authMiddleware to clerkMiddleware, and update server imports to @clerk/nextjs/server.

When should I use Auth0 instead of Firebase Auth?

Use Auth0 when you need FAPI compliance, HIPAA BAA, advanced attack protection like breached password detection, or sender-constrained tokens via DPoP or mTLS. Firebase Auth fits better for mobile apps already using Firestore or Cloud Functions.