createCloudPostgresqlInstance
- Print
- PDF
createCloudPostgresqlInstance
- Print
- PDF
Article Summary
Share feedback
Thanks for sharing your feedback!
Available in VPC
Create Cloud DB for PostgreSQL instance.
Requests
Request Parameters
Parameter | Type | Requirement Status | Description | Restrictions |
---|---|---|---|---|
regionCode | String | N | Region code - regionCode can be obtained via the getRegionList action - default: Selects the first region of the getRegionList query results | - |
vpcNo | String | Y | VPC number - vpcNo can be obtained via the getCloudPostgresqlTargetVpcList action | - |
subnetNo | String | Y | Subnet number - subnetNo can be obtained via the getCloudPostgresqlTargetSubnetList action - Public domain can only be used on a DB server generated on Public Subnet - Subnet transfer is not possible after a Cloud DB for PostgreSQL instance has been created | - |
secondarySubnetNo | String | N | Subnet number of the secondary server - When multi-zone (isMultiZone) is false, input is not accepted. When multi-zone (isMultiZone) is true, you must enter - It must have a different zone from the primary server's subnet, and their public or private statuses must match - secondarySubnetNo can be obtained via the getCloudPostgresqlTargetSubnetList action | - |
cloudPostgresqlImageProductCode | String | N | Cloud DB for PostgreSQL image product code - cloudPostgresqlImageProductCode can be obtained via the getCloudPostgresqlImageProductList action's productCode - Generated in default value if data is not entered | - |
cloudPostgresqlProductCode | String | N | Cloud DB for PostgreSQL product code - Set the server specifications of the Cloud DB for PostgreSQL instance to be created - cloudPostgresqlProductCode can be obtained via the getCloudPostgresqlProductList action's productCode - default: Selected as the minimum specification. The minimum specification is based on 1. memory and 2. CPU | - |
dataStorageTypeCode | String | N | Data storage type code - Data storage type cannot be altered after installation - options: SSD | HDD - default: SSD | - |
isHa | Boolean | N | High availability status - If you select high availability, 2 servers including the secondary server are created, and an additional charge are incurred - If high availability status (isHa) is false, isMultiZone and secondarySubnetNo parameters cannot be used - default: true | - |
isMultiZone | Boolean | N | Multi-zone (True/False) - If the high availability status (isHa) is true, multi-zone status can be selected - If you select multi-zone, primary server and secondary server are created in different zones to provide higher availability - Must be entered if the high availability status (isHa) is true - Not available in the Neurocloud environment - default: false | - |
isStorageEncryption | Boolean | N | Whether data storage encryption is applied - When you apply encryption, DB data will be encrypted and stored in storage - Storage encryption settings cannot be changed after a Cloud DB for PostgreSQL instance has been created - Not available in the Neurocloud environment - default: false | - |
isBackup | Boolean | N | Backup (True/False) - If the high availability status (isHa) is true, backup (isBackup) is to be set at true - default: true | - |
backupFileRetentionPeriod | Integer | N | Backup file storage period - Backups are performed every day, and backup files are saved in a separate backup storage - Charges are based on the storage space used - default: 1 (1 day) | - |
backupTime | String | N | Backup time - Sets the time at which backup is conducted. If backup (isBackup) is set at True and automatic backup (isAutomaticBackup) is set at False, a time must be entered - 01:15 | - |
isAutomaticBackup | Boolean | N | Backup time is automatically set - Select whether backup time is to be set automatically, and if automatic backup (isAutomaticBackup) is true, backupTime cannot be entered - default: true | - |
cloudPostgresqlServiceName | String | Y | Cloud DB for PostgreSQL service name | - Only English alphabets, numbers, dash ( - ) and Korean letters can be entered - Min: 3 - Max: 30 |
cloudPostgresqlServerNamePrefix | String | Y | Cloud DB for PostgreSQL server name prefix - It is created with random text added after the transferred cloudPostgresqlServerNamePrefix value to avoid duplicated host names | - DB server name must contain only English letters (lowercase), numbers, and hyphens (-) - It must start with an English letter and end with an English letter or a number - Min: 3 - Max: 20 |
cloudPostgresqlUserName | String | Y | Admin ID - Enter user name to use for DB admin | - Only English lowercase letters, numbers, and underscore characters ( _ ) are allowed, and must start with an English letter - Min: 4 - Max: 16 |
cloudPostgresqlUserPassword | String | Y | Admin password - Enter user's password to use for DB admin | - Must be at least 8 characters in length and contain at least 1 each of English letter, special character, and number - The following characters cannot be used in the password: ` & + \ " ' / and space - Cannot include user ID - Min: 8 - Max: 20 |
clientCidr | String | Y | Access control - Enter CIDR of a client you want to have access to | - Allow full access: 0.0.0.0/0 - Allow access to specific IPs: 192.168.1.1/32 - Allow access to an IP range: 192.168.1.0/24 |
cloudPostgresqlPort | Integer | N | Cloud DB for PostgreSQL port - Enter the TCP port number for PostgreSQL access - default: 5432 | 5432 or - Min: 10000 - Max: 20000 |
cloudPostgresqlDatabaseName | String | Y | Cloud DB for PostgreSQL's DB name - Enter the default DB name | - Only English lowercase letters, numbers, and underscore characters ( _ ) are allowed, and must start with an English letter - Min: 1 - Max: 30 |
responseFormatType | String | N | Format type of the response result - options: xml | json - default: xml | - |
Responses
Response bodies
For response bodies, refer to CloudPostgresqlInstanceList.
Examples
Request Examples
The following is an example of a request body.
GET {API_URL}/createCloudPostgresqlInstance
?regionCode=KR
&vpcNo=****87
&subnetNo=****49
&secondarySubnetNo=****51
&cloudPostgresqlImageProductCode=SW.VPGSL.OS.LNX64.CNTOS.0708.PGSQL.133.B050
&cloudPostgresqlProductCode=SVR.VPGSL.DBSVR.STAND.C002.M004.NET.SSD.B050.G001
&dataStorageTypeCode=SSD
&isHa=true
&isMultiZone=true
&isStorageEncryption=true
&isBackup=true
&backupFileRetentionPeriod=10
&backupTime=02:00
&isAutomaticBackup=false
&cloudPostgresqlServiceName=test-****
&cloudPostgresqlServerNamePrefix=test-****
&cloudPostgresqlUserName=test****
&cloudPostgresqlUserPassword=********
&clientCidr=0.0.0.0/0
&cloudPostgresqlPort=15432
&cloudPostgresqlDatabaseName=test****
Response examples
The following are examples of responses.
If the response shows that format type (responseFormatType) is json
{
"createCloudPostgresqlInstanceResponse": {
"requestId": "9f76fa24-67a4-4cdf-bf70-f62f251d5138",
"returnCode": 0,
"returnMessage": "success",
"totalRows": 1,
"cloudPostgresqlInstanceList": [
{
"cloudPostgresqlInstanceNo": "****925",
"cloudPostgresqlServiceName": "test-****",
"cloudPostgresqlInstanceStatusName": "creating",
"cloudPostgresqlInstanceStatus": {
"code": "INIT",
"codeName": "CLOUD DATABASE(VPC) Init State"
},
"cloudPostgresqlInstanceOperation": {
"code": "CREAT",
"codeName": "CLOUD DATABASE(VPC) Creat OP"
},
"cloudPostgresqlImageProductCode": "SW.VPGSL.OS.LNX64.CNTOS.0708.PGSQL.133.B050",
"engineVersion": "PostgreSQL 13.3",
"license": "PostgreSQL License",
"cloudPostgresqlPort": 15432,
"isHa": true,
"isMultiZone": true,
"isBackup": true,
"backupFileRetentionPeriod": 10,
"backupTime": "02:00",
"createDate": "2021-09-16T18:00:00+0900",
"accessControlGroupNoList": [],
"cloudPostgresqlServerInstanceList": [
{
"cloudPostgresqlServerName": "test-****-001-gcb",
"cloudPostgresqlServerRole": {
"code": "M",
"codeName": "Primary"
},
"cloudPostgresqlServerInstanceStatusName": "creating",
"cloudPostgresqlServerInstanceStatus": {
"code": "PEND",
"codeName": "CLOUD DATABASE(VPC) Server Pending State"
},
"cloudPostgresqlServerInstanceOperation": {
"code": "CREAT",
"codeName": "CLOUD DATABASE(VPC) Server Create OP"
},
"cloudPostgresqlProductCode": "SVR.VPGSL.DBSVR.STAND.C002.M004.NET.SSD.B050.G001",
"regionCode": "KR",
"zoneCode": "KR-1",
"vpcNo": "****87",
"subnetNo": "****49",
"isPublicSubnet": true,
"dataStorageType": {
"code": "SSD",
"codeName": "SSD"
},
"isStorageEncryption": true,
"dataStorageSize": 10737418240,
"cpuCount": 2,
"memorySize": 4294967296,
"createDate": "2021-09-16T18:00:00+0900"
},
{
"cloudPostgresqlServerName": "test-****-002-gcc",
"cloudPostgresqlServerRole": {
"code": "H",
"codeName": "Secondary"
},
"cloudPostgresqlServerInstanceStatusName": "creating",
"cloudPostgresqlServerInstanceStatus": {
"code": "PEND",
"codeName": "CLOUD DATABASE(VPC) Server Pending State"
},
"cloudPostgresqlServerInstanceOperation": {
"code": "CREAT",
"codeName": "CLOUD DATABASE(VPC) Server Create OP"
},
"cloudPostgresqlProductCode": "SVR.VPGSL.DBSVR.STAND.C002.M004.NET.SSD.B050.G001",
"regionCode": "KR",
"zoneCode": "KR-2",
"vpcNo": "****87",
"subnetNo": "****51",
"isPublicSubnet": true,
"dataStorageType": {
"code": "SSD",
"codeName": "SSD"
},
"isStorageEncryption": true,
"dataStorageSize": 10737418240,
"cpuCount": 2,
"memorySize": 4294967296,
"createDate": "2021-09-16T18:00:00+0900"
}
]
}
]
}
}
If the response shows that format type (responseFormatType) is xml
<createCloudPostgresqlInstanceResponse>
<requestId>9f76fa24-67a4-4cdf-bf70-f62f251d5138</requestId>
<returnCode>0</returnCode>
<returnMessage>success</returnMessage>
<totalRows>1</totalRows>
<cloudPostgresqlInstanceList>
<cloudPostgresqlInstance>
<cloudPostgresqlInstanceNo>****925</cloudPostgresqlInstanceNo>
<cloudPostgresqlServiceName>test-****</cloudPostgresqlServiceName>
<cloudPostgresqlInstanceStatusName>creating</cloudPostgresqlInstanceStatusName>
<cloudPostgresqlInstanceStatus>
<code>INIT</code>
<codeName>CLOUD DATABASE(VPC) Init State</codeName>
</cloudPostgresqlInstanceStatus>
<cloudPostgresqlInstanceOperation>
<code>CREAT</code>
<codeName>CLOUD DATABASE(VPC) Creat OP</codeName>
</cloudPostgresqlInstanceOperation>
<cloudPostgresqlImageProductCode>SW.VPGSL.OS.LNX64.CNTOS.0708.PGSQL.133.B050</cloudPostgresqlImageProductCode>
<engineVersion>PostgreSQL 13.3</engineVersion>
<license>PostgreSQL License</license>
<cloudPostgresqlPort>15432</cloudPostgresqlPort>
<isHa>true</isHa>
<isMultiZone>true</isMultiZone>
<isBackup>true</isBackup>
<backupFileRetentionPeriod>10</backupFileRetentionPeriod>
<backupTime>02:00</backupTime>
<createDate>2021-09-16T18:00:00+0900</createDate>
<accessControlGroupNoList/>
<cloudPostgresqlServerInstanceList>
<cloudPostgresqlServerInstance>
<cloudPostgresqlServerName>test-****-001-gcb</cloudPostgresqlServerName>
<cloudPostgresqlServerRole>
<code>M</code>
<codeName>Primary</codeName>
</cloudPostgresqlServerRole>
<cloudPostgresqlServerInstanceStatusName>creating</cloudPostgresqlServerInstanceStatusName>
<cloudPostgresqlServerInstanceStatus>
<code>PEND</code>
<codeName>CLOUD DATABASE(VPC) Server Pending State</codeName>
</cloudPostgresqlServerInstanceStatus>
<cloudPostgresqlServerInstanceOperation>
<code>CREAT</code>
<codeName>CLOUD DATABASE(VPC) Server Create OP</codeName>
</cloudPostgresqlServerInstanceOperation>
<cloudPostgresqlProductCode>SVR.VPGSL.DBSVR.STAND.C002.M004.NET.SSD.B050.G001</cloudPostgresqlProductCode>
<regionCode>KR</regionCode>
<zoneCode>KR-1</zoneCode>
<vpcNo>****87</vpcNo>
<subnetNo>****49</subnetNo>
<isPublicSubnet>true</isPublicSubnet>
<dataStorageType>
<code>SSD</code>
<codeName>SSD</codeName>
</dataStorageType>
<isStorageEncryption>true</isStorageEncryption>
<dataStorageSize>10737418240</dataStorageSize>
<cpuCount>2</cpuCount>
<memorySize>4294967296</memorySize>
<createDate>2021-09-16T18:00:00+0900</createDate>
</cloudPostgresqlServerInstance>
<cloudPostgresqlServerInstance>
<cloudPostgresqlServerName>test-****-002-gcc</cloudPostgresqlServerName>
<cloudPostgresqlServerRole>
<code>H</code>
<codeName>Secondary</codeName>
</cloudPostgresqlServerRole>
<cloudPostgresqlServerInstanceStatusName>creating</cloudPostgresqlServerInstanceStatusName>
<cloudPostgresqlServerInstanceStatus>
<code>PEND</code>
<codeName>CLOUD DATABASE(VPC) Server Pending State</codeName>
</cloudPostgresqlServerInstanceStatus>
<cloudPostgresqlServerInstanceOperation>
<code>CREAT</code>
<codeName>CLOUD DATABASE(VPC) Server Create OP</codeName>
</cloudPostgresqlServerInstanceOperation>
<cloudPostgresqlProductCode>SVR.VPGSL.DBSVR.STAND.C002.M004.NET.SSD.B050.G001</cloudPostgresqlProductCode>
<regionCode>KR</regionCode>
<zoneCode>KR-2</zoneCode>
<vpcNo>****87</vpcNo>
<subnetNo>****51</subnetNo>
<isPublicSubnet>true</isPublicSubnet>
<dataStorageType>
<code>SSD</code>
<codeName>SSD</codeName>
</dataStorageType>
<isStorageEncryption>true</isStorageEncryption>
<dataStorageSize>10737418240</dataStorageSize>
<cpuCount>2</cpuCount>
<memorySize>4294967296</memorySize>
<createDate>2021-09-16T18:00:00+0900</createDate>
</cloudPostgresqlServerInstance>
</cloudPostgresqlServerInstanceList>
</cloudPostgresqlInstance>
</cloudPostgresqlInstanceList>
</createCloudPostgresqlInstanceResponse>
Was this article helpful?