nextjs-supabase-auth

nextjs-supabase-auth is a skill for Claude Code, Codex from guillermoscript/lms-front. It costs 40 tokens per session (343 once invoked), scanned A, original, MIT.

A guide for adding Supabase Auth to a Next.js application that uses the App Router. Supabase Auth handles user sign-in, while Next.js App Router organizes pages and server-side application code.

In plain words
What is it for?
Use it to set up Supabase clients, protect routes with middleware, handle OAuth callbacks, and implement authentication operations.
Why use it?
It helps keep login sessions, cookies, protected pages, and server-side authentication working together correctly.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/guillermoscript/lms-front/nextjs-supabase-auth
Any agent
npx skills add guillermoscript/lms-front --skill nextjs-supabase-auth
Clone the repo
git clone --depth 1 https://github.com/guillermoscript/lms-front

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for nextjs-supabase-auth

README.md
[![agentmods](https://agentmods.dev/badge/skills/guillermoscript/lms-front/nextjs-supabase-auth.svg)](https://agentmods.dev/skills/guillermoscript/lms-front/nextjs-supabase-auth)
Your own site
<a href="https://agentmods.dev/skills/guillermoscript/lms-front/nextjs-supabase-auth"><img src="https://agentmods.dev/badge/skills/guillermoscript/lms-front/nextjs-supabase-auth.svg" alt="Measured on agentmods" height="20"></a>
Per session 40 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 343 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00040 $0.00343
Opus 5 $0.00020 $0.00171
Sonnet 5 $0.00008 $0.00069
Haiku 4.5 $0.00004 $0.00034

Measured 4d ago against content hash 4f50bad1d6b0, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

nextjs-supabase-auth scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.agents/skills/nextjs-supabase-auth/SKILL.md · 62 lines

What it actually says

Next.js + Supabase Auth

You are an expert in integrating Supabase Auth with Next.js App Router. You understand the server/client boundary, how to handle auth in middleware, Server Components, Client Components, and Server Actions.

Your core principles:

  1. Use @supabase/ssr for App Router integration
  2. Handle tokens in middleware for protected routes
  3. Never expose auth tokens to client unnecessarily
  4. Use Server Actions for auth operations when possible
  5. Understand the cookie-based session flow

Capabilities

  • nextjs-auth
  • supabase-auth-nextjs
  • auth-middleware
  • auth-callback

Requirements

  • nextjs-app-router
  • supabase-backend

Patterns

Supabase Client Setup

Create properly configured Supabase clients for different contexts

Auth Middleware

Protect routes and refresh sessions in middleware

Auth Callback Route

Handle OAuth callback and exchange code for session

Anti-Patterns

❌ getSession in Server Components

❌ Auth State in Client Without Listener

❌ Storing Tokens Manually

Works well with: nextjs-app-router, supabase-backend

When to Use

This skill is applicable to execute the workflow or actions described in the overview.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 62 lines · 40 tokens per session scan A 4f50bad1d6b0

Subscribe to this mod's changes

nextjs-supabase-auth is a skill published in the GitHub repository guillermoscript/lms-front (25 stars, last pushed yesterday), licensed MIT. It adds 40 tokens to every session and 343 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

moodle-performance

Use when optimizing Moodle plugin performance — MUC caching definitions, query optimization, recordsets vs records, ad-hoc and scheduled tasks, lazy loading, OPcache, query log analysis, $PERF, and performance debug toolbar.

SaadRahman01/claude-moodle-dev · 50 tokens

emil-design-eng

This skill encodes Emil Kowalski's philosophy on UI polish, component design, animation decisions, and the invisible details that make software feel great.

classroomio/classroomio · 35 tokens

humanizer

Remove signs of AI-generated writing from text. Use when editing or reviewing text to make it sound more natural and human-written. Based on Wikipedia's comprehensive "Signs of AI writing" guide. Detects and fixes patterns including: inflated symbolism, promotional language, superficial -ing analyses, vague…

classroomio/classroomio · 93 tokens

apple-design

Apple's approach to interface design and fluid, physical motion, translated for the web. Use when building or reviewing gesture-driven UI, spring animations, drag/swipe/sheet interactions, momentum and interruptible transitions, translucent materials and depth, typography (optical sizing, tracking, leading)…

classroomio/classroomio · 80 tokens

add-landing-template

Add a new org landing-page template to the ClassroomIO monorepo. Use when the user asks to "create/add a new landing template", "add a new template like X to the org landing pages", "build a new theme for the org landing page", or hands over a design reference (image, URL, prototype) for a new landing visual style.

classroomio/classroomio · 78 tokens

animation-vocabulary

Reverse-lookup glossary that turns a vague description of a web animation or motion effect into its exact term ("the bouncy thing when a popover opens" → Pop in; "the iOS rubber-band scroll" → Rubber-banding). Use when the user asks "what's it called when…", or describes a motion effect without knowing its name and…

classroomio/classroomio · 98 tokens