clerk — скилл для Claude Code: маршрутизатор задач Clerk
Разбирает запрос про Clerk и отправляет к нужному скиллу: настройка, CLI, паттерны фреймворков, биллинг, вебхуки.
npx skills add clerk/skills --skill clerk -a claude-codeЧто делает clerk
Этот скилл не решает задачу сам, а работает как диспетчер. Агент читает ваш запрос и выбирает один из внутренних скиллов: clerk-setup для подключения Clerk к проекту, clerk-cli для работы с CLI, clerk-custom-ui для своих форм входа, отдельные наборы паттернов под Next.js, React, Vue, Nuxt, Astro, TanStack Start, Expo и Chrome Extension, плюс clerk-orgs, clerk-billing, clerk-webhooks, clerk-testing, clerk-swift, clerk-android и clerk-backend-api.
Перед выбором паттернов скилл смотрит версию SDK в package.json. Для @clerk/nextjs и @clerk/react это v5–v6 (Core 2) против v7+, для @clerk/expo и @clerk/react-router — v1–v2 против v3+, для @clerk/tanstack-react-start — до v0.26.0 против v0.26.0+. Если версия непонятна или проект новый, берётся текущая. Все скиллы написаны под текущий SDK, отличия Core 2 помечены прямо в тексте. Исключение — clerk-custom-ui: там отдельные каталоги core-2/ и core-3/, потому что хуки кастомных флоу между версиями различаются полностью.
Полезно, если вы уже знаете, что нужно: можно вызвать нужный скилл напрямую, минуя маршрутизацию. Для нативных Android-проектов на Kotlin и Jetpack Compose есть clerk-android, но он не подходит для Expo и React Native — там свой скилл. А для iOS и macOS на Swift сначала придётся пройти clerk-setup, если Clerk в проекте ещё не настроен.
Какие задачи решает
- подключить Clerk к проекту на нужном фреймворке
- выбрать паттерны под версию SDK из
package.json - собрать свою форму входа на
useSignInиuseSignUp - настроить организации, роли и права в мультитенантном приложении
- протестировать вебхуки локально и подменить пользователя
Примеры запросов агенту
- добавь Clerk в мой проект на Next.js и подскажи, какие ключи нужны
- у меня
@clerk/nextjsv5, покажи паттерны под Core 2 - настрой биллинг с тарифами и ограничением фич через
has()
Как установить clerk
1Через Skills CLI (Vercel)
npx skills add clerk/skills --skill clerk -a claude-code2Вручную: положить файлы
~/.claude/skills/clerk/SKILL.mdПапка скилла целиком; для одного проекта — .claude/skills/clerk/
1Через Skills CLI (Vercel)
npx skills add clerk/skills --skill clerk -a codex2Вручную: положить файлы
.agents/skills/clerk/SKILL.mdДля всех проектов — ~/.agents/skills/
1Через Skills CLI (Vercel)
npx skills add clerk/skills --skill clerk -a cursor2Вручную: положить файлы
.cursor/skills/clerk/SKILL.mdCursor читает и .agents/skills/, и .claude/skills/
1GitHub CLI
gh skill install clerk/skills clerk2Вручную: положить файлы
.github/skills/clerk/SKILL.md1Через Skills CLI (Vercel)
npx skills add clerk/skills --skill clerk -a gemini-cli2Командой платформы
gemini skills install https://github.com/clerk/skills --path skills/clerkВручную: положить файлы
.devin/skills/clerk/SKILL.mdСтарый путь .windsurf/skills/ тоже читается
Через Skills CLI (Vercel)
npx skills add clerk/skills --skill clerk -a opencodeClaude.ai
Упакуйте папку в zip и загрузите в Settings → Capabilities → Skills
По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов
Из того же набора19
Похожие
Рядом в теме «Безопасность»
Всё по теме «Безопасность» →Вопросы о clerk
Как установить clerk в Claude?
Выполните npx skills add clerk/skills --skill clerk -a claude-code. После этого файл скилла лежит в ~/.claude/skills/clerk/SKILL.md.
Что делает скилл clerk?
Служит маршрутизатором: по вашему запросу выбирает один из внутренних скиллов Clerk — настройку, CLI, паттерны фреймворков, биллинг, вебхуки, тестирование или нативные платформы.
Как он понимает, какие паттерны использовать?
Смотрит версию Clerk SDK в package.json. Для Core 2 и текущей версии паттерны различаются, а если версия непонятна или проект новый, берётся текущая.
Исходный текст
SKILL.md · MIT
--- name: clerk description: Clerk authentication router. Use when user asks about Clerk CLI operations, adding authentication, setting up Clerk, custom sign-in flows, Swift or native iOS auth, native Android auth, Next.js patterns, React patterns, Vue patterns, Nuxt patterns, Astro patterns, TanStack Start patterns, Expo patterns, React Router patterns, Chrome Extension patterns, organizations, billing, subscriptions, payments, pricing, plans, seat-based pricing, feature entitlements, syncing users, testing, impersonating a user, or testing webhooks locally. Automatically routes to the specific skill based on their task. license: MIT metadata: version: 2.0.0 --- # Clerk Skills Router ## Version Detection Check `package.json` to determine the Clerk SDK version. This determines which patterns to use: | Package | Core 2 (LTS until Jan 2027) | Current | |---------|----------------------------|---------| | `@clerk/nextjs` | v5–v6 | v7+ | | `@clerk/react` or `@clerk/clerk-react` | v5–v6 | v7+ | | `@clerk/expo` or `@clerk/clerk-expo` | v1–v2 | v3+ | | `@clerk/react-router` | v1–v2 | v3+ | | `@clerk/tanstack-react-start` | < v0.26.0 | v0.26.0+ | **Default to current** if the version is unclear or the project is new. Core 2 packages use `@clerk/clerk-react` and `@clerk/clerk-expo` (with `clerk-` prefix); current packages use `@clerk/react` and `@clerk/expo`. All skills are written for the current SDK. When something differs in Core 2, it's noted inline with `> **Core 2 ONLY (skip if current SDK):**` callouts. The exception is `clerk-custom-ui`, which has separate `core-2/` and `core-3/` directories for custom flow hooks since those APIs are entirely different between versions. --- ## By Task **Adding Clerk to your project** → Use `clerk-setup` - Framework detection and quickstart - Environment setup, API keys, temporary dev keys via `clerk init` - Migration from other auth providers - Native iOS and macOS apps in Xcode, through the iOS setup prompt **Operating Clerk from the CLI** → Use `clerk-cli` - Auth, linking, `doctor`, and environment pulls - User, org, session, app, and instance management - Impersonating a user (`clerk impersonate`) and local webhook testing (`clerk webhooks listen`) - Feature toggles (`clerk enable orgs`, `clerk enable billing`) - Backend, Platform, and Frontend API calls through `clerk api` - Deploy handoff and deploy status verification **Custom sign-in/sign-up UI** → Use `clerk-custom-ui` - Custom authentication flows with `useSignIn` / `useSignUp` hooks - Appearance and styling (themes, colors, layout) - `<Show>` component for conditional rendering **Advanced Next.js patterns** → Use `clerk-nextjs-patterns` - Server vs Client auth APIs - Middleware strategies - Server Actions, caching - API route protection **React patterns** → Use `clerk-react-patterns` - Hooks (`useAuth`, `useUser`, `useClerk`) - Protected routes, auth guards - Router integration **React Router patterns** → Use `clerk-react-router-patterns` - Loaders & actions with auth - Route protection - SSR auth **Vue patterns** → Use `clerk-vue-patterns` - Composables (`useAuth`, `useUser`, `useClerk`) - Vue Router guards - Pinia auth store integration **Nuxt patterns** → Use `clerk-nuxt-patterns` - Server middleware auth - SSR auth with composables - Server API routes **Astro patterns** → Use `clerk-astro-patterns` - SSR auth pages - Island components with React - Middleware & API routes **TanStack Start patterns** → Use `clerk-tanstack-patterns` - Server functions with auth - Route protection via loaders - Vite plugin and request middleware setup **Expo / React Native auth** → Use `clerk-expo` - Prebuilt native components (AuthView, UserButton) - Custom flows: email, password, SMS/phone OTP, MFA - OAuth/SSO and native Google/Apple sign-in - Expo Router protected routes, token storage, push notifications **Chrome Extension patterns** → Use `clerk-chrome-extension-patterns` - Background scripts auth - Popup auth flows - Content scripts with sync host **B2B / Organizations** → Use `clerk-orgs` - Multi-tenant apps - Organization slugs in URLs - Roles, permissions, RBAC - Member management **Billing & Subscriptions** → Use `clerk-billing` - `<PricingTable />` component - Plan and feature gating with `has()` - Seat-based B2B billing with organizations - Subscription lifecycle webhooks - Free trials, invoicing **Webhooks** → Use `clerk-webhooks` - Real-time events - Data syncing - Notifications & integrations **E2E Testing** → Use `clerk-testing` - Playwright/Cypress setup - Auth flow testing - Test utilities **Swift / native iOS auth** → Use `clerk-swift` - Sign-in UI in native iOS and macOS Swift and SwiftUI projects - ClerkKitUI prebuilt views and custom ClerkKit flows - Source-driven patterns from `clerk-ios` - If Clerk isn't set up yet, set it up first through `clerk-setup` **Android / native mobile auth** → Use `clerk-android` - Native Android Kotlin and Jetpack Compose projects - `clerk-android-api` and `clerk-android-ui` implementation guidance - Source-driven patterns from `clerk-android` - Do not use for Expo or React Native projects **Backend REST API** → Use `clerk-backend-api` - Browse API tags and endpoints - Inspect endpoint schemas - Execute API requests with scope enforcement ## Quick Navigation If you know your task, you can directly access: - `/clerk-setup` - Framework setup - `/clerk-cli` - CLI operations and Clerk resource management - `/clerk-custom-ui` - Custom flows & appearance - `/clerk-nextjs-patterns` - Next.js patterns - `/clerk-react-patterns` - React patterns - `/clerk-react-router-patterns` - React Router patterns - `/clerk-vue-patterns` - Vue patterns - `/clerk-nuxt-patterns` - Nuxt patterns - `/clerk-astro-patterns` - Astro patterns - `/clerk-tanstack-patterns` - TanStack Start patterns - `/clerk-expo` - Expo / React Native - `/clerk-chrome-extension-patterns` - Chrome Extension patterns - `/clerk-orgs` - Organizations - `/clerk-billing` - Billing & subscriptions - `/clerk-webhooks` - Webhooks - `/clerk-testing` - Testing - `/clerk-swift` - Swift/native iOS and macOS UI - `/clerk-android` - Native Android - `/clerk-backend-api` - Backend REST API Or describe what you need and I'll recommend the right one.
© clerk · MIT · clerk/skills