Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.gumloop.com/llms.txt

Use this file to discover all available pages before exploring further.

PostgreSQL is a powerful open-source relational database. The PostgreSQL MCP server lets you explore schemas, execute SQL queries, and analyze query plans using natural language.

What Can It Do?

  • Explore database schemas and table structures
  • Execute SQL queries and view results
  • Analyze query performance with execution plans
  • Browse tables, views, and sequences across schemas

Where to Use It

Add PostgreSQL as a tool to any agent. The agent can then interact with PostgreSQL conversationally, choosing the right actions based on context. To add an MCP tool to your agent:
  1. Open your agent’s configuration
  2. Click Add toolsConnect an app with MCP
  3. Search for the integration and select it
  4. Authenticate with your account
You can control which tools your agent has access to. After adding an integration, click on it to enable or disable specific tools based on what your agent needs.

In Workflows (Via Agent Node)

For automated pipelines, use an Agent Node with PostgreSQL tools. This gives you the flexibility of an agent within a deterministic workflow.

As a Custom MCP Node

You can also create a standalone MCP node for a specific action. This generates a reusable node that performs one task, useful when you need the same operation repeatedly in workflows.
To create a custom MCP node:
  1. Go to your node library and search for the integration
  2. Click Create a node with AI
  3. Describe the specific action you want (e.g., “List all tables in the database”)
  4. Test the node and save it for reuse
Custom MCP nodes are single-purpose by design. For tasks that require multiple steps or dynamic decision-making, use an agent instead.

Available Tools

ToolDescription
List SchemasList all schemas with their owners
List ObjectsList tables, views, sequences, or extensions in a schema
Get Object DetailsGet detailed information about a table, view, sequence, or extension
Execute SqlExecute any SQL query and return results
Explain QueryShow query execution plan with costs and strategy

Example Prompts

Use these with your agent or in the Agent Node: Explore schema:
List all tables in the public schema
Run a query:
Show me the top 10 customers by order count
Analyze performance:
Explain the query plan for selecting from the orders table

Troubleshooting

IssueSolution
Authentication failedVerify your PostgreSQL credentials and that you have the required permissions
Tool not availableVerify the tool is enabled in your agent’s MCP configuration
Unexpected resultsThe agent may chain multiple tools together. Review the agent’s reasoning to understand its approach.
Agents are smart enough to chain multiple API calls together. If results seem off, check the agent’s step-by-step reasoning.

Need Help?


Use this integration directly in Claude or Cursor. Connect remotely via the PostgreSQL MCP server using your Gumloop credentials.