How to integrate Neon MCP with Codex

Trusted by
AWS
Glean
Zoom
Airtable

30 min · no commitment · see it on your stack

Neon logo
Codex logo
divider

Introduction

Codex is one of the most popular coding harnesses out there. And MCP makes the experience even better. With Neon MCP integration, you can draft, triage, summarise emails, and much more, all without leaving the terminal or the app, whichever you prefer.

Also integrate Neon with

Why use Composio?

Apart from a managed and hosted MCP server, you will get:

  • CodeAct: A dedicated workbench that allows GPT to write its code to handle complex tool chaining. Reduces to-and-fro with LLMs for frequent tool calling.
  • Large tool responses: Handle them to minimise context rot.
  • Dynamic just-in-time access to 20,000 tools across 1000+ other Apps for cross-app workflows. It loads the tools you need, so GPTs aren't overwhelmed by tools you don't need.

How to install Neon MCP in Codex

Run the setup command

Run this command in your terminal to add the Composio MCP server to Codex.

Terminal

It will initiate the authentication in a browser window, authorize Codex to access your Composio account.

Composio authentication page

(Optional) Authenticate with OAuth

To authenticate manually, run the login command to open a browser window and authorize Codex to access your Composio account.

bash
codex mcp login composio

Verify the connection

Run codex mcp list to confirm Composio appears as a registered MCP server.

bash
codex mcp list

Codex App

Codex App follows the same approach as VS Code.

  1. Click ⚙️ on the bottom left → MCP Servers → + Add servers → Streamable HTTP:
  2. Fill the header and Key fields with { "x-consumer-api-key" = "ck_*******" }.
  3. The Key is the Composio API key, that you can find on dashboard.composio.dev
  4. Click on Authenticate and authorize Codex to your Composio account and you're all set.
Codex App MCP setup
  1. Restart and verify if it's there in .codex/config.toml
bash
[mcp_servers.composio]
url = "https://connect.composio.dev/mcp"
http_headers = { "x-consumer-api-key" = "ck_*******" }

What is the Neon MCP server, and what's possible with it?

The Neon MCP server is an implementation of the Model Context Protocol that connects your AI agent and assistants like Claude, Cursor, etc directly to your Neon account. It provides structured and secure access to your serverless Postgres databases and project infrastructure, so your agent can perform actions like managing projects, configuring authentication, creating branches, and automating database operations on your behalf.

  • Project management and insights: Retrieve detailed information about specific Neon projects, including configurations, workflows, and current status for monitoring or troubleshooting.
  • Automated role and permission setup: Grant email-based permissions, add new roles to branches, and streamline access control across your projects with granular, automated adjustments.
  • Seamless API key and authentication management: Create new API keys for organizations or projects, manage authentication flows, and securely handle access credentials for integrations.
  • Database and branch orchestration: Spin up new Postgres databases within branches, create and configure compute endpoints, and automate the creation of development, testing, or isolated environments as needed.
  • Custom project provisioning: Launch new Neon projects with advanced quota, resource, and networking settings—tailored to your application's requirements and operational best practices.

Supported Tools & Triggers

Tools
Accept project transfer requestTool to accept a transfer request for a Neon project.
Access project details by idRetrieves detailed information about a specific Neon serverless Postgres project.
Add new jwks to project endpointAdds a new JSON Web Key Set (JWKS) URL to a Neon project for JWT-based authentication.
Add project email permissionAdds permissions for a specified email address to a particular project within the Neon B2B SaaS integration platform.
Add role to branchCreates a new PostgreSQL role within a specific branch of a Neon project.
Count project branchesTool to get the total number of branches in a Neon project.
Create API Key for OrganizationCreates a new API key for the specified organization in Neon.
Create Auth Provider SDK KeysTool to generate SDK or API keys for authentication providers.
Create auth userTool to create a new user in Neon Auth for a specific project branch.
Create branch databaseCreates a new database within a specified project and branch in the Neon platform.
Enable Neon Auth for branchTool to enable Neon Auth integration for a branch.
Create Neon Data APICreates a new instance of Neon Data API in the specified branch.
Create branch snapshotCreates a snapshot from the specified branch at a specific point in time.
Create compute endpointCreates a new compute endpoint for a specified branch within a Neon project.
Create New API KeyCreates a new personal API key for the authenticated Neon user account.
Create new project branchCreates a new branch in a Neon project.
Create anonymized branchCreates a new branch with anonymized data using PostgreSQL Anonymizer for static masking.
Create project transfer requestTool to create a transfer request for a Neon project.
Create project with quota and settingsCreates a new Neon project with specified configuration settings.
Set VPC endpoint restrictionSets or updates a VPC endpoint restriction for a Neon project.
Assign or Update VPC EndpointAssigns an AWS VPC endpoint to a Neon organization for Private Networking, or updates the label of an existing VPC endpoint assignment.
Delete api key by idDeletes a specific API key from the Neon platform.
Delete auth domainsDeletes domains from the redirect_uri whitelist for a specific branch's authentication configuration.
Delete OAuth providerDeletes an OAuth provider configuration from a specific branch in a Neon project.
Delete auth userDeletes an authentication user from a specified branch within a Neon project.
Delete branch data APIDeletes the Neon Data API for a specified branch and database.
Delete database from branchDeletes a specific database from a designated branch within a project in the Neon platform.
Delete organization api keyDeletes a specific API key associated with an organization in the Neon platform.
Delete organization memberRemoves a specific member from a Neon organization.
Delete project branch by idDeletes a specific branch within a project in the Neon B2B SaaS integration platform.
Delete project branch roleDeletes a PostgreSQL role from a specific branch within a Neon project.
Delete project by idPermanently deletes a Neon PostgreSQL project and all its associated resources.
Delete project endpointDeletes a specific endpoint within a Neon project.
Delete project jwks by idDeletes a specific JSON Web Key Set (JWKS) associated with a given project in the Neon B2B SaaS integration platform.
Delete project permissionDeletes a specific permission associated with a project in the Neon B2B SaaS integration platform.
Delete project snapshotDeletes a specific snapshot for a project in Neon.
Delete vpc endpoint by idsPermanently deletes a VPC endpoint from a Neon organization in a specified AWS region.
Delete vpc endpoint by project idDeletes a specific VPC endpoint within a designated project in the Neon platform.
Disable branches authTool to disable Neon Auth for a specific branch in a Neon project.
Fetch database for branchRetrieves a list of databases associated with a specific project and branch in the Neon platform.
Fetch organization members by idRetrieves a list of all members associated with a specific organization in the Neon B2B SaaS integration platform.
Fetch vpcendpoint details by idRetrieves the current state and configuration details of a specific VPC endpoint assigned to a Neon organization.
Finalize branch restoreFinalizes the restore operation for a branch created from a snapshot.
Get authRetrieves authentication information about the current API request credentials.
Get auth allow localhostRetrieves the allow localhost configuration for a specific branch in a Neon project.
Get auth email providerRetrieves the email provider configuration for Neon Auth on a specific branch.
Get available preload librariesRetrieves the list of available shared preload libraries for a Neon project.
Get branches anonymized statusRetrieves the current status of an anonymized branch, including its state and progress information.
Get branches backup scheduleRetrieves the backup schedule configuration for a specified branch within a Neon project.
Get Neon Data API for branchRetrieves the Neon Data API information for a specific branch and database.
Get branches for projectRetrieves a list of branches associated with a specific project in the Neon B2B SaaS integration platform.
Get branches masking rulesRetrieves the masking rules for the specified anonymized branch.
Get branch roles for projectRetrieves the roles associated with a specific branch within a project in the Neon B2B SaaS integration platform.
Get consumption history projectsRetrieves consumption history for projects within a Neon organization.
Get current user informationRetrieves the profile information for the currently authenticated user.
Get organization api keysRetrieves a list of all API keys associated with a specific organization in the Neon B2B SaaS integration platform.
Get project branchesRetrieves detailed information about a specific branch within a Neon project.
Get project branch roleRetrieves detailed information about a specific role within a particular branch of a Neon project.
Get project branch schema comparisonCompares the database schema of a branch with another branch's schema in a Neon project.
Get project connection uriRetrieves the connection URI for a specified project within the Neon B2B SaaS integration platform.
Get project endpoint informationRetrieves a list of all compute endpoints associated with a specific Neon project.
Get project operation by idRetrieves detailed information about a specific operation within a Neon serverless PostgreSQL project.
Get schema for project branchRetrieves the PostgreSQL database schema (DDL) for a specific database on a branch within a Neon project.
Get user organizationsRetrieves a list of organizations associated with the currently authenticated user in the Neon platform.
Get vpc region endpointsRetrieves a list of VPC endpoints for a specified organization within a particular AWS region.
List api keysRetrieves a list of API keys associated with the authenticated user's Neon account.
List auth domainsLists the domains in the redirect_uri whitelist for the specified project and branch.
List Auth OAuth ProvidersRetrieves the OAuth providers configured for Neon Auth on a specific branch.
List project snapshotsTool to list all snapshots for a specified Neon project.
List shared projectsRetrieves a list of Neon Postgres projects shared with your account.
List VPC endpoints for organizationTool to retrieve the list of VPC endpoints for a specified Neon organization across all regions.
Modify branch details in projectUpdates the details of a specific branch within a project in the Neon platform.
Patch branch database informationUpdates the properties of a specific database within a project branch in the Neon platform.
Reset role password for branchResets the password for a PostgreSQL role on a specific Neon branch and generates a new password.
Restart project endpointRestarts a Neon compute endpoint (Postgres instance) within a project.
Restore project branchThis endpoint restores a branch to a specific state or point in time.
Restore snapshot to new branchTool to restore a Neon snapshot to a new branch.
Retrieve account consumption historyRetrieves the consumption history for a specified account within the Neon platform.
Retrieve all regionsRetrieves a list of available geographic regions supported by the Neon B2B SaaS integration platform.
Retrieve branch database detailsRetrieves detailed information about a specific database within a Neon project and branch.
Retrieve branch endpointsRetrieves all compute endpoints associated with a specific branch in a Neon project.
Retrieve jwks for projectRetrieves the JSON Web Key Set (JWKS) for a specified project.
Retrieve organization by idRetrieves detailed information about a specific organization within the Neon platform.
Retrieve organization invitationsRetrieves a list of all pending invitations for a specified organization.
Retrieve organization member infoRetrieves detailed information about a specific member within an organization in the Neon B2B SaaS integration platform.
Retrieve project endpoint detailsRetrieves detailed information about a specific compute endpoint within a Neon serverless PostgreSQL project.
Retrieve project operationsRetrieves a list of operations associated with a specific project in the Neon B2B SaaS integration platform.
Retrieve project permissionsRetrieves the current permissions settings for a specific project within the Neon B2B SaaS integration platform.
Retrieve projects listRetrieves a list of all Neon projects associated with the authenticated user's account.
Retrieve vpc endpoints for projectRetrieves a list of VPC (Virtual Private Cloud) endpoints associated with a specific project in the Neon B2B SaaS integration platform.
Reveal role password in branchReveals the password for a specific role within a branch of a Neon project.
Send auth test emailTool to send a test email using specified SMTP configuration for Neon Auth.
Send organization invitationsCreates and sends invitations to join an organization in the Neon B2B SaaS integration platform.
Set branch as defaultSets a specified branch as the default branch for a given project in Neon.
Start branch anonymizationStarts the anonymization process for an anonymized branch that is in the initialized, error, or anonymized state.
Start endpoint for projectStarts a suspended or idle compute endpoint for a Neon PostgreSQL project.
Suspend project endpoint by idSuspends a specific endpoint within a project in the Neon B2B SaaS integration platform.
Transfer projects between organizationsTransfers selected projects from one organization to another organization.
Transfer user projects to organizationTransfers multiple projects from the authenticated user's personal account to a specified organization within the Neon B2B SaaS integration platform.
Update auth allow localhostUpdates the allow localhost configuration for a specific branch in a Neon project.
Update branch auth email providerUpdates the email provider configuration for a specific branch's authentication system.
Update branches data APIUpdates the Neon Data API configuration for the specified branch.
Update branches masking rulesUpdates the masking rules for the specified anonymized branch.
Update organization member roleUpdates the role of a specific member within an organization in the Neon B2B SaaS integration platform.
Update project compute endpoint settingsUpdates the configuration of a specific compute endpoint within a Neon project.
Update project settings by idUpdates the configuration and settings of a specific Neon project.
Update project snapshotTool to update the name of a specific snapshot in a Neon project.

Conclusion

You've successfully integrated Neon with Codex using Composio's MCP server. Now you can interact with Neon directly from your terminal, VS Code, or the Codex App using natural language commands.

Key benefits of this setup:

  • Seamless integration across CLI, VS Code, and standalone app
  • Natural language commands for Neon operations
  • Managed authentication through Composio
  • Access to 20,000+ tools across 1000+ apps for cross-app workflows
  • CodeAct workbench for complex tool chaining

Next steps:

  • Try asking Codex to perform various Neon operations
  • Explore cross-app workflows by connecting more toolkits
  • Build automation scripts that leverage Codex's AI capabilities

How to build Neon MCP Agent with another framework

FAQ

What are the differences in Tool Router MCP and Neon MCP?

With a standalone Neon MCP server, the agents and LLMs can only access a fixed set of Neon tools tied to that server. However, with the Composio Tool Router, agents can dynamically load tools from Neon and many other apps based on the task at hand, all through a single MCP endpoint.

Can I use Tool Router MCP with Codex?

Yes, you can. Codex fully supports MCP integration. You get structured tool calling, message history handling, and model orchestration while Tool Router takes care of discovering and serving the right Neon tools.

Can I manage the permissions and scopes for Neon while using Tool Router?

Yes, absolutely. You can configure which Neon scopes and actions are allowed when connecting your account to Composio. You can also bring your own OAuth credentials or API configuration so you keep full control over what the agent can do.

How safe is my data with Composio Tool Router?

All sensitive data such as tokens, keys, and configuration is fully encrypted at rest and in transit. Composio is SOC 2 Type 2 compliant and follows strict security practices so your Neon data and credentials are handled as safely as possible.

Used by agents from

Context
Letta
glean
HubSpot
Agent.ai
Altera
DataStax
Entelligence
Rolai
Context
Letta
glean
HubSpot
Agent.ai
Altera
DataStax
Entelligence
Rolai
Context
Letta
glean
HubSpot
Agent.ai
Altera
DataStax
Entelligence
Rolai

Never worry about agent reliability

We handle tool reliability, observability, and security so you never have to second-guess an agent action.