aiskillstore/marketplace / skills/abdul-haseeb360/next-js-better-auth-integration
next-js-better-auth-integration
VerifiedA conceptual skill for integrating Better Auth with Next.js App Router
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 6.1 KB |
| skill-report.json | config | 8.9 KB |
skill-report.json
View on GitHub{
"schema_version": "2.0",
"meta": {
"generated_at": "2026-07-18T09:36:06.357Z",
"slug": "abdul-haseeb360-next-js-better-auth-integration",
"source_url": "https://github.com/Abdul-Haseeb360/Hackathon-II-AI-Native-Systems/tree/main/.claude/skills/nextjs-better-auth",
"source_ref": "main",
"model": "claude",
"analysis_version": "3.0.0",
"source_type": "community",
"content_hash": "89adf1372568572aaf547889ae8d22b0cbd7d7f207a3beb6befe972f5081a08b",
"tree_hash": "3f5d62346bab3b94581ced71fd8448f2b9e18acc3e8bad098308c48bfe07e041",
"provenance": {
"model_effective": "claude",
"fallback_chain": [
{
"agent": "codex",
"outcome": "failed",
"error": "2026-07-18T09:36:06.482201Z ERROR codex_models_manager::manager: failed to refresh available models: Missing environment variable: `HELM_API_KEY`.\n2026-07-18T09:36:06.502228Z ERROR codex_models_manage…"
},
{
"agent": "claude",
"outcome": "success"
}
],
"analysis_version": "3.0.0"
}
},
"skill": {
"name": "Next.js Better Auth Integration",
"description": "Guides conceptual Better Auth integration with the Next.js App Router, including sessions, JWTs, protected routes, and security considerations.",
"summary": "Plan Better Auth sessions and protected routes for a Next.js App Router application.",
"icon": "📦",
"version": "1.0.0",
"author": "Claude",
"license": "MIT",
"category": "coding",
"tags": [
"nextjs",
"better-auth",
"authentication",
"app-router",
"session-management"
],
"supported_tools": [
"claude",
"codex",
"claude-code"
],
"risk_factors": []
},
"security_audit": {
"risk_level": "safe",
"is_blocked": false,
"safe_to_publish": true,
"analysis_status": "ok",
"summary": "The single static finding is a false positive. The referenced text describes server-side session access in Next.js and contains no network reconnaissance instruction or executable behavior. No prompt injection, data-exfiltration intent, or other semantic security concern was found in SKILL.md.",
"remediation": [],
"risk_factor_evidence": [],
"static_findings": [
{
"id": "blocker:SKILL.md:122:network-reconnaissance",
"category": "blocker",
"severity": "low",
"pattern": "Network reconnaissance",
"file": "SKILL.md",
"line_start": 122,
"line_end": 123,
"snippet": "- Use server components for server-side session access"
}
],
"finding_verdicts": [
{
"id": "blocker:SKILL.md:122:network-reconnaissance",
"verdict": "false_positive",
"confidence": 0.99,
"reason": "SKILL.md lines 122-123 recommend server components for server-side session access and client components for authentication UI. This is standard Next.js architecture guidance and does not direct network discovery or scanning."
}
],
"semantic_findings": [],
"critical_findings": [],
"high_findings": [],
"medium_findings": [],
"low_findings": [],
"dangerous_patterns": [],
"files_scanned": 1,
"total_lines": 170,
"audit_model": "claude",
"audited_at": "2026-07-18T09:36:06.357Z",
"agent_auto_install_policy": "allowed",
"manual_install_policy": "allowed"
},
"content": {
"user_title": "Build Better Auth for Next.js",
"value_statement": "Setting up authentication with the App Router requires coordinated session, middleware, and component decisions. This skill provides a structured conceptual checklist for planning a Better Auth integration.",
"seo_keywords": [
"Claude",
"Codex",
"Claude Code",
"Next.js authentication",
"Better Auth",
"Next.js App Router",
"JWT sessions",
"protected routes",
"session management"
],
"actual_capabilities": [
"Outlines Better Auth initialization, provider configuration, and adapter planning.",
"Explains JWT expiration, refresh, signing, and validation considerations.",
"Describes session access patterns for server and client components.",
"Covers middleware-based protected routes and unauthorized redirects.",
"Provides security, performance, testing, and error-handling checklists."
],
"limitations": [
"This is conceptual guidance and does not generate a complete application implementation.",
"It does not provide package installation commands or version-specific Better Auth APIs.",
"Database schema, provider credentials, and deployment configuration require project-specific decisions.",
"Security controls must be tested and reviewed for the deployed environment."
],
"use_cases": [
{
"title": "Plan an App Router migration",
"description": "Map session context, middleware, and protected pages before adding Better Auth to an App Router application.",
"target_user": "Next.js developer"
},
{
"title": "Review authentication architecture",
"description": "Check proposed JWT, cookie, session invalidation, and route protection decisions against the skill guidance.",
"target_user": "Technical lead"
},
{
"title": "Create an authentication test plan",
"description": "Build tests for sign-in, expiration, protected routes, provider integration, and authentication error states.",
"target_user": "Quality engineer"
}
],
"prompt_templates": [
{
"title": "Identify integration steps",
"prompt": "Use this skill to list the main steps for adding Better Auth to my Next.js App Router application.",
"scenario": "Beginner planning"
},
{
"title": "Plan protected routes",
"prompt": "Use this skill to propose a plan for protecting these App Router paths: [list paths]. Include middleware and server-side checks.",
"scenario": "Route protection"
},
{
"title": "Review session design",
"prompt": "Use this skill to review my proposed session design. I use [cookie or JWT approach], [providers], and [database adapter]. Identify missing security controls.",
"scenario": "Architecture review"
},
{
"title": "Create a verification checklist",
"prompt": "Use this skill to create a detailed test checklist for Better Auth in a Next.js App Router application with [providers] and [protected routes].",
"scenario": "Advanced testing"
}
],
"output_examples": [
{
"input": "Plan protected routes for /dashboard and /settings.",
"output": [
"Middleware scope for protected paths.",
"Server-side session checks for each page.",
"Redirect behavior for unauthenticated users."
]
},
{
"input": "Review JWT session security for my application.",
"output": [
"Checklist for secure cookie settings and token handling.",
"Recommendations for expiration, refresh, validation, and invalidation.",
"Test cases for expired and invalid sessions."
]
}
],
"best_practices": [
"Store session secrets securely and never expose them to client components.",
"Use secure, HTTP-only cookies and validate authentication on the server.",
"Test route protection, session expiration, and recovery flows before release."
],
"anti_patterns": [
"Do not treat this conceptual skill as a substitute for current Better Auth documentation.",
"Do not store session tokens in insecure client-side storage.",
"Do not rely only on client-side checks to protect sensitive routes."
],
"faq": [
{
"question": "Does this skill install Better Auth?",
"answer": "No. It provides conceptual integration guidance and planning checklists."
},
{
"question": "Which Next.js router does it cover?",
"answer": "It covers Next.js App Router patterns, including middleware and server components."
},
{
"question": "Does it include complete source code?",
"answer": "No. The skill describes implementation areas without providing a complete codebase."
},
{
"question": "Can it help protect routes?",
"answer": "Yes. It outlines middleware, server-side checks, and unauthenticated redirect behavior."
},
{
"question": "Does it support social login planning?",
"answer": "Yes. It includes social provider integration as an authentication flow consideration."
},
{
"question": "How should I handle secrets?",
"answer": "Store them in a secure environment configuration and keep them out of client-side code."
}
]
},
"file_structure": [
{
"name": "SKILL.md",
"type": "file",
"path": "SKILL.md",
"lines": 170
}
]
}
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis. | Stars: 472k | Updated | Claude CodeCodex | Verified | Install |
| diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness. | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |