Secure Neon access for AI agents
Serverless Postgres projects, branches, SQL, schema migrations, and query tuning via Neon's official MCP server.
Connect Neon to the gateway to give agents governed access to your Neon account – projects, branches, databases, SQL execution, schema migrations, query tuning, and the Neon docs.
Server URL: https://mcp.neon.tech/mcp
Credential modes
Neon supports per-org dynamic registration only, so there is no app to create on Neon's side and no client ID or secret to enter. See Credential modes for how it compares with Use SecureAuth's app and Bring your own app.
Before you begin
- A Neon account that can reach the projects and branches your agents need.
- Administrator access to your Agent Authority workspace, to add the resource.
Setup
- In the Agent Authority console, go to Resources and click Add Resource.
- Select Neon from the catalog.
- On Choose how to install Neon, click Per-org dynamic registration. Selecting it adds the resource right away with its tools pre-configured.
Dynamic client registration
When you add the resource, the gateway registers its own OAuth client with Neon – the credential that lets it sign users in. Neon's own organization and project permissions still apply, so an agent can only reach what the person who signed in could already reach.
Verify the connection
The gateway syncs the Neon tools automatically. To check the connection end to end, ask your agent to run a request:
List my Neon projectsIf your projects come back, the connection is working.
How users connect
Access is per user. Each additional user connects their own Neon account the first time their agent calls a Neon tool: the gateway returns a sign-in link, the user authorizes once, and the tools work from then on. Go to Connections to manage linked accounts.
Available tools
Destructive tools are enabled by default
Neon's MCP server runs in write mode and exposes destructive tools
(delete_project, delete_branch, run_sql). Scope them down with a policy
before giving agents broad access.
| Tool | Access | Description |
|---|---|---|
list_projects | read | List Neon projects in the account |
list_organizations | read | List organizations the user belongs to |
list_shared_projects | read | List projects shared with the user |
describe_project | read | Get a project's branches, databases, and metadata |
create_project | write | Create a new Neon project |
delete_project | delete | Delete a project and all its data |
create_branch | write | Create a branch in a project |
describe_branch | read | Get objects and metadata for a branch |
delete_branch | delete | Delete a branch |
reset_from_parent | write | Reset a branch to its parent's state |
list_branch_computes | read | List compute endpoints for a branch |
run_sql | write | Execute a single SQL statement |
run_sql_transaction | write | Execute multiple SQL statements in a transaction |
explain_sql_statement | read | EXPLAIN/ANALYZE a query plan |
describe_table_schema | read | Describe a table's schema |
get_database_tables | read | List tables in a database |
get_connection_string | read | Get a Postgres connection string (includes credentials) |
compare_database_schema | read | Diff a branch's schema against its parent |
prepare_database_migration | write | Apply a schema migration in a temporary branch |
complete_database_migration | write | Apply a prepared migration to the main branch |
prepare_query_tuning | write | Analyze and tune a query in a temporary branch |
complete_query_tuning | write | Apply or discard tuning changes on the main branch |
list_slow_queries | read | List slow queries (requires pg_stat_statements) |
provision_neon_auth | write | Provision Neon Auth for a project |
configure_neon_auth | write | Configure Neon Auth settings |
get_neon_auth_config | read | Get the current Neon Auth configuration |
provision_neon_data_api | write | Provision the Neon Data API for a branch |
search | read | Search the Neon documentation |
fetch | read | Fetch a Neon docs search result by ID |
list_docs_resources | read | List available Neon docs resources |
get_doc_resource | read | Get Neon docs resources by path |
Required scopes
The gateway does not request a fixed scope list for Neon. It registers the client without naming any scopes and records the ones Neon returns.
Policy examples
Read-only Neon access for all agents:
Allow - MCP: neon - Tools: list_*, describe_*, get_*, explain_sql_statement, compare_database_schema, search, fetch - Effect: AllowBlock destructive operations while allowing everything else (higher-priority deny):
Deny - MCP: neon - Tools: delete_*, run_sql, run_sql_transaction - Effect: DenyNext steps
- Create a policy – start from the read-only pattern in Policy examples above.
- Connections – manage the Neon accounts your users have linked.