prisma-composer-core-concepts

Explains Prisma Composer concepts for composing, deploying, and testing typed service applications.

Updated Sep 15, 2026
One-click install
npx skills add https://github.com/Furqan-7/bms-app --skill prisma-composer-core-concepts-furqan-7
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: prisma-composer-core-concepts
Source: https://github.com/Furqan-7/bms-app/tree/main/packages/prisma/.cursor/skills/prisma-composer-core-concepts
Command: npx skills add https://github.com/Furqan-7/bms-app --skill prisma-composer-core-concepts-furqan-7

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Working with @prisma/composer requires understanding non-obvious concepts—typed service declarations, provision wiring, secret binding channels, replay-only migrations, and converge-based deploys—that cannot be discovered from the CLI's help output or inferred from code alone. ## Core Features & Use Cases - Conceptual grounding: Explains declarations (services, resources, modules), typed ports, contracts and RPC, the two input channels (deps vs input), and the build/deploy model. - Operational guidance: Covers local development with dev, testing via mockService and bootstrapService, database migration loops, stage management, and destroy semantics. - Failure diagnosis: Documents known failure modes such as effect version conflicts, 401s on unwired RPC calls, MIGRATION_PATH_NOT_FOUND, and scale-to-zero connection resets. - Use Case: When deploying a Prisma Cloud app whose deploy fails with a connection contract refusal, consult this Skill to understand why the producer's outputs must satisfy the declared connection params and how to fix the correct end. ## Quick Start Explain how to wire a Postgres database dependency into a Prisma Composer service and read it at runtime.

Frequently Asked Questions about prisma-composer-core-concepts

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I wire dependencies between services in Prisma Composer?

Declare what a node needs in its deps ports and wire producers to consumers inside a Module's builder using provision(). Because ports are typed, the TypeScript compiler verifies every wire, so wiring errors fail tsc rather than the deploy.

How do I test a Prisma Composer service?

Use mockService from @prisma/composer/testing to substitute typed dependency doubles for isolated tests, or bootstrapService from @prisma/composer-prisma-cloud/testing to boot the real built entry in-process and drive it over real HTTP.

Why does my deployed Prisma Composer RPC endpoint return 401?

Composer mints a per-binding service key at deploy, and serve() returns 401 to any caller that is not a wired consumer. This is expected behavior, not a broken deploy; debug through a wired consumer or locally where nothing is enforced.

Why does prisma-composer fail with an effect version conflict?

The alchemy engine pins an exact effect version, and a hoisted newer effect from your app or a dependency halts every command. Match your app's effect to @prisma/composer's pin or force it with overrides in package.json, then reinstall.

How do database migrations work in Prisma Composer deploys?

Deploys are replay-only: they apply committed migrations and never create schema. Edit contract.prisma, run prisma contract emit, then prisma migration plan, commit migrations/, and deploy; skipping the plan step causes MIGRATION_PATH_NOT_FOUND.

What are the limitations of Prisma Composer contracts?

RPC over HTTP is currently the only contract kind, with no gRPC, WebSocket, or streaming support. There are also no in-memory contract bindings, so co-located handlers require bootstrapService with a loopback fake.