clerk-setup
Adding Clerk
Version: Check
package.jsonfor the SDK version — seeclerkskill for the version table. Core 2 differences are noted inline with> **Core 2 ONLY (skip if current SDK):**callouts.
This skill sets up Clerk for authentication by following the official quickstart documentation. For agents, the clerk CLI handles most of this end to end — see the next section.
Agent-first: Provision via CLI
The clerk CLI replaces most Dashboard clicks. Three scenarios cover almost everything:
Scenario A — New project, new Clerk app
clerk init --framework <next|react|vue|nuxt|astro|react-router|tanstack-react-start|expressjs|fastify|expo> -y
clerk init creates the Clerk app via PLAPI, links the project, writes the framework-specific publishable + secret keys to the right env file (e.g. .env.local for Next.js, .env for Vite-based projects), and installs the SDK package.
Scenario B — Existing project, existing Clerk app
More from clerk/skills
clerk-nextjs-patterns
Advanced Next.js patterns - middleware, Server Actions, caching with
11.2Kclerk
Clerk authentication router. Use when user asks about adding authentication,
7.7Kclerk-custom-ui
Custom authentication flows and component appearance - hooks (useSignIn,
6.7Kclerk-webhooks
Clerk webhooks for real-time events and data syncing. Verify with verifyWebhook
6.0Kclerk-testing
E2E testing for Clerk apps. Use with Playwright or Cypress for auth flow
5.8Kclerk-orgs
Clerk Organizations for B2B SaaS - create multi-tenant apps with org
5.3K