Natural Language Postgres CLI
Query PostgreSQL databases using natural language from the command line.Commands
Query Database
Show Schema
Interactive Mode
Options
| Option | Type | Default | Description |
|---|---|---|---|
--connection-url | string | env | Database URL |
--read-only | boolean | true | Read-only mode |
--max-rows | number | 100 | Max rows returned |
--allowed-tables | string | - | Comma-separated whitelist |
--blocked-tables | string | - | Comma-separated blacklist |
--json | boolean | false | JSON output |
--show-sql | boolean | false | Show generated SQL |
Examples
Basic Queries
Restricted Access
Environment Variables
| Variable | Required | Description |
|---|---|---|
DATABASE_URL | Yes | PostgreSQL connection URL |
OPENAI_API_KEY | Yes | For NL to SQL |
Related Commands
praisonai-ts postgres test- Test connectionpraisonai-ts postgres export- Export query results

