@googleapis/sqladmin 24.0.0 → 25.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/v1beta4.ts CHANGED
@@ -471,6 +471,10 @@ export namespace sqladmin_v1beta4 {
471
471
  * `SECOND_GEN`: Cloud SQL database instance. `EXTERNAL`: A database server that is not managed by Google. This property is read-only; use the `tier` property in the `settings` object to determine the database type.
472
472
  */
473
473
  backendType?: string | null;
474
+ /**
475
+ * Custom subject alternative names for the server certificate.
476
+ */
477
+ customSubjectAlternativeNames?: string[] | null;
474
478
  /**
475
479
  * The database engine type and version. The `databaseVersion` field cannot be changed after instance creation. MySQL instances: `MYSQL_8_0`, `MYSQL_5_7` (default), or `MYSQL_5_6`. PostgreSQL instances: `POSTGRES_9_6`, `POSTGRES_10`, `POSTGRES_11` or `POSTGRES_12` (default), `POSTGRES_13`, or `POSTGRES_14`. SQL Server instances: `SQLSERVER_2017_STANDARD` (default), `SQLSERVER_2017_ENTERPRISE`, `SQLSERVER_2017_EXPRESS`, `SQLSERVER_2017_WEB`, `SQLSERVER_2019_STANDARD`, `SQLSERVER_2019_ENTERPRISE`, `SQLSERVER_2019_EXPRESS`, or `SQLSERVER_2019_WEB`.
476
480
  */
@@ -680,7 +684,7 @@ export namespace sqladmin_v1beta4 {
680
684
  */
681
685
  replicaNames?: string[] | null;
682
686
  /**
683
- * A primary instance and disaster recovery (DR) replica pair. A DR replica is a cross-region replica that you designate for failover in the event that the primary instance experiences regional failure. Only applicable to MySQL.
687
+ * A primary instance and disaster recovery (DR) replica pair. A DR replica is a cross-region replica that you designate for failover in the event that the primary instance experiences regional failure. Applicable to MySQL and PostgreSQL.
684
688
  */
685
689
  replicationCluster?: Schema$ReplicationCluster;
686
690
  /**
@@ -735,6 +739,10 @@ export namespace sqladmin_v1beta4 {
735
739
  * Input only. Whether Cloud SQL is enabled to switch storing point-in-time recovery log files from a data disk to Cloud Storage.
736
740
  */
737
741
  switchTransactionLogsToCloudStorageEnabled?: boolean | null;
742
+ /**
743
+ * Optional. Input only. Immutable. Tag keys and tag values that are bound to this instance. You must represent each item in the map as: `"" : ""`. For example, a single resource can have the following tags: ``` "123/environment": "production", "123/costCenter": "marketing", ``` For more information on tag creation and management, see https://cloud.google.com/resource-manager/docs/tags/tags-overview.
744
+ */
745
+ tags?: {[key: string]: string} | null;
738
746
  /**
739
747
  * Output only. All database versions that are available for upgrade.
740
748
  */
@@ -904,6 +912,8 @@ export namespace sqladmin_v1beta4 {
904
912
  bakType?: string;
905
913
  copyOnly?: boolean;
906
914
  differentialBase?: boolean;
915
+ exportLogEndTime?: string;
916
+ exportLogStartTime?: string;
907
917
  stripeCount?: number;
908
918
  striped?: boolean;
909
919
  } | null;
@@ -949,6 +959,15 @@ export namespace sqladmin_v1beta4 {
949
959
  */
950
960
  uri?: string | null;
951
961
  }
962
+ /**
963
+ * The selected object that Cloud SQL migrates.
964
+ */
965
+ export interface Schema$ExternalSyncSelectedObject {
966
+ /**
967
+ * The name of the database that Cloud SQL migrates.
968
+ */
969
+ database?: string | null;
970
+ }
952
971
  /**
953
972
  * Database instance failover context.
954
973
  */
@@ -1279,6 +1298,27 @@ export namespace sqladmin_v1beta4 {
1279
1298
  */
1280
1299
  kind?: string | null;
1281
1300
  }
1301
+ /**
1302
+ * Instances ListServerCertificatess response.
1303
+ */
1304
+ export interface Schema$InstancesListServerCertificatesResponse {
1305
+ /**
1306
+ * The `sha1_fingerprint` of the active certificate from `server_certs`.
1307
+ */
1308
+ activeVersion?: string | null;
1309
+ /**
1310
+ * List of server CA certificates for the instance.
1311
+ */
1312
+ caCerts?: Schema$SslCert[];
1313
+ /**
1314
+ * This is always `sql#instancesListServerCertificates`.
1315
+ */
1316
+ kind?: string | null;
1317
+ /**
1318
+ * List of server certificates for the instance, signed by the corresponding CA from the `ca_certs` list.
1319
+ */
1320
+ serverCerts?: Schema$SslCert[];
1321
+ }
1282
1322
  /**
1283
1323
  * Database Instance reencrypt request.
1284
1324
  */
@@ -1306,6 +1346,15 @@ export namespace sqladmin_v1beta4 {
1306
1346
  */
1307
1347
  rotateServerCaContext?: Schema$RotateServerCaContext;
1308
1348
  }
1349
+ /**
1350
+ * Rotate Server Certificate request.
1351
+ */
1352
+ export interface Schema$InstancesRotateServerCertificateRequest {
1353
+ /**
1354
+ * Optional. Contains details about the rotate server CA operation.
1355
+ */
1356
+ rotateServerCertificateContext?: Schema$RotateServerCertificateContext;
1357
+ }
1309
1358
  /**
1310
1359
  * Instance truncate log request.
1311
1360
  */
@@ -1327,6 +1376,10 @@ export namespace sqladmin_v1beta4 {
1327
1376
  * The list of external networks that are allowed to connect to the instance using the IP. In 'CIDR' notation, also known as 'slash' notation (for example: `157.197.200.0/24`).
1328
1377
  */
1329
1378
  authorizedNetworks?: Schema$AclEntry[];
1379
+ /**
1380
+ * Optional. Custom Subject Alternative Name(SAN)s for a Cloud SQL instance.
1381
+ */
1382
+ customSubjectAlternativeNames?: string[] | null;
1330
1383
  /**
1331
1384
  * Controls connectivity to private IP instances from Google services, such as BigQuery.
1332
1385
  */
@@ -1351,6 +1404,10 @@ export namespace sqladmin_v1beta4 {
1351
1404
  * Specify what type of CA is used for the server certificate.
1352
1405
  */
1353
1406
  serverCaMode?: string | null;
1407
+ /**
1408
+ * Optional. The resource name of the server CA pool for an instance with `CUSTOMER_MANAGED_CAS_CA` as the `server_ca_mode`. Format: projects//locations//caPools/
1409
+ */
1410
+ serverCaPool?: string | null;
1354
1411
  /**
1355
1412
  * Specify how SSL/TLS is enforced in database connections. If you must use the `require_ssl` flag for backward compatibility, then only the following value pairs are valid: For PostgreSQL and MySQL: * `ssl_mode=ALLOW_UNENCRYPTED_AND_ENCRYPTED` and `require_ssl=false` * `ssl_mode=ENCRYPTED_ONLY` and `require_ssl=false` * `ssl_mode=TRUSTED_CLIENT_CERTIFICATE_REQUIRED` and `require_ssl=true` For SQL Server: * `ssl_mode=ALLOW_UNENCRYPTED_AND_ENCRYPTED` and `require_ssl=false` * `ssl_mode=ENCRYPTED_ONLY` and `require_ssl=true` The value of `ssl_mode` has priority over the value of `require_ssl`. For example, for the pair `ssl_mode=ENCRYPTED_ONLY` and `require_ssl=false`, `ssl_mode=ENCRYPTED_ONLY` means accept only SSL connections, while `require_ssl=false` means accept both non-SSL and SSL connections. In this case, MySQL and PostgreSQL databases respect `ssl_mode` and accepts only SSL connections.
1356
1413
  */
@@ -1505,10 +1562,18 @@ export namespace sqladmin_v1beta4 {
1505
1562
  * The password for connecting to on-premises instance.
1506
1563
  */
1507
1564
  password?: string | null;
1565
+ /**
1566
+ * Optional. A list of objects that the user selects for replication from an external source instance.
1567
+ */
1568
+ selectedObjects?: Schema$SelectedObjects[];
1508
1569
  /**
1509
1570
  * The reference to Cloud SQL instance if the source is Cloud SQL.
1510
1571
  */
1511
1572
  sourceInstance?: Schema$InstanceReference;
1573
+ /**
1574
+ * Optional. SslOption for replica connection to the on-premises source.
1575
+ */
1576
+ sslOption?: string | null;
1512
1577
  /**
1513
1578
  * The username for connecting to on-premises instance.
1514
1579
  */
@@ -1575,8 +1640,9 @@ export namespace sqladmin_v1beta4 {
1575
1640
  */
1576
1641
  status?: string | null;
1577
1642
  /**
1578
- * Name of the database instance related to this operation.
1643
+ * Optional. The sub operation based on the operation type.
1579
1644
  */
1645
+ subOperationType?: Schema$SqlSubOperationType;
1580
1646
  targetId?: string | null;
1581
1647
  targetLink?: string | null;
1582
1648
  /**
@@ -1627,7 +1693,7 @@ export namespace sqladmin_v1beta4 {
1627
1693
  */
1628
1694
  apiVersion?: string | null;
1629
1695
  /**
1630
- * Output only. Identifies whether the user has requested cancellation of the operation. Operations that have been cancelled successfully have Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.
1696
+ * Output only. Identifies whether the user has requested cancellation of the operation. Operations that have been cancelled successfully have google.longrunning.Operation.error value with a google.rpc.Status.code of `1`, corresponding to `Code.CANCELLED`.
1631
1697
  */
1632
1698
  cancelRequested?: boolean | null;
1633
1699
  /**
@@ -1723,6 +1789,31 @@ export namespace sqladmin_v1beta4 {
1723
1789
  */
1724
1790
  targetSizeGb?: string | null;
1725
1791
  }
1792
+ /**
1793
+ * Settings for an automatically-setup Private Service Connect consumer endpoint that is used to connect to a Cloud SQL instance.
1794
+ */
1795
+ export interface Schema$PscAutoConnectionConfig {
1796
+ /**
1797
+ * The consumer network of this consumer endpoint. This must be a resource path that includes both the host project and the network name. For example, `projects/project1/global/networks/network1`. The consumer host project of this network might be different from the consumer service project.
1798
+ */
1799
+ consumerNetwork?: string | null;
1800
+ /**
1801
+ * The connection policy status of the consumer network.
1802
+ */
1803
+ consumerNetworkStatus?: string | null;
1804
+ /**
1805
+ * This is the project ID of consumer service project of this consumer endpoint. Optional. This is only applicable if consumer_network is a shared vpc network.
1806
+ */
1807
+ consumerProject?: string | null;
1808
+ /**
1809
+ * The IP address of the consumer endpoint.
1810
+ */
1811
+ ipAddress?: string | null;
1812
+ /**
1813
+ * The connection status of the consumer endpoint.
1814
+ */
1815
+ status?: string | null;
1816
+ }
1726
1817
  /**
1727
1818
  * PSC settings for a Cloud SQL instance.
1728
1819
  */
@@ -1731,6 +1822,10 @@ export namespace sqladmin_v1beta4 {
1731
1822
  * Optional. The list of consumer projects that are allow-listed for PSC connections to this instance. This instance can be connected to with PSC from any network in these projects. Each consumer project in this list may be represented by a project number (numeric) or by a project id (alphanumeric).
1732
1823
  */
1733
1824
  allowedConsumerProjects?: string[] | null;
1825
+ /**
1826
+ * Optional. The list of settings for requested Private Service Connect consumer endpoints that can be used to connect to this Cloud SQL instance.
1827
+ */
1828
+ pscAutoConnections?: Schema$PscAutoConnectionConfig[];
1734
1829
  /**
1735
1830
  * Whether PSC connectivity is enabled for this instance.
1736
1831
  */
@@ -1758,7 +1853,7 @@ export namespace sqladmin_v1beta4 {
1758
1853
  mysqlReplicaConfiguration?: Schema$MySqlReplicaConfiguration;
1759
1854
  }
1760
1855
  /**
1761
- * A primary instance and disaster recovery (DR) replica pair. A DR replica is a cross-region replica that you designate for failover in the event that the primary instance has regional failure. Only applicable to MySQL.
1856
+ * A primary instance and disaster recovery (DR) replica pair. A DR replica is a cross-region replica that you designate for failover in the event that the primary instance has regional failure. Applicable to MySQL and PostgreSQL.
1762
1857
  */
1763
1858
  export interface Schema$ReplicationCluster {
1764
1859
  /**
@@ -1770,7 +1865,7 @@ export namespace sqladmin_v1beta4 {
1770
1865
  */
1771
1866
  failoverDrReplicaName?: string | null;
1772
1867
  /**
1773
- * Output only. If set, it indicates this instance has a private service access (PSA) dns endpoint that is pointing to the primary instance of the cluster. If this instance is the primary, the dns should be pointing to this instance. After Switchover or Replica failover, this DNS endpoint points to the promoted instance. This is a read-only field, returned to the user as information. This field can exist even if a standalone instance does not yet have a replica, or had a DR replica that was deleted.
1868
+ * Output only. If set, this field indicates this instance has a private service access (PSA) DNS endpoint that is pointing to the primary instance of the cluster. If this instance is the primary, then the DNS endpoint points to this instance. After a switchover or replica failover operation, this DNS endpoint points to the promoted instance. This is a read-only field, returned to the user as information. This field can exist even if a standalone instance doesn't have a DR replica yet or the DR replica is deleted.
1774
1869
  */
1775
1870
  psaWriteEndpoint?: string | null;
1776
1871
  }
@@ -1818,6 +1913,28 @@ export namespace sqladmin_v1beta4 {
1818
1913
  */
1819
1914
  nextVersion?: string | null;
1820
1915
  }
1916
+ /**
1917
+ * Instance rotate server certificate context.
1918
+ */
1919
+ export interface Schema$RotateServerCertificateContext {
1920
+ /**
1921
+ * Optional. This is always `sql#rotateServerCertificateContext`.
1922
+ */
1923
+ kind?: string | null;
1924
+ /**
1925
+ * Optional. The fingerprint of the next version to be rotated to. If left unspecified, will be rotated to the most recently added server certificate version.
1926
+ */
1927
+ nextVersion?: string | null;
1928
+ }
1929
+ /**
1930
+ * A list of objects that the user selects for replication from an external source instance.
1931
+ */
1932
+ export interface Schema$SelectedObjects {
1933
+ /**
1934
+ * Required. The name of the database to migrate.
1935
+ */
1936
+ database?: string | null;
1937
+ }
1821
1938
  /**
1822
1939
  * Database instance settings.
1823
1940
  */
@@ -1926,6 +2043,10 @@ export namespace sqladmin_v1beta4 {
1926
2043
  * The pricing plan for this instance. This can be either `PER_USE` or `PACKAGE`. Only `PER_USE` is supported for Second Generation instances.
1927
2044
  */
1928
2045
  pricingPlan?: string | null;
2046
+ /**
2047
+ * Optional. Configuration value for recreation of replica after certain replication lag
2048
+ */
2049
+ replicationLagMaxSeconds?: number | null;
1929
2050
  /**
1930
2051
  * The type of replication this instance uses. This can be either `ASYNCHRONOUS` or `SYNCHRONOUS`. (Deprecated) This property was only applicable to First Generation instances.
1931
2052
  */
@@ -2081,6 +2202,10 @@ export namespace sqladmin_v1beta4 {
2081
2202
  * Optional. MySQL-specific settings for start external sync.
2082
2203
  */
2083
2204
  mysqlSyncConfig?: Schema$MySqlSyncConfig;
2205
+ /**
2206
+ * Optional. Migrate only the specified objects from the source instance. If this field is empty, then migrate all objects.
2207
+ */
2208
+ selectedObjects?: Schema$ExternalSyncSelectedObject[];
2084
2209
  /**
2085
2210
  * External sync mode
2086
2211
  */
@@ -2193,6 +2318,15 @@ export namespace sqladmin_v1beta4 {
2193
2318
  */
2194
2319
  serverRoles?: string[] | null;
2195
2320
  }
2321
+ /**
2322
+ * The sub operation type based on the operation type.
2323
+ */
2324
+ export interface Schema$SqlSubOperationType {
2325
+ /**
2326
+ * The type of maintenance to be performed on the instance.
2327
+ */
2328
+ maintenanceType?: string | null;
2329
+ }
2196
2330
  /**
2197
2331
  * SslCerts Resource
2198
2332
  */
@@ -3935,7 +4069,7 @@ export namespace sqladmin_v1beta4 {
3935
4069
  }
3936
4070
 
3937
4071
  /**
3938
- * Add a new trusted Certificate Authority (CA) version for the specified instance. Required to prepare for a certificate rotation. If a CA version was previously added but never used in a certificate rotation, this operation replaces that version. There cannot be more than one CA version waiting to be rotated in. For instances that have enabled Certificate Authority Service (CAS) based server CA, please use AddServerCertificate to add a new server certificate.
4072
+ * Add a new trusted Certificate Authority (CA) version for the specified instance. Required to prepare for a certificate rotation. If a CA version was previously added but never used in a certificate rotation, this operation replaces that version. There cannot be more than one CA version waiting to be rotated in. For instances that have enabled Certificate Authority Service (CAS) based server CA, use AddServerCertificate to add a new server certificate.
3939
4073
  *
3940
4074
  * @param params - Parameters for request
3941
4075
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -4022,6 +4156,96 @@ export namespace sqladmin_v1beta4 {
4022
4156
  }
4023
4157
  }
4024
4158
 
4159
+ /**
4160
+ * Add a new trusted server certificate version for the specified instance using Certificate Authority Service (CAS) server CA. Required to prepare for a certificate rotation. If a server certificate version was previously added but never used in a certificate rotation, this operation replaces that version. There cannot be more than one certificate version waiting to be rotated in. For instances not using CAS server CA, use AddServerCa instead.
4161
+ *
4162
+ * @param params - Parameters for request
4163
+ * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
4164
+ * @param callback - Optional callback that handles the response.
4165
+ * @returns A promise if used with async/await, or void if used with a callback.
4166
+ */
4167
+ addServerCertificate(
4168
+ params: Params$Resource$Instances$Addservercertificate,
4169
+ options: StreamMethodOptions
4170
+ ): GaxiosPromise<Readable>;
4171
+ addServerCertificate(
4172
+ params?: Params$Resource$Instances$Addservercertificate,
4173
+ options?: MethodOptions
4174
+ ): GaxiosPromise<Schema$Operation>;
4175
+ addServerCertificate(
4176
+ params: Params$Resource$Instances$Addservercertificate,
4177
+ options: StreamMethodOptions | BodyResponseCallback<Readable>,
4178
+ callback: BodyResponseCallback<Readable>
4179
+ ): void;
4180
+ addServerCertificate(
4181
+ params: Params$Resource$Instances$Addservercertificate,
4182
+ options: MethodOptions | BodyResponseCallback<Schema$Operation>,
4183
+ callback: BodyResponseCallback<Schema$Operation>
4184
+ ): void;
4185
+ addServerCertificate(
4186
+ params: Params$Resource$Instances$Addservercertificate,
4187
+ callback: BodyResponseCallback<Schema$Operation>
4188
+ ): void;
4189
+ addServerCertificate(
4190
+ callback: BodyResponseCallback<Schema$Operation>
4191
+ ): void;
4192
+ addServerCertificate(
4193
+ paramsOrCallback?:
4194
+ | Params$Resource$Instances$Addservercertificate
4195
+ | BodyResponseCallback<Schema$Operation>
4196
+ | BodyResponseCallback<Readable>,
4197
+ optionsOrCallback?:
4198
+ | MethodOptions
4199
+ | StreamMethodOptions
4200
+ | BodyResponseCallback<Schema$Operation>
4201
+ | BodyResponseCallback<Readable>,
4202
+ callback?:
4203
+ | BodyResponseCallback<Schema$Operation>
4204
+ | BodyResponseCallback<Readable>
4205
+ ): void | GaxiosPromise<Schema$Operation> | GaxiosPromise<Readable> {
4206
+ let params = (paramsOrCallback ||
4207
+ {}) as Params$Resource$Instances$Addservercertificate;
4208
+ let options = (optionsOrCallback || {}) as MethodOptions;
4209
+
4210
+ if (typeof paramsOrCallback === 'function') {
4211
+ callback = paramsOrCallback;
4212
+ params = {} as Params$Resource$Instances$Addservercertificate;
4213
+ options = {};
4214
+ }
4215
+
4216
+ if (typeof optionsOrCallback === 'function') {
4217
+ callback = optionsOrCallback;
4218
+ options = {};
4219
+ }
4220
+
4221
+ const rootUrl = options.rootUrl || 'https://sqladmin.googleapis.com/';
4222
+ const parameters = {
4223
+ options: Object.assign(
4224
+ {
4225
+ url: (
4226
+ rootUrl +
4227
+ '/sql/v1beta4/projects/{project}/instances/{instance}/addServerCertificate'
4228
+ ).replace(/([^:]\/)\/+/g, '$1'),
4229
+ method: 'POST',
4230
+ apiVersion: '',
4231
+ },
4232
+ options
4233
+ ),
4234
+ params,
4235
+ requiredParams: ['project', 'instance'],
4236
+ pathParams: ['instance', 'project'],
4237
+ context: this.context,
4238
+ };
4239
+ if (callback) {
4240
+ createAPIRequest<Schema$Operation>(
4241
+ parameters,
4242
+ callback as BodyResponseCallback<unknown>
4243
+ );
4244
+ } else {
4245
+ return createAPIRequest<Schema$Operation>(parameters);
4246
+ }
4247
+ }
4248
+
4025
4249
  /**
4026
4250
  * Creates a Cloud SQL instance as a clone of the source instance. Using this operation might cause your instance to restart.
4027
4251
  *
@@ -4992,6 +5216,103 @@ export namespace sqladmin_v1beta4 {
4992
5216
  }
4993
5217
  }
4994
5218
 
5219
+ /**
5220
+ * Lists all versions of server certificates and certificate authorities (CAs) for the specified instance. There can be up to three sets of certs listed: the certificate that is currently in use, a future that has been added but not yet used to sign a certificate, and a certificate that has been rotated out. For instances not using Certificate Authority Service (CAS) server CA, use ListServerCas instead.
5221
+ *
5222
+ * @param params - Parameters for request
5223
+ * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
5224
+ * @param callback - Optional callback that handles the response.
5225
+ * @returns A promise if used with async/await, or void if used with a callback.
5226
+ */
5227
+ ListServerCertificates(
5228
+ params: Params$Resource$Instances$Listservercertificates,
5229
+ options: StreamMethodOptions
5230
+ ): GaxiosPromise<Readable>;
5231
+ ListServerCertificates(
5232
+ params?: Params$Resource$Instances$Listservercertificates,
5233
+ options?: MethodOptions
5234
+ ): GaxiosPromise<Schema$InstancesListServerCertificatesResponse>;
5235
+ ListServerCertificates(
5236
+ params: Params$Resource$Instances$Listservercertificates,
5237
+ options: StreamMethodOptions | BodyResponseCallback<Readable>,
5238
+ callback: BodyResponseCallback<Readable>
5239
+ ): void;
5240
+ ListServerCertificates(
5241
+ params: Params$Resource$Instances$Listservercertificates,
5242
+ options:
5243
+ | MethodOptions
5244
+ | BodyResponseCallback<Schema$InstancesListServerCertificatesResponse>,
5245
+ callback: BodyResponseCallback<Schema$InstancesListServerCertificatesResponse>
5246
+ ): void;
5247
+ ListServerCertificates(
5248
+ params: Params$Resource$Instances$Listservercertificates,
5249
+ callback: BodyResponseCallback<Schema$InstancesListServerCertificatesResponse>
5250
+ ): void;
5251
+ ListServerCertificates(
5252
+ callback: BodyResponseCallback<Schema$InstancesListServerCertificatesResponse>
5253
+ ): void;
5254
+ ListServerCertificates(
5255
+ paramsOrCallback?:
5256
+ | Params$Resource$Instances$Listservercertificates
5257
+ | BodyResponseCallback<Schema$InstancesListServerCertificatesResponse>
5258
+ | BodyResponseCallback<Readable>,
5259
+ optionsOrCallback?:
5260
+ | MethodOptions
5261
+ | StreamMethodOptions
5262
+ | BodyResponseCallback<Schema$InstancesListServerCertificatesResponse>
5263
+ | BodyResponseCallback<Readable>,
5264
+ callback?:
5265
+ | BodyResponseCallback<Schema$InstancesListServerCertificatesResponse>
5266
+ | BodyResponseCallback<Readable>
5267
+ ):
5268
+ | void
5269
+ | GaxiosPromise<Schema$InstancesListServerCertificatesResponse>
5270
+ | GaxiosPromise<Readable> {
5271
+ let params = (paramsOrCallback ||
5272
+ {}) as Params$Resource$Instances$Listservercertificates;
5273
+ let options = (optionsOrCallback || {}) as MethodOptions;
5274
+
5275
+ if (typeof paramsOrCallback === 'function') {
5276
+ callback = paramsOrCallback;
5277
+ params = {} as Params$Resource$Instances$Listservercertificates;
5278
+ options = {};
5279
+ }
5280
+
5281
+ if (typeof optionsOrCallback === 'function') {
5282
+ callback = optionsOrCallback;
5283
+ options = {};
5284
+ }
5285
+
5286
+ const rootUrl = options.rootUrl || 'https://sqladmin.googleapis.com/';
5287
+ const parameters = {
5288
+ options: Object.assign(
5289
+ {
5290
+ url: (
5291
+ rootUrl +
5292
+ '/sql/v1beta4/projects/{project}/instances/{instance}/listServerCertificates'
5293
+ ).replace(/([^:]\/)\/+/g, '$1'),
5294
+ method: 'GET',
5295
+ apiVersion: '',
5296
+ },
5297
+ options
5298
+ ),
5299
+ params,
5300
+ requiredParams: ['project', 'instance'],
5301
+ pathParams: ['instance', 'project'],
5302
+ context: this.context,
5303
+ };
5304
+ if (callback) {
5305
+ createAPIRequest<Schema$InstancesListServerCertificatesResponse>(
5306
+ parameters,
5307
+ callback as BodyResponseCallback<unknown>
5308
+ );
5309
+ } else {
5310
+ return createAPIRequest<Schema$InstancesListServerCertificatesResponse>(
5311
+ parameters
5312
+ );
5313
+ }
5314
+ }
5315
+
4995
5316
  /**
4996
5317
  * Partially updates settings of a Cloud SQL instance by merging the request with the current configuration. This method supports patch semantics.
4997
5318
  *
@@ -5616,7 +5937,7 @@ export namespace sqladmin_v1beta4 {
5616
5937
  }
5617
5938
 
5618
5939
  /**
5619
- * Rotates the server certificate to one signed by the Certificate Authority (CA) version previously added with the addServerCA method. For instances that have enabled Certificate Authority Service (CAS) based server CA, please use RotateServerCertificate to rotate the server certificate.
5940
+ * Rotates the server certificate to one signed by the Certificate Authority (CA) version previously added with the addServerCA method. For instances that have enabled Certificate Authority Service (CAS) based server CA, use RotateServerCertificate to rotate the server certificate.
5620
5941
  *
5621
5942
  * @param params - Parameters for request
5622
5943
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -5703,6 +6024,96 @@ export namespace sqladmin_v1beta4 {
5703
6024
  }
5704
6025
  }
5705
6026
 
6027
+ /**
6028
+ * Rotates the server certificate version to one previously added with the addServerCertificate method. For instances not using Certificate Authority Service (CAS) server CA, use RotateServerCa instead.
6029
+ *
6030
+ * @param params - Parameters for request
6031
+ * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
6032
+ * @param callback - Optional callback that handles the response.
6033
+ * @returns A promise if used with async/await, or void if used with a callback.
6034
+ */
6035
+ RotateServerCertificate(
6036
+ params: Params$Resource$Instances$Rotateservercertificate,
6037
+ options: StreamMethodOptions
6038
+ ): GaxiosPromise<Readable>;
6039
+ RotateServerCertificate(
6040
+ params?: Params$Resource$Instances$Rotateservercertificate,
6041
+ options?: MethodOptions
6042
+ ): GaxiosPromise<Schema$Operation>;
6043
+ RotateServerCertificate(
6044
+ params: Params$Resource$Instances$Rotateservercertificate,
6045
+ options: StreamMethodOptions | BodyResponseCallback<Readable>,
6046
+ callback: BodyResponseCallback<Readable>
6047
+ ): void;
6048
+ RotateServerCertificate(
6049
+ params: Params$Resource$Instances$Rotateservercertificate,
6050
+ options: MethodOptions | BodyResponseCallback<Schema$Operation>,
6051
+ callback: BodyResponseCallback<Schema$Operation>
6052
+ ): void;
6053
+ RotateServerCertificate(
6054
+ params: Params$Resource$Instances$Rotateservercertificate,
6055
+ callback: BodyResponseCallback<Schema$Operation>
6056
+ ): void;
6057
+ RotateServerCertificate(
6058
+ callback: BodyResponseCallback<Schema$Operation>
6059
+ ): void;
6060
+ RotateServerCertificate(
6061
+ paramsOrCallback?:
6062
+ | Params$Resource$Instances$Rotateservercertificate
6063
+ | BodyResponseCallback<Schema$Operation>
6064
+ | BodyResponseCallback<Readable>,
6065
+ optionsOrCallback?:
6066
+ | MethodOptions
6067
+ | StreamMethodOptions
6068
+ | BodyResponseCallback<Schema$Operation>
6069
+ | BodyResponseCallback<Readable>,
6070
+ callback?:
6071
+ | BodyResponseCallback<Schema$Operation>
6072
+ | BodyResponseCallback<Readable>
6073
+ ): void | GaxiosPromise<Schema$Operation> | GaxiosPromise<Readable> {
6074
+ let params = (paramsOrCallback ||
6075
+ {}) as Params$Resource$Instances$Rotateservercertificate;
6076
+ let options = (optionsOrCallback || {}) as MethodOptions;
6077
+
6078
+ if (typeof paramsOrCallback === 'function') {
6079
+ callback = paramsOrCallback;
6080
+ params = {} as Params$Resource$Instances$Rotateservercertificate;
6081
+ options = {};
6082
+ }
6083
+
6084
+ if (typeof optionsOrCallback === 'function') {
6085
+ callback = optionsOrCallback;
6086
+ options = {};
6087
+ }
6088
+
6089
+ const rootUrl = options.rootUrl || 'https://sqladmin.googleapis.com/';
6090
+ const parameters = {
6091
+ options: Object.assign(
6092
+ {
6093
+ url: (
6094
+ rootUrl +
6095
+ '/sql/v1beta4/projects/{project}/instances/{instance}/rotateServerCertificate'
6096
+ ).replace(/([^:]\/)\/+/g, '$1'),
6097
+ method: 'POST',
6098
+ apiVersion: '',
6099
+ },
6100
+ options
6101
+ ),
6102
+ params,
6103
+ requiredParams: ['project', 'instance'],
6104
+ pathParams: ['instance', 'project'],
6105
+ context: this.context,
6106
+ };
6107
+ if (callback) {
6108
+ createAPIRequest<Schema$Operation>(
6109
+ parameters,
6110
+ callback as BodyResponseCallback<unknown>
6111
+ );
6112
+ } else {
6113
+ return createAPIRequest<Schema$Operation>(parameters);
6114
+ }
6115
+ }
6116
+
5706
6117
  /**
5707
6118
  * Starts the replication in the read replica instance.
5708
6119
  *
@@ -5880,7 +6291,7 @@ export namespace sqladmin_v1beta4 {
5880
6291
  }
5881
6292
 
5882
6293
  /**
5883
- * Switches over from the primary instance to the designated DR replica instance.
6294
+ * Switches over from the primary instance to the DR replica instance.
5884
6295
  *
5885
6296
  * @param params - Parameters for request
5886
6297
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -6169,6 +6580,17 @@ export namespace sqladmin_v1beta4 {
6169
6580
  */
6170
6581
  project?: string;
6171
6582
  }
6583
+ export interface Params$Resource$Instances$Addservercertificate
6584
+ extends StandardParameters {
6585
+ /**
6586
+ * Required. Cloud SQL instance ID. This does not include the project ID.
6587
+ */
6588
+ instance?: string;
6589
+ /**
6590
+ * Required. Project ID of the project that contains the instance.
6591
+ */
6592
+ project?: string;
6593
+ }
6172
6594
  export interface Params$Resource$Instances$Clone extends StandardParameters {
6173
6595
  /**
6174
6596
  * The ID of the Cloud SQL instance to be cloned (source). This does not include the project ID.
@@ -6321,6 +6743,17 @@ export namespace sqladmin_v1beta4 {
6321
6743
  */
6322
6744
  project?: string;
6323
6745
  }
6746
+ export interface Params$Resource$Instances$Listservercertificates
6747
+ extends StandardParameters {
6748
+ /**
6749
+ * Required. Cloud SQL instance ID. This does not include the project ID.
6750
+ */
6751
+ instance?: string;
6752
+ /**
6753
+ * Required. Project ID of the project that contains the instance.
6754
+ */
6755
+ project?: string;
6756
+ }
6324
6757
  export interface Params$Resource$Instances$Patch extends StandardParameters {
6325
6758
  /**
6326
6759
  * Cloud SQL instance ID. This does not include the project ID.
@@ -6339,7 +6772,7 @@ export namespace sqladmin_v1beta4 {
6339
6772
  export interface Params$Resource$Instances$Promotereplica
6340
6773
  extends StandardParameters {
6341
6774
  /**
6342
- * Set to true to invoke a replica failover to the designated DR replica. As part of replica failover, the promote operation attempts to add the original primary instance as a replica of the promoted DR replica when the original primary instance comes back online. If set to false or not specified, then the original primary instance becomes an independent Cloud SQL primary instance. Only applicable to MySQL.
6775
+ * Set to true to invoke a replica failover to the DR replica. As part of replica failover, the promote operation attempts to add the original primary instance as a replica of the promoted DR replica when the original primary instance comes back online. If set to false or not specified, then the original primary instance becomes an independent Cloud SQL primary instance.
6343
6776
  */
6344
6777
  failover?: boolean;
6345
6778
  /**
@@ -6432,6 +6865,22 @@ export namespace sqladmin_v1beta4 {
6432
6865
  */
6433
6866
  requestBody?: Schema$InstancesRotateServerCaRequest;
6434
6867
  }
6868
+ export interface Params$Resource$Instances$Rotateservercertificate
6869
+ extends StandardParameters {
6870
+ /**
6871
+ * Required. Cloud SQL instance ID. This does not include the project ID.
6872
+ */
6873
+ instance?: string;
6874
+ /**
6875
+ * Required. Project ID of the project that contains the instance.
6876
+ */
6877
+ project?: string;
6878
+
6879
+ /**
6880
+ * Request body metadata
6881
+ */
6882
+ requestBody?: Schema$InstancesRotateServerCertificateRequest;
6883
+ }
6435
6884
  export interface Params$Resource$Instances$Startreplica
6436
6885
  extends StandardParameters {
6437
6886
  /**
@@ -6457,7 +6906,7 @@ export namespace sqladmin_v1beta4 {
6457
6906
  export interface Params$Resource$Instances$Switchover
6458
6907
  extends StandardParameters {
6459
6908
  /**
6460
- * Optional. (MySQL only) Cloud SQL instance operations timeout, which is a sum of all database operations. Default value is 10 minutes and can be modified to a maximum value of 24 hours.
6909
+ * Optional. (MySQL and PostgreSQL only) Cloud SQL instance operations timeout, which is a sum of all database operations. Default value is 10 minutes and can be modified to a maximum value of 24 hours.
6461
6910
  */
6462
6911
  dbTimeout?: string;
6463
6912
  /**