PATCH/projects/{project_id}

Update a project

Updates configurable properties of a Neon project, including its name, project settings, default endpoint settings, and history retention period. Supply the required project object and include only the properties you want to change. The response includes the updated project and any operations associated with the update.

  • IdempotentThe SDK sends Idempotency-Key, so a retried request is only applied once.

1 parameter · 1 body field
project_idstringrequired
The Neon project ID. Must contain 1 to 60 lowercase letters, digits, or hyphens.

Project update payload containing the required project object.

projectobjectrequired
Project properties to update.

2 status codes
200Returns the updated project and an array of operations associated with the update.
projectobjectrequired
Full details of the project, including configuration, consumption metrics, and ownership.
operationsarray<object>required
defaultReturned when the request fails. The error response includes a machine-readable `code`, a human-readable `message`, and may include a `request_id` for debugging.
request_idstringoptional
Unique 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.
codestringrequired
Machine-readable code classifying the error type. See `message` for a human-readable explanation.
Default:
messagestringrequired
Error message

Error handling

The project_id path parameter must match the pattern ^[a-z0-9-]{1,60}$. The request body must include project; if provided, name must be 1 to 256 characters and history_retention_seconds must be between 0 and 2592000. The history retention maximum depends on the plan: 21600 seconds for Free, 604800 for Launch, and 2592000 for Scale.