Method create

Creates a PostgreSQL cluster in the specified folder.

HTTP request

POST https://mdb.api.cloud.yandex.net/managed-postgresql/v1/clusters

Body parameters

 {
  "folderId": "string",
  "name": "string",
  "description": "string",
  "labels": "object",
  "environment": "string",
  "configSpec": {
    "version": "string",
    "poolerConfig": {
      "poolingMode": "string"
    },
    "resources": {
      "resourcePresetId": "string",
      "diskSize": "string",
      "diskTypeId": "string"
    },
    "autofailover": true,

    // `configSpec`includes only one of the fields `postgresqlConfig_9_6`, `postgresqlConfig_10`
    "postgresqlConfig_9_6": {
      "maxConnections": "integer",
      "sharedBuffers": "integer",
      "tempBuffers": "integer",
      "maxPreparedTransactions": "integer",
      "workMem": "integer",
      "maintenanceWorkMem": "integer",
      "replacementSortTuples": "integer",
      "autovacuumWorkMem": "integer",
      "tempFileLimit": "integer",
      "vacuumCostDelay": "integer",
      "vacuumCostPageHit": "integer",
      "vacuumCostPageMiss": "integer",
      "vacuumCostPageDirty": "integer",
      "vacuumCostLimit": "integer",
      "bgwriterDelay": "integer",
      "bgwriterLruMaxpages": "integer",
      "bgwriterLruMultiplier": "number",
      "bgwriterFlushAfter": "integer",
      "backendFlushAfter": "integer",
      "oldSnapshotThreshold": "integer",
      "walLevel": "string",
      "synchronousCommit": "string",
      "checkpointTimeout": "integer",
      "checkpointCompletionTarget": "number",
      "checkpointFlushAfter": "integer",
      "maxWalSize": "integer",
      "minWalSize": "integer",
      "maxStandbyStreamingDelay": "integer",
      "defaultStatisticsTarget": "integer",
      "constraintExclusion": "string",
      "cursorTupleFraction": "number",
      "fromCollapseLimit": "integer",
      "joinCollapseLimit": "integer",
      "forceParallelMode": "string",
      "clientMinMessages": "string",
      "logMinMessages": "string",
      "logMinErrorStatement": "string",
      "logMinDurationStatement": "integer",
      "logCheckpoints": true,
      "logConnections": true,
      "logDisconnections": true,
      "logDuration": true,
      "logErrorVerbosity": "string",
      "logLockWaits": true,
      "logStatement": "string",
      "logTempFiles": "integer",
      "searchPath": "string",
      "rowSecurity": true,
      "defaultTransactionIsolation": "string",
      "statementTimeout": "integer",
      "lockTimeout": "integer",
      "idleInTransactionSessionTimeout": "integer",
      "byteaOutput": "string",
      "xmlbinary": "string",
      "xmloption": "string",
      "ginPendingListLimit": "integer",
      "deadlockTimeout": "integer",
      "maxLocksPerTransaction": "integer",
      "maxPredLocksPerTransaction": "integer",
      "arrayNulls": true,
      "backslashQuote": "string",
      "defaultWithOids": true,
      "escapeStringWarning": true,
      "loCompatPrivileges": true,
      "operatorPrecedenceWarning": true,
      "quoteAllIdentifiers": true,
      "standardConformingStrings": true,
      "synchronizeSeqscans": true,
      "transformNullEquals": true,
      "exitOnError": true,
      "seqPageCost": "number",
      "randomPageCost": "number",
      "sqlInheritance": true,
      "autovacuumNaptime": "integer"
    },
    "postgresqlConfig_10": {
      "maxConnections": "integer",
      "sharedBuffers": "integer",
      "tempBuffers": "integer",
      "maxPreparedTransactions": "integer",
      "workMem": "integer",
      "maintenanceWorkMem": "integer",
      "replacementSortTuples": "integer",
      "autovacuumWorkMem": "integer",
      "tempFileLimit": "integer",
      "vacuumCostDelay": "integer",
      "vacuumCostPageHit": "integer",
      "vacuumCostPageMiss": "integer",
      "vacuumCostPageDirty": "integer",
      "vacuumCostLimit": "integer",
      "bgwriterDelay": "integer",
      "bgwriterLruMaxpages": "integer",
      "bgwriterLruMultiplier": "number",
      "bgwriterFlushAfter": "integer",
      "backendFlushAfter": "integer",
      "oldSnapshotThreshold": "integer",
      "walLevel": "string",
      "synchronousCommit": "string",
      "checkpointTimeout": "integer",
      "checkpointCompletionTarget": "number",
      "checkpointFlushAfter": "integer",
      "maxWalSize": "integer",
      "minWalSize": "integer",
      "maxStandbyStreamingDelay": "integer",
      "defaultStatisticsTarget": "integer",
      "constraintExclusion": "string",
      "cursorTupleFraction": "number",
      "fromCollapseLimit": "integer",
      "joinCollapseLimit": "integer",
      "forceParallelMode": "string",
      "clientMinMessages": "string",
      "logMinMessages": "string",
      "logMinErrorStatement": "string",
      "logMinDurationStatement": "integer",
      "logCheckpoints": true,
      "logConnections": true,
      "logDisconnections": true,
      "logDuration": true,
      "logErrorVerbosity": "string",
      "logLockWaits": true,
      "logStatement": "string",
      "logTempFiles": "integer",
      "searchPath": "string",
      "rowSecurity": true,
      "defaultTransactionIsolation": "string",
      "statementTimeout": "integer",
      "lockTimeout": "integer",
      "idleInTransactionSessionTimeout": "integer",
      "byteaOutput": "string",
      "xmlbinary": "string",
      "xmloption": "string",
      "ginPendingListLimit": "integer",
      "deadlockTimeout": "integer",
      "maxLocksPerTransaction": "integer",
      "maxPredLocksPerTransaction": "integer",
      "arrayNulls": true,
      "backslashQuote": "string",
      "defaultWithOids": true,
      "escapeStringWarning": true,
      "loCompatPrivileges": true,
      "operatorPrecedenceWarning": true,
      "quoteAllIdentifiers": true,
      "standardConformingStrings": true,
      "synchronizeSeqscans": true,
      "transformNullEquals": true,
      "exitOnError": true,
      "seqPageCost": "number",
      "randomPageCost": "number",
      "autovacuumNaptime": "integer"
    },
    // end of the list of possible fields`configSpec`

  },
  "databaseSpecs": [
    {
      "name": "string",
      "owner": "string",
      "lcCollate": "string",
      "lcCtype": "string",
      "extensions": [
        {
          "name": "string",
          "version": "string"
        }
      ]
    }
  ],
  "userSpecs": [
    {
      "name": "string",
      "password": "string",
      "permissions": [
        {
          "databaseName": "string"
        }
      ],
      "connLimit": "integer"
    }
  ],
  "hostSpecs": [
    {
      "zoneId": "string",
      "subnetId": "string",
      "assignPublicIp": true,
      "replicationSource": "string",
      "priority": "integer",
      "configSpec": {

        // `hostSpecs[].configSpec`includes only one of the fields `postgresqlConfig_9_6`, `postgresqlConfig_10`
        "postgresqlConfig_9_6": {
          "recoveryMinApplyDelay": "integer",
          "sharedBuffers": "integer",
          "tempBuffers": "integer",
          "workMem": "integer",
          "replacementSortTuples": "integer",
          "tempFileLimit": "integer",
          "backendFlushAfter": "integer",
          "oldSnapshotThreshold": "integer",
          "maxStandbyStreamingDelay": "integer",
          "constraintExclusion": "string",
          "cursorTupleFraction": "number",
          "fromCollapseLimit": "integer",
          "joinCollapseLimit": "integer",
          "forceParallelMode": "string",
          "clientMinMessages": "string",
          "logMinMessages": "string",
          "logMinErrorStatement": "string",
          "logMinDurationStatement": "integer",
          "logCheckpoints": true,
          "logConnections": true,
          "logDisconnections": true,
          "logDuration": true,
          "logErrorVerbosity": "string",
          "logLockWaits": true,
          "logStatement": "string",
          "logTempFiles": "integer",
          "searchPath": "string",
          "rowSecurity": true,
          "defaultTransactionIsolation": "string",
          "statementTimeout": "integer",
          "lockTimeout": "integer",
          "idleInTransactionSessionTimeout": "integer",
          "byteaOutput": "string",
          "xmlbinary": "string",
          "xmloption": "string",
          "ginPendingListLimit": "integer",
          "deadlockTimeout": "integer",
          "maxLocksPerTransaction": "integer",
          "maxPredLocksPerTransaction": "integer",
          "arrayNulls": true,
          "backslashQuote": "string",
          "defaultWithOids": true,
          "escapeStringWarning": true,
          "loCompatPrivileges": true,
          "operatorPrecedenceWarning": true,
          "quoteAllIdentifiers": true,
          "standardConformingStrings": true,
          "synchronizeSeqscans": true,
          "transformNullEquals": true,
          "exitOnError": true,
          "seqPageCost": "number",
          "randomPageCost": "number",
          "sqlInheritance": true
        },
        "postgresqlConfig_10": {
          "recoveryMinApplyDelay": "integer",
          "sharedBuffers": "integer",
          "tempBuffers": "integer",
          "workMem": "integer",
          "replacementSortTuples": "integer",
          "tempFileLimit": "integer",
          "backendFlushAfter": "integer",
          "oldSnapshotThreshold": "integer",
          "maxStandbyStreamingDelay": "integer",
          "constraintExclusion": "string",
          "cursorTupleFraction": "number",
          "fromCollapseLimit": "integer",
          "joinCollapseLimit": "integer",
          "forceParallelMode": "string",
          "clientMinMessages": "string",
          "logMinMessages": "string",
          "logMinErrorStatement": "string",
          "logMinDurationStatement": "integer",
          "logCheckpoints": true,
          "logConnections": true,
          "logDisconnections": true,
          "logDuration": true,
          "logErrorVerbosity": "string",
          "logLockWaits": true,
          "logStatement": "string",
          "logTempFiles": "integer",
          "searchPath": "string",
          "rowSecurity": true,
          "defaultTransactionIsolation": "string",
          "statementTimeout": "integer",
          "lockTimeout": "integer",
          "idleInTransactionSessionTimeout": "integer",
          "byteaOutput": "string",
          "xmlbinary": "string",
          "xmloption": "string",
          "ginPendingListLimit": "integer",
          "deadlockTimeout": "integer",
          "maxLocksPerTransaction": "integer",
          "maxPredLocksPerTransaction": "integer",
          "arrayNulls": true,
          "backslashQuote": "string",
          "defaultWithOids": true,
          "escapeStringWarning": true,
          "loCompatPrivileges": true,
          "operatorPrecedenceWarning": true,
          "quoteAllIdentifiers": true,
          "standardConformingStrings": true,
          "synchronizeSeqscans": true,
          "transformNullEquals": true,
          "exitOnError": true,
          "seqPageCost": "number",
          "randomPageCost": "number"
        },
        // end of the list of possible fields`hostSpecs[].configSpec`

      }
    }
  ],
  "networkId": "string"
}
Field Description
folderId string

Required. ID of the folder to create the PostgreSQL cluster in.

The maximum string length in characters is 50.

name string

Required. Name of the PostgreSQL cluster. The name must be unique within the folder.

The maximum string length in characters is 63. Value must match the regular expression [a-zA-Z0-9_-]*.

description string

Description of the PostgreSQL cluster.

The maximum string length in characters is 256.

labels object

Custom labels for the PostgreSQL cluster as key:value pairs. Maximum 64 per resource. For example, "project": "mvp" or "source": "dictionary".

No more than 64 per resource. The maximum string length in characters for each key is 63. Each key must match the regular expression [a-z][-_0-9a-z]. The maximum string length in characters for each value is 63. Each value must match the regular expression [-_0-9a-z].

environment string

Required. Deployment environment of the PostgreSQL cluster.

  • PRODUCTION: Stable environment with a conservative update policy: only hotfixes are applied during regular maintenance.
  • PRESTABLE: Environment with more aggressive update policy: new versions are rolled out irrespective of backward compatibility.
configSpec object

Required. Configuration and resources for hosts that should be created for the PostgreSQL cluster.

configSpec.
version
string

Version of PostgreSQL used in the cluster. Possible values:

  • 10
  • 9.6
configSpec.
poolerConfig
object
configSpec.
poolerConfig.
poolingMode
string

Mode that the connection pooler is working in. See descriptions of all modes in the documentation for PgBouncer.

  • SESSION: Session pooling mode.
  • TRANSACTION: Transaction pooling mode.
  • STATEMENT: Statement pooling mode.
configSpec.
resources
object
configSpec.
resources.
resourcePresetId
string

ID of the preset for computational resources available to a host (CPU, memory etc.). All available presets are listed in the documentation.

configSpec.
resources.
diskSize
string (int64)

Volume of the storage available to a host, in bytes.

configSpec.
resources.
diskTypeId
string

Type of the storage environment for the host. Possible values:

  • network-hdd — network HDD drive,
  • network-nvme — network SSD drive,
  • local-nvme — local SSD storage.
configSpec.
autofailover
boolean (boolean)

Configuration setting which enables/disables autofailover in cluster.

configSpec.
postgresqlConfig_9_6
object
configSpec includes only one of the fields postgresqlConfig_9_6, postgresqlConfig_10

Options and structure of PostgresqlConfig reflects PostgreSQL configuration file parameters whose detailed description is available in PostgreSQL documentation.

configSpec.
postgresqlConfig_9_6.
maxConnections
integer (int64)
configSpec.
postgresqlConfig_9_6.
sharedBuffers
integer (int64)
configSpec.
postgresqlConfig_9_6.
tempBuffers
integer (int64)
configSpec.
postgresqlConfig_9_6.
maxPreparedTransactions
integer (int64)
configSpec.
postgresqlConfig_9_6.
workMem
integer (int64)
configSpec.
postgresqlConfig_9_6.
maintenanceWorkMem
integer (int64)
configSpec.
postgresqlConfig_9_6.
replacementSortTuples
integer (int64)
configSpec.
postgresqlConfig_9_6.
autovacuumWorkMem
integer (int64)
configSpec.
postgresqlConfig_9_6.
tempFileLimit
integer (int64)
configSpec.
postgresqlConfig_9_6.
vacuumCostDelay
integer (int64)
configSpec.
postgresqlConfig_9_6.
vacuumCostPageHit
integer (int64)
configSpec.
postgresqlConfig_9_6.
vacuumCostPageMiss
integer (int64)
configSpec.
postgresqlConfig_9_6.
vacuumCostPageDirty
integer (int64)
configSpec.
postgresqlConfig_9_6.
vacuumCostLimit
integer (int64)
configSpec.
postgresqlConfig_9_6.
bgwriterDelay
integer (int64)

Acceptable values are 10 to 10000, inclusive.

configSpec.
postgresqlConfig_9_6.
bgwriterLruMaxpages
integer (int64)
configSpec.
postgresqlConfig_9_6.
bgwriterLruMultiplier
number (double)
configSpec.
postgresqlConfig_9_6.
bgwriterFlushAfter
integer (int64)

Acceptable values are 0 to 2048, inclusive.

configSpec.
postgresqlConfig_9_6.
backendFlushAfter
integer (int64)

Acceptable values are 0 to 2048, inclusive.

configSpec.
postgresqlConfig_9_6.
oldSnapshotThreshold
integer (int64)

Acceptable values are -1 to 86400000, inclusive.

configSpec.
postgresqlConfig_9_6.
walLevel
string
configSpec.
postgresqlConfig_9_6.
synchronousCommit
string
configSpec.
postgresqlConfig_9_6.
checkpointTimeout
integer (int64)

Acceptable values are 30000 to 86400000, inclusive.

configSpec.
postgresqlConfig_9_6.
checkpointCompletionTarget
number (double)
configSpec.
postgresqlConfig_9_6.
checkpointFlushAfter
integer (int64)

Acceptable values are 0 to 2048, inclusive.

configSpec.
postgresqlConfig_9_6.
maxWalSize
integer (int64)
configSpec.
postgresqlConfig_9_6.
minWalSize
integer (int64)
configSpec.
postgresqlConfig_9_6.
maxStandbyStreamingDelay
integer (int64)
configSpec.
postgresqlConfig_9_6.
defaultStatisticsTarget
integer (int64)
configSpec.
postgresqlConfig_9_6.
constraintExclusion
string
configSpec.
postgresqlConfig_9_6.
cursorTupleFraction
number (double)
configSpec.
postgresqlConfig_9_6.
fromCollapseLimit
integer (int64)

Acceptable values are 1 to 2147483647, inclusive.

configSpec.
postgresqlConfig_9_6.
joinCollapseLimit
integer (int64)

Acceptable values are 1 to 2147483647, inclusive.

configSpec.
postgresqlConfig_9_6.
forceParallelMode
string
configSpec.
postgresqlConfig_9_6.
clientMinMessages
string
configSpec.
postgresqlConfig_9_6.
logMinMessages
string
configSpec.
postgresqlConfig_9_6.
logMinErrorStatement
string
configSpec.
postgresqlConfig_9_6.
logMinDurationStatement
integer (int64)
configSpec.
postgresqlConfig_9_6.
logCheckpoints
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
logConnections
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
logDisconnections
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
logDuration
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
logErrorVerbosity
string
configSpec.
postgresqlConfig_9_6.
logLockWaits
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
logStatement
string
configSpec.
postgresqlConfig_9_6.
logTempFiles
integer (int64)
configSpec.
postgresqlConfig_9_6.
searchPath
string
configSpec.
postgresqlConfig_9_6.
rowSecurity
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
defaultTransactionIsolation
string
configSpec.
postgresqlConfig_9_6.
statementTimeout
integer (int64)
configSpec.
postgresqlConfig_9_6.
lockTimeout
integer (int64)
configSpec.
postgresqlConfig_9_6.
idleInTransactionSessionTimeout
integer (int64)
configSpec.
postgresqlConfig_9_6.
byteaOutput
string
configSpec.
postgresqlConfig_9_6.
xmlbinary
string
configSpec.
postgresqlConfig_9_6.
xmloption
string
configSpec.
postgresqlConfig_9_6.
ginPendingListLimit
integer (int64)
configSpec.
postgresqlConfig_9_6.
deadlockTimeout
integer (int64)
configSpec.
postgresqlConfig_9_6.
maxLocksPerTransaction
integer (int64)
configSpec.
postgresqlConfig_9_6.
maxPredLocksPerTransaction
integer (int64)
configSpec.
postgresqlConfig_9_6.
arrayNulls
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
backslashQuote
string
configSpec.
postgresqlConfig_9_6.
defaultWithOids
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
escapeStringWarning
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
loCompatPrivileges
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
operatorPrecedenceWarning
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
quoteAllIdentifiers
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
standardConformingStrings
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
synchronizeSeqscans
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
transformNullEquals
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
exitOnError
boolean (boolean)
configSpec.
postgresqlConfig_9_6.
seqPageCost
number (double)
configSpec.
postgresqlConfig_9_6.
randomPageCost
number (double)
configSpec.
postgresqlConfig_9_6.
sqlInheritance
boolean (boolean)

This option has been removed in PostgreSQL 10.

configSpec.
postgresqlConfig_9_6.
autovacuumNaptime
integer (int64)

Acceptable values are 6000 to 86400000, inclusive.

configSpec.
postgresqlConfig_10
object
configSpec includes only one of the fields postgresqlConfig_9_6, postgresqlConfig_10

Options and structure of PostgresqlConfig reflects PostgreSQL configuration file parameters whose detailed description is available in PostgreSQL documentation.

configSpec.
postgresqlConfig_10.
maxConnections
integer (int64)
configSpec.
postgresqlConfig_10.
sharedBuffers
integer (int64)
configSpec.
postgresqlConfig_10.
tempBuffers
integer (int64)
configSpec.
postgresqlConfig_10.
maxPreparedTransactions
integer (int64)
configSpec.
postgresqlConfig_10.
workMem
integer (int64)
configSpec.
postgresqlConfig_10.
maintenanceWorkMem
integer (int64)
configSpec.
postgresqlConfig_10.
replacementSortTuples
integer (int64)
configSpec.
postgresqlConfig_10.
autovacuumWorkMem
integer (int64)
configSpec.
postgresqlConfig_10.
tempFileLimit
integer (int64)
configSpec.
postgresqlConfig_10.
vacuumCostDelay
integer (int64)
configSpec.
postgresqlConfig_10.
vacuumCostPageHit
integer (int64)
configSpec.
postgresqlConfig_10.
vacuumCostPageMiss
integer (int64)
configSpec.
postgresqlConfig_10.
vacuumCostPageDirty
integer (int64)
configSpec.
postgresqlConfig_10.
vacuumCostLimit
integer (int64)
configSpec.
postgresqlConfig_10.
bgwriterDelay
integer (int64)

Acceptable values are 10 to 10000, inclusive.

configSpec.
postgresqlConfig_10.
bgwriterLruMaxpages
integer (int64)
configSpec.
postgresqlConfig_10.
bgwriterLruMultiplier
number (double)
configSpec.
postgresqlConfig_10.
bgwriterFlushAfter
integer (int64)

Acceptable values are 0 to 2048, inclusive.

configSpec.
postgresqlConfig_10.
backendFlushAfter
integer (int64)

Acceptable values are 0 to 2048, inclusive.

configSpec.
postgresqlConfig_10.
oldSnapshotThreshold
integer (int64)

Acceptable values are -1 to 86400000, inclusive.

configSpec.
postgresqlConfig_10.
walLevel
string
configSpec.
postgresqlConfig_10.
synchronousCommit
string
configSpec.
postgresqlConfig_10.
checkpointTimeout
integer (int64)

Acceptable values are 30000 to 86400000, inclusive.

configSpec.
postgresqlConfig_10.
checkpointCompletionTarget
number (double)
configSpec.
postgresqlConfig_10.
checkpointFlushAfter
integer (int64)

Acceptable values are 0 to 2048, inclusive.

configSpec.
postgresqlConfig_10.
maxWalSize
integer (int64)
configSpec.
postgresqlConfig_10.
minWalSize
integer (int64)
configSpec.
postgresqlConfig_10.
maxStandbyStreamingDelay
integer (int64)
configSpec.
postgresqlConfig_10.
defaultStatisticsTarget
integer (int64)
configSpec.
postgresqlConfig_10.
constraintExclusion
string
configSpec.
postgresqlConfig_10.
cursorTupleFraction
number (double)
configSpec.
postgresqlConfig_10.
fromCollapseLimit
integer (int64)

Acceptable values are 1 to 2147483647, inclusive.

configSpec.
postgresqlConfig_10.
joinCollapseLimit
integer (int64)

Acceptable values are 1 to 2147483647, inclusive.

configSpec.
postgresqlConfig_10.
forceParallelMode
string
configSpec.
postgresqlConfig_10.
clientMinMessages
string
configSpec.
postgresqlConfig_10.
logMinMessages
string
configSpec.
postgresqlConfig_10.
logMinErrorStatement
string
configSpec.
postgresqlConfig_10.
logMinDurationStatement
integer (int64)
configSpec.
postgresqlConfig_10.
logCheckpoints
boolean (boolean)
configSpec.
postgresqlConfig_10.
logConnections
boolean (boolean)
configSpec.
postgresqlConfig_10.
logDisconnections
boolean (boolean)
configSpec.
postgresqlConfig_10.
logDuration
boolean (boolean)
configSpec.
postgresqlConfig_10.
logErrorVerbosity
string
configSpec.
postgresqlConfig_10.
logLockWaits
boolean (boolean)
configSpec.
postgresqlConfig_10.
logStatement
string
configSpec.
postgresqlConfig_10.
logTempFiles
integer (int64)
configSpec.
postgresqlConfig_10.
searchPath
string
configSpec.
postgresqlConfig_10.
rowSecurity
boolean (boolean)
configSpec.
postgresqlConfig_10.
defaultTransactionIsolation
string
configSpec.
postgresqlConfig_10.
statementTimeout
integer (int64)
configSpec.
postgresqlConfig_10.
lockTimeout
integer (int64)
configSpec.
postgresqlConfig_10.
idleInTransactionSessionTimeout
integer (int64)
configSpec.
postgresqlConfig_10.
byteaOutput
string
configSpec.
postgresqlConfig_10.
xmlbinary
string
configSpec.
postgresqlConfig_10.
xmloption
string
configSpec.
postgresqlConfig_10.
ginPendingListLimit
integer (int64)
configSpec.
postgresqlConfig_10.
deadlockTimeout
integer (int64)
configSpec.
postgresqlConfig_10.
maxLocksPerTransaction
integer (int64)
configSpec.
postgresqlConfig_10.
maxPredLocksPerTransaction
integer (int64)
configSpec.
postgresqlConfig_10.
arrayNulls
boolean (boolean)
configSpec.
postgresqlConfig_10.
backslashQuote
string
configSpec.
postgresqlConfig_10.
defaultWithOids
boolean (boolean)
configSpec.
postgresqlConfig_10.
escapeStringWarning
boolean (boolean)
configSpec.
postgresqlConfig_10.
loCompatPrivileges
boolean (boolean)
configSpec.
postgresqlConfig_10.
operatorPrecedenceWarning
boolean (boolean)
configSpec.
postgresqlConfig_10.
quoteAllIdentifiers
boolean (boolean)
configSpec.
postgresqlConfig_10.
standardConformingStrings
boolean (boolean)
configSpec.
postgresqlConfig_10.
synchronizeSeqscans
boolean (boolean)
configSpec.
postgresqlConfig_10.
transformNullEquals
boolean (boolean)
configSpec.
postgresqlConfig_10.
exitOnError
boolean (boolean)
configSpec.
postgresqlConfig_10.
seqPageCost
number (double)
configSpec.
postgresqlConfig_10.
randomPageCost
number (double)
configSpec.
postgresqlConfig_10.
autovacuumNaptime
integer (int64)

Acceptable values are 6000 to 86400000, inclusive.

databaseSpecs[] object

Required. Descriptions of databases to be created in the PostgreSQL cluster.

databaseSpecs[].
name
string

Required. Name of the PostgreSQL database. 1-63 characters long.

The maximum string length in characters is 63. Value must match the regular expression [a-zA-Z0-9_-]*.

databaseSpecs[].
owner
string

Required. Name of the user to be assigned as the owner of the database. To get the list of available PostgreSQL users, make a list request.

The maximum string length in characters is 63. Value must match the regular expression [a-zA-Z0-9_]*.

databaseSpecs[].
lcCollate
string

POSIX locale for string sorting order. Can only be set at creation time.

Value must match the regular expression [a-zA-Z_]+.UTF-8|C.

databaseSpecs[].
lcCtype
string

POSIX locale for character classification. Can only be set at creation time.

Value must match the regular expression [a-zA-Z_]+.UTF-8|C.

databaseSpecs[].
extensions[]
object

PostgreSQL extensions to be enabled for the database.

databaseSpecs[].
extensions[].
name
string

Name of the extension, e.g. pg_trgm or pg_btree. Extensions supported by MDB are listed in the Developer's Guide.

databaseSpecs[].
extensions[].
version
string

Version of the extension.

userSpecs[] object

Required. Descriptions of database users to be created in the PostgreSQL cluster.

userSpecs[].
name
string

Required. Name of the PostgreSQL user.

The maximum string length in characters is 63. Value must match the regular expression [a-zA-Z0-9_]*.

userSpecs[].
password
string

Required. Password of the PostgreSQL user.

The string length in characters must be 8-128.

userSpecs[].
permissions[]
object

Set of permissions to grant to the user.

userSpecs[].
permissions[].
databaseName
string

Name of the database that the permission grants access to.

userSpecs[].
connLimit
integer (int64)

Number of database connections that should be available to the user.

The minimum value is 10.

hostSpecs[] object

Required. Individual configurations for hosts that should be created for the PostgreSQL cluster.

hostSpecs[].
zoneId
string

ID of the availability zone where the host resides. To get a list of available zones, use the list request.

The maximum string length in characters is 50.

hostSpecs[].
subnetId
string

ID of the subnet that the host should belong to. This subnet should be a part of the network that the cluster belongs to. The ID of the network is set in the field Cluster.networkId.

The maximum string length in characters is 50.

hostSpecs[].
assignPublicIp
boolean (boolean)

Whether the host should get a public IP address on creation.

After a host has been created, this setting cannot be changed. To remove an assigned public IP, or to assign a public IP to a host without one, recreate the host with assignPublicIp set as needed.

Possible values:

  • false — don't assign a public IP to the host.
  • true — the host should have a public IP address.
hostSpecs[].
replicationSource
string

name of the host to be used as the replication source (for cascading replication).

hostSpecs[].
priority
integer (int64)

Priority of the host as a replica. A higher value corresponds to higher priority.

The host with the highest priority is the synchronous replica. All others are asynchronous. The synchronous replica replaces the master when needed.

When a replica becomes the master, its priority is ignored.

hostSpecs[].
configSpec
object

Configuration of a PostgreSQL server for the host.

hostSpecs[].
configSpec.
postgresqlConfig_9_6
object
hostSpecs[].configSpec includes only one of the fields postgresqlConfig_9_6, postgresqlConfig_10

Options and structure of PostgresqlHostConfig reflects parameters of a PostgreSQL configuration file. Detailed description is available in PostgreSQL documentation.

hostSpecs[].
configSpec.
postgresqlConfig_9_6.
recoveryMinApplyDelay
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
sharedBuffers
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
tempBuffers
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
workMem
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
replacementSortTuples
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
tempFileLimit
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
backendFlushAfter
integer (int64)

Acceptable values are 0 to 2048, inclusive.

hostSpecs[].
configSpec.
postgresqlConfig_9_6.
oldSnapshotThreshold
integer (int64)

Acceptable values are -1 to 86400, inclusive.

hostSpecs[].
configSpec.
postgresqlConfig_9_6.
maxStandbyStreamingDelay
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
constraintExclusion
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
cursorTupleFraction
number (double)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
fromCollapseLimit
integer (int64)

Acceptable values are 1 to 2147483647, inclusive.

hostSpecs[].
configSpec.
postgresqlConfig_9_6.
joinCollapseLimit
integer (int64)

Acceptable values are 1 to 2147483647, inclusive.

hostSpecs[].
configSpec.
postgresqlConfig_9_6.
forceParallelMode
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
clientMinMessages
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
logMinMessages
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
logMinErrorStatement
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
logMinDurationStatement
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
logCheckpoints
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
logConnections
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
logDisconnections
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
logDuration
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
logErrorVerbosity
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
logLockWaits
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
logStatement
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
logTempFiles
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
searchPath
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
rowSecurity
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
defaultTransactionIsolation
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
statementTimeout
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
lockTimeout
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
idleInTransactionSessionTimeout
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
byteaOutput
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
xmlbinary
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
xmloption
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
ginPendingListLimit
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
deadlockTimeout
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
maxLocksPerTransaction
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
maxPredLocksPerTransaction
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
arrayNulls
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
backslashQuote
string
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
defaultWithOids
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
escapeStringWarning
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
loCompatPrivileges
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
operatorPrecedenceWarning
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
quoteAllIdentifiers
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
standardConformingStrings
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
synchronizeSeqscans
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
transformNullEquals
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
exitOnError
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
seqPageCost
number (double)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
randomPageCost
number (double)
hostSpecs[].
configSpec.
postgresqlConfig_9_6.
sqlInheritance
boolean (boolean)

This option has been removed in PostgreSQL 10.

hostSpecs[].
configSpec.
postgresqlConfig_10
object
hostSpecs[].configSpec includes only one of the fields postgresqlConfig_9_6, postgresqlConfig_10

Options and structure of PostgresqlHostConfig reflects PostgreSQL configuration file parameters whose detailed description is available in PostgreSQL documentation.

hostSpecs[].
configSpec.
postgresqlConfig_10.
recoveryMinApplyDelay
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
sharedBuffers
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
tempBuffers
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
workMem
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
replacementSortTuples
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
tempFileLimit
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
backendFlushAfter
integer (int64)

Acceptable values are 0 to 2048, inclusive.

hostSpecs[].
configSpec.
postgresqlConfig_10.
oldSnapshotThreshold
integer (int64)

Acceptable values are -1 to 86400, inclusive.

hostSpecs[].
configSpec.
postgresqlConfig_10.
maxStandbyStreamingDelay
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
constraintExclusion
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
cursorTupleFraction
number (double)
hostSpecs[].
configSpec.
postgresqlConfig_10.
fromCollapseLimit
integer (int64)

Acceptable values are 1 to 2147483647, inclusive.

hostSpecs[].
configSpec.
postgresqlConfig_10.
joinCollapseLimit
integer (int64)

Acceptable values are 1 to 2147483647, inclusive.

hostSpecs[].
configSpec.
postgresqlConfig_10.
forceParallelMode
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
clientMinMessages
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
logMinMessages
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
logMinErrorStatement
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
logMinDurationStatement
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
logCheckpoints
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
logConnections
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
logDisconnections
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
logDuration
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
logErrorVerbosity
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
logLockWaits
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
logStatement
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
logTempFiles
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
searchPath
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
rowSecurity
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
defaultTransactionIsolation
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
statementTimeout
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
lockTimeout
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
idleInTransactionSessionTimeout
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
byteaOutput
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
xmlbinary
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
xmloption
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
ginPendingListLimit
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
deadlockTimeout
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
maxLocksPerTransaction
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
maxPredLocksPerTransaction
integer (int64)
hostSpecs[].
configSpec.
postgresqlConfig_10.
arrayNulls
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
backslashQuote
string
hostSpecs[].
configSpec.
postgresqlConfig_10.
defaultWithOids
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
escapeStringWarning
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
loCompatPrivileges
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
operatorPrecedenceWarning
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
quoteAllIdentifiers
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
standardConformingStrings
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
synchronizeSeqscans
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
transformNullEquals
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
exitOnError
boolean (boolean)
hostSpecs[].
configSpec.
postgresqlConfig_10.
seqPageCost
number (double)
hostSpecs[].
configSpec.
postgresqlConfig_10.
randomPageCost
number (double)
networkId string

Required. ID of the network to create the cluster in.

The maximum string length in characters is 50.

Response

HTTP Code: 200 - OK

 {
  "id": "string",
  "description": "string",
  "createdAt": "string",
  "createdBy": "string",
  "modifiedAt": "string",
  "done": true,
  "metadata": "object",

  // includes only one of the fields `error`, `response`
  "error": {
    "code": "integer",
    "message": "string",
    "details": [
      "object"
    ]
  },
  "response": "object",
  // end of the list of possible fields

}

An Operation resource. For more information, see Operation.

Field Description
id string

ID of the operation.

description string

Description of the operation. 0-256 characters long.

createdAt string (date-time)

Creation timestamp in RFC3339 text format.

createdBy string

ID of the user or service account who initiated the operation.

modifiedAt string (date-time)

The time when the Operation resource was last modified. This value is in RFC3339 text format.

done boolean (boolean)

If the value is false, it means the operation is still in progress. If true, the operation is completed, and either error or response is available.

metadata object

Service-specific metadata associated with the operation. It typically contains the ID of the target resource that the operation is performed on. Any method that returns a long-running operation should document the metadata type, if any.

error object
includes only one of the fields error, response

The error result of the operation in case of failure or cancellation.

error.
code
integer (int32)

Error code. An enum value of google.rpc.Code.

error.
message
string

An error message.

error.
details[]
object

A list of messages that carry the error details.

response object
includes only one of the fields error, response

The normal response of the operation in case of success. If the original method returns no data on success, such as Delete, the response is google.protobuf.Empty. If the original method is the standard Create/Update, the response should be the target resource of the operation. Any method that returns a long-running operation should document the response type, if any.