# Clusters

Everything about PostgreSQL clusters.

## List clusters

> Retrieves a list of PostgreSQL clusters.

```json
{"openapi":"3.0.3","info":{"title":"IONOS DBaaS PostgreSQL REST API","version":"1.0.0"},"tags":[{"name":"Clusters","description":"Everything about PostgreSQL clusters."}],"servers":[{"url":"https://api.ionos.com/databases/postgresql","description":"Production"}],"security":[{"basicAuth":[]},{"tokenAuth":[]}],"components":{"securitySchemes":{"basicAuth":{"type":"http","scheme":"basic","description":"You will need to base64 encode the string containing your credentials.\nSeparate your username and password with a colon, i.e.,\nusername:password and send it as 'Authorization' request header. More\ndetails: https://en.wikipedia.org/wiki/Basic_access_authentication.\n"},"tokenAuth":{"type":"apiKey","in":"header","name":"Authorization","description":"Please provide header value as 'Bearer <token>' and don't forget to add\n'Bearer' HTTP Authorization Scheme before the token.\n"}},"parameters":{"PaginationLimit":{"name":"limit","in":"query","description":"The maximum number of elements to return. Use together with 'offset' for pagination.","required":false,"schema":{"type":"integer","default":100,"maximum":1000,"minimum":1}},"PaginationOffset":{"name":"offset","in":"query","description":"The first element to return. Use together with 'limit' for pagination.","required":false,"schema":{"type":"integer","default":0}},"ClusterNameQuery":{"name":"filter.name","in":"query","description":"Response filter to list only the PostgreSQL clusters that contain\nthe specified name. The value is case insensitive and matched on the\n'displayName' field.\n","required":false,"schema":{"type":"string"}}},"schemas":{"ClusterList":{"description":"List of clusters.","allOf":[{"type":"object","properties":{"type":{"$ref":"#/components/schemas/ResourceType"},"id":{"$ref":"#/components/schemas/ResourceId"},"items":{"type":"array","items":{"$ref":"#/components/schemas/ClusterResponse"}}}},{"$ref":"#/components/schemas/DeprecatedPagination"}],"type":"object"},"ResourceType":{"description":"The type of the resource.","type":"string","enum":["collection","cluster","backup","user","database"]},"ResourceId":{"type":"string","description":"The unique ID of the resource."},"ClusterResponse":{"description":"A database cluster.","properties":{"type":{"allOf":[{"$ref":"#/components/schemas/ResourceType"}]},"id":{"$ref":"#/components/schemas/ResourceId"},"metadata":{"$ref":"#/components/schemas/ClusterMetadata"},"properties":{"$ref":"#/components/schemas/ClusterProperties"}},"type":"object"},"ClusterMetadata":{"description":"Metadata of the resource.","properties":{"createdDate":{"type":"string","format":"date-time","description":"The ISO 8601 creation timestamp."},"createdBy":{"type":"string"},"createdByUserId":{"type":"string"},"lastModifiedDate":{"type":"string","format":"date-time","description":"The ISO 8601 modified timestamp."},"lastModifiedBy":{"type":"string"},"lastModifiedByUserId":{"type":"string"},"state":{"$ref":"#/components/schemas/State"}}},"State":{"description":"The current status reported back by the cluster.","type":"string","enum":["AVAILABLE","BUSY","DESTROYING","DEGRADED","FAILED","UNKNOWN"]},"ClusterProperties":{"description":"Properties of a database cluster.","properties":{"displayName":{"$ref":"#/components/schemas/DisplayName"},"postgresVersion":{"$ref":"#/components/schemas/PostgresVersion"},"location":{"$ref":"#/components/schemas/Location"},"dnsName":{"$ref":"#/components/schemas/DNSName"},"backupLocation":{"$ref":"#/components/schemas/BackupLocation"},"instances":{"$ref":"#/components/schemas/Instances"},"ram":{"$ref":"#/components/schemas/Ram"},"cores":{"$ref":"#/components/schemas/Cores"},"storageSize":{"$ref":"#/components/schemas/StorageSize"},"storageType":{"$ref":"#/components/schemas/StorageType"},"connections":{"type":"array","minItems":1,"maxItems":1,"items":{"$ref":"#/components/schemas/Connection"}},"maintenanceWindow":{"$ref":"#/components/schemas/MaintenanceWindow"},"synchronizationMode":{"$ref":"#/components/schemas/SynchronizationMode"},"connectionPooler":{"$ref":"#/components/schemas/ConnectionPooler"}},"type":"object"},"DisplayName":{"type":"string","description":"The friendly name of your cluster."},"PostgresVersion":{"type":"string","description":"The PostgreSQL version of your cluster."},"Location":{"type":"string","description":"The physical location where the cluster will be created. This will be\nwhere all of your instances live. Property cannot be modified after\ndatacenter creation.\n"},"DNSName":{"type":"string","description":"The DNS name pointing to your cluster."},"BackupLocation":{"type":"string","description":"The S3 location where the backups will be stored."},"Instances":{"type":"integer","description":"The total number of instances in the cluster (one master and n-1\nstandbys).\n","minimum":1,"maximum":5},"Ram":{"type":"integer","description":"The amount of memory per instance in megabytes. Has to be a multiple of 1024.","multipleOf":1024,"minimum":4096},"Cores":{"type":"integer","description":"The number of CPU cores per instance.","minimum":1},"StorageSize":{"type":"integer","description":"The amount of storage per instance in megabytes.","minimum":10240,"maximum":2097152},"StorageType":{"description":"The storage type used in your cluster. (Value \"SSD\" is deprecated. Use the equivalent \"SSD Premium\" instead)","type":"string","enum":["HDD","SSD","SSD Standard","SSD Premium"]},"Connection":{"description":"Details about the network connection for your cluster.","properties":{"datacenterId":{"description":"The datacenter to connect your cluster to.","type":"string"},"lanId":{"description":"The numeric LAN ID to connect your cluster to.","type":"string"},"cidr":{"type":"string","description":"The IP and subnet for your cluster.\nNote the following unavailable IP ranges:\n10.233.64.0/18\n10.233.0.0/18\n10.233.114.0/24\n"}},"required":["datacenterId","lanId","cidr"],"type":"object"},"MaintenanceWindow":{"description":"A weekly 4 hour-long window, during which maintenance might occur.\n","properties":{"time":{"type":"string","description":"Start of the maintenance window in UTC time."},"dayOfTheWeek":{"$ref":"#/components/schemas/DayOfTheWeek"}},"required":["time","dayOfTheWeek"],"type":"object"},"DayOfTheWeek":{"description":"The name of the week day.","type":"string","enum":["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},"SynchronizationMode":{"description":"Represents different modes of replication.\nBe aware that the SYNCHRONOUS mode is deprecated and will be removed in future versions.\nExisting clusters will eventually be migrated to one of the supported modes.\n","type":"string","enum":["ASYNCHRONOUS","SYNCHRONOUS","STRICTLY_SYNCHRONOUS"]},"ConnectionPooler":{"description":"Configuration options for the connection pooler","properties":{"enabled":{"type":"boolean"},"poolMode":{"$ref":"#/components/schemas/PoolMode"}}},"PoolMode":{"description":"Represents different modes of connection pooling for the connection pooler.\n","type":"string","enum":["transaction","session"]},"DeprecatedPagination":{"description":"Pagination information in list responses. DEPRECATED because of misspelled _links attribute.","type":"object","properties":{"offset":{"$ref":"#/components/schemas/PaginationOffset"},"limit":{"$ref":"#/components/schemas/PaginationLimit"},"links":{"$ref":"#/components/schemas/PaginationLinks"}}},"PaginationOffset":{"description":"The offset specified in the request (if none was specified, the default\noffset is 0).\n","type":"integer","minimum":0,"default":0},"PaginationLimit":{"description":"The limit specified in the request (if none was specified, the default\nlimit is 100).\n","type":"integer","minimum":0,"default":100,"maximum":1000},"PaginationLinks":{"description":"URLs to navigate the different pages.\n","type":"object","properties":{"prev":{"description":"URL (with offset and limit parameters) of the previous page; only\npresent if offset is greater than 0.\n","type":"string","format":"uri","readOnly":true},"self":{"description":"URL (with offset and limit parameters) of the current page.\n","type":"string","format":"uri","readOnly":true},"next":{"description":"URL (with offset and limit parameters) of the next page; only\npresent if offset + limit is less than the total number of elements.\n","type":"string","format":"uri","readOnly":true}}},"ErrorResponse":{"properties":{"httpStatus":{"type":"integer","description":"The HTTP status code of the operation."},"messages":{"type":"array","items":{"$ref":"#/components/schemas/ErrorMessage"}}},"type":"object"},"ErrorMessage":{"properties":{"errorCode":{"type":"string","description":"Application internal error code\n"},"message":{"type":"string","description":"A human readable explanation specific to this occurrence of the\nproblem.\n"}},"type":"object"}},"responses":{"ApiError":{"description":"Any erroneous status code: 400 (parse error), 401 (auth error),\n402 (trial access), 403 (insufficient permissions), 404 (not found),\n405 (unsupported HTTP method), 415 (unsupported content type,\n422 (validation error), 429 (request rate limit exceeded),\n500 (server error), 503 (maintenance)\n","headers":{"Content-Type":{"description":"application/problem+json","schema":{"type":"string","default":"application/problem+json"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"paths":{"/clusters":{"get":{"operationId":"clustersGet","summary":"List clusters","description":"Retrieves a list of PostgreSQL clusters.","tags":["Clusters"],"parameters":[{"$ref":"#/components/parameters/PaginationLimit"},{"$ref":"#/components/parameters/PaginationOffset"},{"$ref":"#/components/parameters/ClusterNameQuery"}],"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterList"}}}},"default":{"$ref":"#/components/responses/ApiError"}}}}}}
```

## Create a cluster

> Creates a new PostgreSQL cluster.\
> If the \`fromBackup\` field is populated, the new cluster will be created\
> based on the given backup.<br>

```json
{"openapi":"3.0.3","info":{"title":"IONOS DBaaS PostgreSQL REST API","version":"1.0.0"},"tags":[{"name":"Clusters","description":"Everything about PostgreSQL clusters."}],"servers":[{"url":"https://api.ionos.com/databases/postgresql","description":"Production"}],"security":[{"basicAuth":[]},{"tokenAuth":[]}],"components":{"securitySchemes":{"basicAuth":{"type":"http","scheme":"basic","description":"You will need to base64 encode the string containing your credentials.\nSeparate your username and password with a colon, i.e.,\nusername:password and send it as 'Authorization' request header. More\ndetails: https://en.wikipedia.org/wiki/Basic_access_authentication.\n"},"tokenAuth":{"type":"apiKey","in":"header","name":"Authorization","description":"Please provide header value as 'Bearer <token>' and don't forget to add\n'Bearer' HTTP Authorization Scheme before the token.\n"}},"schemas":{"CreateClusterRequest":{"description":"Request payload with all data needed to create a new PostgreSQL cluster.\n","properties":{"metadata":{"$ref":"#/components/schemas/ClusterMetadata"},"properties":{"$ref":"#/components/schemas/CreateClusterProperties"}},"type":"object"},"ClusterMetadata":{"description":"Metadata of the resource.","properties":{"createdDate":{"type":"string","format":"date-time","description":"The ISO 8601 creation timestamp."},"createdBy":{"type":"string"},"createdByUserId":{"type":"string"},"lastModifiedDate":{"type":"string","format":"date-time","description":"The ISO 8601 modified timestamp."},"lastModifiedBy":{"type":"string"},"lastModifiedByUserId":{"type":"string"},"state":{"$ref":"#/components/schemas/State"}}},"State":{"description":"The current status reported back by the cluster.","type":"string","enum":["AVAILABLE","BUSY","DESTROYING","DEGRADED","FAILED","UNKNOWN"]},"CreateClusterProperties":{"description":"Properties with all data needed to create a new PostgreSQL cluster.\n","required":["postgresVersion","instances","cores","ram","storageSize","storageType","connections","location","displayName","credentials","synchronizationMode"],"properties":{"postgresVersion":{"$ref":"#/components/schemas/PostgresVersion"},"instances":{"$ref":"#/components/schemas/Instances"},"cores":{"$ref":"#/components/schemas/Cores"},"ram":{"$ref":"#/components/schemas/Ram"},"storageSize":{"$ref":"#/components/schemas/StorageSize"},"storageType":{"$ref":"#/components/schemas/StorageType"},"connections":{"type":"array","minItems":1,"maxItems":1,"items":{"$ref":"#/components/schemas/Connection"}},"location":{"$ref":"#/components/schemas/Location"},"backupLocation":{"$ref":"#/components/schemas/BackupLocation"},"displayName":{"$ref":"#/components/schemas/DisplayName"},"maintenanceWindow":{"$ref":"#/components/schemas/MaintenanceWindow"},"credentials":{"$ref":"#/components/schemas/DBUser"},"synchronizationMode":{"$ref":"#/components/schemas/CreateSynchronizationMode"},"fromBackup":{"$ref":"#/components/schemas/CreateRestoreRequest"},"connectionPooler":{"$ref":"#/components/schemas/ConnectionPooler"}},"type":"object"},"PostgresVersion":{"type":"string","description":"The PostgreSQL version of your cluster."},"Instances":{"type":"integer","description":"The total number of instances in the cluster (one master and n-1\nstandbys).\n","minimum":1,"maximum":5},"Cores":{"type":"integer","description":"The number of CPU cores per instance.","minimum":1},"Ram":{"type":"integer","description":"The amount of memory per instance in megabytes. Has to be a multiple of 1024.","multipleOf":1024,"minimum":4096},"StorageSize":{"type":"integer","description":"The amount of storage per instance in megabytes.","minimum":10240,"maximum":2097152},"StorageType":{"description":"The storage type used in your cluster. (Value \"SSD\" is deprecated. Use the equivalent \"SSD Premium\" instead)","type":"string","enum":["HDD","SSD","SSD Standard","SSD Premium"]},"Connection":{"description":"Details about the network connection for your cluster.","properties":{"datacenterId":{"description":"The datacenter to connect your cluster to.","type":"string"},"lanId":{"description":"The numeric LAN ID to connect your cluster to.","type":"string"},"cidr":{"type":"string","description":"The IP and subnet for your cluster.\nNote the following unavailable IP ranges:\n10.233.64.0/18\n10.233.0.0/18\n10.233.114.0/24\n"}},"required":["datacenterId","lanId","cidr"],"type":"object"},"Location":{"type":"string","description":"The physical location where the cluster will be created. This will be\nwhere all of your instances live. Property cannot be modified after\ndatacenter creation.\n"},"BackupLocation":{"type":"string","description":"The S3 location where the backups will be stored."},"DisplayName":{"type":"string","description":"The friendly name of your cluster."},"MaintenanceWindow":{"description":"A weekly 4 hour-long window, during which maintenance might occur.\n","properties":{"time":{"type":"string","description":"Start of the maintenance window in UTC time."},"dayOfTheWeek":{"$ref":"#/components/schemas/DayOfTheWeek"}},"required":["time","dayOfTheWeek"],"type":"object"},"DayOfTheWeek":{"description":"The name of the week day.","type":"string","enum":["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},"DBUser":{"description":"Credentials for the database user to be created.","properties":{"username":{"type":"string","description":"The username for the initial PostgreSQL user. Some system usernames\nare restricted (e.g. \"postgres\", \"admin\", \"standby\").\n"},"password":{"type":"string","minLength":10}},"required":["username","password"],"type":"object"},"CreateSynchronizationMode":{"description":"Represents the supported replication modes when creating a cluster.\nThe SYNCHRONOUS mode is deprecated and cannot be used in create requests.\nIt may still appear on existing clusters via the SynchronizationMode response schema.\nYou may update your cluster to one of the supported modes yourself.\nElse, it will eventually be migrated to one of the supported modes.\n","type":"string","enum":["ASYNCHRONOUS","STRICTLY_SYNCHRONOUS"]},"CreateRestoreRequest":{"description":"The restore request.","properties":{"backupId":{"type":"string","description":"The unique ID of the backup you want to restore."},"recoveryTargetTime":{"type":"string","format":"date-time","description":"If this value is supplied as ISO 8601 timestamp, the backup will be\nreplayed up until the given timestamp. If empty, the backup will be\napplied completely.\n"}},"required":["backupId"],"type":"object"},"ConnectionPooler":{"description":"Configuration options for the connection pooler","properties":{"enabled":{"type":"boolean"},"poolMode":{"$ref":"#/components/schemas/PoolMode"}}},"PoolMode":{"description":"Represents different modes of connection pooling for the connection pooler.\n","type":"string","enum":["transaction","session"]},"ClusterResponse":{"description":"A database cluster.","properties":{"type":{"allOf":[{"$ref":"#/components/schemas/ResourceType"}]},"id":{"$ref":"#/components/schemas/ResourceId"},"metadata":{"$ref":"#/components/schemas/ClusterMetadata"},"properties":{"$ref":"#/components/schemas/ClusterProperties"}},"type":"object"},"ResourceType":{"description":"The type of the resource.","type":"string","enum":["collection","cluster","backup","user","database"]},"ResourceId":{"type":"string","description":"The unique ID of the resource."},"ClusterProperties":{"description":"Properties of a database cluster.","properties":{"displayName":{"$ref":"#/components/schemas/DisplayName"},"postgresVersion":{"$ref":"#/components/schemas/PostgresVersion"},"location":{"$ref":"#/components/schemas/Location"},"dnsName":{"$ref":"#/components/schemas/DNSName"},"backupLocation":{"$ref":"#/components/schemas/BackupLocation"},"instances":{"$ref":"#/components/schemas/Instances"},"ram":{"$ref":"#/components/schemas/Ram"},"cores":{"$ref":"#/components/schemas/Cores"},"storageSize":{"$ref":"#/components/schemas/StorageSize"},"storageType":{"$ref":"#/components/schemas/StorageType"},"connections":{"type":"array","minItems":1,"maxItems":1,"items":{"$ref":"#/components/schemas/Connection"}},"maintenanceWindow":{"$ref":"#/components/schemas/MaintenanceWindow"},"synchronizationMode":{"$ref":"#/components/schemas/SynchronizationMode"},"connectionPooler":{"$ref":"#/components/schemas/ConnectionPooler"}},"type":"object"},"DNSName":{"type":"string","description":"The DNS name pointing to your cluster."},"SynchronizationMode":{"description":"Represents different modes of replication.\nBe aware that the SYNCHRONOUS mode is deprecated and will be removed in future versions.\nExisting clusters will eventually be migrated to one of the supported modes.\n","type":"string","enum":["ASYNCHRONOUS","SYNCHRONOUS","STRICTLY_SYNCHRONOUS"]},"ErrorResponse":{"properties":{"httpStatus":{"type":"integer","description":"The HTTP status code of the operation."},"messages":{"type":"array","items":{"$ref":"#/components/schemas/ErrorMessage"}}},"type":"object"},"ErrorMessage":{"properties":{"errorCode":{"type":"string","description":"Application internal error code\n"},"message":{"type":"string","description":"A human readable explanation specific to this occurrence of the\nproblem.\n"}},"type":"object"}},"responses":{"ApiError":{"description":"Any erroneous status code: 400 (parse error), 401 (auth error),\n402 (trial access), 403 (insufficient permissions), 404 (not found),\n405 (unsupported HTTP method), 415 (unsupported content type,\n422 (validation error), 429 (request rate limit exceeded),\n500 (server error), 503 (maintenance)\n","headers":{"Content-Type":{"description":"application/problem+json","schema":{"type":"string","default":"application/problem+json"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"paths":{"/clusters":{"post":{"operationId":"clustersPost","summary":"Create a cluster","description":"Creates a new PostgreSQL cluster.\nIf the `fromBackup` field is populated, the new cluster will be created\nbased on the given backup.\n","tags":["Clusters"],"requestBody":{"description":"The cluster to be created.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateClusterRequest"}}},"required":true},"responses":{"200":{"description":"The created cluster is returned with `metadata.state` set to \"BUSY\".\n","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterResponse"}}}},"default":{"$ref":"#/components/responses/ApiError"}}}}}}
```

## Fetch a cluster

> You can retrieve a PostgreSQL cluster by using its ID. This value can be\
> found in the response body when a PostgreSQL cluster is created or when\
> you GET a list of PostgreSQL clusters.<br>

```json
{"openapi":"3.0.3","info":{"title":"IONOS DBaaS PostgreSQL REST API","version":"1.0.0"},"tags":[{"name":"Clusters","description":"Everything about PostgreSQL clusters."}],"servers":[{"url":"https://api.ionos.com/databases/postgresql","description":"Production"}],"security":[{"basicAuth":[]},{"tokenAuth":[]}],"components":{"securitySchemes":{"basicAuth":{"type":"http","scheme":"basic","description":"You will need to base64 encode the string containing your credentials.\nSeparate your username and password with a colon, i.e.,\nusername:password and send it as 'Authorization' request header. More\ndetails: https://en.wikipedia.org/wiki/Basic_access_authentication.\n"},"tokenAuth":{"type":"apiKey","in":"header","name":"Authorization","description":"Please provide header value as 'Bearer <token>' and don't forget to add\n'Bearer' HTTP Authorization Scheme before the token.\n"}},"parameters":{"ClusterIdPath":{"name":"clusterId","in":"path","description":"The unique ID of the cluster.","required":true,"schema":{"type":"string"}}},"schemas":{"ClusterResponse":{"description":"A database cluster.","properties":{"type":{"allOf":[{"$ref":"#/components/schemas/ResourceType"}]},"id":{"$ref":"#/components/schemas/ResourceId"},"metadata":{"$ref":"#/components/schemas/ClusterMetadata"},"properties":{"$ref":"#/components/schemas/ClusterProperties"}},"type":"object"},"ResourceType":{"description":"The type of the resource.","type":"string","enum":["collection","cluster","backup","user","database"]},"ResourceId":{"type":"string","description":"The unique ID of the resource."},"ClusterMetadata":{"description":"Metadata of the resource.","properties":{"createdDate":{"type":"string","format":"date-time","description":"The ISO 8601 creation timestamp."},"createdBy":{"type":"string"},"createdByUserId":{"type":"string"},"lastModifiedDate":{"type":"string","format":"date-time","description":"The ISO 8601 modified timestamp."},"lastModifiedBy":{"type":"string"},"lastModifiedByUserId":{"type":"string"},"state":{"$ref":"#/components/schemas/State"}}},"State":{"description":"The current status reported back by the cluster.","type":"string","enum":["AVAILABLE","BUSY","DESTROYING","DEGRADED","FAILED","UNKNOWN"]},"ClusterProperties":{"description":"Properties of a database cluster.","properties":{"displayName":{"$ref":"#/components/schemas/DisplayName"},"postgresVersion":{"$ref":"#/components/schemas/PostgresVersion"},"location":{"$ref":"#/components/schemas/Location"},"dnsName":{"$ref":"#/components/schemas/DNSName"},"backupLocation":{"$ref":"#/components/schemas/BackupLocation"},"instances":{"$ref":"#/components/schemas/Instances"},"ram":{"$ref":"#/components/schemas/Ram"},"cores":{"$ref":"#/components/schemas/Cores"},"storageSize":{"$ref":"#/components/schemas/StorageSize"},"storageType":{"$ref":"#/components/schemas/StorageType"},"connections":{"type":"array","minItems":1,"maxItems":1,"items":{"$ref":"#/components/schemas/Connection"}},"maintenanceWindow":{"$ref":"#/components/schemas/MaintenanceWindow"},"synchronizationMode":{"$ref":"#/components/schemas/SynchronizationMode"},"connectionPooler":{"$ref":"#/components/schemas/ConnectionPooler"}},"type":"object"},"DisplayName":{"type":"string","description":"The friendly name of your cluster."},"PostgresVersion":{"type":"string","description":"The PostgreSQL version of your cluster."},"Location":{"type":"string","description":"The physical location where the cluster will be created. This will be\nwhere all of your instances live. Property cannot be modified after\ndatacenter creation.\n"},"DNSName":{"type":"string","description":"The DNS name pointing to your cluster."},"BackupLocation":{"type":"string","description":"The S3 location where the backups will be stored."},"Instances":{"type":"integer","description":"The total number of instances in the cluster (one master and n-1\nstandbys).\n","minimum":1,"maximum":5},"Ram":{"type":"integer","description":"The amount of memory per instance in megabytes. Has to be a multiple of 1024.","multipleOf":1024,"minimum":4096},"Cores":{"type":"integer","description":"The number of CPU cores per instance.","minimum":1},"StorageSize":{"type":"integer","description":"The amount of storage per instance in megabytes.","minimum":10240,"maximum":2097152},"StorageType":{"description":"The storage type used in your cluster. (Value \"SSD\" is deprecated. Use the equivalent \"SSD Premium\" instead)","type":"string","enum":["HDD","SSD","SSD Standard","SSD Premium"]},"Connection":{"description":"Details about the network connection for your cluster.","properties":{"datacenterId":{"description":"The datacenter to connect your cluster to.","type":"string"},"lanId":{"description":"The numeric LAN ID to connect your cluster to.","type":"string"},"cidr":{"type":"string","description":"The IP and subnet for your cluster.\nNote the following unavailable IP ranges:\n10.233.64.0/18\n10.233.0.0/18\n10.233.114.0/24\n"}},"required":["datacenterId","lanId","cidr"],"type":"object"},"MaintenanceWindow":{"description":"A weekly 4 hour-long window, during which maintenance might occur.\n","properties":{"time":{"type":"string","description":"Start of the maintenance window in UTC time."},"dayOfTheWeek":{"$ref":"#/components/schemas/DayOfTheWeek"}},"required":["time","dayOfTheWeek"],"type":"object"},"DayOfTheWeek":{"description":"The name of the week day.","type":"string","enum":["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},"SynchronizationMode":{"description":"Represents different modes of replication.\nBe aware that the SYNCHRONOUS mode is deprecated and will be removed in future versions.\nExisting clusters will eventually be migrated to one of the supported modes.\n","type":"string","enum":["ASYNCHRONOUS","SYNCHRONOUS","STRICTLY_SYNCHRONOUS"]},"ConnectionPooler":{"description":"Configuration options for the connection pooler","properties":{"enabled":{"type":"boolean"},"poolMode":{"$ref":"#/components/schemas/PoolMode"}}},"PoolMode":{"description":"Represents different modes of connection pooling for the connection pooler.\n","type":"string","enum":["transaction","session"]},"ErrorResponse":{"properties":{"httpStatus":{"type":"integer","description":"The HTTP status code of the operation."},"messages":{"type":"array","items":{"$ref":"#/components/schemas/ErrorMessage"}}},"type":"object"},"ErrorMessage":{"properties":{"errorCode":{"type":"string","description":"Application internal error code\n"},"message":{"type":"string","description":"A human readable explanation specific to this occurrence of the\nproblem.\n"}},"type":"object"}},"responses":{"ApiError":{"description":"Any erroneous status code: 400 (parse error), 401 (auth error),\n402 (trial access), 403 (insufficient permissions), 404 (not found),\n405 (unsupported HTTP method), 415 (unsupported content type,\n422 (validation error), 429 (request rate limit exceeded),\n500 (server error), 503 (maintenance)\n","headers":{"Content-Type":{"description":"application/problem+json","schema":{"type":"string","default":"application/problem+json"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"paths":{"/clusters/{clusterId}":{"get":{"operationId":"clustersFindById","summary":"Fetch a cluster","description":"You can retrieve a PostgreSQL cluster by using its ID. This value can be\nfound in the response body when a PostgreSQL cluster is created or when\nyou GET a list of PostgreSQL clusters.\n","tags":["Clusters"],"parameters":[{"$ref":"#/components/parameters/ClusterIdPath"}],"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterResponse"}}}},"default":{"$ref":"#/components/responses/ApiError"}}}}}}
```

## Delete a cluster

> Delete a PostgreSQL cluster.

```json
{"openapi":"3.0.3","info":{"title":"IONOS DBaaS PostgreSQL REST API","version":"1.0.0"},"tags":[{"name":"Clusters","description":"Everything about PostgreSQL clusters."}],"servers":[{"url":"https://api.ionos.com/databases/postgresql","description":"Production"}],"security":[{"basicAuth":[]},{"tokenAuth":[]}],"components":{"securitySchemes":{"basicAuth":{"type":"http","scheme":"basic","description":"You will need to base64 encode the string containing your credentials.\nSeparate your username and password with a colon, i.e.,\nusername:password and send it as 'Authorization' request header. More\ndetails: https://en.wikipedia.org/wiki/Basic_access_authentication.\n"},"tokenAuth":{"type":"apiKey","in":"header","name":"Authorization","description":"Please provide header value as 'Bearer <token>' and don't forget to add\n'Bearer' HTTP Authorization Scheme before the token.\n"}},"parameters":{"ClusterIdPath":{"name":"clusterId","in":"path","description":"The unique ID of the cluster.","required":true,"schema":{"type":"string"}}},"schemas":{"ClusterResponse":{"description":"A database cluster.","properties":{"type":{"allOf":[{"$ref":"#/components/schemas/ResourceType"}]},"id":{"$ref":"#/components/schemas/ResourceId"},"metadata":{"$ref":"#/components/schemas/ClusterMetadata"},"properties":{"$ref":"#/components/schemas/ClusterProperties"}},"type":"object"},"ResourceType":{"description":"The type of the resource.","type":"string","enum":["collection","cluster","backup","user","database"]},"ResourceId":{"type":"string","description":"The unique ID of the resource."},"ClusterMetadata":{"description":"Metadata of the resource.","properties":{"createdDate":{"type":"string","format":"date-time","description":"The ISO 8601 creation timestamp."},"createdBy":{"type":"string"},"createdByUserId":{"type":"string"},"lastModifiedDate":{"type":"string","format":"date-time","description":"The ISO 8601 modified timestamp."},"lastModifiedBy":{"type":"string"},"lastModifiedByUserId":{"type":"string"},"state":{"$ref":"#/components/schemas/State"}}},"State":{"description":"The current status reported back by the cluster.","type":"string","enum":["AVAILABLE","BUSY","DESTROYING","DEGRADED","FAILED","UNKNOWN"]},"ClusterProperties":{"description":"Properties of a database cluster.","properties":{"displayName":{"$ref":"#/components/schemas/DisplayName"},"postgresVersion":{"$ref":"#/components/schemas/PostgresVersion"},"location":{"$ref":"#/components/schemas/Location"},"dnsName":{"$ref":"#/components/schemas/DNSName"},"backupLocation":{"$ref":"#/components/schemas/BackupLocation"},"instances":{"$ref":"#/components/schemas/Instances"},"ram":{"$ref":"#/components/schemas/Ram"},"cores":{"$ref":"#/components/schemas/Cores"},"storageSize":{"$ref":"#/components/schemas/StorageSize"},"storageType":{"$ref":"#/components/schemas/StorageType"},"connections":{"type":"array","minItems":1,"maxItems":1,"items":{"$ref":"#/components/schemas/Connection"}},"maintenanceWindow":{"$ref":"#/components/schemas/MaintenanceWindow"},"synchronizationMode":{"$ref":"#/components/schemas/SynchronizationMode"},"connectionPooler":{"$ref":"#/components/schemas/ConnectionPooler"}},"type":"object"},"DisplayName":{"type":"string","description":"The friendly name of your cluster."},"PostgresVersion":{"type":"string","description":"The PostgreSQL version of your cluster."},"Location":{"type":"string","description":"The physical location where the cluster will be created. This will be\nwhere all of your instances live. Property cannot be modified after\ndatacenter creation.\n"},"DNSName":{"type":"string","description":"The DNS name pointing to your cluster."},"BackupLocation":{"type":"string","description":"The S3 location where the backups will be stored."},"Instances":{"type":"integer","description":"The total number of instances in the cluster (one master and n-1\nstandbys).\n","minimum":1,"maximum":5},"Ram":{"type":"integer","description":"The amount of memory per instance in megabytes. Has to be a multiple of 1024.","multipleOf":1024,"minimum":4096},"Cores":{"type":"integer","description":"The number of CPU cores per instance.","minimum":1},"StorageSize":{"type":"integer","description":"The amount of storage per instance in megabytes.","minimum":10240,"maximum":2097152},"StorageType":{"description":"The storage type used in your cluster. (Value \"SSD\" is deprecated. Use the equivalent \"SSD Premium\" instead)","type":"string","enum":["HDD","SSD","SSD Standard","SSD Premium"]},"Connection":{"description":"Details about the network connection for your cluster.","properties":{"datacenterId":{"description":"The datacenter to connect your cluster to.","type":"string"},"lanId":{"description":"The numeric LAN ID to connect your cluster to.","type":"string"},"cidr":{"type":"string","description":"The IP and subnet for your cluster.\nNote the following unavailable IP ranges:\n10.233.64.0/18\n10.233.0.0/18\n10.233.114.0/24\n"}},"required":["datacenterId","lanId","cidr"],"type":"object"},"MaintenanceWindow":{"description":"A weekly 4 hour-long window, during which maintenance might occur.\n","properties":{"time":{"type":"string","description":"Start of the maintenance window in UTC time."},"dayOfTheWeek":{"$ref":"#/components/schemas/DayOfTheWeek"}},"required":["time","dayOfTheWeek"],"type":"object"},"DayOfTheWeek":{"description":"The name of the week day.","type":"string","enum":["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},"SynchronizationMode":{"description":"Represents different modes of replication.\nBe aware that the SYNCHRONOUS mode is deprecated and will be removed in future versions.\nExisting clusters will eventually be migrated to one of the supported modes.\n","type":"string","enum":["ASYNCHRONOUS","SYNCHRONOUS","STRICTLY_SYNCHRONOUS"]},"ConnectionPooler":{"description":"Configuration options for the connection pooler","properties":{"enabled":{"type":"boolean"},"poolMode":{"$ref":"#/components/schemas/PoolMode"}}},"PoolMode":{"description":"Represents different modes of connection pooling for the connection pooler.\n","type":"string","enum":["transaction","session"]},"ErrorResponse":{"properties":{"httpStatus":{"type":"integer","description":"The HTTP status code of the operation."},"messages":{"type":"array","items":{"$ref":"#/components/schemas/ErrorMessage"}}},"type":"object"},"ErrorMessage":{"properties":{"errorCode":{"type":"string","description":"Application internal error code\n"},"message":{"type":"string","description":"A human readable explanation specific to this occurrence of the\nproblem.\n"}},"type":"object"}},"responses":{"ApiError":{"description":"Any erroneous status code: 400 (parse error), 401 (auth error),\n402 (trial access), 403 (insufficient permissions), 404 (not found),\n405 (unsupported HTTP method), 415 (unsupported content type,\n422 (validation error), 429 (request rate limit exceeded),\n500 (server error), 503 (maintenance)\n","headers":{"Content-Type":{"description":"application/problem+json","schema":{"type":"string","default":"application/problem+json"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"paths":{"/clusters/{clusterId}":{"delete":{"operationId":"clustersDelete","summary":"Delete a cluster","description":"Delete a PostgreSQL cluster.","tags":["Clusters"],"parameters":[{"$ref":"#/components/parameters/ClusterIdPath"}],"responses":{"200":{"description":"The deleted cluster with `metadata.state` set to \"DESTROYING\".\n","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterResponse"}}}},"default":{"$ref":"#/components/responses/ApiError"}}}}}}
```

## Patch a cluster

> Patch attributes of a PostgreSQL cluster.

```json
{"openapi":"3.0.3","info":{"title":"IONOS DBaaS PostgreSQL REST API","version":"1.0.0"},"tags":[{"name":"Clusters","description":"Everything about PostgreSQL clusters."}],"servers":[{"url":"https://api.ionos.com/databases/postgresql","description":"Production"}],"security":[{"basicAuth":[]},{"tokenAuth":[]}],"components":{"securitySchemes":{"basicAuth":{"type":"http","scheme":"basic","description":"You will need to base64 encode the string containing your credentials.\nSeparate your username and password with a colon, i.e.,\nusername:password and send it as 'Authorization' request header. More\ndetails: https://en.wikipedia.org/wiki/Basic_access_authentication.\n"},"tokenAuth":{"type":"apiKey","in":"header","name":"Authorization","description":"Please provide header value as 'Bearer <token>' and don't forget to add\n'Bearer' HTTP Authorization Scheme before the token.\n"}},"parameters":{"ClusterIdPath":{"name":"clusterId","in":"path","description":"The unique ID of the cluster.","required":true,"schema":{"type":"string"}}},"schemas":{"PatchClusterRequest":{"description":"Request payload to change a cluster.","properties":{"metadata":{"$ref":"#/components/schemas/ClusterMetadata"},"properties":{"$ref":"#/components/schemas/PatchClusterProperties"}},"type":"object"},"ClusterMetadata":{"description":"Metadata of the resource.","properties":{"createdDate":{"type":"string","format":"date-time","description":"The ISO 8601 creation timestamp."},"createdBy":{"type":"string"},"createdByUserId":{"type":"string"},"lastModifiedDate":{"type":"string","format":"date-time","description":"The ISO 8601 modified timestamp."},"lastModifiedBy":{"type":"string"},"lastModifiedByUserId":{"type":"string"},"state":{"$ref":"#/components/schemas/State"}}},"State":{"description":"The current status reported back by the cluster.","type":"string","enum":["AVAILABLE","BUSY","DESTROYING","DEGRADED","FAILED","UNKNOWN"]},"PatchClusterProperties":{"description":"Properties of the payload to change a cluster.","properties":{"cores":{"$ref":"#/components/schemas/Cores"},"ram":{"$ref":"#/components/schemas/Ram"},"storageSize":{"$ref":"#/components/schemas/StorageSize"},"connections":{"type":"array","minItems":0,"maxItems":1,"items":{"$ref":"#/components/schemas/Connection"}},"displayName":{"$ref":"#/components/schemas/DisplayName"},"maintenanceWindow":{"$ref":"#/components/schemas/MaintenanceWindow"},"postgresVersion":{"$ref":"#/components/schemas/PostgresVersion"},"instances":{"$ref":"#/components/schemas/Instances"},"connectionPooler":{"$ref":"#/components/schemas/ConnectionPooler"},"synchronizationMode":{"$ref":"#/components/schemas/SynchronizationMode"}},"type":"object"},"Cores":{"type":"integer","description":"The number of CPU cores per instance.","minimum":1},"Ram":{"type":"integer","description":"The amount of memory per instance in megabytes. Has to be a multiple of 1024.","multipleOf":1024,"minimum":4096},"StorageSize":{"type":"integer","description":"The amount of storage per instance in megabytes.","minimum":10240,"maximum":2097152},"Connection":{"description":"Details about the network connection for your cluster.","properties":{"datacenterId":{"description":"The datacenter to connect your cluster to.","type":"string"},"lanId":{"description":"The numeric LAN ID to connect your cluster to.","type":"string"},"cidr":{"type":"string","description":"The IP and subnet for your cluster.\nNote the following unavailable IP ranges:\n10.233.64.0/18\n10.233.0.0/18\n10.233.114.0/24\n"}},"required":["datacenterId","lanId","cidr"],"type":"object"},"DisplayName":{"type":"string","description":"The friendly name of your cluster."},"MaintenanceWindow":{"description":"A weekly 4 hour-long window, during which maintenance might occur.\n","properties":{"time":{"type":"string","description":"Start of the maintenance window in UTC time."},"dayOfTheWeek":{"$ref":"#/components/schemas/DayOfTheWeek"}},"required":["time","dayOfTheWeek"],"type":"object"},"DayOfTheWeek":{"description":"The name of the week day.","type":"string","enum":["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},"PostgresVersion":{"type":"string","description":"The PostgreSQL version of your cluster."},"Instances":{"type":"integer","description":"The total number of instances in the cluster (one master and n-1\nstandbys).\n","minimum":1,"maximum":5},"ConnectionPooler":{"description":"Configuration options for the connection pooler","properties":{"enabled":{"type":"boolean"},"poolMode":{"$ref":"#/components/schemas/PoolMode"}}},"PoolMode":{"description":"Represents different modes of connection pooling for the connection pooler.\n","type":"string","enum":["transaction","session"]},"SynchronizationMode":{"description":"Represents different modes of replication.\nBe aware that the SYNCHRONOUS mode is deprecated and will be removed in future versions.\nExisting clusters will eventually be migrated to one of the supported modes.\n","type":"string","enum":["ASYNCHRONOUS","SYNCHRONOUS","STRICTLY_SYNCHRONOUS"]},"ClusterResponse":{"description":"A database cluster.","properties":{"type":{"allOf":[{"$ref":"#/components/schemas/ResourceType"}]},"id":{"$ref":"#/components/schemas/ResourceId"},"metadata":{"$ref":"#/components/schemas/ClusterMetadata"},"properties":{"$ref":"#/components/schemas/ClusterProperties"}},"type":"object"},"ResourceType":{"description":"The type of the resource.","type":"string","enum":["collection","cluster","backup","user","database"]},"ResourceId":{"type":"string","description":"The unique ID of the resource."},"ClusterProperties":{"description":"Properties of a database cluster.","properties":{"displayName":{"$ref":"#/components/schemas/DisplayName"},"postgresVersion":{"$ref":"#/components/schemas/PostgresVersion"},"location":{"$ref":"#/components/schemas/Location"},"dnsName":{"$ref":"#/components/schemas/DNSName"},"backupLocation":{"$ref":"#/components/schemas/BackupLocation"},"instances":{"$ref":"#/components/schemas/Instances"},"ram":{"$ref":"#/components/schemas/Ram"},"cores":{"$ref":"#/components/schemas/Cores"},"storageSize":{"$ref":"#/components/schemas/StorageSize"},"storageType":{"$ref":"#/components/schemas/StorageType"},"connections":{"type":"array","minItems":1,"maxItems":1,"items":{"$ref":"#/components/schemas/Connection"}},"maintenanceWindow":{"$ref":"#/components/schemas/MaintenanceWindow"},"synchronizationMode":{"$ref":"#/components/schemas/SynchronizationMode"},"connectionPooler":{"$ref":"#/components/schemas/ConnectionPooler"}},"type":"object"},"Location":{"type":"string","description":"The physical location where the cluster will be created. This will be\nwhere all of your instances live. Property cannot be modified after\ndatacenter creation.\n"},"DNSName":{"type":"string","description":"The DNS name pointing to your cluster."},"BackupLocation":{"type":"string","description":"The S3 location where the backups will be stored."},"StorageType":{"description":"The storage type used in your cluster. (Value \"SSD\" is deprecated. Use the equivalent \"SSD Premium\" instead)","type":"string","enum":["HDD","SSD","SSD Standard","SSD Premium"]},"ErrorResponse":{"properties":{"httpStatus":{"type":"integer","description":"The HTTP status code of the operation."},"messages":{"type":"array","items":{"$ref":"#/components/schemas/ErrorMessage"}}},"type":"object"},"ErrorMessage":{"properties":{"errorCode":{"type":"string","description":"Application internal error code\n"},"message":{"type":"string","description":"A human readable explanation specific to this occurrence of the\nproblem.\n"}},"type":"object"}},"responses":{"ApiError":{"description":"Any erroneous status code: 400 (parse error), 401 (auth error),\n402 (trial access), 403 (insufficient permissions), 404 (not found),\n405 (unsupported HTTP method), 415 (unsupported content type,\n422 (validation error), 429 (request rate limit exceeded),\n500 (server error), 503 (maintenance)\n","headers":{"Content-Type":{"description":"application/problem+json","schema":{"type":"string","default":"application/problem+json"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"paths":{"/clusters/{clusterId}":{"patch":{"operationId":"clustersPatch","summary":"Patch a cluster","description":"Patch attributes of a PostgreSQL cluster.","tags":["Clusters"],"parameters":[{"$ref":"#/components/parameters/ClusterIdPath"}],"requestBody":{"description":"Part of the cluster which should be modified.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatchClusterRequest"}}},"required":true},"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterResponse"}}}},"default":{"$ref":"#/components/responses/ApiError"}}}}}}
```

## List all PostgreSQL versions

> Retrieves a list of all available PostgreSQL versions.

```json
{"openapi":"3.0.3","info":{"title":"IONOS DBaaS PostgreSQL REST API","version":"1.0.0"},"tags":[{"name":"Clusters","description":"Everything about PostgreSQL clusters."}],"servers":[{"url":"https://api.ionos.com/databases/postgresql","description":"Production"}],"security":[{"basicAuth":[]},{"tokenAuth":[]}],"components":{"securitySchemes":{"basicAuth":{"type":"http","scheme":"basic","description":"You will need to base64 encode the string containing your credentials.\nSeparate your username and password with a colon, i.e.,\nusername:password and send it as 'Authorization' request header. More\ndetails: https://en.wikipedia.org/wiki/Basic_access_authentication.\n"},"tokenAuth":{"type":"apiKey","in":"header","name":"Authorization","description":"Please provide header value as 'Bearer <token>' and don't forget to add\n'Bearer' HTTP Authorization Scheme before the token.\n"}},"schemas":{"PostgresVersionList":{"description":"List of PostgreSQL versions.","properties":{"data":{"type":"array","items":{"properties":{"name":{"type":"string"}},"type":"object"}}},"type":"object"},"ErrorResponse":{"properties":{"httpStatus":{"type":"integer","description":"The HTTP status code of the operation."},"messages":{"type":"array","items":{"$ref":"#/components/schemas/ErrorMessage"}}},"type":"object"},"ErrorMessage":{"properties":{"errorCode":{"type":"string","description":"Application internal error code\n"},"message":{"type":"string","description":"A human readable explanation specific to this occurrence of the\nproblem.\n"}},"type":"object"}},"responses":{"ApiError":{"description":"Any erroneous status code: 400 (parse error), 401 (auth error),\n402 (trial access), 403 (insufficient permissions), 404 (not found),\n405 (unsupported HTTP method), 415 (unsupported content type,\n422 (validation error), 429 (request rate limit exceeded),\n500 (server error), 503 (maintenance)\n","headers":{"Content-Type":{"description":"application/problem+json","schema":{"type":"string","default":"application/problem+json"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"paths":{"/clusters/postgresversions":{"get":{"operationId":"postgresVersionsGet","summary":"List all PostgreSQL versions","description":"Retrieves a list of all available PostgreSQL versions.","deprecated":true,"tags":["Clusters"],"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PostgresVersionList"}}}},"default":{"$ref":"#/components/responses/ApiError"}}}}}}
```

## Supported PostgreSQL versions of cluster

> Retrieves a list of all PostgreSQL versions available for this cluster.

```json
{"openapi":"3.0.3","info":{"title":"IONOS DBaaS PostgreSQL REST API","version":"1.0.0"},"tags":[{"name":"Clusters","description":"Everything about PostgreSQL clusters."}],"servers":[{"url":"https://api.ionos.com/databases/postgresql","description":"Production"}],"security":[{"basicAuth":[]},{"tokenAuth":[]}],"components":{"securitySchemes":{"basicAuth":{"type":"http","scheme":"basic","description":"You will need to base64 encode the string containing your credentials.\nSeparate your username and password with a colon, i.e.,\nusername:password and send it as 'Authorization' request header. More\ndetails: https://en.wikipedia.org/wiki/Basic_access_authentication.\n"},"tokenAuth":{"type":"apiKey","in":"header","name":"Authorization","description":"Please provide header value as 'Bearer <token>' and don't forget to add\n'Bearer' HTTP Authorization Scheme before the token.\n"}},"parameters":{"ClusterIdPath":{"name":"clusterId","in":"path","description":"The unique ID of the cluster.","required":true,"schema":{"type":"string"}}},"schemas":{"PostgresVersionList":{"description":"List of PostgreSQL versions.","properties":{"data":{"type":"array","items":{"properties":{"name":{"type":"string"}},"type":"object"}}},"type":"object"},"ErrorResponse":{"properties":{"httpStatus":{"type":"integer","description":"The HTTP status code of the operation."},"messages":{"type":"array","items":{"$ref":"#/components/schemas/ErrorMessage"}}},"type":"object"},"ErrorMessage":{"properties":{"errorCode":{"type":"string","description":"Application internal error code\n"},"message":{"type":"string","description":"A human readable explanation specific to this occurrence of the\nproblem.\n"}},"type":"object"}},"responses":{"ApiError":{"description":"Any erroneous status code: 400 (parse error), 401 (auth error),\n402 (trial access), 403 (insufficient permissions), 404 (not found),\n405 (unsupported HTTP method), 415 (unsupported content type,\n422 (validation error), 429 (request rate limit exceeded),\n500 (server error), 503 (maintenance)\n","headers":{"Content-Type":{"description":"application/problem+json","schema":{"type":"string","default":"application/problem+json"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"paths":{"/clusters/{clusterId}/versions":{"get":{"operationId":"clustersVersionsGet","summary":"Supported PostgreSQL versions of cluster","description":"Retrieves a list of all PostgreSQL versions available for this cluster.","tags":["Clusters"],"parameters":[{"$ref":"#/components/parameters/ClusterIdPath"}],"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PostgresVersionList"}}}},"default":{"$ref":"#/components/responses/ApiError"}}}}}}
```

## List PostgreSQL versions

> Retrieves a list of all PostgreSQL versions available for this cluster\
> including the current version.<br>

```json
{"openapi":"3.0.3","info":{"title":"IONOS DBaaS PostgreSQL REST API","version":"1.0.0"},"tags":[{"name":"Clusters","description":"Everything about PostgreSQL clusters."}],"servers":[{"url":"https://api.ionos.com/databases/postgresql","description":"Production"}],"security":[{"basicAuth":[]},{"tokenAuth":[]}],"components":{"securitySchemes":{"basicAuth":{"type":"http","scheme":"basic","description":"You will need to base64 encode the string containing your credentials.\nSeparate your username and password with a colon, i.e.,\nusername:password and send it as 'Authorization' request header. More\ndetails: https://en.wikipedia.org/wiki/Basic_access_authentication.\n"},"tokenAuth":{"type":"apiKey","in":"header","name":"Authorization","description":"Please provide header value as 'Bearer <token>' and don't forget to add\n'Bearer' HTTP Authorization Scheme before the token.\n"}},"parameters":{"ClusterIdPath":{"name":"clusterId","in":"path","description":"The unique ID of the cluster.","required":true,"schema":{"type":"string"}}},"schemas":{"PostgresVersionList":{"description":"List of PostgreSQL versions.","properties":{"data":{"type":"array","items":{"properties":{"name":{"type":"string"}},"type":"object"}}},"type":"object"},"ErrorResponse":{"properties":{"httpStatus":{"type":"integer","description":"The HTTP status code of the operation."},"messages":{"type":"array","items":{"$ref":"#/components/schemas/ErrorMessage"}}},"type":"object"},"ErrorMessage":{"properties":{"errorCode":{"type":"string","description":"Application internal error code\n"},"message":{"type":"string","description":"A human readable explanation specific to this occurrence of the\nproblem.\n"}},"type":"object"}},"responses":{"ApiError":{"description":"Any erroneous status code: 400 (parse error), 401 (auth error),\n402 (trial access), 403 (insufficient permissions), 404 (not found),\n405 (unsupported HTTP method), 415 (unsupported content type,\n422 (validation error), 429 (request rate limit exceeded),\n500 (server error), 503 (maintenance)\n","headers":{"Content-Type":{"description":"application/problem+json","schema":{"type":"string","default":"application/problem+json"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"paths":{"/clusters/{clusterId}/postgresversions":{"get":{"operationId":"clusterPostgresVersionsGet","summary":"List PostgreSQL versions","description":"Retrieves a list of all PostgreSQL versions available for this cluster\nincluding the current version.\n","deprecated":true,"tags":["Clusters"],"parameters":[{"$ref":"#/components/parameters/ClusterIdPath"}],"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PostgresVersionList"}}}},"default":{"$ref":"#/components/responses/ApiError"}}}}}}
```
