better-auth-add-plugin
Add a better-auth plugin to an existing project. Configures server and client plugins with proper imports.
Interactive Durable Objects debugging workflow. Diagnoses common DO errors, configuration issues, and runtime problems with step-by-step troubleshooting.
$ npx -y skills add secondsky/claude-skills --agent claude-codeHow it fires
How this command gets triggered: by you, by Claude, or both.
/do-debugContext preview
What this command does when you run it.
Interactive Durable Objects debugging workflow. Diagnoses common DO errors, configuration issues, and runtime problems with step-by-step troubleshooting.
name: cloudflare-durable-objects:debug description: Interactive Durable Objects debugging workflow. Diagnoses common DO errors, configuration issues, and runtime problems with step-by-step troubleshooting.
Interactive command to diagnose and fix common Durable Objects issues. Provides step-by-step troubleshooting for configuration errors, runtime failures, and performance problems.
This command helps debug DO issues by:
Use AskUserQuestion tool to understand the problem:
**Question**: "What type of issue are you experiencing with Durable Objects?" **Header**: "Issue Type" **Options**:
If user selected error-based category (Deployment, Runtime):
**Prompt**: "Please paste the full error message:"
Enter error message (or 'none' if no specific error): _____________________________________________ _____________________________________________ _____________________________________________
Parse error message for known patterns:
**Deployment Error Patterns:**
**Runtime Error Patterns:**
**Question**: "When does this issue occur?" **Header**: "Timing" **Options**:
**Question**: "Have you made any recent changes to your Durable Objects configuration or code?" **Header**: "Recent Changes" **Options (multiselect)**:
Based on error category and context, run relevant diagnostic checks:
Run validation script:
./scripts/validate-do-config.sh
Parse output for errors:
**Common Configuration Issues:**
1. **Missing Class Export**
Error: Class 'MyDO' not found in src/index.ts
**Fix:**
// src/index.ts
export class MyDO extends DurableObject { ... }
// Or if in separate file:
export { MyDO } from "./MyDO";2. **Missing Migration**
Error: No migrations found in configuration
**Fix:**
"migrations": [
{
"tag": "v1",
"new_sqlite_classes": ["MyDO"]
}
]3. **Binding Name Mismatch**
Error: Binding 'MY_DO' references class 'MyDO' but class not in migrations
**Fix:** Add class to migrations or update binding to match existing class.
Read DO class implementation and check for common issues:
# Find DO constructor grep -A 20 "constructor(ctx: DurableObjectState" src/*.ts
**Common Constructor Issues:**
1. **Long-Running Constructor**
// ❌ BAD: Heavy work in constructor (blocks all requests)
constructor(ctx: DurableObjectState, env: Env) {
super(ctx, env);
await this.heavyInitialization(); // Blocks!
}**Fix:**
// ✅ GOOD: Use blockConcurrencyWhile for critical initialization only
constructor(ctx: DurableObjectState, env: Env) {
super(ctx, env);
this.ctx.blockConcurrencyWhile(async () => {
// Only critical schema setup here
await this.ctx.storage.sql.exec(`CREATE TABLE IF NOT EXISTS ...`);
});
}2. **Missing super() Call**
// ❌ BAD: Forgot super()
constructor(ctx: DurableObjectState, env: Env) {
this.ctx = ctx; // Error!
}**Fix:**
// ✅ GOOD: Always call super() first
constructor(ctx: DurableObjectState, env: Env) {
super(ctx, env);
}# Find SQL queries grep -r "storage.sql.exec" src/
**C
145 production-ready skills for Claude Code CLI 🔌 Platform / Harness Support These plugins ship as Claude Code marketplace plugins (.claude-plugin/ manifests) and Codex CLI plugins (.codex-plugin/ manifests).
Repo: secondsky/claude-skills
Add a better-auth plugin to an existing project. Configures server and client plugins with proper imports.
Interactive setup wizard for better-auth authentication. Guides through database, framework, OAuth providers, and plugin configuration.
Explain Better Auth error codes and provide solutions with code examples
Display Better Auth available authentication providers and their configuration