@maxim_mazurok/gapi.client.sqladmin-v1 0.0.20231017 → 0.0.20231029

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/index.d.ts CHANGED
@@ -9,7 +9,7 @@
9
9
  // This file was generated by https://github.com/Maxim-Mazurok/google-api-typings-generator. Please do not edit it manually.
10
10
  // In case of any problems please post issue to https://github.com/Maxim-Mazurok/google-api-typings-generator
11
11
  // Generated from: https://sqladmin.googleapis.com/$discovery/rest?version=v1
12
- // Revision: 20231017
12
+ // Revision: 20231029
13
13
 
14
14
  /// <reference types="gapi.client" />
15
15
 
@@ -449,6 +449,14 @@ declare namespace gapi.client {
449
449
  dataCacheEnabled?:
450
450
  boolean;
451
451
  }
452
+ interface DemoteContext {
453
+ /** This is always `sql#demoteContext`. */
454
+ kind?:
455
+ string;
456
+ /** Required. The name of the instance which acts as the on-premises primary instance in the replication setup. */
457
+ sourceRepresentativeInstanceName?:
458
+ string;
459
+ }
452
460
  interface DemoteMasterConfiguration {
453
461
  /** This is always `sql#demoteMasterConfiguration`. */
454
462
  kind?:
@@ -832,6 +840,11 @@ declare namespace gapi.client {
832
840
  demoteMasterContext?:
833
841
  DemoteMasterContext;
834
842
  }
843
+ interface InstancesDemoteRequest {
844
+ /** Required. Contains details about the demote operation. */
845
+ demoteContext?:
846
+ DemoteContext;
847
+ }
835
848
  interface InstancesExportRequest {
836
849
  /** Contains details about the export operation. */
837
850
  exportContext?:
@@ -2686,6 +2699,93 @@ declare namespace gapi.client {
2686
2699
  uploadType?:
2687
2700
  string;
2688
2701
  }): Request<Operation>;
2702
+ /** Demotes an existing standalone instance to be a Cloud SQL read replica for an external database server. */
2703
+ demote(request: {
2704
+ /** V1 error format. */
2705
+ "$.xgafv"?:
2706
+ string;
2707
+ /** OAuth access token. */
2708
+ access_token?:
2709
+ string;
2710
+ /** Data format for response. */
2711
+ alt?:
2712
+ string;
2713
+ /** JSONP */
2714
+ callback?:
2715
+ string;
2716
+ /** Selector specifying which fields to include in a partial response. */
2717
+ fields?:
2718
+ string;
2719
+ /** Required. Cloud SQL instance name. */
2720
+ instance:
2721
+ string;
2722
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
2723
+ key?:
2724
+ string;
2725
+ /** OAuth 2.0 token for the current user. */
2726
+ oauth_token?:
2727
+ string;
2728
+ /** Returns response with indentations and line breaks. */
2729
+ prettyPrint?:
2730
+ boolean;
2731
+ /** Required. ID of the project that contains the instance. */
2732
+ project:
2733
+ string;
2734
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
2735
+ quotaUser?:
2736
+ string;
2737
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
2738
+ upload_protocol?:
2739
+ string;
2740
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
2741
+ uploadType?:
2742
+ string;
2743
+ /** Request body */
2744
+ resource:
2745
+ InstancesDemoteRequest;
2746
+ }): Request<Operation>;
2747
+ demote(request: {
2748
+ /** V1 error format. */
2749
+ "$.xgafv"?:
2750
+ string;
2751
+ /** OAuth access token. */
2752
+ access_token?:
2753
+ string;
2754
+ /** Data format for response. */
2755
+ alt?:
2756
+ string;
2757
+ /** JSONP */
2758
+ callback?:
2759
+ string;
2760
+ /** Selector specifying which fields to include in a partial response. */
2761
+ fields?:
2762
+ string;
2763
+ /** Required. Cloud SQL instance name. */
2764
+ instance:
2765
+ string;
2766
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
2767
+ key?:
2768
+ string;
2769
+ /** OAuth 2.0 token for the current user. */
2770
+ oauth_token?:
2771
+ string;
2772
+ /** Returns response with indentations and line breaks. */
2773
+ prettyPrint?:
2774
+ boolean;
2775
+ /** Required. ID of the project that contains the instance. */
2776
+ project:
2777
+ string;
2778
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
2779
+ quotaUser?:
2780
+ string;
2781
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
2782
+ upload_protocol?:
2783
+ string;
2784
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
2785
+ uploadType?:
2786
+ string;
2787
+ },
2788
+ body: InstancesDemoteRequest): Request<Operation>;
2689
2789
  /** Demotes the stand-alone instance to be a Cloud SQL read replica for an external database server. */
2690
2790
  demoteMaster(request: {
2691
2791
  /** V1 error format. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maxim_mazurok/gapi.client.sqladmin-v1",
3
- "version": "0.0.20231017",
3
+ "version": "0.0.20231029",
4
4
  "description": "TypeScript typings for Cloud SQL Admin API v1",
5
5
  "license": "MIT",
6
6
  "author": {
package/readme.md CHANGED
@@ -149,6 +149,11 @@ Deletes a Cloud SQL instance.
149
149
  */
150
150
  await gapi.client.sql.instances.delete({ instance: "instance", project: "project", });
151
151
 
152
+ /*
153
+ Demotes an existing standalone instance to be a Cloud SQL read replica for an external database server.
154
+ */
155
+ await gapi.client.sql.instances.demote({ instance: "instance", project: "project", });
156
+
152
157
  /*
153
158
  Demotes the stand-alone instance to be a Cloud SQL read replica for an external database server.
154
159
  */
package/tests.ts CHANGED
@@ -3,7 +3,7 @@
3
3
  // This file was generated by https://github.com/Maxim-Mazurok/google-api-typings-generator. Please do not edit it manually.
4
4
  // In case of any problems please post issue to https://github.com/Maxim-Mazurok/google-api-typings-generator
5
5
 
6
- // Revision: 20231017
6
+ // Revision: 20231029
7
7
 
8
8
  gapi.load('client', async () => {
9
9
  /** now we can use gapi.client */
@@ -214,6 +214,16 @@ gapi.load('client', async () => {
214
214
  instance: "Test string",
215
215
  project: "Test string",
216
216
  });
217
+ /** Demotes an existing standalone instance to be a Cloud SQL read replica for an external database server. */
218
+ await gapi.client.sql.instances.demote({
219
+ instance: "Test string",
220
+ project: "Test string",
221
+ }, {
222
+ demoteContext: {
223
+ kind: "Test string",
224
+ sourceRepresentativeInstanceName: "Test string",
225
+ },
226
+ });
217
227
  /** Demotes the stand-alone instance to be a Cloud SQL read replica for an external database server. */
218
228
  await gapi.client.sql.instances.demoteMaster({
219
229
  instance: "Test string",