prisma-postgres

Provision and manage Prisma Postgres databases via Console, create-db CLI, and Management API.

Updated Jul 1, 2026
One-click install
npx skills add https://github.com/son1cleo/databrief --skill prisma-postgres-son1cleo
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: prisma-postgres
Source: https://github.com/son1cleo/databrief/tree/main/frontend/.windsurf/skills/prisma-postgres
Command: npx skills add https://github.com/son1cleo/databrief --skill prisma-postgres-son1cleo

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires create-db, @prisma/management-api-sdk, @prisma/cli, and includes references (resource) components.

What problem does it solve? Setting up and managing Prisma Postgres databases involves multiple surfaces — the Prisma Console, the create-db CLI, the Management API, and its TypeScript SDK — and choosing the right workflow for each scenario is confusing without consolidated guidance. ## Core Features & Use Cases - Instant Provisioning: Create temporary or persistent databases with npx create-db, including region selection, TTL, JSON output, and .env writing. - Programmatic Management: Automate workspace, project, branch, and database operations through the Management API with service tokens or OAuth 2.0. - Typed SDK Integration: Use @prisma/management-api-sdk for typed endpoint calls with OAuth token refresh and storage. - Use Case: A backend engineer building a multi-tenant SaaS needs to provision an isolated Postgres database per customer; the skill guides them through Management API authentication, database creation endpoints, and one-time connection string handling. ## Quick Start Ask the assistant to provision a new Prisma Postgres database with create-db and write the connection string into your project's .env file.

Frequently Asked Questions about prisma-postgres

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

FAQPage Schema
How do I create a Prisma Postgres database from the terminal?

Run `npx create-db@latest` to provision a database instantly, with aliases `create-pg` and `create-postgres`. Use flags like `--region`, `--json`, `--env .env`, or `--ttl 2h` to control region, output format, env file writing, and auto-deletion time.

How do I provision Prisma Postgres databases programmatically?

Use the Management API at https://api.prisma.io/v1 with a service token or OAuth 2.0, or install @prisma/management-api-sdk for typed endpoint calls. The SDK's createManagementApiSdk handles OAuth login, callback, and token refresh automatically.

What is the difference between create-db and prisma postgres link?

create-db provisions a new temporary database that auto-deletes after about 24 hours unless claimed. prisma postgres link connects an existing Prisma Postgres database to your local project by writing DATABASE_URL into your .env file.

Does Prisma Postgres support direct TCP connections?

Yes, direct TCP connections use db.prisma.io:5432 with sslmode=require, suitable for pg and @prisma/adapter-pg. Connection responses expose endpoints.direct and endpoints.pooled; secrets are shown only once at creation, so store them immediately.

Why did my create-db database get deleted?

Databases created with create-db are temporary by default and unclaimed instances auto-delete after roughly 24 hours, or sooner if you set a --ttl flag. Open the claim URL printed in the command output to keep the database permanently.