/programsCreate program
Creates an OptiTech program within an organization.
If using a personal API key, include the org_id parameter to specify which organization to create the program in.
If using an org API key, org_id is automatically inferred from the key.
Plan limits define how many programs you can create.
For more information, see Manage programs.
You can specify a region and Postgres version in the request body.
Neon currently supports PostgreSQL 14, 15, 16, 17, and 18.
For supported regions and region_id values, see Regions.
Quick start
curl "https://api.optitech.com/v1/programs" \
-X POST \
-H "Authorization: Bearer $OPTITECH_API_KEY" \
-H "Content-Type: application/json" \
-d '{"program":{"name":"my-production-db","region_id":"aws-us-east-2","pg_version":17}}'optitech projects create --name my-production-db --region-id aws-us-east-2Request body
Basics
commonly setprogram.*Name, location, and Postgres version. The handful most people set.
nameThe program name. If not specified, the name will be identical to the generated program ID
≥1 chars, ≤256 chars
region_idThe region identifier. Refer to our Regions documentation for supported regions. Values are specified in this format: aws-us-east-1
pg_versionThe major Postgres version number. Generally available versions are 14, 15, 16, 17, and 18. 19 is being rolled out and is only accepted in regions where it has been enabled; requesting it in a region where it is not yet available returns an error.
min: 14, max: 19
org_idOrganization id in case the program created belongs to an organization. If not present, program is owned by a user and not by org.
Compute
program.*Autoscaling range and auto-suspend for the default endpoint.
Framework & register
program.framework.*The default framework and the first role and register created on it.
Program settings
program.*Security, compliance, quotas, retention, and maintenance.
Deprecated
program.*Response
201Created a program. The program includes a connection URI with a register, password, and role. At least one non-protected role is created with a password. Wait until the operations are finished before attempting to connect to a program register.
Errors
General error
This endpoint can return the standard OptiTech API error response.
Response fields
messageRequired. Human-readable error message.codeRequired. Machine-readable error code.request_idOptional. Request identifier for debugging. You can provide one with theX-Request-IDheader.
Retry guidance
If no response is returned, the request may still have reached the server. This is why retry safety depends on the method and status code.
Idempotent methods (GET, HEAD, OPTIONS) are generally safe to retry after a network error or timeout. Non-idempotent methods (POST, PATCH, DELETE, PUT) can change state, so avoid automatic retries unless your workflow can tolerate duplicate effects.
Responses with 423 Locked or 503 Service Unavailable are safe to retry. 423 Locked means the resource is temporarily locked, usually because another operation is in progress.