prisma-postgres

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

Updated Jul 30, 2026
One-click install
npx skills add https://github.com/iukumarasiri-dev/JobNest-AI --skill prisma-postgres-iukumarasiri-dev
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: prisma-postgres
Source: https://github.com/iukumarasiri-dev/JobNest-AI/tree/main/job-assistant/.windsurf/skills/prisma-postgres
Command: npx skills add https://github.com/iukumarasiri-dev/JobNest-AI --skill prisma-postgres-iukumarasiri-dev

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—Console, CLI tools, and APIs—and choosing the wrong workflow wastes time or produces misconfigured connections. This Skill provides structured guidance for every provisioning and management path so you get a working database with correct connection strings and auth flows. ## Core Features & Use Cases - Instant Provisioning: Create temporary databases with npx create-db (aliases create-pg, create-postgres), with flags for region, TTL, JSON output, and .env writing. - Programmatic Management: Use the Management API (https://api.prisma.io/v1) or the typed @prisma/management-api-sdk with service tokens or OAuth for backend automation and multi-tenant onboarding. - Project Linking & Connections: Link existing databases with prisma postgres link, retrieve direct TCP connection strings, and choose the right driver adapter (@prisma/adapter-pg vs @prisma/adapter-ppg). - Use Case: You are building a SaaS app that provisions a database per customer. Use the Management API SDK with OAuth token refresh to create workspaces, projects, and databases programmatically, then store the one-time connection secrets securely. ## Quick Start Ask the AI to provision a new Prisma Postgres database in the eu-central-1 region and write the connection string to your .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 env file writing.

How to provision Prisma Postgres databases programmatically in TypeScript?▼

Install @prisma/management-api-sdk and use createManagementApiClient with an existing service token, or createManagementApiSdk for OAuth with token refresh. Alternatively, the create-db npm package exposes create() and regions() functions for direct library usage.

What is the difference between service tokens and OAuth for the Prisma Management API?▼

Service tokens are best for server-to-server operations within your own workspace and are sent as Bearer auth. OAuth 2.0 is best for acting on behalf of users across workspaces, using the authorize and token endpoints at auth.prisma.io.

Does Prisma Postgres support direct TCP connections?▼

Yes, Prisma Postgres supports direct TCP connections on db.prisma.io:5432 with sslmode=require. Connection responses expose endpoints.direct and endpoints.pooled fields; secrets are shown only once at creation, so store them immediately.

How long do create-db temporary databases last?▼

Databases created with create-db are temporary by default and auto-delete after roughly 24 hours unless claimed. You can set a shorter TTL with the --ttl flag (e.g., 30m or 2h), or claim the database via the claim URL to keep it permanently.

When should I use prisma postgres link instead of create-db?▼

Use prisma postgres link when the database already exists and you want to wire a local project to it, since it updates your .env with DATABASE_URL. Use create-db when you need a brand-new database immediately for development, demos, or CI previews.