safe-action-better-auth

Community

Secure safe actions with typed authorization.

Authorgepetojj
Version1.0.0
Installs0

System Documentation

What problem does it solve?

Safe server actions in Next.js often require typed user context and robust authorization. This Skill provides a guided integration of Better Auth with Next.js server actions, enabling secure, typed access control and predictable behavior across actions.

Core Features & Use Cases

  • Typed auth context injected into actions (ctx.auth with user and session)
  • Pre-fetched session data and centralized authorization flows (authorize patterns)
  • Guidance to enable cookies integration (nextCookies) and auth interrupts for reliable server actions

Quick Start

Configure BetterAuth with your auth instance, enable nextCookies() for cookies, enable authInterrupts in Next.js, and use the adapter in server actions to protect authenticated flows.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: safe-action-better-auth
Download link: https://github.com/gepetojj/umo/archive/main.zip#safe-action-better-auth

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.