Skip to main content
Glama

Prisma MCP Server

Official
by prisma
Apache 2.0
4
44,213
  • Linux
  • Apple
tests.ts1.3 kB
import testMatrix from './_matrix' // @ts-ignore import type { PrismaClient } from './generated/prisma/client' declare let prisma: PrismaClient testMatrix.setupTestSuite( () => { beforeAll(async () => { await prisma.component.createMany({ data: [ { id: 1, title: 'Blog', }, { id: 2, title: 'Blog 2', }, ], }) await prisma.componentCategory.createMany({ data: [ { id: 1, name: 'Blog', }, ], }) await prisma.component.update({ where: { id: 1 }, data: { categories: { set: { id: 1 } }, }, }) await prisma.component.update({ where: { id: 2 }, data: { categories: { set: { id: 1 } }, }, }) }) test('example', async () => { const components = await prisma.component.findMany({ include: { categories: true } }) expect(components[0].categories[0].id).toBe(BigInt('1')) expect(components[1].categories[0].id).toBe(BigInt('1')) }) }, { optOut: { from: ['sqlite', 'postgresql', 'mongodb', 'cockroachdb', 'sqlserver'], reason: 'mysql specific problem', }, }, )

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/prisma/prisma'

If you have feedback or need assistance with the MCP directory API, please join our Discord server