From website-deployment
Adds Cognito authentication and route protection. Use when adding login, signup, authentication, or user management.
How this skill is triggered — by the user, by Claude, or both
Slash command
/website-deployment:add-authThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
You are adding Cognito authentication to protect API routes and manage user accounts.
You are adding Cognito authentication to protect API routes and manage user accounts.
Based on the migration plan, show the user:
Explain the auth flow before asking questions: "Here's how authentication will work in your app:
Ask the user:
Create infrastructure/lib/auth-stack.ts
Add Cognito Authorizer to API Gateway
api-stack.ts to:
Create React auth integration (if frontend exists)
cd frontend && npm install amazon-cognito-identity-jsfrontend/src/lib/auth.ts with:
signUp(email, password), confirmSignUp(email, code), signIn(email, password)signOut(), getSession(), getIdToken()VITE_COGNITO_USER_POOL_ID, VITE_COGNITO_CLIENT_IDfrontend/src/hooks/useAuth.ts — manages auth state, provides auth functions, checks session on mountfrontend/src/context/AuthContext.tsx — wraps app to provide auth statefrontend/src/components/:
SignInForm.tsx, SignUpForm.tsx, ConfirmSignUp.tsx, ProtectedRoute.tsxUpdate API client to include auth token:
Update frontend/src/lib/api.ts:
import { getIdToken } from './auth';
export async function apiFetch(path: string, options?: RequestInit) {
const token = await getIdToken();
const headers: Record<string, string> = {
'Content-Type': 'application/json',
...options?.headers as Record<string, string>,
};
if (token) {
headers['Authorization'] = `Bearer ${token}`;
}
const response = await fetch(`${API_BASE}${path}`, { ...options, headers });
if (!response.ok) throw new Error(`API error: ${response.status}`);
return response.json();
}
Update React Router to protect routes:
<Route path="/dashboard" element={
<ProtectedRoute>
<DashboardPage />
</ProtectedRoute>
} />
cd infrastructure && npx cdk synth to verify compilation.migration/plan.md to mark add-auth as complete[email protected].npx claudepluginhub schuettc/website-deployment-plugin --plugin website-deploymentScaffold signin and signup authentication endpoints for a project. Use when the user wants to add authentication, create login/register flows, or set up auth from scratch.
Use when adding authentication or login to any app - detects your stack (React, Next.js, Vue, Nuxt, Angular, Express, Fastify, FastAPI, ASP.NET Core, React Native, Expo, Android, Swift), sets up an Auth0 account if needed, and routes to the correct SDK setup workflow.
Implements fullstack auth flows: login/signup/forgot-password pages, JWT+refresh tokens, session auth, social login (Google/GitHub/Apple), MFA/2FA, protected routes via middleware, role-based UI. Use for adding auth/authorization.