@googleapis/servicenetworking 21.7.0 → 23.1.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/v1beta.ts CHANGED
@@ -23,7 +23,7 @@ import {
23
23
  Compute,
24
24
  UserRefreshClient,
25
25
  BaseExternalAccountClient,
26
- GaxiosPromise,
26
+ GaxiosResponseWithHTTP2,
27
27
  GoogleConfigurable,
28
28
  createAPIRequest,
29
29
  MethodOptions,
@@ -239,7 +239,7 @@ export namespace servicenetworking_v1beta {
239
239
  */
240
240
  kind?: string | null;
241
241
  /**
242
- * Content of the configuration. The underlying schema should be defined by Aspect owners as protobuf message under `apiserving/configaspects/proto`.
242
+ * Content of the configuration. The underlying schema should be defined by Aspect owners as protobuf message under `google/api/configaspects/proto`.
243
243
  */
244
244
  spec?: {[key: string]: any} | null;
245
245
  }
@@ -374,6 +374,73 @@ export namespace servicenetworking_v1beta {
374
374
  */
375
375
  selector?: string | null;
376
376
  }
377
+ /**
378
+ * `BatchingConfigProto` defines the batching configuration for an API method.
379
+ */
380
+ export interface Schema$BatchingConfigProto {
381
+ /**
382
+ * The request and response fields used in batching.
383
+ */
384
+ batchDescriptor?: Schema$BatchingDescriptorProto;
385
+ /**
386
+ * The thresholds which trigger a batched request to be sent.
387
+ */
388
+ thresholds?: Schema$BatchingSettingsProto;
389
+ }
390
+ /**
391
+ * `BatchingDescriptorProto` specifies the fields of the request message to be used for batching, and, optionally, the fields of the response message to be used for demultiplexing.
392
+ */
393
+ export interface Schema$BatchingDescriptorProto {
394
+ /**
395
+ * The repeated field in the request message to be aggregated by batching.
396
+ */
397
+ batchedField?: string | null;
398
+ /**
399
+ * A list of the fields in the request message. Two requests will be batched together only if the values of every field specified in `request_discriminator_fields` is equal between the two requests.
400
+ */
401
+ discriminatorFields?: string[] | null;
402
+ /**
403
+ * Optional. When present, indicates the field in the response message to be used to demultiplex the response into multiple response messages, in correspondence with the multiple request messages originally batched together.
404
+ */
405
+ subresponseField?: string | null;
406
+ }
407
+ /**
408
+ * `BatchingSettingsProto` specifies a set of batching thresholds, each of which acts as a trigger to send a batch of messages as a request. At least one threshold must be positive nonzero.
409
+ */
410
+ export interface Schema$BatchingSettingsProto {
411
+ /**
412
+ * The duration after which a batch should be sent, starting from the addition of the first message to that batch.
413
+ */
414
+ delayThreshold?: string | null;
415
+ /**
416
+ * The maximum number of elements collected in a batch that could be accepted by server.
417
+ */
418
+ elementCountLimit?: number | null;
419
+ /**
420
+ * The number of elements of a field collected into a batch which, if exceeded, causes the batch to be sent.
421
+ */
422
+ elementCountThreshold?: number | null;
423
+ /**
424
+ * The maximum size of data allowed by flow control.
425
+ */
426
+ flowControlByteLimit?: number | null;
427
+ /**
428
+ * The maximum number of elements allowed by flow control.
429
+ */
430
+ flowControlElementLimit?: number | null;
431
+ /**
432
+ * The behavior to take when the flow control limit is exceeded.
433
+ */
434
+ flowControlLimitExceededBehavior?: string | null;
435
+ /**
436
+ * The maximum size of the request that could be accepted by server.
437
+ */
438
+ requestByteLimit?: number | null;
439
+ /**
440
+ * The aggregated size of the batched field which, if exceeded, causes the batch to be sent. This size is computed by aggregating the sizes of the request field to be batched, not of the entire request message.
441
+ */
442
+ requestByteThreshold?: string | null;
443
+ }
377
444
  /**
378
445
  * Billing related configuration of the service. The following example shows how to configure monitored resources and metrics for billing, `consumer_destinations` is the only supported destination and the monitored resources need at least one label key `cloud.googleapis.com/location` to indicate the location of the billing usage, using different monitored resources between monitoring and billing is recommended so they can be evolved independently: monitored_resources: - type: library.googleapis.com/billing_branch labels: - key: cloud.googleapis.com/location description: | Predefined label to support billing location restriction. - key: city description: | Custom label to define the city where the library branch is located in. - key: name description: Custom label to define the name of the library branch. metrics: - name: library.googleapis.com/book/borrowed_count metric_kind: DELTA value_type: INT64 unit: "1" billing: consumer_destinations: - monitored_resource: library.googleapis.com/billing_branch metrics: - library.googleapis.com/book/borrowed_count
379
446
  */
@@ -396,6 +463,10 @@ export namespace servicenetworking_v1beta {
396
463
  */
397
464
  monitoredResource?: string | null;
398
465
  }
466
+ /**
467
+ * Metadata provided through GetOperation request for the LRO generated by Cleanup Connection API
468
+ */
469
+ export interface Schema$CleanupConnectionMetadata {}
399
470
  /**
400
471
  * Details about how and where to publish client libraries.
401
472
  */
@@ -450,15 +521,15 @@ export namespace servicenetworking_v1beta {
450
521
  */
451
522
  export interface Schema$CloudSQLConfig {
452
523
  /**
453
- * Peering service used for peering with the Cloud SQL project.
524
+ * Required. Peering service used for peering with the Cloud SQL project.
454
525
  */
455
526
  service?: string | null;
456
527
  /**
457
- * The name of the umbrella network in the Cloud SQL umbrella project.
528
+ * Required. The name of the umbrella network in the Cloud SQL umbrella project.
458
529
  */
459
530
  umbrellaNetwork?: string | null;
460
531
  /**
461
- * The project number of the Cloud SQL umbrella project.
532
+ * Required. The project number of the Cloud SQL umbrella project.
462
533
  */
463
534
  umbrellaProject?: string | null;
464
535
  }
@@ -484,7 +555,7 @@ export namespace servicenetworking_v1beta {
484
555
  */
485
556
  export interface Schema$Connection {
486
557
  /**
487
- * The name of service consumer's VPC network that's connected with service producer network, in the following format: `projects/{project\}/global/networks/{network\}`. `{project\}` is a project number, such as in `12345` that includes the VPC service consumer's VPC network. `{network\}` is the name of the service consumer's VPC network.
558
+ * Required. The name of service consumer's VPC network that's connected with service producer network, in the following format: `projects/{project\}/global/networks/{network\}`. `{project\}` is a project number, such as in `12345` that includes the VPC service consumer's VPC network. `{network\}` is the name of the service consumer's VPC network.
488
559
  */
489
560
  network?: string | null;
490
561
  /**
@@ -1247,6 +1318,10 @@ export namespace servicenetworking_v1beta {
1247
1318
  * List of top-level fields of the request message, that should be automatically populated by the client libraries based on their (google.api.field_info).format. Currently supported format: UUID4. Example of a YAML configuration: publishing: method_settings: - selector: google.example.v1.ExampleService.CreateExample auto_populated_fields: - request_id
1248
1319
  */
1249
1320
  autoPopulatedFields?: string[] | null;
1321
+ /**
1322
+ * Batching configuration for an API method in client libraries. Example of a YAML configuration: publishing: method_settings: - selector: google.example.v1.ExampleService.BatchCreateExample batching: element_count_threshold: 1000 request_byte_threshold: 100000000 delay_threshold_millis: 10
1323
+ */
1324
+ batching?: Schema$BatchingConfigProto;
1250
1325
  /**
1251
1326
  * Describes settings to use for long-running operations when generating API methods for RPCs. Complements RPCs that use the annotations in google/longrunning/operations.proto. Example of a YAML configuration:: publishing: method_settings: - selector: google.cloud.speech.v2.Speech.BatchRecognize long_running: initial_poll_delay: 60s # 1 minute poll_delay_multiplier: 1.5 max_poll_delay: 360s # 6 minutes total_poll_timeout: 54000s # 90 minutes
1252
1327
  */
@@ -1493,7 +1568,7 @@ export namespace servicenetworking_v1beta {
1493
1568
  */
1494
1569
  dnsSuffix?: string | null;
1495
1570
  /**
1496
- * User assigned name for this resource. Must be unique within the consumer network. The name must be 1-63 characters long, must begin with a letter, end with a letter or digit, and only contain lowercase letters, digits or dashes.
1571
+ * Required. User assigned name for this resource. Must be unique within the consumer network. The name must be 1-63 characters long, must begin with a letter, end with a letter or digit, and only contain lowercase letters, digits or dashes.
1497
1572
  */
1498
1573
  name?: string | null;
1499
1574
  }
@@ -1509,6 +1584,10 @@ export namespace servicenetworking_v1beta {
1509
1584
  * Some settings.
1510
1585
  */
1511
1586
  common?: Schema$CommonLanguageSettings;
1587
+ /**
1588
+ * The package name to use in Php. Clobbers the php_namespace option set in the protobuf. This should be used **only** by APIs who have already set the language_settings.php.package_name" field in gapic.yaml. API teams should use the protobuf php_namespace option where possible. Example of a YAML configuration:: publishing: library_settings: php_settings: library_package: Google\Cloud\PubSub\V1
1589
+ */
1590
+ libraryPackage?: string | null;
1512
1591
  }
1513
1592
  /**
1514
1593
  * Grouping of IAM role and IAM member.
@@ -2051,6 +2130,59 @@ export namespace servicenetworking_v1beta {
2051
2130
 
2052
2131
  /**
2053
2132
  * Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.
2133
+ * @example
2134
+ * ```js
2135
+ * // Before running the sample:
2136
+ * // - Enable the API at:
2137
+ * // https://console.developers.google.com/apis/api/servicenetworking.googleapis.com
2138
+ * // - Login into gcloud by running:
2139
+ * // ```sh
2140
+ * // $ gcloud auth application-default login
2141
+ * // ```
2142
+ * // - Install the npm module by running:
2143
+ * // ```sh
2144
+ * // $ npm install googleapis
2145
+ * // ```
2146
+ *
2147
+ * const {google} = require('googleapis');
2148
+ * const servicenetworking = google.servicenetworking('v1beta');
2149
+ *
2150
+ * async function main() {
2151
+ * const auth = new google.auth.GoogleAuth({
2152
+ * // Scopes can be specified either as an array or as a single, space-delimited string.
2153
+ * scopes: [
2154
+ * 'https://www.googleapis.com/auth/cloud-platform',
2155
+ * 'https://www.googleapis.com/auth/service.management',
2156
+ * ],
2157
+ * });
2158
+ *
2159
+ * // Acquire an auth client, and bind it to all future calls
2160
+ * const authClient = await auth.getClient();
2161
+ * google.options({auth: authClient});
2162
+ *
2163
+ * // Do the magic
2164
+ * const res = await servicenetworking.operations.get({
2165
+ * // The name of the operation resource.
2166
+ * name: 'operations/my-operation',
2167
+ * });
2168
+ * console.log(res.data);
2169
+ *
2170
+ * // Example response
2171
+ * // {
2172
+ * // "done": false,
2173
+ * // "error": {},
2174
+ * // "metadata": {},
2175
+ * // "name": "my_name",
2176
+ * // "response": {}
2177
+ * // }
2178
+ * }
2179
+ *
2180
+ * main().catch(e => {
2181
+ * console.error(e);
2182
+ * throw e;
2183
+ * });
2184
+ *
2185
+ * ```
2054
2186
  *
2055
2187
  * @param params - Parameters for request
2056
2188
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -2060,11 +2192,11 @@ export namespace servicenetworking_v1beta {
2060
2192
  get(
2061
2193
  params: Params$Resource$Operations$Get,
2062
2194
  options: StreamMethodOptions
2063
- ): GaxiosPromise<Readable>;
2195
+ ): Promise<GaxiosResponseWithHTTP2<Readable>>;
2064
2196
  get(
2065
2197
  params?: Params$Resource$Operations$Get,
2066
2198
  options?: MethodOptions
2067
- ): GaxiosPromise<Schema$Operation>;
2199
+ ): Promise<GaxiosResponseWithHTTP2<Schema$Operation>>;
2068
2200
  get(
2069
2201
  params: Params$Resource$Operations$Get,
2070
2202
  options: StreamMethodOptions | BodyResponseCallback<Readable>,
@@ -2093,7 +2225,10 @@ export namespace servicenetworking_v1beta {
2093
2225
  callback?:
2094
2226
  | BodyResponseCallback<Schema$Operation>
2095
2227
  | BodyResponseCallback<Readable>
2096
- ): void | GaxiosPromise<Schema$Operation> | GaxiosPromise<Readable> {
2228
+ ):
2229
+ | void
2230
+ | Promise<GaxiosResponseWithHTTP2<Schema$Operation>>
2231
+ | Promise<GaxiosResponseWithHTTP2<Readable>> {
2097
2232
  let params = (paramsOrCallback || {}) as Params$Resource$Operations$Get;
2098
2233
  let options = (optionsOrCallback || {}) as MethodOptions;
2099
2234
 
@@ -2152,6 +2287,74 @@ export namespace servicenetworking_v1beta {
2152
2287
 
2153
2288
  /**
2154
2289
  * For service producers, provisions a new subnet in a peered service's shared VPC network in the requested region and with the requested size that's expressed as a CIDR range (number of leading bits of ipV4 network mask). The method checks against the assigned allocated ranges to find a non-conflicting IP address range. The method will reuse a subnet if subsequent calls contain the same subnet name, region, and prefix length. This method will make producer's tenant project to be a shared VPC service project as needed. The response from the `get` operation will be of type `Subnetwork` if the operation successfully completes.
2290
+ * @example
2291
+ * ```js
2292
+ * // Before running the sample:
2293
+ * // - Enable the API at:
2294
+ * // https://console.developers.google.com/apis/api/servicenetworking.googleapis.com
2295
+ * // - Login into gcloud by running:
2296
+ * // ```sh
2297
+ * // $ gcloud auth application-default login
2298
+ * // ```
2299
+ * // - Install the npm module by running:
2300
+ * // ```sh
2301
+ * // $ npm install googleapis
2302
+ * // ```
2303
+ *
2304
+ * const {google} = require('googleapis');
2305
+ * const servicenetworking = google.servicenetworking('v1beta');
2306
+ *
2307
+ * async function main() {
2308
+ * const auth = new google.auth.GoogleAuth({
2309
+ * // Scopes can be specified either as an array or as a single, space-delimited string.
2310
+ * scopes: [
2311
+ * 'https://www.googleapis.com/auth/cloud-platform',
2312
+ * 'https://www.googleapis.com/auth/service.management',
2313
+ * ],
2314
+ * });
2315
+ *
2316
+ * // Acquire an auth client, and bind it to all future calls
2317
+ * const authClient = await auth.getClient();
2318
+ * google.options({auth: authClient});
2319
+ *
2320
+ * // Do the magic
2321
+ * const res = await servicenetworking.services.addSubnetwork({
2322
+ * // Required. A tenant project in the service producer organization, in the following format: services/{service\}/{collection-id\}/{resource-id\}. {collection-id\} is the cloud resource collection type that represents the tenant project. Only `projects` are supported. {resource-id\} is the tenant project numeric id, such as `123456`. {service\} the name of the peering service, such as `service-peering.example.com`. This service must already be enabled in the service consumer's project.
2323
+ * parent: 'services/my-service/[^/]+/[^/]+',
2324
+ *
2325
+ * // Request body metadata
2326
+ * requestBody: {
2327
+ * // request body parameters
2328
+ * // {
2329
+ * // "consumer": "my_consumer",
2330
+ * // "consumerNetwork": "my_consumerNetwork",
2331
+ * // "description": "my_description",
2332
+ * // "ipPrefixLength": 0,
2333
+ * // "region": "my_region",
2334
+ * // "requestedAddress": "my_requestedAddress",
2335
+ * // "subnetwork": "my_subnetwork",
2336
+ * // "subnetworkUsers": []
2337
+ * // }
2338
+ * },
2339
+ * });
2340
+ * console.log(res.data);
2341
+ *
2342
+ * // Example response
2343
+ * // {
2344
+ * // "done": false,
2345
+ * // "error": {},
2346
+ * // "metadata": {},
2347
+ * // "name": "my_name",
2348
+ * // "response": {}
2349
+ * // }
2350
+ * }
2351
+ *
2352
+ * main().catch(e => {
2353
+ * console.error(e);
2354
+ * throw e;
2355
+ * });
2356
+ *
2357
+ * ```
2155
2358
  *
2156
2359
  * @param params - Parameters for request
2157
2360
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -2161,11 +2364,11 @@ export namespace servicenetworking_v1beta {
2161
2364
  addSubnetwork(
2162
2365
  params: Params$Resource$Services$Addsubnetwork,
2163
2366
  options: StreamMethodOptions
2164
- ): GaxiosPromise<Readable>;
2367
+ ): Promise<GaxiosResponseWithHTTP2<Readable>>;
2165
2368
  addSubnetwork(
2166
2369
  params?: Params$Resource$Services$Addsubnetwork,
2167
2370
  options?: MethodOptions
2168
- ): GaxiosPromise<Schema$Operation>;
2371
+ ): Promise<GaxiosResponseWithHTTP2<Schema$Operation>>;
2169
2372
  addSubnetwork(
2170
2373
  params: Params$Resource$Services$Addsubnetwork,
2171
2374
  options: StreamMethodOptions | BodyResponseCallback<Readable>,
@@ -2194,7 +2397,10 @@ export namespace servicenetworking_v1beta {
2194
2397
  callback?:
2195
2398
  | BodyResponseCallback<Schema$Operation>
2196
2399
  | BodyResponseCallback<Readable>
2197
- ): void | GaxiosPromise<Schema$Operation> | GaxiosPromise<Readable> {
2400
+ ):
2401
+ | void
2402
+ | Promise<GaxiosResponseWithHTTP2<Schema$Operation>>
2403
+ | Promise<GaxiosResponseWithHTTP2<Readable>> {
2198
2404
  let params = (paramsOrCallback ||
2199
2405
  {}) as Params$Resource$Services$Addsubnetwork;
2200
2406
  let options = (optionsOrCallback || {}) as MethodOptions;
@@ -2241,6 +2447,68 @@ export namespace servicenetworking_v1beta {
2241
2447
 
2242
2448
  /**
2243
2449
  * Service producers can use this method to find a currently unused range within consumer allocated ranges. This returned range is not reserved, and not guaranteed to remain unused. It will validate previously provided allocated ranges, find non-conflicting sub-range of requested size (expressed in number of leading bits of ipv4 network mask, as in CIDR range notation). Operation
2450
+ * @example
2451
+ * ```js
2452
+ * // Before running the sample:
2453
+ * // - Enable the API at:
2454
+ * // https://console.developers.google.com/apis/api/servicenetworking.googleapis.com
2455
+ * // - Login into gcloud by running:
2456
+ * // ```sh
2457
+ * // $ gcloud auth application-default login
2458
+ * // ```
2459
+ * // - Install the npm module by running:
2460
+ * // ```sh
2461
+ * // $ npm install googleapis
2462
+ * // ```
2463
+ *
2464
+ * const {google} = require('googleapis');
2465
+ * const servicenetworking = google.servicenetworking('v1beta');
2466
+ *
2467
+ * async function main() {
2468
+ * const auth = new google.auth.GoogleAuth({
2469
+ * // Scopes can be specified either as an array or as a single, space-delimited string.
2470
+ * scopes: [
2471
+ * 'https://www.googleapis.com/auth/cloud-platform',
2472
+ * 'https://www.googleapis.com/auth/service.management',
2473
+ * ],
2474
+ * });
2475
+ *
2476
+ * // Acquire an auth client, and bind it to all future calls
2477
+ * const authClient = await auth.getClient();
2478
+ * google.options({auth: authClient});
2479
+ *
2480
+ * // Do the magic
2481
+ * const res = await servicenetworking.services.searchRange({
2482
+ * // Required. This is in a form services/{service\}. {service\} the name of the private access management service, for example 'service-peering.example.com'.
2483
+ * parent: 'services/my-service',
2484
+ *
2485
+ * // Request body metadata
2486
+ * requestBody: {
2487
+ * // request body parameters
2488
+ * // {
2489
+ * // "ipPrefixLength": 0,
2490
+ * // "network": "my_network"
2491
+ * // }
2492
+ * },
2493
+ * });
2494
+ * console.log(res.data);
2495
+ *
2496
+ * // Example response
2497
+ * // {
2498
+ * // "done": false,
2499
+ * // "error": {},
2500
+ * // "metadata": {},
2501
+ * // "name": "my_name",
2502
+ * // "response": {}
2503
+ * // }
2504
+ * }
2505
+ *
2506
+ * main().catch(e => {
2507
+ * console.error(e);
2508
+ * throw e;
2509
+ * });
2510
+ *
2511
+ * ```
2244
2512
  *
2245
2513
  * @param params - Parameters for request
2246
2514
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -2250,11 +2518,11 @@ export namespace servicenetworking_v1beta {
2250
2518
  searchRange(
2251
2519
  params: Params$Resource$Services$Searchrange,
2252
2520
  options: StreamMethodOptions
2253
- ): GaxiosPromise<Readable>;
2521
+ ): Promise<GaxiosResponseWithHTTP2<Readable>>;
2254
2522
  searchRange(
2255
2523
  params?: Params$Resource$Services$Searchrange,
2256
2524
  options?: MethodOptions
2257
- ): GaxiosPromise<Schema$Operation>;
2525
+ ): Promise<GaxiosResponseWithHTTP2<Schema$Operation>>;
2258
2526
  searchRange(
2259
2527
  params: Params$Resource$Services$Searchrange,
2260
2528
  options: StreamMethodOptions | BodyResponseCallback<Readable>,
@@ -2283,7 +2551,10 @@ export namespace servicenetworking_v1beta {
2283
2551
  callback?:
2284
2552
  | BodyResponseCallback<Schema$Operation>
2285
2553
  | BodyResponseCallback<Readable>
2286
- ): void | GaxiosPromise<Schema$Operation> | GaxiosPromise<Readable> {
2554
+ ):
2555
+ | void
2556
+ | Promise<GaxiosResponseWithHTTP2<Schema$Operation>>
2557
+ | Promise<GaxiosResponseWithHTTP2<Readable>> {
2287
2558
  let params = (paramsOrCallback ||
2288
2559
  {}) as Params$Resource$Services$Searchrange;
2289
2560
  let options = (optionsOrCallback || {}) as MethodOptions;
@@ -2330,6 +2601,74 @@ export namespace servicenetworking_v1beta {
2330
2601
 
2331
2602
  /**
2332
2603
  * Updates the allocated ranges that are assigned to a connection. The response from the `get` operation will be of type `Connection` if the operation successfully completes.
2604
+ * @example
2605
+ * ```js
2606
+ * // Before running the sample:
2607
+ * // - Enable the API at:
2608
+ * // https://console.developers.google.com/apis/api/servicenetworking.googleapis.com
2609
+ * // - Login into gcloud by running:
2610
+ * // ```sh
2611
+ * // $ gcloud auth application-default login
2612
+ * // ```
2613
+ * // - Install the npm module by running:
2614
+ * // ```sh
2615
+ * // $ npm install googleapis
2616
+ * // ```
2617
+ *
2618
+ * const {google} = require('googleapis');
2619
+ * const servicenetworking = google.servicenetworking('v1beta');
2620
+ *
2621
+ * async function main() {
2622
+ * const auth = new google.auth.GoogleAuth({
2623
+ * // Scopes can be specified either as an array or as a single, space-delimited string.
2624
+ * scopes: [
2625
+ * 'https://www.googleapis.com/auth/cloud-platform',
2626
+ * 'https://www.googleapis.com/auth/service.management',
2627
+ * ],
2628
+ * });
2629
+ *
2630
+ * // Acquire an auth client, and bind it to all future calls
2631
+ * const authClient = await auth.getClient();
2632
+ * google.options({auth: authClient});
2633
+ *
2634
+ * // Do the magic
2635
+ * const res = await servicenetworking.services.updateConnections({
2636
+ * // If a previously defined allocated range is removed, force flag must be set to true.
2637
+ * force: 'placeholder-value',
2638
+ * // The service producer peering service that is managing peering connectivity for a service producer organization. For Google services that support this functionality, this is `services/servicenetworking.googleapis.com`.
2639
+ * name: 'services/my-service',
2640
+ * // The update mask. If this is omitted, it defaults to "*". You can only update the listed peering ranges.
2641
+ * updateMask: 'placeholder-value',
2642
+ *
2643
+ * // Request body metadata
2644
+ * requestBody: {
2645
+ * // request body parameters
2646
+ * // {
2647
+ * // "network": "my_network",
2648
+ * // "peering": "my_peering",
2649
+ * // "reservedPeeringRanges": [],
2650
+ * // "service": "my_service"
2651
+ * // }
2652
+ * },
2653
+ * });
2654
+ * console.log(res.data);
2655
+ *
2656
+ * // Example response
2657
+ * // {
2658
+ * // "done": false,
2659
+ * // "error": {},
2660
+ * // "metadata": {},
2661
+ * // "name": "my_name",
2662
+ * // "response": {}
2663
+ * // }
2664
+ * }
2665
+ *
2666
+ * main().catch(e => {
2667
+ * console.error(e);
2668
+ * throw e;
2669
+ * });
2670
+ *
2671
+ * ```
2333
2672
  *
2334
2673
  * @param params - Parameters for request
2335
2674
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -2339,11 +2678,11 @@ export namespace servicenetworking_v1beta {
2339
2678
  updateConnections(
2340
2679
  params: Params$Resource$Services$Updateconnections,
2341
2680
  options: StreamMethodOptions
2342
- ): GaxiosPromise<Readable>;
2681
+ ): Promise<GaxiosResponseWithHTTP2<Readable>>;
2343
2682
  updateConnections(
2344
2683
  params?: Params$Resource$Services$Updateconnections,
2345
2684
  options?: MethodOptions
2346
- ): GaxiosPromise<Schema$Operation>;
2685
+ ): Promise<GaxiosResponseWithHTTP2<Schema$Operation>>;
2347
2686
  updateConnections(
2348
2687
  params: Params$Resource$Services$Updateconnections,
2349
2688
  options: StreamMethodOptions | BodyResponseCallback<Readable>,
@@ -2372,7 +2711,10 @@ export namespace servicenetworking_v1beta {
2372
2711
  callback?:
2373
2712
  | BodyResponseCallback<Schema$Operation>
2374
2713
  | BodyResponseCallback<Readable>
2375
- ): void | GaxiosPromise<Schema$Operation> | GaxiosPromise<Readable> {
2714
+ ):
2715
+ | void
2716
+ | Promise<GaxiosResponseWithHTTP2<Schema$Operation>>
2717
+ | Promise<GaxiosResponseWithHTTP2<Readable>> {
2376
2718
  let params = (paramsOrCallback ||
2377
2719
  {}) as Params$Resource$Services$Updateconnections;
2378
2720
  let options = (optionsOrCallback || {}) as MethodOptions;
@@ -2471,6 +2813,70 @@ export namespace servicenetworking_v1beta {
2471
2813
 
2472
2814
  /**
2473
2815
  * Creates a private connection that establishes a VPC Network Peering connection to a VPC network in the service producer's organization. The administrator of the service consumer's VPC network invokes this method. The administrator must assign one or more allocated IP ranges for provisioning subnetworks in the service producer's VPC network. This connection is used for all supported services in the service producer's organization, so it only needs to be invoked once. The response from the `get` operation will be of type `Connection` if the operation successfully completes.
2816
+ * @example
2817
+ * ```js
2818
+ * // Before running the sample:
2819
+ * // - Enable the API at:
2820
+ * // https://console.developers.google.com/apis/api/servicenetworking.googleapis.com
2821
+ * // - Login into gcloud by running:
2822
+ * // ```sh
2823
+ * // $ gcloud auth application-default login
2824
+ * // ```
2825
+ * // - Install the npm module by running:
2826
+ * // ```sh
2827
+ * // $ npm install googleapis
2828
+ * // ```
2829
+ *
2830
+ * const {google} = require('googleapis');
2831
+ * const servicenetworking = google.servicenetworking('v1beta');
2832
+ *
2833
+ * async function main() {
2834
+ * const auth = new google.auth.GoogleAuth({
2835
+ * // Scopes can be specified either as an array or as a single, space-delimited string.
2836
+ * scopes: [
2837
+ * 'https://www.googleapis.com/auth/cloud-platform',
2838
+ * 'https://www.googleapis.com/auth/service.management',
2839
+ * ],
2840
+ * });
2841
+ *
2842
+ * // Acquire an auth client, and bind it to all future calls
2843
+ * const authClient = await auth.getClient();
2844
+ * google.options({auth: authClient});
2845
+ *
2846
+ * // Do the magic
2847
+ * const res = await servicenetworking.services.connections.create({
2848
+ * // The service that is managing peering connectivity for a service producer's organization. For Google services that support this functionality, this value is `services/servicenetworking.googleapis.com`.
2849
+ * parent: 'services/my-service',
2850
+ *
2851
+ * // Request body metadata
2852
+ * requestBody: {
2853
+ * // request body parameters
2854
+ * // {
2855
+ * // "network": "my_network",
2856
+ * // "peering": "my_peering",
2857
+ * // "reservedPeeringRanges": [],
2858
+ * // "service": "my_service"
2859
+ * // }
2860
+ * },
2861
+ * });
2862
+ * console.log(res.data);
2863
+ *
2864
+ * // Example response
2865
+ * // {
2866
+ * // "done": false,
2867
+ * // "error": {},
2868
+ * // "metadata": {},
2869
+ * // "name": "my_name",
2870
+ * // "response": {}
2871
+ * // }
2872
+ * }
2873
+ *
2874
+ * main().catch(e => {
2875
+ * console.error(e);
2876
+ * throw e;
2877
+ * });
2878
+ *
2879
+ * ```
2474
2880
  *
2475
2881
  * @param params - Parameters for request
2476
2882
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -2480,11 +2886,11 @@ export namespace servicenetworking_v1beta {
2480
2886
  create(
2481
2887
  params: Params$Resource$Services$Connections$Create,
2482
2888
  options: StreamMethodOptions
2483
- ): GaxiosPromise<Readable>;
2889
+ ): Promise<GaxiosResponseWithHTTP2<Readable>>;
2484
2890
  create(
2485
2891
  params?: Params$Resource$Services$Connections$Create,
2486
2892
  options?: MethodOptions
2487
- ): GaxiosPromise<Schema$Operation>;
2893
+ ): Promise<GaxiosResponseWithHTTP2<Schema$Operation>>;
2488
2894
  create(
2489
2895
  params: Params$Resource$Services$Connections$Create,
2490
2896
  options: StreamMethodOptions | BodyResponseCallback<Readable>,
@@ -2513,7 +2919,10 @@ export namespace servicenetworking_v1beta {
2513
2919
  callback?:
2514
2920
  | BodyResponseCallback<Schema$Operation>
2515
2921
  | BodyResponseCallback<Readable>
2516
- ): void | GaxiosPromise<Schema$Operation> | GaxiosPromise<Readable> {
2922
+ ):
2923
+ | void
2924
+ | Promise<GaxiosResponseWithHTTP2<Schema$Operation>>
2925
+ | Promise<GaxiosResponseWithHTTP2<Readable>> {
2517
2926
  let params = (paramsOrCallback ||
2518
2927
  {}) as Params$Resource$Services$Connections$Create;
2519
2928
  let options = (optionsOrCallback || {}) as MethodOptions;
@@ -2560,6 +2969,57 @@ export namespace servicenetworking_v1beta {
2560
2969
 
2561
2970
  /**
2562
2971
  * List the private connections that are configured in a service consumer's VPC network.
2972
+ * @example
2973
+ * ```js
2974
+ * // Before running the sample:
2975
+ * // - Enable the API at:
2976
+ * // https://console.developers.google.com/apis/api/servicenetworking.googleapis.com
2977
+ * // - Login into gcloud by running:
2978
+ * // ```sh
2979
+ * // $ gcloud auth application-default login
2980
+ * // ```
2981
+ * // - Install the npm module by running:
2982
+ * // ```sh
2983
+ * // $ npm install googleapis
2984
+ * // ```
2985
+ *
2986
+ * const {google} = require('googleapis');
2987
+ * const servicenetworking = google.servicenetworking('v1beta');
2988
+ *
2989
+ * async function main() {
2990
+ * const auth = new google.auth.GoogleAuth({
2991
+ * // Scopes can be specified either as an array or as a single, space-delimited string.
2992
+ * scopes: [
2993
+ * 'https://www.googleapis.com/auth/cloud-platform',
2994
+ * 'https://www.googleapis.com/auth/service.management',
2995
+ * ],
2996
+ * });
2997
+ *
2998
+ * // Acquire an auth client, and bind it to all future calls
2999
+ * const authClient = await auth.getClient();
3000
+ * google.options({auth: authClient});
3001
+ *
3002
+ * // Do the magic
3003
+ * const res = await servicenetworking.services.connections.list({
3004
+ * // The name of service consumer's VPC network that's connected with service producer network through a private connection. The network name must be in the following format: `projects/{project\}/global/networks/{network\}`. {project\} is a project number, such as in `12345` that includes the VPC service consumer's VPC network. {network\} is the name of the service consumer's VPC network.
3005
+ * network: 'placeholder-value',
3006
+ * // The service that is managing peering connectivity for a service producer's organization. For Google services that support this functionality, this value is `services/servicenetworking.googleapis.com`. If you specify `-` as the parameter value, all configured public peering services are listed.
3007
+ * parent: 'services/my-service',
3008
+ * });
3009
+ * console.log(res.data);
3010
+ *
3011
+ * // Example response
3012
+ * // {
3013
+ * // "connections": []
3014
+ * // }
3015
+ * }
3016
+ *
3017
+ * main().catch(e => {
3018
+ * console.error(e);
3019
+ * throw e;
3020
+ * });
3021
+ *
3022
+ * ```
2563
3023
  *
2564
3024
  * @param params - Parameters for request
2565
3025
  * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
@@ -2569,11 +3029,11 @@ export namespace servicenetworking_v1beta {
2569
3029
  list(
2570
3030
  params: Params$Resource$Services$Connections$List,
2571
3031
  options: StreamMethodOptions
2572
- ): GaxiosPromise<Readable>;
3032
+ ): Promise<GaxiosResponseWithHTTP2<Readable>>;
2573
3033
  list(
2574
3034
  params?: Params$Resource$Services$Connections$List,
2575
3035
  options?: MethodOptions
2576
- ): GaxiosPromise<Schema$ListConnectionsResponse>;
3036
+ ): Promise<GaxiosResponseWithHTTP2<Schema$ListConnectionsResponse>>;
2577
3037
  list(
2578
3038
  params: Params$Resource$Services$Connections$List,
2579
3039
  options: StreamMethodOptions | BodyResponseCallback<Readable>,
@@ -2606,8 +3066,8 @@ export namespace servicenetworking_v1beta {
2606
3066
  | BodyResponseCallback<Readable>
2607
3067
  ):
2608
3068
  | void
2609
- | GaxiosPromise<Schema$ListConnectionsResponse>
2610
- | GaxiosPromise<Readable> {
3069
+ | Promise<GaxiosResponseWithHTTP2<Schema$ListConnectionsResponse>>
3070
+ | Promise<GaxiosResponseWithHTTP2<Readable>> {
2611
3071
  let params = (paramsOrCallback ||
2612
3072
  {}) as Params$Resource$Services$Connections$List;
2613
3073
  let options = (optionsOrCallback || {}) as MethodOptions;