v1

latestOpenAPI 3.0.0Creative Commons Attribution 3.02026-07-1328122178.2 KB
projects

Creates a new Instance in a given project and location.

post/v1/{+parent}/instances

Path parameters

parentstring required

Required. The name of the parent resource. For the required format, see the comment on the Instance.name field.

Query parameters

instanceIdstring

Required. ID of the requesting object.

requestIdstring

Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server ignores the request if it has already been completed. The server guarantees that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if the original operation with the same request ID was received, and if so, ignores the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).

validateOnlyboolean

Optional. If set, performs request validation, for example, permission checks and any other type of validation, but does not actually execute the create request.

Request body

satisfiesPzsboolean

Output only. Reserved for future use.

state'STATE_UNSPECIFIED' | 'READY' | 'STOPPED' | 'CREATING' | 'DELETING' | 'MAINTENANCE' | 'FAILED' | 'BOOTSTRAPPING' | 'PROMOTING' | 'SWITCHOVER' | 'STOPPING' | 'STARTING'

Output only. The current serving state of the instance.

displayNamestring

User-settable and human-readable display name for the Instance.

uidstring

Output only. The system-generated UID of the resource. The UID is assigned when the resource is created, and it is retained until it is deleted.

outboundPublicIpAddressesstring[]

Output only. All outbound public IP addresses configured for the instance.

etagstring

For Resource freshness validation (https://google.aip.dev/154)

annotationsobject

Annotations to allow client tools to store small amount of arbitrary data. This is distinct from labels. https://google.aip.dev/128

gceZonestring

The Compute Engine zone that the instance should serve from, per https://cloud.google.com/compute/docs/regions-zones This can ONLY be specified for ZONAL instances. If present for a REGIONAL instance, an error will be thrown. If this is absent for a ZONAL instance, instance is created in a random zone with available capacity.

updateTimestring google-datetime

Output only. Update time stamp

dataApiAccess'DEFAULT_DATA_API_ENABLED_FOR_GOOGLE_CLOUD_SERVICES' | 'DISABLED' | 'ENABLED'

Optional. Controls whether the Data API is enabled for this instance. When enabled, this allows authorized users to connect to the instance from the public internet using the executeSql API, even for private IP instances. If this is not specified, the data API is enabled by default for Google internal services like AlloyDB Studio. Disable it explicitly to disallow Google internal services as well.

activationPolicy'ACTIVATION_POLICY_UNSPECIFIED' | 'ALWAYS' | 'NEVER'

Optional. Specifies whether an instance needs to spin up. Once the instance is active, the activation policy can be updated to the NEVER to stop the instance. Likewise, the activation policy can be updated to ALWAYS to start the instance. There are restrictions around when an instance can/cannot be activated (for example, a read pool instance should be stopped before stopping primary etc.). Please refer to the API documentation for more details.

availabilityType'AVAILABILITY_TYPE_UNSPECIFIED' | 'ZONAL' | 'REGIONAL'

Availability type of an Instance. If empty, defaults to REGIONAL for primary instances. For read pools, availability_type is always UNSPECIFIED. Instances in the read pools are evenly distributed across available zones within the region (i.e. read pools with more than one node will have a node in at least two zones).

publicIpAddressstring

Output only. The public IP addresses for the Instance. This is available ONLY when enable_public_ip is set. This is the connection endpoint for an end-user application.

namestring

Output only. The name of the instance resource with the format: * projects/{project}/locations/{region}/clusters/{cluster_id}/instances/{instance_id} where the cluster and instance ID segments should satisfy the regex expression [a-z]([a-z0-9-]{0,61}[a-z0-9])?, e.g. 1-63 characters of lowercase letters, numbers, and dashes, starting with a letter, and ending with a letter or number. For more details see https://google.aip.dev/122. The prefix of the instance resource name is the name of the parent resource: * projects/{project}/locations/{region}/clusters/{cluster_id}

reconcilingboolean

Output only. Reconciling (https://google.aip.dev/128#reconciliation). Set to true if the current state of Instance does not match the user's intended state, and the service is actively updating the resource to reconcile them. This can happen due to user-triggered updates or system actions like failover or maintenance.

deleteTimestring google-datetime

Output only. Delete time stamp

labelsobject

Labels as key value pairs

ipAddressstring

Output only. The IP address for the Instance. This is the connection endpoint for an end-user application.

instanceType'INSTANCE_TYPE_UNSPECIFIED' | 'PRIMARY' | 'READ_POOL' | 'SECONDARY'

Required. The type of the instance. Specified at creation time.

createTimestring google-datetime

Output only. Create time stamp

maintenanceVersionNamestring

Output only. Maintenance version of the instance, for example: POSTGRES_15.2025_07_15.04_00. Output only. Update this field via the parent cluster's maintenance_version field(s).

databaseFlagsobject

Database flags. Set at the instance level. They are copied from the primary instance on secondary instance creation. Flags that have restrictions default to the value at primary instance on read instances during creation. Read instances can set new flags or override existing flags that are relevant for reads, for example, for enabling columnar cache on a read instance. Flags set on read instance might or might not be present on the primary instance. This is a list of "key": "value" pairs. "key": The name of the flag. These flags are passed at instance setup time, so include both server options and system variables for Postgres. Flags are specified with underscores, not hyphens. "value": The value of the flag. Booleans are set to on for true and off for false. This field must be omitted if the flag doesn't take a value.

Response

Successful response