/projects/{project_id}/connection_uriRetrieve connection URIRetrieves a connection URI for the specified database. The URI uses the standard PostgreSQL connection string format. Set pooled=true to include the -pooler suffix for a connection pooler URI.
Parameters
project_idstringpathrequiredThe Neon project ID
branch_idstringqueryThe branch ID. Defaults to your project's default `branch_id` if not specified.
endpoint_idstringqueryThe endpoint ID. Defaults to the read-write `endpoint_id` associated with the `branch_id` if not specified.
database_namestringqueryrequiredThe database name
role_namestringqueryrequiredThe role name
pooledbooleanqueryAdds the `-pooler` option to the connection URI when set to `true`, creating a pooled connection URI.
Responses
uristringrequiredThe connection URI.
{
"uri": "string"
}codestringrequiredmessagestringrequiredError message
request_idstringUnique identifier for the request, useful for debugging. You can set this value manually by including an `X-Request-ID` header in the request. If not provided, the value will be generated automatically.
{
"code": "",
"message": "string",
"request_id": "string"
}