This repository contains a number of ready-to-run example projects demonstrating various use cases of Prisma. Pick an example and follow the instructions in the corresponding README.
You can also find links to real-world and production ready examples further below in this README.
Are you missing an example? Please feel free to open an issue (read the contribution guidelines for more info).
Demo | Description |
---|---|
rest-nextjs-api-routes |
Next.js app with a REST API (using Next.js API routes) |
rest-nextjs-api-routes-auth |
Next.js app with a REST API (using Next.js API routes) and authentication (using NextAuth.js) |
rest-nextjs-express |
Next.js app with a REST API (using Express) |
graphql-nextjs |
Next.js app with a GraphQL API (using Apollo Server and Nexus Schema) |
Demo | Description |
---|---|
graphql-apollo-server |
GraphQL server based on apollo-server and Nexus Schema |
graphql-auth |
GraphQL server with email-password authentication & permissions |
graphql-sdl-first |
GraphQL server based on the SDL-first approach of graphql-tools |
graphql-subscriptions |
GraphQL server with realtime subscriptions based on apollo-server and Nexus Schema |
graphql-typegraphql |
GraphQL server based on apollo-server and TypeGraphQL |
graphql-express |
GraphQL server based on Express and Nexus Schema |
graphql-express-sdl-first |
GraphQL server based on Express and the SDL-first approach of graphql-tools |
graphql-hapi |
GraphQL server based on Hapi and Nexus Schema |
graphql-hapi-sdl-first |
GraphQL server based on Hapi and the SDL-first approach of Apollo Server Hapi |
graphql-nestjs |
GraphQL server based on NestJS (code-first) |
graphql-nestjs-sdl-first |
GraphQL server based on NestJS and the SDL-first approach of graphql-tools |
graphql |
GraphQL server based on apollo-server and Nexus Schema |
grpc |
gRPC API including runnable client scripts for testing |
postgis-express |
Demo of spatial queries using Postgis and Express |
rest-express |
REST API with Express |
rest-hapi |
REST API with hapi |
rest-nestjs |
REST API with NestJS |
script |
Usage of Prisma Client JS in a TypeScript script |
testing-express |
Demo of integration tests with Jest, Supertest and Express |
Demo | Description |
---|---|
rest-nextjs |
Next.js app with a REST API (using Next.js API routes) |
Demo | Description |
---|---|
graphql-apollo-server |
GraphQL server based on apollo-server |
graphql-auth |
GraphQL server with email-password authentication & permissions |
graphql-sdl-first |
GraphQL server based on the SDL-first approach of graphql-tools |
graphql |
GraphQL server based on apollo-server |
grpc |
gRPC API including runnable client scripts for testing |
rest-express |
REST API with Express |
rest-fastify |
REST API with Fastify |
script |
Usage of Prisma Client JS in a Node.js script |
The projects in the deployment-platforms
directory show what "Prisma Client"-based deployment setups look like for various deployment providers. Learn more about deployment in the Prisma documentation.
- Backend for a real world grading application (incl video and written tutorials)
- Tottem – Fullstack app for "social library management" (based on Next.js)
The latest
branch of this repository contains the examples with the latest stable version of Prisma CLI and Prisma Client (@latest
on npm). These dependencies are kept up to date with a GitHub Action workflow, which updates them every time a new version of Prisma is released.
There are also the automated branches dev
and patch-dev
, which mirror the code from latest
(synced via a GitHub Action workflow), but they use the respective development channels of Prisma CLI and Prisma Client from npm instead (@dev
and @patch-dev
, also updated via a GitHub Action workflow). Thanks to the test coverage of all projects, this can point us to incompatibilities early.
If you have a security issue to report, please contact us at [email protected]
CI Status | Branch |
---|---|
latest |
|
dev |
|
patch-dev |
CI Status |
---|