prisma-postgres

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

Updated Aug 17, 2026
One-click install
npx skills add https://github.com/Sahil-Showket/ShopSphere --skill prisma-postgres-sahil-showket
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: prisma-postgres
Source: https://github.com/Sahil-Showket/ShopSphere/tree/main/services/product-service/.windsurf/skills/prisma-postgres
Command: npx skills add https://github.com/Sahil-Showket/ShopSphere --skill prisma-postgres-sahil-showket

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—Prisma Console, the create-db CLI, the Management API, and its TypeScript SDK—and choosing the wrong workflow or mishandling one-time credentials leads to lost connection strings and broken environments. ## Core Features & Use Cases - Instant Provisioning: Create temporary or persistent Prisma Postgres databases with create-db (aliases create-pg, create-postgres), including region selection, TTL, JSON output, and .env writing. - Programmatic Management: Use the Management API at https://api.prisma.io/v1 or the typed @prisma/management-api-sdk with service tokens or OAuth for workspace, project, branch, and database automation. - Project Linking & Connections: Link existing databases with prisma postgres link, configure direct TCP connections with sslmode=require, and choose between @prisma/adapter-pg and the serverless @prisma/adapter-ppg. - Use Case: A backend engineer needs a Postgres database for a CI preview environment. They run npx create-db@latest --ttl 2h --json to provision a temporary instance, capture the connection string, and let it auto-delete after the pipeline finishes. ## Quick Start Ask the AI to provision a new Prisma Postgres database using 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`, `--ttl`, `--json`, or `--env .env` to control region, auto-deletion, output format, and environment file writing.

How to provision Prisma Postgres programmatically in TypeScript?▼

Install `@prisma/management-api-sdk` and use `createManagementApiClient` with an existing service token, or `createManagementApiSdk` for OAuth with token refresh. The SDK exposes typed endpoints for workspaces, projects, databases, and service tokens.

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, Prisma Postgres exposes a direct endpoint at db.prisma.io:5432 and a pooled endpoint at pooled.db.prisma.io:5432. Use `sslmode=require` in the connection URL and the `@prisma/adapter-pg` adapter for standard Node.js applications.

Why did my Prisma Postgres database get deleted automatically?▼

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 shown in the command output to keep the database permanently.

When should I use the Management API instead of Prisma Console?▼

Use the Management API when you need backend automation, multi-tenant onboarding, or controlled resource provisioning that interactive Console workflows cannot provide. Authenticate with a workspace service token for server-to-server calls or OAuth 2.0 to act on behalf of users.