prisma ยท Prisma Docs
Prisma Clerk (with Next.js) (/docs/guides/authentication/clerk/nextjs)
Integrate Clerk authentication with Prisma ORM within an Astro application framework.
Derived skill
Files assembled from official documentation
Viewing SKILL.md
Prisma Clerk (with Next.js) (/docs/guides/authentication/clerk/nextjs)
Integrate Clerk authentication with Prisma ORM within an Astro application framework.
When To Use
Use when you need to implement user authentication using Clerk while managing database interactions via Prisma in an Astro project.
Reference Files
| File | Contains | Use For |
|---|---|---|
SKILL.md | Entry point: scope, routing table, and workflow. | Start here. |
docs/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-workflow-guide.md | A guide explaining how to integrate Prisma ORM with Clerk authentication in a Next.js application. | Questions about a guide explaining how to integrate Prisma ORM with Clerk authentication in a Next.js application. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk.bash | The bash command to initialize a new Next.js application named clerk-nextjs-prisma for the Prisma and Clerk integration guide. | Exact payloads, commands, or snippets shown in The bash command to initialize a new Next.js application named clerk-nextjs-prisma for the Prisma and Clerk integrati... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-2.bash | A bash command to initialize a new Next.js application named clerk-nextjs-prisma using pnpm. | Exact payloads, commands, or snippets shown in A bash command to initialize a new Next.js application named clerk-nextjs-prisma using pnpm. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-3.bash | A bash command to initialize a new Next.js application named clerk-nextjs-prisma using yarn dlx. | Exact payloads, commands, or snippets shown in A bash command to initialize a new Next.js application named clerk-nextjs-prisma using yarn dlx. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-4.bash | A bash command to initialize a new Next.js application using bunx for a Prisma and Clerk integration project. | Exact payloads, commands, or snippets shown in A bash command to initialize a new Next.js application using bunx for a Prisma and Clerk integration project. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-5.bash | Bash commands to initialize the clerk-nextjs-prisma project directory. | Exact payloads, commands, or snippets shown in Bash commands to initialize the clerk-nextjs-prisma project directory. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-6.bash | The npm install command to add the Clerk Next.js SDK to a project. | Exact payloads, commands, or snippets shown in The npm install command to add the Clerk Next.js SDK to a project. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-7.bash | The bash command to install the @clerk/nextjs package using pnpm. | Exact payloads, commands, or snippets shown in The bash command to install the @clerk/nextjs package using pnpm. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-8.bash | The bash command to install the @clerk/nextjs package using yarn. | Exact payloads, commands, or snippets shown in The bash command to install the @clerk/nextjs package using yarn. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-9.bash | A bash command to install the @clerk/nextjs package using the bun package manager. | Exact payloads, commands, or snippets shown in A bash command to install the @clerk/nextjs package using the bun package manager. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-10.bash | A bash script containing the required Clerk environment variables for a Next.js application using Prisma. | Exact payloads, commands, or snippets shown in A bash script containing the required Clerk environment variables for a Next.js application using Prisma. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk.tsx | A TypeScript React component file demonstrating the implementation of clerkMiddleware and matcher configuration for Next.js authentication. | Exact payloads, commands, or snippets shown in A TypeScript React component file demonstrating the implementation of clerkMiddleware and matcher configuration for N... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-2.tsx | A Next.js root layout component implementation using TypeScript and Geist fonts for a Prisma and Clerk authentication setup. | Exact payloads, commands, or snippets shown in A Next.js root layout component implementation using TypeScript and Geist fonts for a Prisma and Clerk authentication... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-3.tsx | A Next.js layout component demonstrating the integration of Clerk authentication components like UserButton and SignInButton within a Prisma-enabled application. | Exact payloads, commands, or snippets shown in A Next.js layout component demonstrating the integration of Clerk authentication components like UserButton and SignI... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-11.bash | The bash command to install prisma, tsx, and postgres types as development dependencies for a Next.js project using Clerk authentication. | Exact payloads, commands, or snippets shown in The bash command to install prisma, tsx, and postgres types as development dependencies for a Next.js project using C... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-12.bash | Bash command to install prisma, tsx, and postgres types as development dependencies for a Next.js project using Clerk authentication. | Exact payloads, commands, or snippets shown in Bash command to install prisma, tsx, and postgres types as development dependencies for a Next.js project using Clerk... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-13.bash | Bash commands to install prisma, tsx, and postgres types as development dependencies for a Next.js project using Clerk authentication. | Exact payloads, commands, or snippets shown in Bash commands to install prisma, tsx, and postgres types as development dependencies for a Next.js project using Cler... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-14.bash | A bash command to install prisma, tsx, and postgres types using the bun package manager for a Next.js and Clerk integration. | Exact payloads, commands, or snippets shown in A bash command to install prisma, tsx, and postgres types using the bun package manager for a Next.js and Clerk integ... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-15.bash | The npm install command to add Prisma client, PostgreSQL adapter, dotenv, and pg to a Next.js project using Clerk authentication. | Exact payloads, commands, or snippets shown in The npm install command to add Prisma client, PostgreSQL adapter, dotenv, and pg to a Next.js project using Clerk aut... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-16.bash | A bash command to install Prisma client, PostgreSQL adapter, dotenv, and pg using pnpm for a Next.js and Clerk integration. | Exact payloads, commands, or snippets shown in A bash command to install Prisma client, PostgreSQL adapter, dotenv, and pg using pnpm for a Next.js and Clerk integr... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-17.bash | Bash commands to install the Prisma client, PostgreSQL adapter, and dotenv dependencies for a Next.js Clerk integration. | Exact payloads, commands, or snippets shown in Bash commands to install the Prisma client, PostgreSQL adapter, and dotenv dependencies for a Next.js Clerk integration. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-18.bash | A bash command to install Prisma client, PostgreSQL adapter, dotenv, and pg using the bun package manager for a Clerk and Next.js integration. | Exact payloads, commands, or snippets shown in A bash command to install Prisma client, PostgreSQL adapter, dotenv, and pg using the bun package manager for a Clerk... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-19.bash | A bash command to initialize Prisma with a custom output directory for a Next.js project using Clerk authentication. | Exact payloads, commands, or snippets shown in A bash command to initialize Prisma with a custom output directory for a Next.js project using Clerk authentication. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-20.bash | A bash command to initialize Prisma with a specific output directory for a Next.js project using Clerk authentication. | Exact payloads, commands, or snippets shown in A bash command to initialize Prisma with a specific output directory for a Next.js project using Clerk authentication. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-21.bash | A bash command to initialize Prisma with a specific output directory for a Next.js project using Clerk authentication. | Exact payloads, commands, or snippets shown in A bash command to initialize Prisma with a specific output directory for a Next.js project using Clerk authentication. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-22.bash | A bash command to initialize Prisma with a specific output directory using bunx. | Exact payloads, commands, or snippets shown in A bash command to initialize Prisma with a specific output directory using bunx. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-23.bash | A bash command to initialize the database using npx create-db within a Prisma and Clerk Next.js integration setup. | Exact payloads, commands, or snippets shown in A bash command to initialize the database using npx create-db within a Prisma and Clerk Next.js integration setup. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-24.bash | A bash command to execute the create-db utility using pnpm dlx for a Prisma and Clerk integration setup. | Exact payloads, commands, or snippets shown in A bash command to execute the create-db utility using pnpm dlx for a Prisma and Clerk integration setup. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-25.bash | A bash command to initialize the database using yarn dlx create-db for a Prisma and Clerk integration in Next.js. | Exact payloads, commands, or snippets shown in A bash command to initialize the database using yarn dlx create-db for a Prisma and Clerk integration in Next.js. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-26.bash | A bash command using bunx to create the database for a Prisma and Clerk integration in Next.js. | Exact payloads, commands, or snippets shown in A bash command using bunx to create the database for a Prisma and Clerk integration in Next.js. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk.prisma | A Prisma schema definition extending the User model with Clerk-specific fields like clerkId for authentication integration. | Exact payloads, commands, or snippets shown in A Prisma schema definition extending the User model with Clerk-specific fields like clerkId for authentication integr... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk.typescript | A TypeScript configuration example demonstrating the integration of Prisma with Clerk authentication in a Next.js environment. | Exact payloads, commands, or snippets shown in A TypeScript configuration example demonstrating the integration of Prisma with Clerk authentication in a Next.js env... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-27.bash | Bash commands to install the dotenv package for a Prisma and Clerk integration in a Next.js project. | Exact payloads, commands, or snippets shown in Bash commands to install the dotenv package for a Prisma and Clerk integration in a Next.js project. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-28.bash | A bash command to install the dotenv package using pnpm for a Prisma and Clerk integration in Next.js. | Exact payloads, commands, or snippets shown in A bash command to install the dotenv package using pnpm for a Prisma and Clerk integration in Next.js. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-29.bash | A bash command to install the dotenv package using yarn for a Prisma and Clerk integration in Next.js. | Exact payloads, commands, or snippets shown in A bash command to install the dotenv package using yarn for a Prisma and Clerk integration in Next.js. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-30.bash | A bash command to install the dotenv package using the bun package manager for a Prisma and Clerk Next.js integration. | Exact payloads, commands, or snippets shown in A bash command to install the dotenv package using the bun package manager for a Prisma and Clerk Next.js integration. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-31.bash | A bash command to initialize the database schema using Prisma migrations for a Clerk authentication setup in Next.js. | Exact payloads, commands, or snippets shown in A bash command to initialize the database schema using Prisma migrations for a Clerk authentication setup in Next.js. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-32.bash | A bash command to initialize the database schema using prisma migrate dev. | Exact payloads, commands, or snippets shown in A bash command to initialize the database schema using prisma migrate dev. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-33.bash | A bash command to initialize the database schema using Prisma Migrate for a Clerk authentication setup in Next.js. | Exact payloads, commands, or snippets shown in A bash command to initialize the database schema using Prisma Migrate for a Clerk authentication setup in Next.js. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-34.bash | A bash command to run a Prisma database migration using bunx. | Exact payloads, commands, or snippets shown in A bash command to run a Prisma database migration using bunx. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-35.bash | A bash command to generate the Prisma client for a Next.js application using Clerk authentication. | Exact payloads, commands, or snippets shown in A bash command to generate the Prisma client for a Next.js application using Clerk authentication. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-gener.bash | A bash command to generate the Prisma client using pnpm dlx. | Exact payloads, commands, or snippets shown in A bash command to generate the Prisma client using pnpm dlx. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-36.bash | The bash command to generate the Prisma client using yarn dlx. | Exact payloads, commands, or snippets shown in The bash command to generate the Prisma client using yarn dlx. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-37.bash | A bash command to generate the Prisma client using bunx with the bun runtime. | Exact payloads, commands, or snippets shown in A bash command to generate the Prisma client using bunx with the bun runtime. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-4.tsx | A TypeScript React component implementation demonstrating the integration of Prisma with Clerk authentication in a Next.js application. | Exact payloads, commands, or snippets shown in A TypeScript React component implementation demonstrating the integration of Prisma with Clerk authentication in a Ne... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-5.tsx | A TypeScript React component demonstrating how to verify Clerk webhooks within a Next.js application using the @clerk/nextjs/webhooks library. | Exact payloads, commands, or snippets shown in A TypeScript React component demonstrating how to verify Clerk webhooks within a Next.js application using the @clerk... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-6.tsx | A Next.js API route handler implementation using Clerk's verifyWebhook to process incoming webhook events. | Exact payloads, commands, or snippets shown in A Next.js API route handler implementation using Clerk's verifyWebhook to process incoming webhook events. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-7.tsx | A Next.js API route implementation using Clerk webhooks to synchronize user data with a Prisma database. | Exact payloads, commands, or snippets shown in A Next.js API route implementation using Clerk webhooks to synchronize user data with a Prisma database. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-8.tsx | A Next.js API route implementation using Clerk webhooks to upsert user data into a Prisma database. | Exact payloads, commands, or snippets shown in A Next.js API route implementation using Clerk webhooks to upsert user data into a Prisma database. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-38.bash | A bash command to install the ngrok CLI globally via npm for local development tunneling. | Exact payloads, commands, or snippets shown in A bash command to install the ngrok CLI globally via npm for local development tunneling. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-39.bash | A bash command to install ngrok globally using pnpm for local development tunneling. | Exact payloads, commands, or snippets shown in A bash command to install ngrok globally using pnpm for local development tunneling. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-40.bash | Bash commands to install ngrok globally and tunnel local port 3000 for Clerk authentication testing. | Exact payloads, commands, or snippets shown in Bash commands to install ngrok globally and tunnel local port 3000 for Clerk authentication testing. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-41.bash | A bash command to install ngrok globally using bun for local development tunneling. | Exact payloads, commands, or snippets shown in A bash command to install ngrok globally using bun for local development tunneling. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk.text | The webhook endpoint URL used to configure Clerk to send authentication events to a Next.js application. | Exact payloads, commands, or snippets shown in The webhook endpoint URL used to configure Clerk to send authentication events to a Next.js application. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-42.bash | A list of required environment variables for integrating Prisma with Clerk in a Next.js application. | Exact payloads, commands, or snippets shown in A list of required environment variables for integrating Prisma with Clerk in a Next.js application. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-studi.bash | The bash command to launch Prisma Studio for inspecting the database during the Clerk authentication integration guide. | Exact payloads, commands, or snippets shown in The bash command to launch Prisma Studio for inspecting the database during the Clerk authentication integration guide. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-43.bash | A bash command to launch Prisma Studio for inspecting the database used in a Clerk and Next.js authentication setup. | Exact payloads, commands, or snippets shown in A bash command to launch Prisma Studio for inspecting the database used in a Clerk and Next.js authentication setup. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-44.bash | A bash command to launch Prisma Studio for inspecting the database used in a Prisma and Clerk authentication setup with Next.js. | Exact payloads, commands, or snippets shown in A bash command to launch Prisma Studio for inspecting the database used in a Prisma and Clerk authentication setup wi... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-45.bash | A bash command to run Prisma Studio using the Bun runtime for a Next.js project integrated with Clerk authentication. | Exact payloads, commands, or snippets shown in A bash command to run Prisma Studio using the Bun runtime for a Next.js project integrated with Clerk authentication. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-9.tsx | A TypeScript React component demonstrating how to integrate Clerk authentication with Prisma in a Next.js application. | Exact payloads, commands, or snippets shown in A TypeScript React component demonstrating how to integrate Clerk authentication with Prisma in a Next.js application. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-10.tsx | A Next.js route handler implementation using Clerk authentication to retrieve a userId for Prisma operations. | Exact payloads, commands, or snippets shown in A Next.js route handler implementation using Clerk authentication to retrieve a userId for Prisma operations. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-11.tsx | A Next.js route handler demonstrating how to retrieve a Clerk userId and query a Prisma user record using the clerkId. | Exact payloads, commands, or snippets shown in A Next.js route handler demonstrating how to retrieve a Clerk userId and query a Prisma user record using the clerkId. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-12.tsx | A Next.js API route handler demonstrating how to retrieve a Clerk userId and query a Prisma user record. | Exact payloads, commands, or snippets shown in A Next.js API route handler demonstrating how to retrieve a Clerk userId and query a Prisma user record. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-13.tsx | A Next.js client component implementation for handling post input states within a Prisma and Clerk authentication workflow. | Exact payloads, commands, or snippets shown in A Next.js client component implementation for handling post input states within a Prisma and Clerk authentication wor... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-14.tsx | A Next.js client component using React state to handle form inputs for creating posts within a Clerk authentication context. | Exact payloads, commands, or snippets shown in A Next.js client component using React state to handle form inputs for creating posts within a Clerk authentication c... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-15.tsx | A Next.js client component using React state and fetch to send post data to an API endpoint. | Exact payloads, commands, or snippets shown in A Next.js client component using React state and fetch to send post data to an API endpoint. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-16.tsx | A Next.js home component demonstrating the integration of Prisma and Clerk for authentication using TypeScript JSX. | Exact payloads, commands, or snippets shown in A Next.js home component demonstrating the integration of Prisma and Clerk for authentication using TypeScript JSX. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-17.tsx | A TypeScript React component demonstrating how to use Clerk's currentUser helper within a Next.js page to integrate with Prisma. | Exact payloads, commands, or snippets shown in A TypeScript React component demonstrating how to use Clerk's currentUser helper within a Next.js page to integrate w... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-18.tsx | A Next.js page component demonstrating how to retrieve the current user session using Clerk and integrate it with Prisma. | Exact payloads, commands, or snippets shown in A Next.js page component demonstrating how to retrieve the current user session using Clerk and integrate it with Pri... |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-19.tsx | A Next.js server component demonstrating how to fetch database records using Prisma filtered by a Clerk user ID. | Exact payloads, commands, or snippets shown in A Next.js server component demonstrating how to fetch database records using Prisma filtered by a Clerk user ID. |
examples/prisma-clerk-with-next-js-docs-guides-authentication-nextjs-prisma-clerk-20.tsx | A Next.js server component demonstrating how to fetch database records using Prisma by filtering with the Clerk user ID. | Exact payloads, commands, or snippets shown in A Next.js server component demonstrating how to fetch database records using Prisma by filtering with the Clerk user ID. |
What This Skill Covers
-
- Clerk (with Astro): Learn how to use Prisma ORM in an Astro app with Clerk Auth
- Main sections:
Related pages.
Workflow
- Open the most relevant file under
docs/for the exact documented workflow and wording. - Open
schemas/files for exact structured contracts. - Open
examples/files for concrete requests, commands, snippets, and manifests. - Do not add behavior or configuration that is not present in the attached source files.
Canonical source: https://www.prisma.io/docs/guides/authentication/clerk/nextjs