Skip to content
On this page

Getting started

Prisma-AppSync is a Prisma Generator, that instantly converts your Schema into a full-blown GraphQL API for AWS AppSync.

From schema.prisma:

prisma
model Post {
    id         Int
    title      String
}

To full-blown GraphQL API:

graphql
query list {
  listPosts {
    id
    title
  }
}

👉 Features

  • 💎 Utilize ◭ Prisma Schema to define data structure and quickly spin up a GraphQL API.
  • ⚡️ Auto-generated CRUD operations, fully customisable and using Prisma syntax.
  • Built-in, zero-config XSS data sanitization, query depth control and rate limiting.
  • 🔐 Fine-grained access control and authorization modes (API key, IAM, Cognito, etc).
  • 🔌 Fully extensible GQL schema and TS Client API to add custom hooks and resolvers.

👉 Built around 4 packages

packages/generator

Generator for Prisma ORM, whose role is to parse schema.prisma and generate a fully typed Client (written in TypeScript for AWS Lambda), plus all the files required to run and deploy a GraphQL API on AWS AppSync (Schema + Resolver mapping).

packages/client

Think of it as Prisma Client on steroids 💪. Fully typed, written in TypeScript for AWS Lambda AppSync resolvers, and capable to handle CRUD operations with a single line of code. It also allows extending and customising the GraphQL API.

packages/installer

Interactive scaffolding CLI to quickly start new Prisma-AppSync projects, accessible from a single npx create-prisma-appsync-app@latest command. It can also plug into existing projects already using Prisma.

packages/server

Local development environment built for Prisma-AppSync (local database, auto-reload, TS support, GraphQL IDE). Simulate a GraphQL API running on AWS AppSync + AWS Lambda Resolver + Prisma ORM + Database.

Released under the BSD 2-Clause License.