{"_id":"@bossforce.ai/mcp-postgres","name":"@bossforce.ai/mcp-postgres","dist-tags":{"latest":"0.1.0"},"versions":{"0.1.0":{"name":"@bossforce.ai/mcp-postgres","version":"0.1.0","type":"module","repository":{"type":"git","url":"git+https://github.com/bossforce-ai/bossforce-tools.git","directory":"mcps/databases-data/postgres"},"publishConfig":{"access":"public"},"bin":{"bossforce-mcp-postgres":"dist/bin.js"},"dependencies":{"pg":"^8.13.1","zod":"^4.4.3","@bossforce.ai/mcp-core":"0.3.0"},"devDependencies":{"@types/pg":"^8.11.10","@bossforce.ai/mcp-testkit":"0.0.0"},"scripts":{"build":"tsc -p tsconfig.json","test":"node --test \"dist/*.test.js\""},"_id":"@bossforce.ai/mcp-postgres@0.1.0","description":"MCP server for **PostgreSQL**, built on the [`pg`](https://node-postgres.com/) driver. Read-only by default — a good fit for reporting and data lookups.","bugs":{"url":"https://github.com/bossforce-ai/bossforce-tools/issues"},"homepage":"https://github.com/bossforce-ai/bossforce-tools#readme","_integrity":"sha512-dzjBpnPhUI7s1ENZvGQVaoZGlUiBhpIVkJlBrJHkka0tTTs/p5rI+47lJrIdxBL2hWDPLzG9q9mA+X8X6Mq84w==","_resolved":"C:\\Users\\user\\AppData\\Local\\Temp\\1c0510126ea957671a3e0bf20dfb9780\\bossforce.ai-mcp-postgres-0.1.0.tgz","_from":"file:bossforce.ai-mcp-postgres-0.1.0.tgz","_nodeVersion":"22.18.0","_npmVersion":"10.9.3","dist":{"integrity":"sha512-dzjBpnPhUI7s1ENZvGQVaoZGlUiBhpIVkJlBrJHkka0tTTs/p5rI+47lJrIdxBL2hWDPLzG9q9mA+X8X6Mq84w==","shasum":"a95b1bef274e75f6ae132e4745437ddf3a47a219","tarball":"https://registry.npmjs.org/@bossforce.ai/mcp-postgres/-/mcp-postgres-0.1.0.tgz","fileCount":26,"unpackedSize":19953,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIFucZ8GlxAQ+QN1zGEXOTITQbJoMx3gsplVwJlCB3nduAiEA2hb7mY8mZ5b+hx4qaIzOg6iD1e59dn8G7J7725Hl9co="}]},"_npmUser":{"name":"bossforce.ai","email":"bossforce.ai@gmail.com"},"directories":{},"maintainers":[{"name":"bossforce.ai","email":"bossforce.ai@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/mcp-postgres_0.1.0_1781237937917_0.20013502760341528"},"_hasShrinkwrap":false}},"time":{"created":"2026-06-12T04:18:57.765Z","0.1.0":"2026-06-12T04:18:58.082Z","modified":"2026-06-12T04:18:58.271Z"},"maintainers":[{"name":"bossforce.ai","email":"bossforce.ai@gmail.com"}],"description":"MCP server for **PostgreSQL**, built on the [`pg`](https://node-postgres.com/) driver. Read-only by default — a good fit for reporting and data lookups.","homepage":"https://github.com/bossforce-ai/bossforce-tools#readme","repository":{"type":"git","url":"git+https://github.com/bossforce-ai/bossforce-tools.git","directory":"mcps/databases-data/postgres"},"bugs":{"url":"https://github.com/bossforce-ai/bossforce-tools/issues"},"readme":"# @bossforce.ai/mcp-postgres\n\nMCP server for **PostgreSQL**, built on the [`pg`](https://node-postgres.com/)\ndriver. Read-only by default — a good fit for reporting and data lookups.\n\n## Credentials\n\n| Env                          | How to obtain                                                               |\n| ---------------------------- | --------------------------------------------------------------------------- |\n| `POSTGRES_CONNECTION_STRING` | `postgres://user:password@host:port/database` for your database.            |\n| `POSTGRES_ALLOW_WRITES`      | Optional. Set to `true` to permit writes; omit for read-only (recommended). |\n\nThe connection string is read lazily, so the server boots and answers\n`tools/list` without it; calls fail with an `auth` error until it is set. For\ndefence in depth, point it at a **read-only database role** when writes aren't\nneeded.\n\n## Tools\n\n| Tool             | Arguments                  | Returns                       |\n| ---------------- | -------------------------- | ----------------------------- |\n| `query`          | `sql`, `params?`           | `{ rows, row_count, fields }` |\n| `list_tables`    | `schema?` (default public) | `{ tables: [...] }`           |\n| `describe_table` | `table`, `schema?`         | `{ columns: [...] }`          |\n\n### Safety\n\nBy default every statement runs inside a `BEGIN READ ONLY` transaction, so any\n`INSERT`/`UPDATE`/`DELETE`/DDL fails at the database (SQLSTATE `25006`). Set\n`POSTGRES_ALLOW_WRITES=true` to allow writes. Always pass user-supplied values\nthrough `params` (`$1`, `$2`, …) rather than concatenating them into the SQL.\n\n## Develop\n\n```bash\npnpm --filter @bossforce.ai/mcp-postgres build\npnpm --filter @bossforce.ai/mcp-postgres test\n```\n\nTests inject a fake query implementation, so they run without a real database.\nRegenerate the tools/list snapshot after an intentional signature change:\n\n```bash\nUPDATE_SNAPSHOTS=1 pnpm --filter @bossforce.ai/mcp-postgres test\n```\n","readmeFilename":"README.md","_rev":"1-de1268bdf2a901290b51bd520bc1d374"}