curl --request POST \ --url 'https://api.e2enetworks.com/myaccount/api/v1/gpu/dbaas/?project_id=<PROJECT_ID>&location=<LOCATION>&apikey=<API_KEY>' \ --header 'Authorization: Bearer <API_TOKEN>' \ --header 'Content-Type: application/json' \ --data '{ "name": "orders-db", "engine": "postgresql", "engine_version": "16", "sku_item_price_id": 2301, "disk_size": 100, "admin_username": "appadmin", "admin_password": "<password>", "pgvector_enabled": true, "extensions": [ "pg_trgm" ], "ip_allowlist": [ { "cidr": "203.0.113.0/24", "label": "office VPN" }, "198.51.100.7" ], "vpc_id": 17, "deletion_protection": false}'import requests
response = requests.post( "https://api.e2enetworks.com/myaccount/api/v1/gpu/dbaas/", params={"project_id": "<PROJECT_ID>", "location": "<LOCATION>", "apikey": "<API_KEY>"}, headers={"Authorization": "Bearer <API_TOKEN>"}, json={ "name": "orders-db", "engine": "postgresql", "engine_version": "16", "sku_item_price_id": 2301, "disk_size": 100, "admin_username": "appadmin", "admin_password": "<password>", "pgvector_enabled": True, "extensions": [ "pg_trgm", ], "ip_allowlist": [ { "cidr": "203.0.113.0/24", "label": "office VPN", }, "198.51.100.7", ], "vpc_id": 17, "deletion_protection": False, },)print(response.json())const url = new URL("https://api.e2enetworks.com/myaccount/api/v1/gpu/dbaas/");url.search = new URLSearchParams({ project_id: "<PROJECT_ID>", location: "<LOCATION>", apikey: "<API_KEY>" });
const response = await fetch(url, { method: "POST", headers: { "Authorization": "Bearer <API_TOKEN>", "Content-Type": "application/json" }, body: JSON.stringify({ "name": "orders-db", "engine": "postgresql", "engine_version": "16", "sku_item_price_id": 2301, "disk_size": 100, "admin_username": "appadmin", "admin_password": "<password>", "pgvector_enabled": true, "extensions": [ "pg_trgm" ], "ip_allowlist": [ { "cidr": "203.0.113.0/24", "label": "office VPN" }, "198.51.100.7" ], "vpc_id": 17, "deletion_protection": false }),});console.log(await response.json());Creates a PostgreSQL database with one node and starts setting it up. The call returns at once with the database in Creating; poll Get Database Provisioning or Get Database until status is Running. The admin login is created with the username and password you send; no call returns the password later. The pg_stat_statements extension is always installed. Needs the Create permission on DBaaS.
Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”Project ID
Active IAM ID (To access contact person account) Find your Active IAM ID here
Location
Request Bodyrequired
Section titled “Request Bodyrequired”object
Name of the database, up to 50 characters: lowercase letters, digits and hyphens, starting and ending with a letter or digit. Unique in the project.
Example
orders-dbExample
postgresqlA version that List Database Versions returns.
Example
16The plan: a sku_item_price_id from SKU List with service=dbaas. It sets the vCPUs and memory.
Example
2301Disk size in GB, 20 to 2,000.
Example
100The admin login: starts with a lowercase letter, then lowercase letters, digits and underscores, up to 63 characters. Names the platform reserves and names starting with pg_ are refused. No call changes it later.
Example
appadmin12 to 64 characters with at least one uppercase letter, one lowercase letter, one digit and one symbol.
Example
<password>Install the vector extension. Default true.
Example
trueMore extensions to install, from List Database Extensions.
Example
[ "pg_trgm"]IPv4 ranges allowed to reach the public endpoint. Each entry is an IPv4 address or CIDR range, as a string or as an object with cidr and an optional label. A bare address becomes a /32 range, host bits are cleared (10.0.0.5/24 becomes 10.0.0.0/24), and a repeated range is kept once. Up to 50 entries. 0.0.0.0/0 allows any address. Without an allowlist the database gets no public endpoint and is reached only through its VPC.
object
Example
203.0.113.0/24Optional description, up to 63 characters.
Example
office VPNExample
[ { "cidr": "203.0.113.0/24", "label": "office VPN" }, "198.51.100.7"]A VPC in the project, in Active state.
Example
17Refuse every delete of this database. The API has no call that turns it off later. Default false.
Example
falseResponses
Section titled “Responses”Creation started; the database is Creating
object
object
Creating while the database is being set up, started or restarted, Running, Scaling while the disk grows, Degraded when the database is serving but its health could not be fully confirmed (Stop and Restart are also accepted from it), Stopped, Failed when the launch did not finish or a storage resize did not complete, and Terminating while it is deleted.
VCPUs, set by the plan.
Memory, set by the plan.
Disk size in GB.
Public read-write address and port. null until the database first reaches Running, and while it has no IP allowlist.
true when the database cannot be deleted.
The attached parameter group.
object
The plan: its specification under specs and its pricing under plan. null when the plan is gone.
object
IPv4 ranges allowed to reach the public endpoint.
object
Description of the range; empty when none was given.
The VPC attachment. null when no VPC is attached.
object
The database’s address in the VPC.
The database’s VPC address; null without a VPC.
true when the vector extension was chosen at creation.
Extensions set at creation.
object
Example
{ "code": 201, "message": "Created Successfully", "data": { "id": 123, "name": "orders-db", "engine": "postgresql", "engine_version": "16", "status": "Creating", "cpu": "4", "memory": "16Gi", "disk_size": 100, "endpoint_url": "<host>:5432", "public_ip": "203.0.113.25", "private_ip": "10.0.4.17", "deletion_protection": false, "parameter_group_id": null, "created_by": { "id": 501, "name": "Example User", "email": "user@example.com", "username": "user@example.com" }, "created_at": "2026-10-21T11:17:29Z", "updated_at": "2026-10-21T11:31:05Z", "ip_allowlist": [ { "cidr": "203.0.113.0/24", "label": "office VPN" } ], "location": "Chennai", "vpc_id": null, "vpc": { "id": 41, "vpc_name": "app-vpc", "subnet_name": "app-subnet", "resource_type": "Database", "resource_name": "orders-db", "object_id": 123, "ip_address": "10.10.0.12", "status": "Attached", "attached_at": "2026-10-21T11:20:02Z", "created_at": "2026-10-21T11:17:29Z" }, "vpc_private_ip": null, "pgvector_enabled": true, "extensions": [ "pg_stat_statements", "vector" ] }, "errors": {}}A field is not valid; errors is keyed by field. The messages include “Database name should contain lowercase letters, digits, and hyphens only.”, “A database with the same name already exists in the Project.”, “Database Name can contain a maximum of 50 characters”, “‘postgresql errors “Project ID is missing or invalid”.
object
object
Keyed by field.
object
Example
{ "code": 400, "message": "Bad Request", "data": {}, "errors": { "name": [ "A database with the same name already exists in the Project." ] }}The caller lacks the permission the call needs on the project, or the region is not allowed.
object
object
Example
{ "code": 403, "message": "Forbidden", "data": {}, "errors": "You don't have permission to access this service. Please verify your policy or project."}The plan is missing or is not an active database plan in the account’s currency (“SKU_ITEM_PRICE is either invalid or not provided”); there is not enough capacity (“Inventory temporarily unavailable. Please try again after some time.”) or credit (“Insufficient Credits! …”); or the launch could not start (“Managed Database creation failed”). Nothing is created.
object
object
Example
{ "code": 412, "message": "Precondition Failed", "data": {}, "errors": "Inventory temporarily unavailable. Please try again after some time."}