prisma-postgres-setup

Provision Prisma Postgres databases via the Management API and connect them to local projects.

Updated Aug 21, 2026
One-click install
npx skills add https://github.com/soumeningit/FlowBoard --skill prisma-postgres-setup-soumeningit
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: prisma-postgres-setup
Source: https://github.com/soumeningit/FlowBoard/tree/main/packages/database/.windsurf/skills/prisma-postgres-setup
Command: npx skills add https://github.com/soumeningit/FlowBoard --skill prisma-postgres-setup-soumeningit

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires prisma, @prisma/client, @prisma/adapter-pg, pg, dotenv, and includes references (resource) components.

What problem does it solve? Setting up a new Prisma Postgres database involves multiple manual steps: creating a project through the Management API, retrieving connection strings, configuring Prisma 7's new client adapter pattern, and verifying connectivity. This Skill automates the entire provisioning workflow so you get a working database connection without reading API documentation. ## Core Features & Use Cases - Automated Provisioning: Creates Prisma Postgres projects and databases through the Management API, including region selection and connection string retrieval. - Prisma 7 Configuration: Sets up prisma.config.ts, the @prisma/adapter-pg driver adapter, ESM output, and environment variables correctly for the new Prisma 7 architecture. - End-to-End Verification: Runs a live connection test against the provisioned database to confirm the full setup works before you start building. - Use Case: You are starting a new Node.js project and need a hosted Postgres database. Ask the agent to set up Prisma Postgres, and it provisions the database, writes your .env, scaffolds the schema, runs the initial migration, and verifies connectivity. ## Quick Start Set up a new Prisma Postgres database for this project and connect it locally using my service token.

Frequently Asked Questions about prisma-postgres-setup

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

FAQPage Schema
How do I set up a Prisma Postgres database from the command line?▼

Use the Prisma Management API with a workspace service token to create a project with createDatabase enabled, then extract the direct connection string from the response. Write it to your .env file as DATABASE_URL and configure prisma.config.ts to load it.

How do I get a Prisma Postgres connection string?▼

Create a project via POST /v1/projects with createDatabase set to true, then read data.database.connections[0].endpoints.direct.connectionString from the response. Use the direct endpoint, not the pooled or Accelerate endpoints.

How do I instantiate PrismaClient in Prisma 7?▼

Create a pg.Pool with your DATABASE_URL, wrap it in a PrismaPg adapter from @prisma/adapter-pg, and pass { adapter } to the PrismaClient constructor. Calling new PrismaClient() with no arguments or with datasourceUrl throws in Prisma 7.

Why does Prisma 7 not read the connection URL from schema.prisma?▼

Prisma 7 moved connection URLs out of the schema into prisma.config.ts, which loads DATABASE_URL from the environment via dotenv. The datasource block in schema.prisma should only declare the postgresql provider with no url property.

What should I do when Prisma Postgres project creation hits a database limit?▼

List your existing projects with GET /v1/projects, pick one to remove, and delete it via DELETE /v1/projects/{projectId}. Then retry the project creation request with the same parameters.

When should I not use the Prisma Management API for database setup?▼

Do not use it for CI/CD preview databases or multi-tenant provisioning built into an application, which require dedicated workflows. Standard schema and migration tasks on an existing database use the regular Prisma CLI instead.