From 381f54a89e55939ec4592f475c44a2054295ee4f Mon Sep 17 00:00:00 2001 From: Justin Beckwith Date: Fri, 6 Sep 2019 12:21:21 -0700 Subject: [PATCH] feat(gen): run the generator (#1814) BREAKING CHANGES: This release has multiple breaking changes. The following APIs have been removed: - appstate/v1 - compute/alpha - run/v1beta1 In addition, the default rootUrl for the compute API has been switched from `www.googleapis.com` to `compute.googleapis.com`. The following APIs have been added: - bigqueryreservation/v1 - bigqueryreservation/v1alpha2 - domainsrdap/v1 - homegraph/v1 - speech/v2beta - translate/v3beta1 - verifiedaccess/v1 --- src/apis/abusiveexperiencereport/v1.ts | 22 +- src/apis/accessapproval/v1beta1.ts | 38 +- src/apis/adexperiencereport/v1.ts | 32 +- src/apis/admin/directory_v1.ts | 66 +- src/apis/alertcenter/v1beta1.ts | 391 +- src/apis/analytics/v3.ts | 4 + src/apis/analyticsreporting/v4.ts | 6 +- src/apis/androidenterprise/v1.ts | 2 +- src/apis/androidmanagement/v1.ts | 42 +- src/apis/androidpublisher/v2.ts | 14 +- src/apis/androidpublisher/v3.ts | 31 +- src/apis/appstate/v1.ts | 614 - src/apis/bigquery/v2.ts | 138 +- src/apis/bigqueryreservation/README.md | 47 + src/apis/bigqueryreservation/index.ts | 53 + src/apis/bigqueryreservation/package.json | 43 + .../tsconfig.json | 0 src/apis/bigqueryreservation/v1.ts | 386 + src/apis/bigqueryreservation/v1alpha2.ts | 1977 + .../bigqueryreservation/webpack.config.js | 71 + src/apis/bigtableadmin/v2.ts | 24 +- src/apis/binaryauthorization/v1beta1.ts | 12 +- src/apis/calendar/v3.ts | 2 +- src/apis/cloudasset/v1.ts | 226 +- src/apis/cloudasset/v1beta1.ts | 10 +- src/apis/cloudbilling/v1.ts | 4 +- src/apis/cloudbuild/v1.ts | 12 +- src/apis/cloudbuild/v1alpha1.ts | 4 +- src/apis/cloudfunctions/v1.ts | 23 +- src/apis/cloudfunctions/v1beta2.ts | 8 +- src/apis/cloudiot/v1.ts | 8 +- src/apis/cloudkms/v1.ts | 54 +- .../cloudprivatecatalogproducer/v1beta1.ts | 8 +- src/apis/cloudresourcemanager/v1.ts | 14 +- src/apis/cloudresourcemanager/v1beta1.ts | 18 +- src/apis/cloudresourcemanager/v2.ts | 2 +- src/apis/cloudresourcemanager/v2beta1.ts | 2 +- src/apis/cloudscheduler/v1.ts | 32 +- src/apis/cloudscheduler/v1beta1.ts | 32 +- src/apis/cloudsearch/v1.ts | 18 +- src/apis/cloudshell/v1.ts | 4 + src/apis/cloudshell/v1alpha1.ts | 4 + src/apis/cloudtasks/v2.ts | 82 +- src/apis/cloudtasks/v2beta2.ts | 96 +- src/apis/cloudtasks/v2beta3.ts | 70 +- src/apis/cloudtrace/v2.ts | 4 + src/apis/commentanalyzer/v1alpha1.ts | 2 +- src/apis/composer/v1.ts | 2 +- src/apis/composer/v1beta1.ts | 2 +- src/apis/compute/alpha.ts | 79284 ---------------- src/apis/compute/beta.ts | 485 +- src/apis/compute/index.ts | 16 +- src/apis/compute/v1.ts | 2950 +- src/apis/container/v1.ts | 42 + src/apis/container/v1beta1.ts | 115 + src/apis/containeranalysis/v1alpha1.ts | 105 +- src/apis/containeranalysis/v1beta1.ts | 48 +- src/apis/content/v2.1.ts | 1236 +- src/apis/content/v2.ts | 16 +- src/apis/dataflow/v1b3.ts | 1004 +- src/apis/dataproc/v1.ts | 2087 +- src/apis/dataproc/v1beta2.ts | 189 +- src/apis/datastore/v1.ts | 4 +- src/apis/datastore/v1beta1.ts | 4 +- src/apis/dfareporting/v3.1.ts | 522 +- src/apis/dialogflow/package.json | 8 +- src/apis/dialogflow/webpack.config.js | 12 +- src/apis/dlp/v2.ts | 383 +- src/apis/docs/v1.ts | 146 +- src/apis/domainsrdap/README.md | 47 + src/apis/domainsrdap/index.ts | 35 + src/apis/domainsrdap/package.json | 43 + src/apis/domainsrdap/tsconfig.json | 10 + src/apis/domainsrdap/v1.ts | 1078 + src/apis/domainsrdap/webpack.config.js | 71 + src/apis/doubleclicksearch/v2.ts | 4 +- src/apis/drive/v2.ts | 1 + src/apis/drive/v3.ts | 1 + src/apis/driveactivity/v2.ts | 2 +- src/apis/factchecktools/v1alpha1.ts | 4 + src/apis/fcm/v1.ts | 86 + src/apis/file/v1.ts | 6 +- src/apis/file/v1beta1.ts | 6 +- src/apis/firebase/v1beta1.ts | 329 +- src/apis/firebasehosting/v1beta1.ts | 20 +- src/apis/firebaserules/v1.ts | 4 + src/apis/firestore/v1.ts | 8 +- src/apis/firestore/v1beta1.ts | 8 +- src/apis/firestore/v1beta2.ts | 4 +- src/apis/games/v1.ts | 3 - src/apis/gamesManagement/v1management.ts | 3 - src/apis/genomics/v1.ts | 4 + src/apis/genomics/v1alpha2.ts | 4 + src/apis/genomics/v2alpha1.ts | 18 +- src/apis/groupssettings/v1.ts | 134 +- src/apis/healthcare/v1alpha2.ts | 253 +- src/apis/healthcare/v1beta1.ts | 52 +- src/apis/{appstate => homegraph}/README.md | 12 +- src/apis/{appstate => homegraph}/index.ts | 16 +- src/apis/{appstate => homegraph}/package.json | 4 +- src/apis/homegraph/tsconfig.json | 10 + src/apis/homegraph/v1.ts | 856 + .../{appstate => homegraph}/webpack.config.js | 4 +- src/apis/iam/v1.ts | 121 +- src/apis/iamcredentials/v1.ts | 134 - src/apis/iap/v1.ts | 2 +- src/apis/iap/v1beta1.ts | 2 +- src/apis/index.ts | 15 +- src/apis/jobs/v2.ts | 402 +- src/apis/jobs/v3.ts | 326 +- src/apis/jobs/v3p1beta1.ts | 336 +- src/apis/language/v1.ts | 14 +- src/apis/language/v1beta2.ts | 14 +- src/apis/libraryagent/v1.ts | 20 +- src/apis/ml/v1.ts | 33 +- src/apis/monitoring/v3.ts | 14 +- src/apis/pagespeedonline/v5.ts | 3 +- src/apis/people/v1.ts | 234 +- src/apis/pubsub/v1.ts | 22 +- src/apis/pubsub/v1beta2.ts | 14 +- src/apis/remotebuildexecution/v1.ts | 21 +- src/apis/remotebuildexecution/v1alpha.ts | 25 +- src/apis/remotebuildexecution/v2.ts | 21 +- src/apis/run/index.ts | 14 +- src/apis/run/v1.ts | 116 + src/apis/run/v1alpha1.ts | 173 +- src/apis/run/v1beta1.ts | 278 - src/apis/runtimeconfig/v1beta1.ts | 6 +- src/apis/securitycenter/v1.ts | 26 +- src/apis/securitycenter/v1beta1.ts | 6 +- src/apis/servicebroker/v1.ts | 4 +- src/apis/servicebroker/v1alpha1.ts | 4 +- src/apis/servicebroker/v1beta1.ts | 4 +- src/apis/serviceconsumermanagement/v1.ts | 2 +- src/apis/servicecontrol/v1.ts | 35 +- src/apis/servicemanagement/v1.ts | 16 +- src/apis/serviceusage/v1.ts | 17 +- src/apis/serviceusage/v1beta1.ts | 13 + src/apis/sheets/v4.ts | 77 + src/apis/slides/v1.ts | 4 +- src/apis/spanner/v1.ts | 141 +- src/apis/speech/index.ts | 10 +- src/apis/speech/v1.ts | 8 +- src/apis/speech/v1p1beta1.ts | 21 +- src/apis/speech/v2beta.ts | 474 + src/apis/sqladmin/v1beta4.ts | 22 +- src/apis/storage/v1.ts | 9 + src/apis/storagetransfer/v1.ts | 20 +- src/apis/testing/v1.ts | 14 +- src/apis/toolresults/v1beta3.ts | 20 +- src/apis/tpu/v1.ts | 8 + src/apis/tpu/v1alpha1.ts | 8 + src/apis/translate/index.ts | 16 +- src/apis/translate/v3beta1.ts | 2224 + src/apis/verifiedaccess/README.md | 47 + src/apis/verifiedaccess/index.ts | 35 + src/apis/verifiedaccess/package.json | 43 + src/apis/verifiedaccess/tsconfig.json | 10 + src/apis/verifiedaccess/v1.ts | 368 + src/apis/verifiedaccess/webpack.config.js | 71 + src/apis/videointelligence/v1.ts | 291 +- src/apis/videointelligence/v1beta2.ts | 20 + src/apis/videointelligence/v1p1beta1.ts | 20 + src/apis/videointelligence/v1p2beta1.ts | 20 + src/apis/videointelligence/v1p3beta1.ts | 20 + src/apis/vision/v1.ts | 4121 +- src/apis/vision/v1p1beta1.ts | 2699 +- src/apis/vision/v1p2beta1.ts | 2699 +- src/apis/websecurityscanner/v1.ts | 1718 + src/apis/youtube/v3.ts | 365 +- src/generator/templates/package.json.njk | 4 +- src/index.ts | 12 +- test/test.query.ts | 4 +- 173 files changed, 24584 insertions(+), 90098 deletions(-) delete mode 100644 src/apis/appstate/v1.ts create mode 100644 src/apis/bigqueryreservation/README.md create mode 100644 src/apis/bigqueryreservation/index.ts create mode 100644 src/apis/bigqueryreservation/package.json rename src/apis/{appstate => bigqueryreservation}/tsconfig.json (100%) create mode 100644 src/apis/bigqueryreservation/v1.ts create mode 100644 src/apis/bigqueryreservation/v1alpha2.ts create mode 100644 src/apis/bigqueryreservation/webpack.config.js delete mode 100644 src/apis/compute/alpha.ts create mode 100644 src/apis/domainsrdap/README.md create mode 100644 src/apis/domainsrdap/index.ts create mode 100644 src/apis/domainsrdap/package.json create mode 100644 src/apis/domainsrdap/tsconfig.json create mode 100644 src/apis/domainsrdap/v1.ts create mode 100644 src/apis/domainsrdap/webpack.config.js rename src/apis/{appstate => homegraph}/README.md (84%) rename src/apis/{appstate => homegraph}/index.ts (67%) rename src/apis/{appstate => homegraph}/package.json (93%) create mode 100644 src/apis/homegraph/tsconfig.json create mode 100644 src/apis/homegraph/v1.ts rename src/apis/{appstate => homegraph}/webpack.config.js (96%) delete mode 100644 src/apis/run/v1beta1.ts create mode 100644 src/apis/speech/v2beta.ts create mode 100644 src/apis/translate/v3beta1.ts create mode 100644 src/apis/verifiedaccess/README.md create mode 100644 src/apis/verifiedaccess/index.ts create mode 100644 src/apis/verifiedaccess/package.json create mode 100644 src/apis/verifiedaccess/tsconfig.json create mode 100644 src/apis/verifiedaccess/v1.ts create mode 100644 src/apis/verifiedaccess/webpack.config.js diff --git a/src/apis/abusiveexperiencereport/v1.ts b/src/apis/abusiveexperiencereport/v1.ts index 6157ab3a558..656e44d7ce2 100644 --- a/src/apis/abusiveexperiencereport/v1.ts +++ b/src/apis/abusiveexperiencereport/v1.ts @@ -124,27 +124,27 @@ export namespace abusiveexperiencereport_v1 { */ export interface Schema$SiteSummaryResponse { /** - * The status of the site reviewed for the abusive experiences. + * The site's Abusive Experience Report status. */ abusiveStatus?: string; /** - * The date on which enforcement begins. + * The time at which [enforcement](https://support.google.com/webtools/answer/7538608) against the site began or will begin. Not set when the filter_status is OFF. */ enforcementTime?: string; /** - * The abusive experience enforcement status of the site. + * The site's [enforcement status](https://support.google.com/webtools/answer/7538608). */ filterStatus?: string; /** - * The last time that the site changed status. + * The time at which the site's status last changed. */ lastChangeTime?: string; /** - * A link that leads to a full abusive experience report. + * A link to the full Abusive Experience Report for the site. Not set in ViolatingSitesResponse. Note that you must complete the [Search Console verification process](https://support.google.com/webmasters/answer/9008080) for the site before you can access the full report. */ reportUrl?: string; /** - * The name of the site reviewed. + * The name of the reviewed site, e.g. `google.com`. */ reviewedSite?: string; /** @@ -157,7 +157,7 @@ export namespace abusiveexperiencereport_v1 { */ export interface Schema$ViolatingSitesResponse { /** - * A list of summaries of violating sites. + * The list of violating sites. */ violatingSites?: Schema$SiteSummaryResponse[]; } @@ -170,12 +170,12 @@ export namespace abusiveexperiencereport_v1 { /** * abusiveexperiencereport.sites.get - * @desc Gets a summary of the abusive experience rating of a site. + * @desc Gets a site's Abusive Experience Report summary. * @alias abusiveexperiencereport.sites.get * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name The required site name. This is the site property whose abusive experiences have been reviewed, and it must be URL-encoded. For example, sites/https%3A%2F%2Fwww.google.com. The server will return an error of BAD_REQUEST if this field is not filled in. Note that if the site property is not yet verified in Search Console, the reportUrl field returned by the API will lead to the verification page, prompting the user to go through that process before they can gain access to the Abusive Experience Report. + * @param {string} params.name Required. The name of the site whose summary to get, e.g. `sites/http%3A%2F%2Fwww.google.com%2F`. Format: `sites/{site}` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -247,7 +247,7 @@ export namespace abusiveexperiencereport_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The required site name. This is the site property whose abusive experiences have been reviewed, and it must be URL-encoded. For example, sites/https%3A%2F%2Fwww.google.com. The server will return an error of BAD_REQUEST if this field is not filled in. Note that if the site property is not yet verified in Search Console, the reportUrl field returned by the API will lead to the verification page, prompting the user to go through that process before they can gain access to the Abusive Experience Report. + * Required. The name of the site whose summary to get, e.g. `sites/http%3A%2F%2Fwww.google.com%2F`. Format: `sites/{site}` */ name?: string; } @@ -260,7 +260,7 @@ export namespace abusiveexperiencereport_v1 { /** * abusiveexperiencereport.violatingSites.list - * @desc Lists sites with Abusive Experience Report statuses of "Failing". + * @desc Lists sites that are failing in the Abusive Experience Report. * @alias abusiveexperiencereport.violatingSites.list * @memberOf! () * diff --git a/src/apis/accessapproval/v1beta1.ts b/src/apis/accessapproval/v1beta1.ts index 0a10a413e9b..1136dc5ef1e 100644 --- a/src/apis/accessapproval/v1beta1.ts +++ b/src/apis/accessapproval/v1beta1.ts @@ -125,6 +125,10 @@ export namespace accessapproval_v1beta1 { * Settings on a Project/Folder/Organization related to Access Approval. */ export interface Schema$AccessApprovalSettings { + /** + * A list of Google Cloud Services for which the given resource has Access Approval enrolled. Access requests for the resource given by name against any of these services contained here will be required to have explicit approval. If name refers to an organization, enrollment can be done for individual services. If name refers to a folder or project, enrollment can only be done on an all or nothing basis. If a cloud_product is repeated in this list, the first entry will be honored and all following entries will be discarded. + */ + enrolledServices?: Schema$EnrolledService[]; /** * The resource name of the settings. Format is one of: <ol> <li>"projects/{project_id}/accessApprovalSettings"</li> <li>"folders/{folder_id}/accessApprovalSettings"</li> <li>"organizations/{organization_id}/accessApprovalSettings"</li> <ol> */ @@ -233,6 +237,19 @@ export namespace accessapproval_v1beta1 { */ dismissTime?: string; } + /** + * Represents the enrollment of a cloud resource into a specific service. + */ + export interface Schema$EnrolledService { + /** + * The product for which Access Approval will be enrolled. Allowed values are listed below (case-sensitive): <ol> <li>all</li> <li>appengine.googleapis.com</li> <li>bigquery.googleapis.com</li> <li>bigtable.googleapis.com</li> <li>cloudkms.googleapis.com</li> <li>compute.googleapis.com</li> <li>dataflow.googleapis.com</li> <li>iam.googleapis.com</li> <li>pubsub.googleapis.com</li> <li>storage.googleapis.com</li> <ol> + */ + cloudProduct?: string; + /** + * The enrollment level of the service. + */ + enrollmentLevel?: string; + } /** * Response to listing of ApprovalRequest objects. */ @@ -344,12 +361,13 @@ export namespace accessapproval_v1beta1 { /** * accessapproval.folders.updateAccessApprovalSettings - * @desc Updates the settings associated with a project, folder, or organization. Completely replaces the existing settings. + * @desc Updates the settings associated with a project, folder, or organization. Settings to update are determined by the value of field_mask. * @alias accessapproval.folders.updateAccessApprovalSettings * @memberOf! () * * @param {object} params Parameters for request * @param {string} params.name The resource name of the settings. Format is one of:
  1. "projects/{project_id}/accessApprovalSettings"
  2. "folders/{folder_id}/accessApprovalSettings"
  3. "organizations/{organization_id}/accessApprovalSettings"
    1. + * @param {string=} params.updateMask The update mask applies to the settings. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask If this field is left unset, only the notification_emails field will be updated. * @param {().AccessApprovalSettings} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -443,6 +461,10 @@ export namespace accessapproval_v1beta1 { * The resource name of the settings. Format is one of:
      1. "projects/{project_id}/accessApprovalSettings"
      2. "folders/{folder_id}/accessApprovalSettings"
      3. "organizations/{organization_id}/accessApprovalSettings"
        1. */ name?: string; + /** + * The update mask applies to the settings. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask If this field is left unset, only the notification_emails field will be updated. + */ + updateMask?: string; /** * Request body metadata @@ -927,12 +949,13 @@ export namespace accessapproval_v1beta1 { /** * accessapproval.organizations.updateAccessApprovalSettings - * @desc Updates the settings associated with a project, folder, or organization. Completely replaces the existing settings. + * @desc Updates the settings associated with a project, folder, or organization. Settings to update are determined by the value of field_mask. * @alias accessapproval.organizations.updateAccessApprovalSettings * @memberOf! () * * @param {object} params Parameters for request * @param {string} params.name The resource name of the settings. Format is one of:
          1. "projects/{project_id}/accessApprovalSettings"
          2. "folders/{folder_id}/accessApprovalSettings"
          3. "organizations/{organization_id}/accessApprovalSettings"
            1. + * @param {string=} params.updateMask The update mask applies to the settings. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask If this field is left unset, only the notification_emails field will be updated. * @param {().AccessApprovalSettings} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1026,6 +1049,10 @@ export namespace accessapproval_v1beta1 { * The resource name of the settings. Format is one of:
              1. "projects/{project_id}/accessApprovalSettings"
              2. "folders/{folder_id}/accessApprovalSettings"
              3. "organizations/{organization_id}/accessApprovalSettings"
                1. */ name?: string; + /** + * The update mask applies to the settings. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask If this field is left unset, only the notification_emails field will be updated. + */ + updateMask?: string; /** * Request body metadata @@ -1510,12 +1537,13 @@ export namespace accessapproval_v1beta1 { /** * accessapproval.projects.updateAccessApprovalSettings - * @desc Updates the settings associated with a project, folder, or organization. Completely replaces the existing settings. + * @desc Updates the settings associated with a project, folder, or organization. Settings to update are determined by the value of field_mask. * @alias accessapproval.projects.updateAccessApprovalSettings * @memberOf! () * * @param {object} params Parameters for request * @param {string} params.name The resource name of the settings. Format is one of:
                  1. "projects/{project_id}/accessApprovalSettings"
                  2. "folders/{folder_id}/accessApprovalSettings"
                  3. "organizations/{organization_id}/accessApprovalSettings"
                    1. + * @param {string=} params.updateMask The update mask applies to the settings. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask If this field is left unset, only the notification_emails field will be updated. * @param {().AccessApprovalSettings} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1609,6 +1637,10 @@ export namespace accessapproval_v1beta1 { * The resource name of the settings. Format is one of:
                      1. "projects/{project_id}/accessApprovalSettings"
                      2. "folders/{folder_id}/accessApprovalSettings"
                      3. "organizations/{organization_id}/accessApprovalSettings"
                        1. */ name?: string; + /** + * The update mask applies to the settings. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask If this field is left unset, only the notification_emails field will be updated. + */ + updateMask?: string; /** * Request body metadata diff --git a/src/apis/adexperiencereport/v1.ts b/src/apis/adexperiencereport/v1.ts index 5ef1ced9a48..867b4af51e6 100644 --- a/src/apis/adexperiencereport/v1.ts +++ b/src/apis/adexperiencereport/v1.ts @@ -120,35 +120,35 @@ export namespace adexperiencereport_v1 { } /** - * Summary of the ad experience rating of a site for a specific platform. + * A site's Ad Experience Report summary on a single platform. */ export interface Schema$PlatformSummary { /** - * The status of the site reviewed for the Better Ads Standards. + * The site's Ad Experience Report status on this platform. */ betterAdsStatus?: string; /** - * The date on which ad filtering begins. + * The time at which [enforcement](https://support.google.com/webtools/answer/7308033) against the site began or will begin on this platform. Not set when the filter_status is OFF. */ enforcementTime?: string; /** - * The ad filtering status of the site. + * The site's [enforcement status](https://support.google.com/webtools/answer/7308033) on this platform. */ filterStatus?: string; /** - * The last time that the site changed status. + * The time at which the site's status last changed on this platform. */ lastChangeTime?: string; /** - * The assigned regions for the site and platform. + * The site's regions on this platform. No longer populated, because there is no longer any semantic difference between sites in different regions. */ region?: string[]; /** - * A link that leads to a full ad experience report. + * A link to the full Ad Experience Report for the site on this platform.. Not set in ViolatingSitesResponse. Note that you must complete the [Search Console verification process](https://support.google.com/webmasters/answer/9008080) for the site before you can access the full report. */ reportUrl?: string; /** - * Whether the site is currently under review. + * Whether the site is currently under review on this platform. */ underReview?: boolean; } @@ -157,15 +157,15 @@ export namespace adexperiencereport_v1 { */ export interface Schema$SiteSummaryResponse { /** - * Summary for the desktop review of the site. + * The site's Ad Experience Report summary on desktop. */ desktopSummary?: Schema$PlatformSummary; /** - * Summary for the mobile review of the site. + * The site's Ad Experience Report summary on mobile. */ mobileSummary?: Schema$PlatformSummary; /** - * The name of the site reviewed. + * The name of the reviewed site, e.g. `google.com`. */ reviewedSite?: string; } @@ -174,7 +174,7 @@ export namespace adexperiencereport_v1 { */ export interface Schema$ViolatingSitesResponse { /** - * A list of summaries of violating sites. + * The list of violating sites. */ violatingSites?: Schema$SiteSummaryResponse[]; } @@ -187,12 +187,12 @@ export namespace adexperiencereport_v1 { /** * adexperiencereport.sites.get - * @desc Gets a summary of the ad experience rating of a site. + * @desc Gets a site's Ad Experience Report summary. * @alias adexperiencereport.sites.get * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name The required site name. It should be the site property whose ad experiences may have been reviewed, and it should be URL-encoded. For example, sites/https%3A%2F%2Fwww.google.com. The server will return an error of BAD_REQUEST if this field is not filled in. Note that if the site property is not yet verified in Search Console, the reportUrl field returned by the API will lead to the verification page, prompting the user to go through that process before they can gain access to the Ad Experience Report. + * @param {string} params.name Required. The name of the site whose summary to get, e.g. `sites/http%3A%2F%2Fwww.google.com%2F`. Format: `sites/{site}` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -264,7 +264,7 @@ export namespace adexperiencereport_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The required site name. It should be the site property whose ad experiences may have been reviewed, and it should be URL-encoded. For example, sites/https%3A%2F%2Fwww.google.com. The server will return an error of BAD_REQUEST if this field is not filled in. Note that if the site property is not yet verified in Search Console, the reportUrl field returned by the API will lead to the verification page, prompting the user to go through that process before they can gain access to the Ad Experience Report. + * Required. The name of the site whose summary to get, e.g. `sites/http%3A%2F%2Fwww.google.com%2F`. Format: `sites/{site}` */ name?: string; } @@ -277,7 +277,7 @@ export namespace adexperiencereport_v1 { /** * adexperiencereport.violatingSites.list - * @desc Lists sites with Ad Experience Report statuses of "Failing" or "Warning". + * @desc Lists sites that are failing in the Ad Experience Report on at least one platform. * @alias adexperiencereport.violatingSites.list * @memberOf! () * diff --git a/src/apis/admin/directory_v1.ts b/src/apis/admin/directory_v1.ts index 9e3de9e8745..1b332af023f 100644 --- a/src/apis/admin/directory_v1.ts +++ b/src/apis/admin/directory_v1.ts @@ -519,6 +519,10 @@ export namespace admin_directory_v1 { * User of the device */ annotatedUser?: string; + /** + * (Read-only) The timestamp after which the device will stop receiving Chrome updates or support + */ + autoUpdateExpiration?: string; /** * Chromebook boot mode (Read-only) */ @@ -554,6 +558,10 @@ export namespace admin_directory_v1 { volumeId?: string; }>; }>; + /** + * (Read-only) Built-in MAC address for the docking station that the device connected to. Factory sets Media access control address (MAC address) assigned for use by a dock. Currently this is only supported on the Dell Arcada / Sarien devices and the Dell WD19 / WD19TB Docking Station. It is reserved specifically for MAC pass through device policy. The format is twelve (12) hexadecimal digits without any delimiter (uppercase letters). This is only relevant for Dell devices. + */ + dockMacAddress?: string; /** * ETag of the resource. */ @@ -562,6 +570,10 @@ export namespace admin_directory_v1 { * Chromebook Mac Address on ethernet network interface (Read-only) */ ethernetMacAddress?: string; + /** + * (Read-only) MAC address used by the Chromebook’s internal ethernet port, and for onboard network (ethernet) interface. The format is twelve (12) hexadecimal digits without any delimiter (uppercase letters). This is only relevant for Dell devices. + */ + ethernetMacAddress0?: string; /** * Chromebook firmware version (Read-only) */ @@ -582,6 +594,10 @@ export namespace admin_directory_v1 { * Chromebook Mac Address on wifi network interface (Read-only) */ macAddress?: string; + /** + * (Read-only) The date the device was manufactured in yyyy-mm-dd format. + */ + manufactureDate?: string; /** * Mobile Equipment identifier for the 3G mobile card in the Chromebook (Read-only) */ @@ -1010,7 +1026,7 @@ export namespace admin_directory_v1 { */ etag?: string; /** - * Unique identifier of customer member (Read-only) Unique identifier of group (Read-only) Unique identifier of member (Read-only) + * The unique ID of the group member. A member id can be used as a member request URI's memberKey. Unique identifier of group (Read-only) Unique identifier of member (Read-only) */ id?: string; /** @@ -1403,7 +1419,7 @@ export namespace admin_directory_v1 { */ privilegeName?: string; /** - * The obfuscated ID of the service this privilege is for. + * The obfuscated ID of the service this privilege is for. This value is returned with Privileges.list(). */ serviceId?: string; /** @@ -1832,6 +1848,14 @@ export namespace admin_directory_v1 { * username of User */ primaryEmail?: string; + /** + * Recovery email of the user. + */ + recoveryEmail?: string; + /** + * Recovery phone of the user. The phone number must be in the E.164 format, starting with the plus sign (+). Example: +16506661212. + */ + recoveryPhone?: string; relations?: any; sshPublicKeys?: any; /** @@ -2121,7 +2145,7 @@ export namespace admin_directory_v1 { */ domain?: string; /** - * The full-time equivalent percent within the organization (100000 = 100%). + * The full-time equivalent millipercent within the organization (100000 = 100%). */ fullTimeEquivalent?: number; /** @@ -2895,7 +2919,7 @@ export namespace admin_directory_v1 { * * @param {object} params Parameters for request * @param {string} params.customerId Immutable ID of the G Suite account - * @param {integer=} params.maxResults Maximum number of results to return. Default is 100 + * @param {integer=} params.maxResults Maximum number of results to return. Max allowed value is 200. * @param {string=} params.orderBy Column to use for sorting results * @param {string=} params.orgUnitPath Full path of the organizational unit or its ID * @param {string=} params.pageToken Token to specify next page in the list @@ -3250,7 +3274,7 @@ export namespace admin_directory_v1 { */ customerId?: string; /** - * Maximum number of results to return. Default is 100 + * Maximum number of results to return. Max allowed value is 200. */ maxResults?: number; /** @@ -4562,12 +4586,12 @@ export namespace admin_directory_v1 { * @param {object=} params Parameters for request * @param {string=} params.customer Immutable ID of the G Suite account. In case of multi-domain, to fetch all groups for a customer, fill this field instead of domain. * @param {string=} params.domain Name of the domain. Fill this field to get groups from only this domain. To return all groups in a multi-domain fill customer field instead. - * @param {integer=} params.maxResults Maximum number of results to return. Default is 200 + * @param {integer=} params.maxResults Maximum number of results to return. Max allowed value is 200. * @param {string=} params.orderBy Column to use for sorting results * @param {string=} params.pageToken Token to specify next page in the list * @param {string=} params.query Query string search. Should be of the form "". Complete documentation is at https://developers.google.com/admin-sdk/directory/v1/guides/search-groups * @param {string=} params.sortOrder Whether to return results in ascending or descending order. Only of use when orderBy is also used - * @param {string=} params.userKey Email or immutable Id of the user if only those groups are to be listed, the given user is a member of. If Id, it should match with id of user object + * @param {string=} params.userKey Email or immutable ID of the user if only those groups are to be listed, the given user is a member of. If it's an ID, it should match with the ID of the user object. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -4824,7 +4848,7 @@ export namespace admin_directory_v1 { */ domain?: string; /** - * Maximum number of results to return. Default is 200 + * Maximum number of results to return. Max allowed value is 200. */ maxResults?: number; /** @@ -4844,7 +4868,7 @@ export namespace admin_directory_v1 { */ sortOrder?: string; /** - * Email or immutable Id of the user if only those groups are to be listed, the given user is a member of. If Id, it should match with id of user object + * Email or immutable ID of the user if only those groups are to be listed, the given user is a member of. If it's an ID, it should match with the ID of the user object. */ userKey?: string; } @@ -5454,7 +5478,7 @@ export namespace admin_directory_v1 { * @param {object} params Parameters for request * @param {string} params.groupKey Email or immutable ID of the group * @param {boolean=} params.includeDerivedMembership Whether to list indirect memberships. Default: false. - * @param {integer=} params.maxResults Maximum number of results to return. Default is 200 + * @param {integer=} params.maxResults Maximum number of results to return. Max allowed value is 200. * @param {string=} params.pageToken Token to specify next page in the list * @param {string=} params.roles Comma separated role values to filter list results on. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. @@ -5743,7 +5767,7 @@ export namespace admin_directory_v1 { */ includeDerivedMembership?: boolean; /** - * Maximum number of results to return. Default is 200 + * Maximum number of results to return. Max allowed value is 200. */ maxResults?: number; /** @@ -6033,7 +6057,7 @@ export namespace admin_directory_v1 { * * @param {object} params Parameters for request * @param {string} params.customerId Immutable ID of the G Suite account - * @param {integer=} params.maxResults Maximum number of results to return. Default is 100 + * @param {integer=} params.maxResults Maximum number of results to return. Max allowed value is 100. * @param {string=} params.orderBy Column to use for sorting results * @param {string=} params.pageToken Token to specify next page in the list * @param {string=} params.projection Restrict information returned to a set of selected fields. @@ -6175,7 +6199,7 @@ export namespace admin_directory_v1 { */ customerId?: string; /** - * Maximum number of results to return. Default is 100 + * Maximum number of results to return. Max allowed value is 100. */ maxResults?: number; /** @@ -11278,12 +11302,12 @@ export namespace admin_directory_v1 { * @param {string=} params.customFieldMask Comma-separated list of schema names. All fields from these schemas are fetched. This should only be set when projection=custom. * @param {string=} params.domain Name of the domain. Fill this field to get users from only this domain. To return all users in a multi-domain fill customer field instead. * @param {string=} params.event Event on which subscription is intended (if subscribing) - * @param {integer=} params.maxResults Maximum number of results to return. Default is 100. Max allowed is 500 + * @param {integer=} params.maxResults Maximum number of results to return. * @param {string=} params.orderBy Column to use for sorting results * @param {string=} params.pageToken Token to specify next page in the list * @param {string=} params.projection What subset of fields to fetch for this user. * @param {string=} params.query Query string search. Should be of the form "". Complete documentation is at https://developers.google.com/admin-sdk/directory/v1/guides/search-users - * @param {string=} params.showDeleted If set to true retrieves the list of deleted users. Default is false + * @param {string=} params.showDeleted If set to true, retrieves the list of deleted users. (Default: false) * @param {string=} params.sortOrder Whether to return results in ascending or descending order. * @param {string=} params.viewType Whether to fetch the ADMIN_VIEW or DOMAIN_PUBLIC view of the user. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. @@ -11646,12 +11670,12 @@ export namespace admin_directory_v1 { * @param {string=} params.customFieldMask Comma-separated list of schema names. All fields from these schemas are fetched. This should only be set when projection=custom. * @param {string=} params.domain Name of the domain. Fill this field to get users from only this domain. To return all users in a multi-domain fill customer field instead. * @param {string=} params.event Event on which subscription is intended (if subscribing) - * @param {integer=} params.maxResults Maximum number of results to return. Default is 100. Max allowed is 500 + * @param {integer=} params.maxResults Maximum number of results to return. * @param {string=} params.orderBy Column to use for sorting results * @param {string=} params.pageToken Token to specify next page in the list * @param {string=} params.projection What subset of fields to fetch for this user. * @param {string=} params.query Query string search. Should be of the form "". Complete documentation is at https://developers.google.com/admin-sdk/directory/v1/guides/search-users - * @param {string=} params.showDeleted If set to true retrieves the list of deleted users. Default is false + * @param {string=} params.showDeleted If set to true, retrieves the list of deleted users. (Default: false) * @param {string=} params.sortOrder Whether to return results in ascending or descending order. * @param {string=} params.viewType Whether to fetch the ADMIN_VIEW or DOMAIN_PUBLIC view of the user. * @param {().Channel} params.resource Request body data @@ -11787,7 +11811,7 @@ export namespace admin_directory_v1 { */ event?: string; /** - * Maximum number of results to return. Default is 100. Max allowed is 500 + * Maximum number of results to return. */ maxResults?: number; /** @@ -11807,7 +11831,7 @@ export namespace admin_directory_v1 { */ query?: string; /** - * If set to true retrieves the list of deleted users. Default is false + * If set to true, retrieves the list of deleted users. (Default: false) */ showDeleted?: string; /** @@ -11906,7 +11930,7 @@ export namespace admin_directory_v1 { */ event?: string; /** - * Maximum number of results to return. Default is 100. Max allowed is 500 + * Maximum number of results to return. */ maxResults?: number; /** @@ -11926,7 +11950,7 @@ export namespace admin_directory_v1 { */ query?: string; /** - * If set to true retrieves the list of deleted users. Default is false + * If set to true, retrieves the list of deleted users. (Default: false) */ showDeleted?: string; /** diff --git a/src/apis/alertcenter/v1beta1.ts b/src/apis/alertcenter/v1beta1.ts index 6018e4daf28..b68e744696c 100644 --- a/src/apis/alertcenter/v1beta1.ts +++ b/src/apis/alertcenter/v1beta1.ts @@ -213,12 +213,20 @@ export namespace alertcenter_v1beta1 { * Optional. The time the event that caused this alert ceased being active. If provided, the end time must not be earlier than the start time. If not provided, it indicates an ongoing alert. */ endTime?: string; + /** + * Optional. `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of an alert from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform alert updates in order to avoid race conditions: An `etag` is returned in the response which contains alerts, and systems are expected to put that etag in the request to update alert to ensure that their change will be applied to the same version of the alert. If no `etag` is provided in the call to update alert, then the existing alert is overwritten blindly. + */ + etag?: string; + /** + * Output only. The metadata associated with this alert. + */ + metadata?: Schema$AlertMetadata; /** * Output only. An optional [Security Investigation Tool](https://support.google.com/a/answer/7575955) query for this alert. */ securityInvestigationToolLink?: string; /** - * Required. A unique identifier for the system that reported the alert. This is output only after alert is created. Supported sources are any of the following: * Google Operations * Mobile device management * Gmail phishing * Domain wide takeout * Government attack warning * Google identity + * Required. A unique identifier for the system that reported the alert. This is output only after alert is created. Supported sources are any of the following: * Google Operations * Mobile device management * Gmail phishing * Domain wide takeout * State sponsored attack * Google identity */ source?: string; /** @@ -263,6 +271,39 @@ export namespace alertcenter_v1beta1 { */ type?: string; } + /** + * An alert metadata. + */ + export interface Schema$AlertMetadata { + /** + * Output only. The alert identifier. + */ + alertId?: string; + /** + * The email address of the user assigned to the alert. + */ + assignee?: string; + /** + * Output only. The unique identifier of the Google account of the customer. + */ + customerId?: string; + /** + * Optional. `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of an alert metadata from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform metatdata updates in order to avoid race conditions: An `etag` is returned in the response which contains alert metadata, and systems are expected to put that etag in the request to update alert metadata to ensure that their change will be applied to the same version of the alert metadata. If no `etag` is provided in the call to update alert metadata, then the existing alert metadata is overwritten blindly. + */ + etag?: string; + /** + * The severity value of the alert. Alert Center will set this field at alert creation time, default's to an empty string when it could not be determined. The supported values for update actions on this field are the following: * HIGH * MEDIUM * LOW + */ + severity?: string; + /** + * The current status of the alert. The supported values are the following: * NOT_STARTED * IN_PROGRESS * CLOSED + */ + status?: string; + /** + * Output only. The time this metadata was last updated. + */ + updateTime?: string; + } /** * Attachment with application-specific information about an alert. */ @@ -293,6 +334,58 @@ export namespace alertcenter_v1beta1 { */ sourceIp?: string; } + /** + * A request to perform batch delete on alerts. + */ + export interface Schema$BatchDeleteAlertsRequest { + /** + * Required. list of alert ids. + */ + alertId?: string[]; + /** + * Optional. The unique identifier of the G Suite organization account of the customer the alerts are associated with. + */ + customerId?: string; + } + /** + * Response to batch delete operation on alerts. + */ + export interface Schema$BatchDeleteAlertsResponse { + /** + * The status details for each failed alert_id. + */ + failedAlertStatus?: {[key: string]: Schema$Status}; + /** + * The successful list of alert ids. + */ + successAlertIds?: string[]; + } + /** + * A request to perform batch undelete on alerts. + */ + export interface Schema$BatchUndeleteAlertsRequest { + /** + * Required. list of alert ids. + */ + alertId?: string[]; + /** + * Optional. The unique identifier of the G Suite organization account of the customer the alerts are associated with. + */ + customerId?: string; + } + /** + * Response to batch undelete operation on alerts. + */ + export interface Schema$BatchUndeleteAlertsResponse { + /** + * The status details for each failed alert_id. + */ + failedAlertStatus?: {[key: string]: Schema$Status}; + /** + * The successful list of alert ids. + */ + successAlertIds?: string[]; + } /** * A reference to a Cloud Pubsub topic. To register for notifications, the owner of the topic must grant `alerts-api-push-notifications@system.gserviceaccount.com` the `projects.topics.publish` permission. */ @@ -575,6 +668,23 @@ export namespace alertcenter_v1beta1 { */ email?: string; } + /** + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). + */ + export interface Schema$Status { + /** + * The status code, which should be an enum value of google.rpc.Code. + */ + code?: number; + /** + * A list of messages that carry the error details. There is a common set of message types for APIs to use. + */ + details?: Array<{[key: string]: any}>; + /** + * A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. + */ + message?: string; + } /** * A mobile suspicious activity alert. Derived from audit logs. */ @@ -647,6 +757,168 @@ export namespace alertcenter_v1beta1 { this.feedback = new Resource$Alerts$Feedback(this.context); } + /** + * alertcenter.alerts.batchDelete + * @desc Performs batch delete operation on alerts. + * @alias alertcenter.alerts.batchDelete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().BatchDeleteAlertsRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + batchDelete( + params?: Params$Resource$Alerts$Batchdelete, + options?: MethodOptions + ): GaxiosPromise; + batchDelete( + params: Params$Resource$Alerts$Batchdelete, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + batchDelete( + params: Params$Resource$Alerts$Batchdelete, + callback: BodyResponseCallback + ): void; + batchDelete( + callback: BodyResponseCallback + ): void; + batchDelete( + paramsOrCallback?: + | Params$Resource$Alerts$Batchdelete + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Alerts$Batchdelete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Alerts$Batchdelete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://alertcenter.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1beta1/alerts:batchDelete').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest(parameters); + } + } + + /** + * alertcenter.alerts.batchUndelete + * @desc Performs batch undelete operation on alerts. + * @alias alertcenter.alerts.batchUndelete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().BatchUndeleteAlertsRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + batchUndelete( + params?: Params$Resource$Alerts$Batchundelete, + options?: MethodOptions + ): GaxiosPromise; + batchUndelete( + params: Params$Resource$Alerts$Batchundelete, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + batchUndelete( + params: Params$Resource$Alerts$Batchundelete, + callback: BodyResponseCallback + ): void; + batchUndelete( + callback: BodyResponseCallback + ): void; + batchUndelete( + paramsOrCallback?: + | Params$Resource$Alerts$Batchundelete + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Alerts$Batchundelete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Alerts$Batchundelete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://alertcenter.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1beta1/alerts:batchUndelete').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest(parameters); + } + } + /** * alertcenter.alerts.delete * @desc Marks the specified alert for deletion. An alert that has been marked for deletion is removed from Alert Center after 30 days. Marking an alert for deletion has no effect on an alert which has already been marked for deletion. Attempting to mark a nonexistent alert for deletion results in a `NOT_FOUND` error. @@ -791,6 +1063,81 @@ export namespace alertcenter_v1beta1 { } } + /** + * alertcenter.alerts.getMetadata + * @desc Returns the metadata of an alert. Attempting to get metadata for a non-existent alert returns `NOT_FOUND` error. + * @alias alertcenter.alerts.getMetadata + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.alertId Required. The identifier of the alert this metadata belongs to. + * @param {string=} params.customerId Optional. The unique identifier of the G Suite organization account of the customer the alert metadata is associated with. Inferred from the caller identity if not provided. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + getMetadata( + params?: Params$Resource$Alerts$Getmetadata, + options?: MethodOptions + ): GaxiosPromise; + getMetadata( + params: Params$Resource$Alerts$Getmetadata, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + getMetadata( + params: Params$Resource$Alerts$Getmetadata, + callback: BodyResponseCallback + ): void; + getMetadata(callback: BodyResponseCallback): void; + getMetadata( + paramsOrCallback?: + | Params$Resource$Alerts$Getmetadata + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Alerts$Getmetadata; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Alerts$Getmetadata; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://alertcenter.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1beta1/alerts/{alertId}/metadata').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['alertId'], + pathParams: ['alertId'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + /** * alertcenter.alerts.list * @desc Lists the alerts. @@ -938,6 +1285,30 @@ export namespace alertcenter_v1beta1 { } } + export interface Params$Resource$Alerts$Batchdelete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Request body metadata + */ + requestBody?: Schema$BatchDeleteAlertsRequest; + } + export interface Params$Resource$Alerts$Batchundelete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Request body metadata + */ + requestBody?: Schema$BatchUndeleteAlertsRequest; + } export interface Params$Resource$Alerts$Delete extends StandardParameters { /** * Auth client or API Key for the request @@ -968,6 +1339,22 @@ export namespace alertcenter_v1beta1 { */ customerId?: string; } + export interface Params$Resource$Alerts$Getmetadata + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The identifier of the alert this metadata belongs to. + */ + alertId?: string; + /** + * Optional. The unique identifier of the G Suite organization account of the customer the alert metadata is associated with. Inferred from the caller identity if not provided. + */ + customerId?: string; + } export interface Params$Resource$Alerts$List extends StandardParameters { /** * Auth client or API Key for the request @@ -1020,7 +1407,7 @@ export namespace alertcenter_v1beta1 { /** * alertcenter.alerts.feedback.create - * @desc Creates new feedback for an alert. Attempting to create a feedback for a non-existent alert returns `NOT_FOUND` error. + * @desc Creates new feedback for an alert. Attempting to create a feedback for a non-existent alert returns `NOT_FOUND` error. Attempting to create a feedback for an alert that is marked for deletion returns `FAILED_PRECONDITION' error. * @alias alertcenter.alerts.feedback.create * @memberOf! () * diff --git a/src/apis/analytics/v3.ts b/src/apis/analytics/v3.ts index a8d7cc597d1..d94e62075fc 100644 --- a/src/apis/analytics/v3.ts +++ b/src/apis/analytics/v3.ts @@ -2285,6 +2285,10 @@ export namespace analytics_v3 { * Value is "analytics#userDeletionRequest". */ kind?: string; + /** + * Property ID + */ + propertyId?: string; /** * Web property ID of the form UA-XXXXX-YY. */ diff --git a/src/apis/analyticsreporting/v4.ts b/src/apis/analyticsreporting/v4.ts index d7e38d37e40..a020f2458ee 100644 --- a/src/apis/analyticsreporting/v4.ts +++ b/src/apis/analyticsreporting/v4.ts @@ -124,7 +124,7 @@ export namespace analyticsreporting_v4 { */ export interface Schema$Activity { /** - * Timestamp of the activity. + * Timestamp of the activity. If activities for a visit cross midnight and occur in two separate dates, then two sessions (one per date) share the session identifier. */ activityTime?: string; /** @@ -210,7 +210,7 @@ export namespace analyticsreporting_v4 { */ cohorts?: Schema$Cohort[]; /** - * Enable Life Time Value (LTV). LTV measures lifetime value for users acquired through different channels. Please see: [Cohort Analysis](https://support.google.com/analytics/answer/6074676) and [Lifetime Value](https://support.google.com/analytics/answer/6182550) If the value of lifetimeValue is false: - The metric values are similar to the values in the web interface cohort report. - The cohort definition date ranges must be aligned to the calendar week and month. i.e. while requesting `ga:cohortNthWeek` the `startDate` in the cohort definition should be a Sunday and the `endDate` should be the following Saturday, and for `ga:cohortNthMonth`, the `startDate` should be the 1st of the month and `endDate` should be the last day of the month. When the lifetimeValue is true: - The metric values will correspond to the values in the web interface LifeTime value report. - The Lifetime Value report shows you how user value (Revenue) and engagement (Appviews, Goal Completions, Sessions, and Session Duration) grow during the 90 days after a user is acquired. - The metrics are calculated as a cumulative average per user per the time increment. - The cohort definition date ranges need not be aligned to the calendar week and month boundaries. - The `viewId` must be an [app view ID](https://support.google.com/analytics/answer/2649553#WebVersusAppViews) + * Enable Life Time Value (LTV). LTV measures lifetime value for users acquired through different channels. Please see: [Cohort Analysis](https://support.google.com/analytics/answer/6074676) and [Lifetime Value](https://support.google.com/analytics/answer/6182550) If the value of lifetimeValue is false: - The metric values are similar to the values in the web interface cohort report. - The cohort definition date ranges must be aligned to the calendar week and month. i.e. while requesting `ga:cohortNthWeek` the `startDate` in the cohort definition should be a Sunday and the `endDate` should be the following Saturday, and for `ga:cohortNthMonth`, the `startDate` should be the 1st of the month and `endDate` should be the last day of the month. When the lifetimeValue is true: - The metric values will correspond to the values in the web interface LifeTime value report. - The Lifetime Value report shows you how user value (Revenue) and engagement (Appviews, Goal Completions, Sessions, and Session Duration) grow during the 90 days after a user is acquired. - The metrics are calculated as a cumulative average per user per the time increment. - The cohort definition date ranges need not be aligned to the calendar week and month boundaries. - The `viewId` must be an [app view ID](https://support.google.com/analytics/answer/2649553#WebVersusAppViews) */ lifetimeValue?: boolean; } @@ -732,7 +732,7 @@ export namespace analyticsreporting_v4 { */ dimensionFilterClauses?: Schema$DimensionFilterClause[]; /** - * The dimensions requested. Requests can have a total of 7 dimensions. + * The dimensions requested. Requests can have a total of 9 dimensions. */ dimensions?: Schema$Dimension[]; /** diff --git a/src/apis/androidenterprise/v1.ts b/src/apis/androidenterprise/v1.ts index e3b1778179d..627d479f29b 100644 --- a/src/apis/androidenterprise/v1.ts +++ b/src/apis/androidenterprise/v1.ts @@ -172,7 +172,7 @@ export namespace androidenterprise_v1 { */ managedConfigurations?: Schema$AdministratorWebTokenSpecManagedConfigurations; /** - * The URI of the parent frame hosting the iframe. To prevent XSS, the iframe may not be hosted at other URIs. This URI must be https. + * The URI of the parent frame hosting the iframe. To prevent XSS, the iframe may not be hosted at other URIs. This URI must be https. Use whitespaces to separate multiple parent URIs. */ parent?: string; /** diff --git a/src/apis/androidmanagement/v1.ts b/src/apis/androidmanagement/v1.ts index d7024615083..1eaac62fc85 100644 --- a/src/apis/androidmanagement/v1.ts +++ b/src/apis/androidmanagement/v1.ts @@ -213,7 +213,7 @@ export namespace androidmanagement_v1 { */ installType?: string; /** - * Whether the app is allowed to lock itself in full-screen mode. + * Whether the app is allowed to lock itself in full-screen mode. DEPRECATED. Use InstallType KIOSK or kioskCustomLauncherEnabled to to configure a dedicated device. */ lockTaskAllowed?: boolean; /** @@ -483,6 +483,10 @@ export namespace androidmanagement_v1 { * If the same physical device has been enrolled multiple times, this field contains its previous device names. The serial number is used as the unique identifier to determine if the same physical device has enrolled previously. The names are in chronological order. */ previousDeviceNames?: string[]; + /** + * Device's security posture value that reflects how secure the device is. + */ + securityPosture?: Schema$SecurityPosture; /** * Detailed information about the device software. This information is only available if softwareInfoEnabled is true in the device's policy. */ @@ -1110,7 +1114,7 @@ export namespace androidmanagement_v1 { policy?: string; } /** - * A default activity for handling intents that match a particular intent filter. + * A default activity for handling intents that match a particular intent filter. Note: To set up a kiosk, use InstallType to KIOSK rather than use persistent preferred activities. */ export interface Schema$PersistentPreferredActivity { /** @@ -1255,7 +1259,7 @@ export namespace androidmanagement_v1 { */ keyguardDisabledFeatures?: string[]; /** - * Whether the kiosk custom launcher is enabled. This replaces the home screen with a launcher that locks down the device to the apps installed via the applications setting. The apps appear on a single page in alphabetical order. It is recommended to also use status_bar_disabled to block access to device settings. + * Whether the kiosk custom launcher is enabled. This replaces the home screen with a launcher that locks down the device to the apps installed via the applications setting. Apps appear on a single page in alphabetical order. The status bar is disabled when this is set. */ kioskCustomLauncherEnabled?: boolean; /** @@ -1387,7 +1391,7 @@ export namespace androidmanagement_v1 { */ smsDisabled?: boolean; /** - * Whether the status bar is disabled. This disables notifications, quick settings, and other screen overlays that allow escape from full-screen mode. + * Whether the status bar is disabled. This disables notifications, quick settings, and other screen overlays that allow escape from full-screen mode. DEPRECATED. To disable the status bar on a kiosk device, use InstallType KIOSK or kioskCustomLauncherEnabled. */ statusBarDisabled?: boolean; /** @@ -1456,6 +1460,19 @@ export namespace androidmanagement_v1 { */ wipeAction?: Schema$WipeAction; } + /** + * Detail that provides further information if the device is not in the most secure state. + */ + export interface Schema$PostureDetail { + /** + * Corresponding pieces of advice to mitigate the security risk. + */ + advice?: Schema$UserFacingMessage[]; + /** + * The risk that makes the device not in the most secure state. + */ + securityRisk?: string; + } /** * A power management event. */ @@ -1494,6 +1511,19 @@ export namespace androidmanagement_v1 { */ port?: number; } + /** + * . Device's security posture value that reflects how secure the device is. + */ + export interface Schema$SecurityPosture { + /** + * Device's security posture value. + */ + devicePosture?: string; + /** + * Details that provide further information if the device is not in the most secure state. + */ + postureDetails?: Schema$PostureDetail[]; + } /** * An action executed during setup. */ @@ -1643,6 +1673,10 @@ export namespace androidmanagement_v1 { * Whether software info reporting is enabled. */ softwareInfoEnabled?: boolean; + /** + * Whether system properties reporting is enabled. + */ + systemPropertiesEnabled?: boolean; } /** * Configuration for managing system updates diff --git a/src/apis/androidpublisher/v2.ts b/src/apis/androidpublisher/v2.ts index 55cb028ea96..c5fd5c7ff2a 100644 --- a/src/apis/androidpublisher/v2.ts +++ b/src/apis/androidpublisher/v2.ts @@ -398,6 +398,10 @@ export namespace androidpublisher_v2 { * A sha1 hash of the image that was uploaded. */ sha1?: string; + /** + * A sha256 hash of the image that was uploaded. + */ + sha256?: string; /** * A URL that will serve a preview of the image. */ @@ -860,7 +864,7 @@ export namespace androidpublisher_v2 { */ purchaseTimeMillis?: string; /** - * The token that was generated when a purchase was made. This uniquely identifies a purchase. + * The token which uniquely identifies a one-time purchase or subscription. To uniquely identify subscription renewals use order_id (available starting from version 3 of the API). */ purchaseToken?: string; /** @@ -6468,11 +6472,11 @@ export namespace androidpublisher_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.endTime The time, in milliseconds since the Epoch, of the newest voided in-app product purchase that you want to see in the response. The value of this parameter cannot be greater than the current time and is ignored if a pagination token is set. Default value is current time. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. + * @param {string=} params.endTime The time, in milliseconds since the Epoch, of the newest voided purchase that you want to see in the response. The value of this parameter cannot be greater than the current time and is ignored if a pagination token is set. Default value is current time. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. * @param {integer=} params.maxResults * @param {string} params.packageName The package name of the application for which voided purchases need to be returned (for example, 'com.some.thing'). * @param {integer=} params.startIndex - * @param {string=} params.startTime The time, in milliseconds since the Epoch, of the oldest voided in-app product purchase that you want to see in the response. The value of this parameter cannot be older than 30 days and is ignored if a pagination token is set. Default value is current time minus 30 days. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. + * @param {string=} params.startTime The time, in milliseconds since the Epoch, of the oldest voided purchase that you want to see in the response. The value of this parameter cannot be older than 30 days and is ignored if a pagination token is set. Default value is current time minus 30 days. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. * @param {string=} params.token * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -6556,7 +6560,7 @@ export namespace androidpublisher_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The time, in milliseconds since the Epoch, of the newest voided in-app product purchase that you want to see in the response. The value of this parameter cannot be greater than the current time and is ignored if a pagination token is set. Default value is current time. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. + * The time, in milliseconds since the Epoch, of the newest voided purchase that you want to see in the response. The value of this parameter cannot be greater than the current time and is ignored if a pagination token is set. Default value is current time. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. */ endTime?: string; /** @@ -6572,7 +6576,7 @@ export namespace androidpublisher_v2 { */ startIndex?: number; /** - * The time, in milliseconds since the Epoch, of the oldest voided in-app product purchase that you want to see in the response. The value of this parameter cannot be older than 30 days and is ignored if a pagination token is set. Default value is current time minus 30 days. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. + * The time, in milliseconds since the Epoch, of the oldest voided purchase that you want to see in the response. The value of this parameter cannot be older than 30 days and is ignored if a pagination token is set. Default value is current time minus 30 days. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. */ startTime?: string; /** diff --git a/src/apis/androidpublisher/v3.ts b/src/apis/androidpublisher/v3.ts index 356a74241c7..b730322bd9a 100644 --- a/src/apis/androidpublisher/v3.ts +++ b/src/apis/androidpublisher/v3.ts @@ -389,6 +389,10 @@ export namespace androidpublisher_v3 { * A sha1 hash of the image that was uploaded. */ sha1?: string; + /** + * A sha256 hash of the image that was uploaded. + */ + sha256?: string; /** * A URL that will serve a preview of the image. */ @@ -944,14 +948,26 @@ export namespace androidpublisher_v3 { * This kind represents a voided purchase object in the androidpublisher service. */ kind?: string; + /** + * The order id which uniquely identifies a one-time purchase, subscription purchase, or subscription renewal. + */ + orderId?: string; /** * The time at which the purchase was made, in milliseconds since the epoch (Jan 1, 1970). */ purchaseTimeMillis?: string; /** - * The token that was generated when a purchase was made. This uniquely identifies a purchase. + * The token which uniquely identifies a one-time purchase or subscription. To uniquely identify subscription renewals use order_id (available starting from version 3 of the API). */ purchaseToken?: string; + /** + * The reason why the purchase was voided, possible values are: - Other - Remorse - Not_received - Defective - Accidental_purchase - Fraud - Friendly_fraud - Chargeback + */ + voidedReason?: number; + /** + * The initiator of voided purchase, possible values are: - User - Developer - Google + */ + voidedSource?: number; /** * The time at which the purchase was canceled/refunded/charged-back, in milliseconds since the epoch (Jan 1, 1970). */ @@ -6379,12 +6395,13 @@ export namespace androidpublisher_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.endTime The time, in milliseconds since the Epoch, of the newest voided in-app product purchase that you want to see in the response. The value of this parameter cannot be greater than the current time and is ignored if a pagination token is set. Default value is current time. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. + * @param {string=} params.endTime The time, in milliseconds since the Epoch, of the newest voided purchase that you want to see in the response. The value of this parameter cannot be greater than the current time and is ignored if a pagination token is set. Default value is current time. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. * @param {integer=} params.maxResults * @param {string} params.packageName The package name of the application for which voided purchases need to be returned (for example, 'com.some.thing'). * @param {integer=} params.startIndex - * @param {string=} params.startTime The time, in milliseconds since the Epoch, of the oldest voided in-app product purchase that you want to see in the response. The value of this parameter cannot be older than 30 days and is ignored if a pagination token is set. Default value is current time minus 30 days. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. + * @param {string=} params.startTime The time, in milliseconds since the Epoch, of the oldest voided purchase that you want to see in the response. The value of this parameter cannot be older than 30 days and is ignored if a pagination token is set. Default value is current time minus 30 days. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. * @param {string=} params.token + * @param {integer=} params.type The type of voided purchases that you want to see in the response. Possible values are: - 0: Only voided in-app product purchases will be returned in the response. This is the default value. - 1: Both voided in-app purchases and voided subscription purchases will be returned in the response. Note: Before requesting to receive voided subscription purchases, you must switch to use orderId in the response which uniquely identifies one-time purchases and subscriptions. Otherwise, you will receive multiple subscription orders with the same PurchaseToken, because subscription renewal orders share the same PurchaseToken. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -6467,7 +6484,7 @@ export namespace androidpublisher_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The time, in milliseconds since the Epoch, of the newest voided in-app product purchase that you want to see in the response. The value of this parameter cannot be greater than the current time and is ignored if a pagination token is set. Default value is current time. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. + * The time, in milliseconds since the Epoch, of the newest voided purchase that you want to see in the response. The value of this parameter cannot be greater than the current time and is ignored if a pagination token is set. Default value is current time. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. */ endTime?: string; /** @@ -6483,13 +6500,17 @@ export namespace androidpublisher_v3 { */ startIndex?: number; /** - * The time, in milliseconds since the Epoch, of the oldest voided in-app product purchase that you want to see in the response. The value of this parameter cannot be older than 30 days and is ignored if a pagination token is set. Default value is current time minus 30 days. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. + * The time, in milliseconds since the Epoch, of the oldest voided purchase that you want to see in the response. The value of this parameter cannot be older than 30 days and is ignored if a pagination token is set. Default value is current time minus 30 days. Note: This filter is applied on the time at which the record is seen as voided by our systems and not the actual voided time returned in the response. */ startTime?: string; /** * */ token?: string; + /** + * The type of voided purchases that you want to see in the response. Possible values are: - 0: Only voided in-app product purchases will be returned in the response. This is the default value. - 1: Both voided in-app purchases and voided subscription purchases will be returned in the response. Note: Before requesting to receive voided subscription purchases, you must switch to use orderId in the response which uniquely identifies one-time purchases and subscriptions. Otherwise, you will receive multiple subscription orders with the same PurchaseToken, because subscription renewal orders share the same PurchaseToken. + */ + type?: number; } export class Resource$Reviews { diff --git a/src/apis/appstate/v1.ts b/src/apis/appstate/v1.ts deleted file mode 100644 index 453499a00d8..00000000000 --- a/src/apis/appstate/v1.ts +++ /dev/null @@ -1,614 +0,0 @@ -/** - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { - OAuth2Client, - JWT, - Compute, - UserRefreshClient, -} from 'google-auth-library'; -import { - GoogleConfigurable, - createAPIRequest, - MethodOptions, - GlobalOptions, - BodyResponseCallback, - APIRequestContext, -} from 'googleapis-common'; -import {GaxiosPromise} from 'gaxios'; - -// tslint:disable: no-any -// tslint:disable: class-name -// tslint:disable: variable-name -// tslint:disable: jsdoc-format -// tslint:disable: no-namespace - -export namespace appstate_v1 { - export interface Options extends GlobalOptions { - version: 'v1'; - } - - interface StandardParameters { - /** - * Data format for the response. - */ - alt?: string; - /** - * Selector specifying which fields to include in a partial response. - */ - fields?: string; - /** - * 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. - */ - key?: string; - /** - * OAuth 2.0 token for the current user. - */ - oauth_token?: string; - /** - * Returns response with indentations and line breaks. - */ - prettyPrint?: boolean; - /** - * An opaque string that represents a user for quota purposes. Must not exceed 40 characters. - */ - quotaUser?: string; - /** - * Deprecated. Please use quotaUser instead. - */ - userIp?: string; - } - - /** - * Google App State API - * - * The Google App State API. - * - * @example - * const {google} = require('googleapis'); - * const appstate = google.appstate('v1'); - * - * @namespace appstate - * @type {Function} - * @version v1 - * @variation v1 - * @param {object=} options Options for Appstate - */ - export class Appstate { - context: APIRequestContext; - states: Resource$States; - - constructor(options: GlobalOptions, google?: GoogleConfigurable) { - this.context = { - _options: options || {}, - google, - }; - - this.states = new Resource$States(this.context); - } - } - - /** - * This is a JSON template for an app state resource. - */ - export interface Schema$GetResponse { - /** - * The current app state version. - */ - currentStateVersion?: string; - /** - * The requested data. - */ - data?: string; - /** - * Uniquely identifies the type of this resource. Value is always the fixed string appstate#getResponse. - */ - kind?: string; - /** - * The key for the data. - */ - stateKey?: number; - } - /** - * This is a JSON template to convert a list-response for app state. - */ - export interface Schema$ListResponse { - /** - * The app state data. - */ - items?: Schema$GetResponse[]; - /** - * Uniquely identifies the type of this resource. Value is always the fixed string appstate#listResponse. - */ - kind?: string; - /** - * The maximum number of keys allowed for this user. - */ - maximumKeyCount?: number; - } - /** - * This is a JSON template for a requests which update app state - */ - export interface Schema$UpdateRequest { - /** - * The new app state data that your application is trying to update with. - */ - data?: string; - /** - * Uniquely identifies the type of this resource. Value is always the fixed string appstate#updateRequest. - */ - kind?: string; - } - /** - * This is a JSON template for an app state write result. - */ - export interface Schema$WriteResult { - /** - * The version of the data for this key on the server. - */ - currentStateVersion?: string; - /** - * Uniquely identifies the type of this resource. Value is always the fixed string appstate#writeResult. - */ - kind?: string; - /** - * The written key. - */ - stateKey?: number; - } - - export class Resource$States { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * appstate.states.clear - * @desc Clears (sets to empty) the data for the passed key if and only if the passed version matches the currently stored version. This method results in a conflict error on version mismatch. - * @alias appstate.states.clear - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.currentDataVersion The version of the data to be cleared. Version strings are returned by the server. - * @param {integer} params.stateKey The key for the data to be retrieved. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - clear( - params?: Params$Resource$States$Clear, - options?: MethodOptions - ): GaxiosPromise; - clear( - params: Params$Resource$States$Clear, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - clear( - params: Params$Resource$States$Clear, - callback: BodyResponseCallback - ): void; - clear(callback: BodyResponseCallback): void; - clear( - paramsOrCallback?: - | Params$Resource$States$Clear - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$States$Clear; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$States$Clear; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/appstate/v1/states/{stateKey}/clear').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'POST', - }, - options - ), - params, - requiredParams: ['stateKey'], - pathParams: ['stateKey'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * appstate.states.delete - * @desc Deletes a key and the data associated with it. The key is removed and no longer counts against the key quota. Note that since this method is not safe in the face of concurrent modifications, it should only be used for development and testing purposes. Invoking this method in shipping code can result in data loss and data corruption. - * @alias appstate.states.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {integer} params.stateKey The key for the data to be retrieved. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$States$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$States$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$States$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$States$Delete - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$States$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$States$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/appstate/v1/states/{stateKey}').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['stateKey'], - pathParams: ['stateKey'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * appstate.states.get - * @desc Retrieves the data corresponding to the passed key. If the key does not exist on the server, an HTTP 404 will be returned. - * @alias appstate.states.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {integer} params.stateKey The key for the data to be retrieved. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$States$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$States$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$States$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$States$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$States$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$States$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/appstate/v1/states/{stateKey}').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'GET', - }, - options - ), - params, - requiredParams: ['stateKey'], - pathParams: ['stateKey'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * appstate.states.list - * @desc Lists all the states keys, and optionally the state data. - * @alias appstate.states.list - * @memberOf! () - * - * @param {object=} params Parameters for request - * @param {boolean=} params.includeData Whether to include the full data in addition to the version number - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$States$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$States$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$States$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$States$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$States$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$States$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/appstate/v1/states').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'GET', - }, - options - ), - params, - requiredParams: [], - pathParams: [], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * appstate.states.update - * @desc Update the data associated with the input key if and only if the passed version matches the currently stored version. This method is safe in the face of concurrent writes. Maximum per-key size is 128KB. - * @alias appstate.states.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.currentStateVersion The version of the app state your application is attempting to update. If this does not match the current version, this method will return a conflict error. If there is no data stored on the server for this key, the update will succeed irrespective of the value of this parameter. - * @param {integer} params.stateKey The key for the data to be retrieved. - * @param {().UpdateRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$States$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$States$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$States$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$States$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$States$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$States$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/appstate/v1/states/{stateKey}').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['stateKey'], - pathParams: ['stateKey'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$States$Clear extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The version of the data to be cleared. Version strings are returned by the server. - */ - currentDataVersion?: string; - /** - * The key for the data to be retrieved. - */ - stateKey?: number; - } - export interface Params$Resource$States$Delete extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The key for the data to be retrieved. - */ - stateKey?: number; - } - export interface Params$Resource$States$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The key for the data to be retrieved. - */ - stateKey?: number; - } - export interface Params$Resource$States$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Whether to include the full data in addition to the version number - */ - includeData?: boolean; - } - export interface Params$Resource$States$Update extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The version of the app state your application is attempting to update. If this does not match the current version, this method will return a conflict error. If there is no data stored on the server for this key, the update will succeed irrespective of the value of this parameter. - */ - currentStateVersion?: string; - /** - * The key for the data to be retrieved. - */ - stateKey?: number; - - /** - * Request body metadata - */ - requestBody?: Schema$UpdateRequest; - } -} diff --git a/src/apis/bigquery/v2.ts b/src/apis/bigquery/v2.ts index a0fd7a90a38..f2fe7486fac 100644 --- a/src/apis/bigquery/v2.ts +++ b/src/apis/bigquery/v2.ts @@ -342,12 +342,51 @@ export namespace bigquery_v2 { learnRate?: number; minRelProgress?: number; l2Reg?: number; - learnRateStrategy?: string; warmStart?: boolean; + learnRateStrategy?: string; lineSearchInitLearnRate?: number; earlyStop?: boolean; }; } + /** + * Representative value of a categorical feature. + */ + export interface Schema$CategoricalValue { + /** + * Counts of all categories for the categorical feature. If there are more than ten categories, we return top ten (by count) and return one more CategoryCount with category "_OTHER_" and count as aggregate counts of remaining categories. + */ + categoryCounts?: Schema$CategoryCount[]; + } + /** + * Represents the count of a single category within the cluster. + */ + export interface Schema$CategoryCount { + /** + * The name of category. + */ + category?: string; + /** + * The count of training samples matching the category within the cluster. + */ + count?: string; + } + /** + * Message containing the information about one cluster. + */ + export interface Schema$Cluster { + /** + * Centroid id. + */ + centroidId?: string; + /** + * Count of training data rows that were assigned to this cluster. + */ + count?: string; + /** + * Values of highly variant features for this cluster. + */ + featureValues?: Schema$FeatureValue[]; + } /** * Information about a single cluster for clustering model. */ @@ -375,6 +414,10 @@ export namespace bigquery_v2 { * Evaluation metrics for clustering models. */ export interface Schema$ClusteringMetrics { + /** + * [Beta] Information for all clusters. + */ + clusters?: Schema$Cluster[]; /** * Davies-Bouldin index. */ @@ -428,13 +471,13 @@ export namespace bigquery_v2 { * [Optional] An array of objects that define dataset access for one or more entities. You can set this property when inserting or updating a dataset in order to control who is allowed to access the data. If unspecified at dataset creation time, BigQuery adds default dataset access for the following entities: access.specialGroup: projectReaders; access.role: READER; access.specialGroup: projectWriters; access.role: WRITER; access.specialGroup: projectOwners; access.role: OWNER; access.userByEmail: [dataset creator email]; access.role: OWNER; */ access?: Array<{ - role?: string; - view?: Schema$TableReference; - groupByEmail?: string; userByEmail?: string; domain?: string; iamMember?: string; specialGroup?: string; + role?: string; + view?: Schema$TableReference; + groupByEmail?: string; }>; /** * [Output-only] The time when this dataset was created, in milliseconds since the epoch. @@ -495,12 +538,12 @@ export namespace bigquery_v2 { * An array of the dataset resources in the project. Each resource contains basic information. For full information about a particular dataset resource, use the Datasets: get method. This property is omitted when there are no datasets in the project. */ datasets?: Array<{ + labels?: {[key: string]: string}; + datasetReference?: Schema$DatasetReference; id?: string; location?: string; friendlyName?: string; kind?: string; - labels?: {[key: string]: string}; - datasetReference?: Schema$DatasetReference; }>; /** * A hash value of the results page. You can use this property to determine if the page has changed since the last request. @@ -585,7 +628,7 @@ export namespace bigquery_v2 { */ binaryClassificationMetrics?: Schema$BinaryClassificationMetrics; /** - * [Beta] Populated for clustering models. + * Populated for clustering models. */ clusteringMetrics?: Schema$ClusteringMetrics; /** @@ -593,7 +636,7 @@ export namespace bigquery_v2 { */ multiClassClassificationMetrics?: Schema$MultiClassClassificationMetrics; /** - * Populated for regression models. + * Populated for regression models and explicit feedback type matrix factorization models. */ regressionMetrics?: Schema$RegressionMetrics; } @@ -775,6 +818,23 @@ export namespace bigquery_v2 { */ sourceUris?: string[]; } + /** + * Representative value of a single feature within the cluster. + */ + export interface Schema$FeatureValue { + /** + * The categorical feature value. + */ + categoricalValue?: Schema$CategoricalValue; + /** + * The feature column name. + */ + featureColumn?: string; + /** + * The numerical feature value. This is the centroid value for this feature. + */ + numericalValue?: number; + } export interface Schema$GetQueryResultsResponse { /** * Whether the query result was fetched from the query cache. @@ -837,7 +897,7 @@ export namespace bigquery_v2 { } export interface Schema$GoogleSheetsOptions { /** - * [Beta] [Optional] Range of a sheet to query from. Only used when non-empty. Typical format: sheet_name!top_left_cell_id:bottom_right_cell_id For example: sheet1!A1:B20 + * [Optional] Range of a sheet to query from. Only used when non-empty. Typical format: sheet_name!top_left_cell_id:bottom_right_cell_id For example: sheet1!A1:B20 */ range?: string; /** @@ -860,7 +920,7 @@ export namespace bigquery_v2 { */ export interface Schema$IterationResult { /** - * [Beta] Information about top clusters for clustering models. + * Information about top clusters for clustering models. */ clusterInfos?: Schema$ClusterInfo[]; /** @@ -992,9 +1052,17 @@ export namespace bigquery_v2 { */ printHeader?: boolean; /** - * [Required] A reference to the table being exported. + * A reference to the model being exported. + */ + sourceModel?: Schema$ModelReference; + /** + * A reference to the table being exported. */ sourceTable?: Schema$TableReference; + /** + * [Optional] If destinationFormat is set to "AVRO", this flag indicates whether to enable extracting applicable column types (such as TIMESTAMP) to their corresponding AVRO logical types (timestamp-micros), instead of only using their raw types (avro-long). + */ + useAvroLogicalTypes?: boolean; } export interface Schema$JobConfigurationLoad { /** @@ -1235,15 +1303,15 @@ export namespace bigquery_v2 { * List of jobs that were requested. */ jobs?: Array<{ + jobReference?: Schema$JobReference; + status?: Schema$JobStatus; + state?: string; statistics?: Schema$JobStatistics; id?: string; configuration?: Schema$JobConfiguration; user_email?: string; errorResult?: Schema$ErrorProto; kind?: string; - jobReference?: Schema$JobReference; - status?: Schema$JobStatus; - state?: string; }>; /** * The resource type of the response. @@ -1371,6 +1439,10 @@ export namespace bigquery_v2 { * [Output-only] Describes execution plan for the query. */ queryPlan?: Schema$ExplainQueryStage[]; + /** + * [Output-only] Referenced routines (persistent user-defined functions and stored procedures) for the job. + */ + referencedRoutines?: Schema$RoutineReference[]; /** * [Output-only] Referenced tables for the job. Queries that reference more than 50 tables will not have a complete list. */ @@ -1378,7 +1450,7 @@ export namespace bigquery_v2 { /** * [Output-only] Job resource usage breakdown by reservation. */ - reservationUsage?: Array<{slotMs?: string; name?: string}>; + reservationUsage?: Array<{name?: string; slotMs?: string}>; /** * [Output-only] The schema of the results. Present only for successful dry run of non-legacy SQL queries. */ @@ -1515,6 +1587,10 @@ export namespace bigquery_v2 { * [Optional] A user-friendly description of this model. */ description?: string; + /** + * Custom encryption configuration (e.g., Cloud KMS keys). This shows the encryption configuration of the model data while stored in BigQuery storage. + */ + encryptionConfiguration?: Schema$EncryptionConfiguration; /** * Output only. A hash of this resource. */ @@ -1564,15 +1640,12 @@ export namespace bigquery_v2 { /** * [Output-only, Beta] Model options used for the first training run. These options are immutable for subsequent training runs. Default values are used for any options not specified in the input query. */ - modelOptions?: {lossType?: string; modelType?: string; labels?: string[]}; + modelOptions?: {modelType?: string; labels?: string[]; lossType?: string}; /** * [Output-only, Beta] Information about ml training runs, each training run comprises of multiple iterations and there may be multiple training runs for the model if warm start is used or if a user decides to continue a previously cancelled query. */ trainingRuns?: Schema$BqmlTrainingRun[]; } - /** - * Id path of a model. - */ export interface Schema$ModelReference { /** * [Required] The ID of the dataset containing this model. @@ -1809,7 +1882,7 @@ export namespace bigquery_v2 { range?: {interval?: string; start?: string; end?: string}; } /** - * Evaluation metrics for regression models. + * Evaluation metrics for regression and explicit feedback type matrix factorization models. */ export interface Schema$RegressionMetrics { /** @@ -2166,17 +2239,17 @@ export namespace bigquery_v2 { * Tables in the requested dataset. */ tables?: Array<{ + view?: {useLegacySql?: boolean}; + creationTime?: string; + labels?: {[key: string]: string}; clustering?: Schema$Clustering; type?: string; - expirationTime?: string; id?: string; + expirationTime?: string; tableReference?: Schema$TableReference; timePartitioning?: Schema$TimePartitioning; friendlyName?: string; kind?: string; - view?: {useLegacySql?: boolean}; - creationTime?: string; - labels?: {[key: string]: string}; }>; /** * The total number of tables in the dataset. @@ -2238,7 +2311,7 @@ export namespace bigquery_v2 { */ dataSplitMethod?: string; /** - * [Beta] Distance type for clustering models. + * Distance type for clustering models. */ distanceType?: string; /** @@ -2253,6 +2326,14 @@ export namespace bigquery_v2 { * Name of input label columns in training data. */ inputLabelColumns?: string[]; + /** + * The column used to provide the initial centroids for kmeans algorithm when kmeans_initialization_method is CUSTOM. + */ + kmeansInitializationColumn?: string; + /** + * The method used to initialize the centroids for kmeans algorithm. + */ + kmeansInitializationMethod?: string; /** * L1 regularization coefficient. */ @@ -2290,7 +2371,7 @@ export namespace bigquery_v2 { */ modelUri?: string; /** - * [Beta] Number of clusters for clustering models. + * Number of clusters for clustering models. */ numClusters?: string; /** @@ -3820,6 +3901,7 @@ export namespace bigquery_v2 { * @param {integer=} params.maxResults Maximum number of results to return * @param {string=} params.minCreationTime Min value for job creation time, in milliseconds since the POSIX epoch. If set, only jobs created after or at this timestamp are returned * @param {string=} params.pageToken Page token, returned by a previous call, to request the next page of results + * @param {string=} params.parentJobId If set, retrieves only jobs whose parent is this job. Otherwise, retrieves only jobs which have no parent * @param {string} params.projectId Project ID of the jobs to list * @param {string=} params.projection Restrict information returned to a set of selected fields * @param {string=} params.stateFilter Filter for job state @@ -4141,6 +4223,10 @@ export namespace bigquery_v2 { * Page token, returned by a previous call, to request the next page of results */ pageToken?: string; + /** + * If set, retrieves only jobs whose parent is this job. Otherwise, retrieves only jobs which have no parent + */ + parentJobId?: string; /** * Project ID of the jobs to list */ diff --git a/src/apis/bigqueryreservation/README.md b/src/apis/bigqueryreservation/README.md new file mode 100644 index 00000000000..221ed35fdfd --- /dev/null +++ b/src/apis/bigqueryreservation/README.md @@ -0,0 +1,47 @@ +Google Inc. logo + +# bigqueryreservation + +> A service to modify your BigQuery flat-rate reservations. + +## Installation + +```sh +$ npm install googleapis +``` + +## Usage +All documentation and usage information can be found on [GitHub](https://github.com/googleapis/google-api-nodejs-client). + +## Building a browser bundle + +This library can be used in a browser. To prepare a single file bundle, clone the +[repository](https://github.com/googleapis/google-api-nodejs-client) and run + +```sh +$ cd src/apis/bigqueryreservation +$ npm install +$ npm run webpack +``` + +The generated bundle will be written to `dist/bigqueryreservation.min.js`. Use it from your HTML file: + +```html + + +``` + +## License +This library is licensed under Apache 2.0. Full license text is available in [LICENSE](https://github.com/googleapis/google-api-nodejs-client/blob/master/LICENSE). + +## Contributing +We love contributions! Before submitting a Pull Request, it's always good to start with a new issue first. To learn more, see [CONTRIBUTING](https://github.com/google/google-api-nodejs-client/blob/master/.github/CONTRIBUTING.md). + +## Questions/problems? +* Ask your development related questions on [StackOverflow](http://stackoverflow.com/questions/tagged/google-api-nodejs-client). +* If you've found an bug/issue, please [file it on GitHub](https://github.com/googleapis/google-api-nodejs-client/issues). + + +*Crafted with ❤️ by the Google Node.js team* diff --git a/src/apis/bigqueryreservation/index.ts b/src/apis/bigqueryreservation/index.ts new file mode 100644 index 00000000000..fcb6af9752b --- /dev/null +++ b/src/apis/bigqueryreservation/index.ts @@ -0,0 +1,53 @@ +// Copyright 2019 Google LLC +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! THIS FILE IS AUTO-GENERATED */ + +import {AuthPlus, getAPI, GoogleConfigurable} from 'googleapis-common'; +import {bigqueryreservation_v1} from './v1'; +import {bigqueryreservation_v1alpha2} from './v1alpha2'; + +export const VERSIONS = { + v1: bigqueryreservation_v1.Bigqueryreservation, + v1alpha2: bigqueryreservation_v1alpha2.Bigqueryreservation, +}; + +export function bigqueryreservation( + version: 'v1' +): bigqueryreservation_v1.Bigqueryreservation; +export function bigqueryreservation( + options: bigqueryreservation_v1.Options +): bigqueryreservation_v1.Bigqueryreservation; +export function bigqueryreservation( + version: 'v1alpha2' +): bigqueryreservation_v1alpha2.Bigqueryreservation; +export function bigqueryreservation( + options: bigqueryreservation_v1alpha2.Options +): bigqueryreservation_v1alpha2.Bigqueryreservation; +export function bigqueryreservation< + T = + | bigqueryreservation_v1.Bigqueryreservation + | bigqueryreservation_v1alpha2.Bigqueryreservation +>( + this: GoogleConfigurable, + versionOrOptions: + | 'v1' + | bigqueryreservation_v1.Options + | 'v1alpha2' + | bigqueryreservation_v1alpha2.Options +) { + return getAPI('bigqueryreservation', versionOrOptions, VERSIONS, this); +} + +const auth = new AuthPlus(); +export {auth}; diff --git a/src/apis/bigqueryreservation/package.json b/src/apis/bigqueryreservation/package.json new file mode 100644 index 00000000000..5b6ea9931c9 --- /dev/null +++ b/src/apis/bigqueryreservation/package.json @@ -0,0 +1,43 @@ +{ + "name": "@google/bigqueryreservation", + "version": "0.1.0", + "description": "bigqueryreservation", + "main": "build/index.js", + "types": "build/index.d.ts", + "keywords": [ + "google" + ], + "author": "Google LLC", + "license": "Apache-2.0", + "homepage": "https://github.com/googleapis/google-api-nodejs-client", + "bugs": { + "url": "https://github.com/googleapis/google-api-nodejs-client/issues" + }, + "repository": { + "type": "git", + "url": "https://github.com/googleapis/google-api-nodejs-client.git" + }, + "engines": { + "node": ">=8.0.0" + }, + "scripts": { + "fix": "gts fix", + "lint": "gts check", + "compile": "tsc -p .", + "prepare": "npm run compile", + "docs": "typedoc --out docs/", + "webpack": "webpack" + }, + "dependencies": { + "googleapis-common": "^3.0.0" + }, + "devDependencies": { + "gts": "^1.0.0", + "null-loader": "^3.0.0", + "ts-loader": "^6.0.4", + "typedoc": "^0.15.0", + "typescript": "~3.6.0", + "webpack": "^4.35.3", + "webpack-cli": "^3.3.5" + } +} diff --git a/src/apis/appstate/tsconfig.json b/src/apis/bigqueryreservation/tsconfig.json similarity index 100% rename from src/apis/appstate/tsconfig.json rename to src/apis/bigqueryreservation/tsconfig.json diff --git a/src/apis/bigqueryreservation/v1.ts b/src/apis/bigqueryreservation/v1.ts new file mode 100644 index 00000000000..a02afdaf6cc --- /dev/null +++ b/src/apis/bigqueryreservation/v1.ts @@ -0,0 +1,386 @@ +/** + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { + OAuth2Client, + JWT, + Compute, + UserRefreshClient, +} from 'google-auth-library'; +import { + GoogleConfigurable, + createAPIRequest, + MethodOptions, + GlobalOptions, + BodyResponseCallback, + APIRequestContext, +} from 'googleapis-common'; +import {GaxiosPromise} from 'gaxios'; + +// tslint:disable: no-any +// tslint:disable: class-name +// tslint:disable: variable-name +// tslint:disable: jsdoc-format +// tslint:disable: no-namespace + +export namespace bigqueryreservation_v1 { + export interface Options extends GlobalOptions { + version: 'v1'; + } + + interface StandardParameters { + /** + * V1 error format. + */ + '$.xgafv'?: string; + /** + * OAuth access token. + */ + access_token?: string; + /** + * Data format for response. + */ + alt?: string; + /** + * JSONP + */ + callback?: string; + /** + * Selector specifying which fields to include in a partial response. + */ + fields?: string; + /** + * 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. + */ + key?: string; + /** + * OAuth 2.0 token for the current user. + */ + oauth_token?: string; + /** + * Returns response with indentations and line breaks. + */ + prettyPrint?: boolean; + /** + * 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. + */ + quotaUser?: string; + /** + * Legacy upload protocol for media (e.g. "media", "multipart"). + */ + uploadType?: string; + /** + * Upload protocol for media (e.g. "raw", "multipart"). + */ + upload_protocol?: string; + } + + /** + * BigQuery Reservation API + * + * A service to modify your BigQuery flat-rate reservations. + * + * @example + * const {google} = require('googleapis'); + * const bigqueryreservation = google.bigqueryreservation('v1'); + * + * @namespace bigqueryreservation + * @type {Function} + * @version v1 + * @variation v1 + * @param {object=} options Options for Bigqueryreservation + */ + export class Bigqueryreservation { + context: APIRequestContext; + operations: Resource$Operations; + + constructor(options: GlobalOptions, google?: GoogleConfigurable) { + this.context = { + _options: options || {}, + google, + }; + + this.operations = new Resource$Operations(this.context); + } + } + + /** + * The metadata for operation returned from ReservationService.CreateSlotPool. + */ + export interface Schema$CreateSlotPoolMetadata { + /** + * Resource name of the slot pool that is being created. E.g., projects/myproject/locations/us-central1/reservations/foo/slotPools/123 + */ + slotPool?: string; + } + /** + * A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`. + */ + export interface Schema$Empty {} + /** + * The response message for Operations.ListOperations. + */ + export interface Schema$ListOperationsResponse { + /** + * The standard List next-page token. + */ + nextPageToken?: string; + /** + * A list of operations that matches the specified filter in the request. + */ + operations?: Schema$Operation[]; + } + /** + * BigQuery-specific metadata about a location. This will be set on google.cloud.location.Location.metadata in Cloud Location API responses. + */ + export interface Schema$LocationMetadata { + /** + * The legacy BigQuery location ID, e.g. “EU” for the “europe” location. This is for any API consumers that need the legacy “US” and “EU” locations. + */ + legacyLocationId?: string; + } + /** + * This resource represents a long-running operation that is the result of a network API call. + */ + export interface Schema$Operation { + /** + * If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available. + */ + done?: boolean; + /** + * The error result of the operation in case of failure or cancellation. + */ + error?: Schema$Status; + /** + * Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any. + */ + metadata?: {[key: string]: any}; + /** + * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. + */ + name?: string; + /** + * The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. + */ + response?: {[key: string]: any}; + } + /** + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). + */ + export interface Schema$Status { + /** + * The status code, which should be an enum value of google.rpc.Code. + */ + code?: number; + /** + * A list of messages that carry the error details. There is a common set of message types for APIs to use. + */ + details?: Array<{[key: string]: any}>; + /** + * A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. + */ + message?: string; + } + + export class Resource$Operations { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * bigqueryreservation.operations.delete + * @desc Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. + * @alias bigqueryreservation.operations.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The name of the operation resource to be deleted. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + delete( + params?: Params$Resource$Operations$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Operations$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Operations$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Operations$Delete + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Operations$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Operations$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.operations.list + * @desc Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/x/operations`. To override the binding, API services can add a binding such as `"/v1/{name=users/x}/operations"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id. + * @alias bigqueryreservation.operations.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.filter The standard list filter. + * @param {string} params.name The name of the operation's parent resource. + * @param {integer=} params.pageSize The standard list page size. + * @param {string=} params.pageToken The standard list page token. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Operations$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Operations$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Operations$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Operations$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Operations$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Operations$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Operations$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The name of the operation resource to be deleted. + */ + name?: string; + } + export interface Params$Resource$Operations$List extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The standard list filter. + */ + filter?: string; + /** + * The name of the operation's parent resource. + */ + name?: string; + /** + * The standard list page size. + */ + pageSize?: number; + /** + * The standard list page token. + */ + pageToken?: string; + } +} diff --git a/src/apis/bigqueryreservation/v1alpha2.ts b/src/apis/bigqueryreservation/v1alpha2.ts new file mode 100644 index 00000000000..f5824ce85cf --- /dev/null +++ b/src/apis/bigqueryreservation/v1alpha2.ts @@ -0,0 +1,1977 @@ +/** + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { + OAuth2Client, + JWT, + Compute, + UserRefreshClient, +} from 'google-auth-library'; +import { + GoogleConfigurable, + createAPIRequest, + MethodOptions, + GlobalOptions, + BodyResponseCallback, + APIRequestContext, +} from 'googleapis-common'; +import {GaxiosPromise} from 'gaxios'; + +// tslint:disable: no-any +// tslint:disable: class-name +// tslint:disable: variable-name +// tslint:disable: jsdoc-format +// tslint:disable: no-namespace + +export namespace bigqueryreservation_v1alpha2 { + export interface Options extends GlobalOptions { + version: 'v1alpha2'; + } + + interface StandardParameters { + /** + * V1 error format. + */ + '$.xgafv'?: string; + /** + * OAuth access token. + */ + access_token?: string; + /** + * Data format for response. + */ + alt?: string; + /** + * JSONP + */ + callback?: string; + /** + * Selector specifying which fields to include in a partial response. + */ + fields?: string; + /** + * 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. + */ + key?: string; + /** + * OAuth 2.0 token for the current user. + */ + oauth_token?: string; + /** + * Returns response with indentations and line breaks. + */ + prettyPrint?: boolean; + /** + * 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. + */ + quotaUser?: string; + /** + * Legacy upload protocol for media (e.g. "media", "multipart"). + */ + uploadType?: string; + /** + * Upload protocol for media (e.g. "raw", "multipart"). + */ + upload_protocol?: string; + } + + /** + * BigQuery Reservation API + * + * A service to modify your BigQuery flat-rate reservations. + * + * @example + * const {google} = require('googleapis'); + * const bigqueryreservation = google.bigqueryreservation('v1alpha2'); + * + * @namespace bigqueryreservation + * @type {Function} + * @version v1alpha2 + * @variation v1alpha2 + * @param {object=} options Options for Bigqueryreservation + */ + export class Bigqueryreservation { + context: APIRequestContext; + projects: Resource$Projects; + + constructor(options: GlobalOptions, google?: GoogleConfigurable) { + this.context = { + _options: options || {}, + google, + }; + + this.projects = new Resource$Projects(this.context); + } + } + + /** + * The metadata for operation returned from ReservationService.CreateSlotPool. + */ + export interface Schema$CreateSlotPoolMetadata { + /** + * Resource name of the slot pool that is being created. E.g., projects/myproject/locations/us-central1/reservations/foo/slotPools/123 + */ + slotPool?: string; + } + /** + * A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`. + */ + export interface Schema$Empty {} + /** + * The response message for Locations.ListLocations. + */ + export interface Schema$ListLocationsResponse { + /** + * A list of locations that matches the specified filter in the request. + */ + locations?: Schema$Location[]; + /** + * The standard List next-page token. + */ + nextPageToken?: string; + } + /** + * The response for ReservationService.ListReservationGrants. + */ + export interface Schema$ListReservationGrantsResponse { + /** + * Token to retrieve the next page of results, or empty if there are no more results in the list. + */ + nextPageToken?: string; + /** + * List of reservation grants visible to the user. + */ + reservationGrants?: Schema$ReservationGrant[]; + } + /** + * The response for ReservationService.ListReservations. + */ + export interface Schema$ListReservationsResponse { + /** + * Token to retrieve the next page of results, or empty if there are no more results in the list. + */ + nextPageToken?: string; + /** + * List of reservations visible to the user. + */ + reservations?: Schema$Reservation[]; + } + /** + * The response for ReservationService.ListSlotPools. + */ + export interface Schema$ListSlotPoolsResponse { + /** + * Token to retrieve the next page of results, or empty if there are no more results in the list. + */ + nextPageToken?: string; + /** + * List of slot pools visible to the user. + */ + slotPools?: Schema$SlotPool[]; + } + /** + * A resource that represents Google Cloud Platform location. + */ + export interface Schema$Location { + /** + * The friendly name for this location, typically a nearby city name. For example, "Tokyo". + */ + displayName?: string; + /** + * Cross-service attributes for the location. For example {"cloud.googleapis.com/region": "us-east1"} + */ + labels?: {[key: string]: string}; + /** + * The canonical id for this location. For example: `"us-east1"`. + */ + locationId?: string; + /** + * Service-specific metadata. For example the available capacity at the given location. + */ + metadata?: {[key: string]: any}; + /** + * Resource name for the location, which may vary between implementations. For example: `"projects/example-project/locations/us-east1"` + */ + name?: string; + } + /** + * BigQuery-specific metadata about a location. This will be set on google.cloud.location.Location.metadata in Cloud Location API responses. + */ + export interface Schema$LocationMetadata { + /** + * The legacy BigQuery location ID, e.g. “EU” for the “europe” location. This is for any API consumers that need the legacy “US” and “EU” locations. + */ + legacyLocationId?: string; + } + /** + * This resource represents a long-running operation that is the result of a network API call. + */ + export interface Schema$Operation { + /** + * If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available. + */ + done?: boolean; + /** + * The error result of the operation in case of failure or cancellation. + */ + error?: Schema$Status; + /** + * Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any. + */ + metadata?: {[key: string]: any}; + /** + * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. + */ + name?: string; + /** + * The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. + */ + response?: {[key: string]: any}; + } + /** + * A reservation is a mechanism used to guarantee slots to users. + */ + export interface Schema$Reservation { + /** + * The resource name of the reservation, e.g., "projects/x/locations/x/reservations/dev/team/product". Reservation names (e.g., "dev/team/product") exceeding a depth of six will fail with `google.rpc.Code.INVALID_ARGUMENT`. + */ + name?: string; + /** + * Maximum slots available to this reservation and its children. A slot is a unit of computational power in BigQuery, and serves as the unit of parallelism. In a scan of a multi-partitioned table, a single slot operates on a single partition of the table. If the new reservation's slot capacity exceed the parent's slot capacity or if total slot capacity of the new reservation and its siblings exceeds the parent's slot capacity, the request will fail with `google.rpc.Code.RESOURCE_EXHAUSTED`. + */ + slotCapacity?: string; + /** + * If true, any query using this reservation will also be submitted to the parent reservation. This allows the query to share the additional slot capacity of the parent with other queries in the parent reservation. If the parent also has this field set to true, then this process will continue until it encounters a reservation for which this is false. If false, a query using this reservation will execute with the maximum slot capacity as specified above. If not specified, default value is true. Ignored for top-level reservation. + */ + useParentReservation?: boolean; + } + /** + * A ReservationGrant allows a project to submit jobs of a certain type using slots from the specified reservation. + */ + export interface Schema$ReservationGrant { + /** + * The resource which will use the reservation. E.g. projects/myproject, folders/123, organizations/456. + */ + grantee?: string; + /** + * Which type of jobs will use the reservation. + */ + jobType?: string; + /** + * Output only. Name of the resource. E.g.: projects/myproject/locations/eu/reservationGrants/123. + */ + name?: string; + /** + * Resource name of the reservation. E.g., projects/myproject/locations/eu/reservations/my_reservation. This reservation must be in the same location as the grant. This reservation should belong to the same parent project. + */ + reservation?: string; + } + /** + * The response for ReservationService.SearchReservationGrants. + */ + export interface Schema$SearchReservationGrantsResponse { + /** + * Token to retrieve the next page of results, or empty if there are no more results in the list. + */ + nextPageToken?: string; + /** + * List of reservation grants visible to the user. + */ + reservationGrants?: Schema$ReservationGrant[]; + } + /** + * Slot pool is a way to purchase slots with some minimum committed period of usage. Slot pool is immutable and cannot be deleted until the end of the commitment period. After the end of the commitment period, slots are still available but can be freely removed any time. A slot pool resource exists as a child resource of a top-level reservation. Sum of all the ACTIVE pools slot_count is always equal to the reservation slot_capacity. + */ + export interface Schema$SlotPool { + /** + * Output only. The end of the commitment period. Slot pool cannot be removed before commitment_end_time. It is applicable only for ACTIVE slot pools and is computed as a combination of the plan and the time when the slot pool became ACTIVE. + */ + commitmentEndTime?: string; + /** + * Output only. The resource name of the slot pool, e.g., projects/myproject/locations/us-central1/reservations/myreservation/slotPools/123 + */ + name?: string; + /** + * Slot pool commitment plan. + */ + plan?: string; + /** + * Number of slots in this pool. + */ + slotCount?: string; + /** + * Output only. + */ + state?: string; + } + /** + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). + */ + export interface Schema$Status { + /** + * The status code, which should be an enum value of google.rpc.Code. + */ + code?: number; + /** + * A list of messages that carry the error details. There is a common set of message types for APIs to use. + */ + details?: Array<{[key: string]: any}>; + /** + * A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. + */ + message?: string; + } + + export class Resource$Projects { + context: APIRequestContext; + locations: Resource$Projects$Locations; + constructor(context: APIRequestContext) { + this.context = context; + this.locations = new Resource$Projects$Locations(this.context); + } + } + + export class Resource$Projects$Locations { + context: APIRequestContext; + operations: Resource$Projects$Locations$Operations; + reservationGrants: Resource$Projects$Locations$Reservationgrants; + reservations: Resource$Projects$Locations$Reservations; + constructor(context: APIRequestContext) { + this.context = context; + this.operations = new Resource$Projects$Locations$Operations( + this.context + ); + this.reservationGrants = new Resource$Projects$Locations$Reservationgrants( + this.context + ); + this.reservations = new Resource$Projects$Locations$Reservations( + this.context + ); + } + + /** + * bigqueryreservation.projects.locations.get + * @desc Gets information about a location. + * @alias bigqueryreservation.projects.locations.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Resource name for the location. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Projects$Locations$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Projects$Locations$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Projects$Locations$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Get + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.projects.locations.list + * @desc Lists information about the supported locations for this service. + * @alias bigqueryreservation.projects.locations.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.filter The standard list filter. + * @param {string} params.name The resource that owns the locations collection, if applicable. + * @param {integer=} params.pageSize The standard list page size. + * @param {string=} params.pageToken The standard list page token. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Locations$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Locations$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Locations$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Locations$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+name}/locations').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.projects.locations.searchReservationGrants + * @desc Look up grants for a specified resource for a particular region. If the request is about a project: 1) Grants created on the project will be returned if they exist. 2) Otherwise grants created on the closest ancestor will be returned. 3) Grants for different JobTypes will all be returned. Same logic applies if the request is about a folder. If the request is about an organization, then grants created on the organization will be returned (organization doesn't have ancestors). Comparing to ListReservationGrants, there are two behavior differences: 1) permission on the grantee will be verified in this API. 2) Hierarchy lookup (project->folder->organization) happens in this API. + * @alias bigqueryreservation.projects.locations.searchReservationGrants + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {integer=} params.pageSize The maximum number of items to return. + * @param {string=} params.pageToken The next_page_token value returned from a previous List request, if any. + * @param {string} params.parent The parent resource name (containing project and location), which owns the grants. e.g.: "projects/myproject/locations/us-central1". + * @param {string=} params.query Please specify resource name as grantee in the query. e.g., "grantee=projects/myproject" "grantee=folders/123" "grantee=organizations/456" + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + searchReservationGrants( + params?: Params$Resource$Projects$Locations$Searchreservationgrants, + options?: MethodOptions + ): GaxiosPromise; + searchReservationGrants( + params: Params$Resource$Projects$Locations$Searchreservationgrants, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + searchReservationGrants( + params: Params$Resource$Projects$Locations$Searchreservationgrants, + callback: BodyResponseCallback + ): void; + searchReservationGrants( + callback: BodyResponseCallback + ): void; + searchReservationGrants( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Searchreservationgrants + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Searchreservationgrants; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Searchreservationgrants; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + '/v1alpha2/{+parent}:SearchReservationGrants' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest( + parameters + ); + } + } + } + + export interface Params$Resource$Projects$Locations$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Resource name for the location. + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The standard list filter. + */ + filter?: string; + /** + * The resource that owns the locations collection, if applicable. + */ + name?: string; + /** + * The standard list page size. + */ + pageSize?: number; + /** + * The standard list page token. + */ + pageToken?: string; + } + export interface Params$Resource$Projects$Locations$Searchreservationgrants + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The maximum number of items to return. + */ + pageSize?: number; + /** + * The next_page_token value returned from a previous List request, if any. + */ + pageToken?: string; + /** + * The parent resource name (containing project and location), which owns the grants. e.g.: "projects/myproject/locations/us-central1". + */ + parent?: string; + /** + * Please specify resource name as grantee in the query. e.g., "grantee=projects/myproject" "grantee=folders/123" "grantee=organizations/456" + */ + query?: string; + } + + export class Resource$Projects$Locations$Operations { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * bigqueryreservation.projects.locations.operations.cancel + * @desc Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`. + * @alias bigqueryreservation.projects.locations.operations.cancel + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The name of the operation resource to be cancelled. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + cancel( + params?: Params$Resource$Projects$Locations$Operations$Cancel, + options?: MethodOptions + ): GaxiosPromise; + cancel( + params: Params$Resource$Projects$Locations$Operations$Cancel, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + cancel( + params: Params$Resource$Projects$Locations$Operations$Cancel, + callback: BodyResponseCallback + ): void; + cancel(callback: BodyResponseCallback): void; + cancel( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Operations$Cancel + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Operations$Cancel; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Operations$Cancel; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+name}:cancel').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.projects.locations.operations.get + * @desc 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. + * @alias bigqueryreservation.projects.locations.operations.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The name of the operation resource. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Projects$Locations$Operations$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Projects$Locations$Operations$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Projects$Locations$Operations$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Operations$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Operations$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Operations$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Projects$Locations$Operations$Cancel + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The name of the operation resource to be cancelled. + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$Operations$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The name of the operation resource. + */ + name?: string; + } + + export class Resource$Projects$Locations$Reservationgrants { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * bigqueryreservation.projects.locations.reservationGrants.create + * @desc Returns `google.rpc.Code.PERMISSION_DENIED` if user does not have 'bigquery.admin' permissions on the project using the reservation and the project that owns this reservation. Returns `google.rpc.Code.INVALID_ARGUMENT` when location of the grant does not match location of the reservation. + * @alias bigqueryreservation.projects.locations.reservationGrants.create + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent The parent resource name of the reservation grant E.g.: projects/myproject/location/eu. + * @param {().ReservationGrant} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + create( + params?: Params$Resource$Projects$Locations$Reservationgrants$Create, + options?: MethodOptions + ): GaxiosPromise; + create( + params: Params$Resource$Projects$Locations$Reservationgrants$Create, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + create( + params: Params$Resource$Projects$Locations$Reservationgrants$Create, + callback: BodyResponseCallback + ): void; + create(callback: BodyResponseCallback): void; + create( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Reservationgrants$Create + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Reservationgrants$Create; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Reservationgrants$Create; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+parent}/reservationGrants').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.projects.locations.reservationGrants.delete + * @desc Deletes a reservation grant. No expansion will happen. E.g: organizationA contains project1 and project2. Reservation res1 exists. CreateReservationGrant was invoked previously and following grants were created explicitly: Then deletion of won't affect . After deletion of , queries from project1 will still use res1, while queries from project2 will use on-demand mode. + * @alias bigqueryreservation.projects.locations.reservationGrants.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Name of the resource, e.g.: projects/myproject/locations/eu/reservationGrants/123 + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + delete( + params?: Params$Resource$Projects$Locations$Reservationgrants$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Projects$Locations$Reservationgrants$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Projects$Locations$Reservationgrants$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Reservationgrants$Delete + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Reservationgrants$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Reservationgrants$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.projects.locations.reservationGrants.list + * @desc Lists reservation grants. Only explicitly created grants will be returned. E.g: organizationA contains project1 and project2. Reservation res1 exists. CreateReservationGrant was invoked previously and following grants were created explicitly: Then this API will just return the above two grants for reservation res1, and no expansion/merge will happen. + * @alias bigqueryreservation.projects.locations.reservationGrants.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {integer=} params.pageSize The maximum number of items to return. + * @param {string=} params.pageToken The next_page_token value returned from a previous List request, if any. + * @param {string} params.parent The parent resource name e.g.: projects/myproject/location/eu. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Locations$Reservationgrants$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Locations$Reservationgrants$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Locations$Reservationgrants$List, + callback: BodyResponseCallback + ): void; + list( + callback: BodyResponseCallback + ): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Reservationgrants$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Reservationgrants$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Reservationgrants$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+parent}/reservationGrants').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest( + parameters + ); + } + } + } + + export interface Params$Resource$Projects$Locations$Reservationgrants$Create + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The parent resource name of the reservation grant E.g.: projects/myproject/location/eu. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$ReservationGrant; + } + export interface Params$Resource$Projects$Locations$Reservationgrants$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Name of the resource, e.g.: projects/myproject/locations/eu/reservationGrants/123 + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$Reservationgrants$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The maximum number of items to return. + */ + pageSize?: number; + /** + * The next_page_token value returned from a previous List request, if any. + */ + pageToken?: string; + /** + * The parent resource name e.g.: projects/myproject/location/eu. + */ + parent?: string; + } + + export class Resource$Projects$Locations$Reservations { + context: APIRequestContext; + slotPools: Resource$Projects$Locations$Reservations$Slotpools; + constructor(context: APIRequestContext) { + this.context = context; + this.slotPools = new Resource$Projects$Locations$Reservations$Slotpools( + this.context + ); + } + + /** + * bigqueryreservation.projects.locations.reservations.create + * @desc Creates a new reservation resource. Multiple reservations are created if the ancestor reservations do not exist. + * @alias bigqueryreservation.projects.locations.reservations.create + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Project, location, and (optionally) reservation name. E.g., projects/myproject/locations/us-central1/reservations/parent + * @param {string=} params.reservationId The reservation ID relative to the parent, e.g., "dev". This field must only contain alphanumeric characters. + * @param {().Reservation} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + create( + params?: Params$Resource$Projects$Locations$Reservations$Create, + options?: MethodOptions + ): GaxiosPromise; + create( + params: Params$Resource$Projects$Locations$Reservations$Create, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + create( + params: Params$Resource$Projects$Locations$Reservations$Create, + callback: BodyResponseCallback + ): void; + create(callback: BodyResponseCallback): void; + create( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Reservations$Create + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Reservations$Create; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Reservations$Create; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+parent}/reservations').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.projects.locations.reservations.createReservation + * @desc Creates a new reservation resource. Multiple reservations are created if the ancestor reservations do not exist. + * @alias bigqueryreservation.projects.locations.reservations.createReservation + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Project, location, and (optionally) reservation name. E.g., projects/myproject/locations/us-central1/reservations/parent + * @param {string=} params.reservationId The reservation ID relative to the parent, e.g., "dev". This field must only contain alphanumeric characters. + * @param {().Reservation} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + createReservation( + params?: Params$Resource$Projects$Locations$Reservations$Createreservation, + options?: MethodOptions + ): GaxiosPromise; + createReservation( + params: Params$Resource$Projects$Locations$Reservations$Createreservation, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + createReservation( + params: Params$Resource$Projects$Locations$Reservations$Createreservation, + callback: BodyResponseCallback + ): void; + createReservation(callback: BodyResponseCallback): void; + createReservation( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Reservations$Createreservation + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Reservations$Createreservation; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Reservations$Createreservation; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+parent}').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.projects.locations.reservations.delete + * @desc Deletes a reservation. Returns `google.rpc.Code.FAILED_PRECONDITION` in the following cases: 1. When reservation has child reservations. This check can be bypassed by setting DeleteReservationRequest.force flag to true. 2. When top-level reservation with slot pools is being deleted. + * @alias bigqueryreservation.projects.locations.reservations.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {boolean=} params.force If true, deletes all the child reservations of the given reservation. Otherwise, attempting to delete a reservation that has child reservations will fail with error code `google.rpc.Code.FAILED_PRECONDITION`. + * @param {string} params.name Resource name of the reservation to retrieve. E.g., projects/myproject/locations/us-central1/reservations/my_reservation + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + delete( + params?: Params$Resource$Projects$Locations$Reservations$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Projects$Locations$Reservations$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Projects$Locations$Reservations$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Reservations$Delete + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Reservations$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Reservations$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.projects.locations.reservations.get + * @desc Returns information about the reservation. + * @alias bigqueryreservation.projects.locations.reservations.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Resource name of the reservation to retrieve. E.g., projects/myproject/locations/us-central1/reservations/path/to/reserv + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Projects$Locations$Reservations$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Projects$Locations$Reservations$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Projects$Locations$Reservations$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Reservations$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Reservations$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Reservations$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.projects.locations.reservations.list + * @desc Lists all the reservations for the project in the specified location. + * @alias bigqueryreservation.projects.locations.reservations.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.filter Can be used to filter out reservations based on names, capacity, etc, e.g.: filter="reservation.slot_capacity > 200" filter="reservation.name = \"*dev/x\"" Advanced filtering syntax can be [here](https://cloud.google.com/logging/docs/view/advanced-filters). + * @param {integer=} params.pageSize The maximum number of items to return. + * @param {string=} params.pageToken The next_page_token value returned from a previous List request, if any. + * @param {string} params.parent The parent resource name containing project and location, e.g.: "projects/myproject/locations/us-central1" + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Locations$Reservations$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Locations$Reservations$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Locations$Reservations$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Reservations$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Reservations$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Reservations$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+parent}/reservations').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.projects.locations.reservations.patch + * @desc Updates an existing reservation resource. Applicable only for child reservations. + * @alias bigqueryreservation.projects.locations.reservations.patch + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The resource name of the reservation, e.g., "projects/x/locations/x/reservations/dev/team/product". Reservation names (e.g., "dev/team/product") exceeding a depth of six will fail with `google.rpc.Code.INVALID_ARGUMENT`. + * @param {string=} params.updateMask Standard field mask for the set of fields to be updated. + * @param {().Reservation} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + patch( + params?: Params$Resource$Projects$Locations$Reservations$Patch, + options?: MethodOptions + ): GaxiosPromise; + patch( + params: Params$Resource$Projects$Locations$Reservations$Patch, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + patch( + params: Params$Resource$Projects$Locations$Reservations$Patch, + callback: BodyResponseCallback + ): void; + patch(callback: BodyResponseCallback): void; + patch( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Reservations$Patch + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Reservations$Patch; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Reservations$Patch; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'PATCH', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Projects$Locations$Reservations$Create + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Project, location, and (optionally) reservation name. E.g., projects/myproject/locations/us-central1/reservations/parent + */ + parent?: string; + /** + * The reservation ID relative to the parent, e.g., "dev". This field must only contain alphanumeric characters. + */ + reservationId?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$Reservation; + } + export interface Params$Resource$Projects$Locations$Reservations$Createreservation + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Project, location, and (optionally) reservation name. E.g., projects/myproject/locations/us-central1/reservations/parent + */ + parent?: string; + /** + * The reservation ID relative to the parent, e.g., "dev". This field must only contain alphanumeric characters. + */ + reservationId?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$Reservation; + } + export interface Params$Resource$Projects$Locations$Reservations$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * If true, deletes all the child reservations of the given reservation. Otherwise, attempting to delete a reservation that has child reservations will fail with error code `google.rpc.Code.FAILED_PRECONDITION`. + */ + force?: boolean; + /** + * Resource name of the reservation to retrieve. E.g., projects/myproject/locations/us-central1/reservations/my_reservation + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$Reservations$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Resource name of the reservation to retrieve. E.g., projects/myproject/locations/us-central1/reservations/path/to/reserv + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$Reservations$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Can be used to filter out reservations based on names, capacity, etc, e.g.: filter="reservation.slot_capacity > 200" filter="reservation.name = \"*dev/x\"" Advanced filtering syntax can be [here](https://cloud.google.com/logging/docs/view/advanced-filters). + */ + filter?: string; + /** + * The maximum number of items to return. + */ + pageSize?: number; + /** + * The next_page_token value returned from a previous List request, if any. + */ + pageToken?: string; + /** + * The parent resource name containing project and location, e.g.: "projects/myproject/locations/us-central1" + */ + parent?: string; + } + export interface Params$Resource$Projects$Locations$Reservations$Patch + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The resource name of the reservation, e.g., "projects/x/locations/x/reservations/dev/team/product". Reservation names (e.g., "dev/team/product") exceeding a depth of six will fail with `google.rpc.Code.INVALID_ARGUMENT`. + */ + name?: string; + /** + * Standard field mask for the set of fields to be updated. + */ + updateMask?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$Reservation; + } + + export class Resource$Projects$Locations$Reservations$Slotpools { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * bigqueryreservation.projects.locations.reservations.slotPools.delete + * @desc Deletes a slot pool. Attempting to delete slot pool before its commitment_end_time will fail with the error code `google.rpc.Code.FAILED_PRECONDITION`. + * @alias bigqueryreservation.projects.locations.reservations.slotPools.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Resource name of the slot pool to delete. E.g., projects/myproject/locations/us-central1/reservations/my_reservation/slotPools/123 + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + delete( + params?: Params$Resource$Projects$Locations$Reservations$Slotpools$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Projects$Locations$Reservations$Slotpools$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Projects$Locations$Reservations$Slotpools$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Reservations$Slotpools$Delete + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Reservations$Slotpools$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Reservations$Slotpools$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.projects.locations.reservations.slotPools.get + * @desc Returns information about the slot pool. + * @alias bigqueryreservation.projects.locations.reservations.slotPools.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Resource name of the slot pool to retrieve. E.g., projects/myproject/locations/us-central1/reservations/my_reservation/slotPools/123 + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Projects$Locations$Reservations$Slotpools$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Projects$Locations$Reservations$Slotpools$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Projects$Locations$Reservations$Slotpools$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Reservations$Slotpools$Get + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Reservations$Slotpools$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Reservations$Slotpools$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * bigqueryreservation.projects.locations.reservations.slotPools.list + * @desc Lists all the slot pools for the reservation. + * @alias bigqueryreservation.projects.locations.reservations.slotPools.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {integer=} params.pageSize The maximum number of items to return. + * @param {string=} params.pageToken The next_page_token value returned from a previous List request, if any. + * @param {string} params.parent Resource name of the parent reservation. Only top-level reservations can have slot pools. E.g., projects/myproject/locations/us-central1/reservations/my_reservation + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Locations$Reservations$Slotpools$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Locations$Reservations$Slotpools$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Locations$Reservations$Slotpools$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Reservations$Slotpools$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Reservations$Slotpools$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Reservations$Slotpools$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://bigqueryreservation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1alpha2/{+parent}/slotPools').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Projects$Locations$Reservations$Slotpools$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Resource name of the slot pool to delete. E.g., projects/myproject/locations/us-central1/reservations/my_reservation/slotPools/123 + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$Reservations$Slotpools$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Resource name of the slot pool to retrieve. E.g., projects/myproject/locations/us-central1/reservations/my_reservation/slotPools/123 + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$Reservations$Slotpools$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The maximum number of items to return. + */ + pageSize?: number; + /** + * The next_page_token value returned from a previous List request, if any. + */ + pageToken?: string; + /** + * Resource name of the parent reservation. Only top-level reservations can have slot pools. E.g., projects/myproject/locations/us-central1/reservations/my_reservation + */ + parent?: string; + } +} diff --git a/src/apis/bigqueryreservation/webpack.config.js b/src/apis/bigqueryreservation/webpack.config.js new file mode 100644 index 00000000000..2869fa15d8c --- /dev/null +++ b/src/apis/bigqueryreservation/webpack.config.js @@ -0,0 +1,71 @@ +/** + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Use `npm run webpack` to produce Webpack bundle for this library. + +const path = require('path'); + +module.exports = { + entry: './index.ts', + resolve: { + extensions: ['.ts', '.js', '.json'], + }, + output: { + library: 'Bigqueryreservation', + filename: 'bigqueryreservation.min.js', + path: path.resolve(__dirname, 'dist'), + }, + node: { + child_process: 'empty', + fs: 'empty', + crypto: 'empty', + }, + module: { + rules: [ + { + test: /node_modules[\\/]google-auth-library[\\/]src[\\/]crypto[\\/]node[\\/]crypto/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]https-proxy-agent[\\/]/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]gcp-metadata[\\/]/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]gtoken[\\/]/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]pkginfo[\\/]/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]semver[\\/]/, + use: 'null-loader', + }, + { + test: /\.ts$/, + use: 'ts-loader', + exclude: /node_modules/, + }, + ], + }, + mode: 'production', + plugins: [], +}; diff --git a/src/apis/bigtableadmin/v2.ts b/src/apis/bigtableadmin/v2.ts index 84efaf124f3..589f4fc6da8 100644 --- a/src/apis/bigtableadmin/v2.ts +++ b/src/apis/bigtableadmin/v2.ts @@ -145,7 +145,7 @@ export namespace bigtableadmin_v2 { singleClusterRouting?: Schema$SingleClusterRouting; } /** - * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "fooservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:bar@gmail.com" ] } ] } ] } For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts foo@gmail.com from DATA_READ logging, and bar@gmail.com from DATA_WRITE logging. + * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "sampleservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts jose@example.com from DATA_READ logging, and aliya@example.com from DATA_WRITE logging. */ export interface Schema$AuditConfig { /** @@ -158,7 +158,7 @@ export namespace bigtableadmin_v2 { service?: string; } /** - * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting foo@gmail.com from DATA_READ logging. + * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ logging. */ export interface Schema$AuditLogConfig { /** @@ -179,7 +179,7 @@ export namespace bigtableadmin_v2 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -416,7 +416,21 @@ export namespace bigtableadmin_v2 { /** * Request message for `GetIamPolicy` method. */ - export interface Schema$GetIamPolicyRequest {} + export interface Schema$GetIamPolicyRequest { + /** + * OPTIONAL: A `GetPolicyOptions` object for specifying options to `GetIamPolicy`. This field is only used by Cloud IAM. + */ + options?: Schema$GetPolicyOptions; + } + /** + * Encapsulates settings provided to GetIamPolicy. + */ + export interface Schema$GetPolicyOptions { + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + requestedPolicyVersion?: number; + } /** * A collection of Bigtable Tables and the resources that serve them. All tables in an instance are served from all Clusters in the instance. */ @@ -651,7 +665,7 @@ export namespace bigtableadmin_v2 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** diff --git a/src/apis/binaryauthorization/v1beta1.ts b/src/apis/binaryauthorization/v1beta1.ts index 5b2e4b7278a..91f5a667c94 100644 --- a/src/apis/binaryauthorization/v1beta1.ts +++ b/src/apis/binaryauthorization/v1beta1.ts @@ -194,7 +194,7 @@ export namespace binaryauthorization_v1beta1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -236,7 +236,7 @@ export namespace binaryauthorization_v1beta1 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** @@ -758,7 +758,7 @@ export namespace binaryauthorization_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1190,7 +1190,7 @@ export namespace binaryauthorization_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -1283,7 +1283,7 @@ export namespace binaryauthorization_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1520,7 +1520,7 @@ export namespace binaryauthorization_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** diff --git a/src/apis/calendar/v3.ts b/src/apis/calendar/v3.ts index cf65d1e9432..8142eebf52b 100644 --- a/src/apis/calendar/v3.ts +++ b/src/apis/calendar/v3.ts @@ -375,7 +375,7 @@ export namespace calendar_v3 { } export interface Schema$ConferenceData { /** - * The ID of the conference. Can be used by developers to keep track of conferences, should not be displayed to users. Values for solution types: - "eventHangout": unset. - "eventNamedHangout": the name of the Hangout. - "hangoutsMeet": the 10-letter meeting code, for example "aaa-bbbb-ccc". Optional. + * The ID of the conference. Can be used by developers to keep track of conferences, should not be displayed to users. Values for solution types: - "eventHangout": unset. - "eventNamedHangout": the name of the Hangout. - "hangoutsMeet": the 10-letter meeting code, for example "aaa-bbbb-ccc". - "addOn": defined by 3P conference provider. Optional. */ conferenceId?: string; /** diff --git a/src/apis/cloudasset/v1.ts b/src/apis/cloudasset/v1.ts index 102dc60bc5d..3b759386f87 100644 --- a/src/apis/cloudasset/v1.ts +++ b/src/apis/cloudasset/v1.ts @@ -123,6 +123,8 @@ export namespace cloudasset_v1 { * Cloud asset. This includes all Google Cloud Platform resources, Cloud IAM policies, and other non-GCP assets. */ export interface Schema$Asset { + accessLevel?: Schema$GoogleIdentityAccesscontextmanagerV1AccessLevel; + accessPolicy?: Schema$GoogleIdentityAccesscontextmanagerV1AccessPolicy; /** * Type of the asset. Example: "compute.googleapis.com/Disk". */ @@ -143,9 +145,10 @@ export namespace cloudasset_v1 { * Representation of the resource. */ resource?: Schema$Resource; + servicePerimeter?: Schema$GoogleIdentityAccesscontextmanagerV1ServicePerimeter; } /** - * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "fooservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:bar@gmail.com" ] } ] } ] } For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts foo@gmail.com from DATA_READ logging, and bar@gmail.com from DATA_WRITE logging. + * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "sampleservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts jose@example.com from DATA_READ logging, and aliya@example.com from DATA_WRITE logging. */ export interface Schema$AuditConfig { /** @@ -158,7 +161,7 @@ export namespace cloudasset_v1 { service?: string; } /** - * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting foo@gmail.com from DATA_READ logging. + * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ logging. */ export interface Schema$AuditLogConfig { /** @@ -179,6 +182,23 @@ export namespace cloudasset_v1 { */ assets?: Schema$TemporalAsset[]; } + /** + * A BigQuery destination. + */ + export interface Schema$BigQueryDestination { + /** + * Required. The BigQuery dataset in format "projects/projectId/datasets/datasetId", to which the snapshot result should be exported. If this dataset does not exist, the export call returns an error. + */ + dataset?: string; + /** + * If the destination table already exists and this flag is `TRUE`, the table will be overwritten by the contents of assets snapshot. If the flag is not set and the destination table already exists, the export call returns an error. + */ + force?: boolean; + /** + * Required. The BigQuery table to which the snapshot result should be written. If this table does not exist, a new table with the given name will be created. + */ + table?: string; + } /** * Associates `members` with a `role`. */ @@ -188,7 +208,7 @@ export namespace cloudasset_v1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -322,6 +342,198 @@ export namespace cloudasset_v1 { * Ignores policies set above this resource and restores the `constraint_default` enforcement behavior of the specific `Constraint` at this resource. Suppose that `constraint_default` is set to `ALLOW` for the `Constraint` `constraints/serviceuser.services`. Suppose that organization foo.com sets a `Policy` at their Organization resource node that restricts the allowed service activations to deny all service activations. They could then set a `Policy` with the `policy_type` `restore_default` on several experimental projects, restoring the `constraint_default` enforcement of the `Constraint` for only those projects, allowing those projects to have all services activated. */ export interface Schema$GoogleCloudOrgpolicyV1RestoreDefault {} + /** + * An `AccessLevel` is a label that can be applied to requests to GCP services, along with a list of requirements necessary for the label to be applied. + */ + export interface Schema$GoogleIdentityAccesscontextmanagerV1AccessLevel { + /** + * A `BasicLevel` composed of `Conditions`. + */ + basic?: Schema$GoogleIdentityAccesscontextmanagerV1BasicLevel; + /** + * Output only. Time the `AccessLevel` was created in UTC. + */ + createTime?: string; + /** + * Description of the `AccessLevel` and its use. Does not affect behavior. + */ + description?: string; + /** + * Required. Resource name for the Access Level. The `short_name` component must begin with a letter and only include alphanumeric and '_'. Format: `accessPolicies/{policy_id}/accessLevels/{short_name}` + */ + name?: string; + /** + * Human readable title. Must be unique within the Policy. + */ + title?: string; + /** + * Output only. Time the `AccessLevel` was updated in UTC. + */ + updateTime?: string; + } + /** + * `AccessPolicy` is a container for `AccessLevels` (which define the necessary attributes to use GCP services) and `ServicePerimeters` (which define regions of services able to freely pass data within a perimeter). An access policy is globally visible within an organization, and the restrictions it specifies apply to all projects within an organization. + */ + export interface Schema$GoogleIdentityAccesscontextmanagerV1AccessPolicy { + /** + * Output only. Time the `AccessPolicy` was created in UTC. + */ + createTime?: string; + /** + * Output only. Resource name of the `AccessPolicy`. Format: `accessPolicies/{policy_id}` + */ + name?: string; + /** + * Required. The parent of this `AccessPolicy` in the Cloud Resource Hierarchy. Currently immutable once created. Format: `organizations/{organization_id}` + */ + parent?: string; + /** + * Required. Human readable title. Does not affect behavior. + */ + title?: string; + /** + * Output only. Time the `AccessPolicy` was updated in UTC. + */ + updateTime?: string; + } + /** + * `BasicLevel` is an `AccessLevel` using a set of recommended features. + */ + export interface Schema$GoogleIdentityAccesscontextmanagerV1BasicLevel { + /** + * How the `conditions` list should be combined to determine if a request is granted this `AccessLevel`. If AND is used, each `Condition` in `conditions` must be satisfied for the `AccessLevel` to be applied. If OR is used, at least one `Condition` in `conditions` must be satisfied for the `AccessLevel` to be applied. Default behavior is AND. + */ + combiningFunction?: string; + /** + * Required. A list of requirements for the `AccessLevel` to be granted. + */ + conditions?: Schema$GoogleIdentityAccesscontextmanagerV1Condition[]; + } + /** + * A condition necessary for an `AccessLevel` to be granted. The Condition is an AND over its fields. So a Condition is true if: 1) the request IP is from one of the listed subnetworks AND 2) the originating device complies with the listed device policy AND 3) all listed access levels are granted AND 4) the request was sent at a time allowed by the DateTimeRestriction. + */ + export interface Schema$GoogleIdentityAccesscontextmanagerV1Condition { + /** + * Device specific restrictions, all restrictions must hold for the Condition to be true. If not specified, all devices are allowed. + */ + devicePolicy?: Schema$GoogleIdentityAccesscontextmanagerV1DevicePolicy; + /** + * CIDR block IP subnetwork specification. May be IPv4 or IPv6. Note that for a CIDR IP address block, the specified IP address portion must be properly truncated (i.e. all the host bits must be zero) or the input is considered malformed. For example, "192.0.2.0/24" is accepted but "192.0.2.1/24" is not. Similarly, for IPv6, "2001:db8::/32" is accepted whereas "2001:db8::1/32" is not. The originating IP of a request must be in one of the listed subnets in order for this Condition to be true. If empty, all IP addresses are allowed. + */ + ipSubnetworks?: string[]; + /** + * The request must be made by one of the provided user or service accounts. Groups are not supported. Syntax: `user:{emailid}` `serviceAccount:{emailid}` If not specified, a request may come from any user. + */ + members?: string[]; + /** + * Whether to negate the Condition. If true, the Condition becomes a NAND over its non-empty fields, each field must be false for the Condition overall to be satisfied. Defaults to false. + */ + negate?: boolean; + /** + * The request must originate from one of the provided countries/regions. Must be valid ISO 3166-1 alpha-2 codes. + */ + regions?: string[]; + /** + * A list of other access levels defined in the same `Policy`, referenced by resource name. Referencing an `AccessLevel` which does not exist is an error. All access levels listed must be granted for the Condition to be true. Example: "`accessPolicies/MY_POLICY/accessLevels/LEVEL_NAME"` + */ + requiredAccessLevels?: string[]; + } + /** + * `DevicePolicy` specifies device specific restrictions necessary to acquire a given access level. A `DevicePolicy` specifies requirements for requests from devices to be granted access levels, it does not do any enforcement on the device. `DevicePolicy` acts as an AND over all specified fields, and each repeated field is an OR over its elements. Any unset fields are ignored. For example, if the proto is { os_type : DESKTOP_WINDOWS, os_type : DESKTOP_LINUX, encryption_status: ENCRYPTED}, then the DevicePolicy will be true for requests originating from encrypted Linux desktops and encrypted Windows desktops. + */ + export interface Schema$GoogleIdentityAccesscontextmanagerV1DevicePolicy { + /** + * Allowed device management levels, an empty list allows all management levels. + */ + allowedDeviceManagementLevels?: string[]; + /** + * Allowed encryptions statuses, an empty list allows all statuses. + */ + allowedEncryptionStatuses?: string[]; + /** + * Allowed OS versions, an empty list allows all types and all versions. + */ + osConstraints?: Schema$GoogleIdentityAccesscontextmanagerV1OsConstraint[]; + /** + * Whether the device needs to be approved by the customer admin. + */ + requireAdminApproval?: boolean; + /** + * Whether the device needs to be corp owned. + */ + requireCorpOwned?: boolean; + /** + * Whether or not screenlock is required for the DevicePolicy to be true. Defaults to `false`. + */ + requireScreenlock?: boolean; + } + /** + * A restriction on the OS type and version of devices making requests. + */ + export interface Schema$GoogleIdentityAccesscontextmanagerV1OsConstraint { + /** + * The minimum allowed OS version. If not set, any version of this OS satisfies the constraint. Format: `"major.minor.patch"`. Examples: `"10.5.301"`, `"9.2.1"`. + */ + minimumVersion?: string; + /** + * Required. The allowed OS type. + */ + osType?: string; + /** + * Only allows requests from devices with a verified Chrome OS. Verifications includes requirements that the device is enterprise-managed, conformant to Dasher domain policies, and the caller has permission to call the API targeted by the request. + */ + requireVerifiedChromeOs?: boolean; + } + /** + * `ServicePerimeter` describes a set of GCP resources which can freely import and export data amongst themselves, but not export outside of the `ServicePerimeter`. If a request with a source within this `ServicePerimeter` has a target outside of the `ServicePerimeter`, the request will be blocked. Otherwise the request is allowed. There are two types of Service Perimeter - Regular and Bridge. Regular Service Perimeters cannot overlap, a single GCP project can only belong to a single regular Service Perimeter. Service Perimeter Bridges can contain only GCP projects as members, a single GCP project may belong to multiple Service Perimeter Bridges. + */ + export interface Schema$GoogleIdentityAccesscontextmanagerV1ServicePerimeter { + /** + * Output only. Time the `ServicePerimeter` was created in UTC. + */ + createTime?: string; + /** + * Description of the `ServicePerimeter` and its use. Does not affect behavior. + */ + description?: string; + /** + * Required. Resource name for the ServicePerimeter. The `short_name` component must begin with a letter and only include alphanumeric and '_'. Format: `accessPolicies/{policy_id}/servicePerimeters/{short_name}` + */ + name?: string; + /** + * Perimeter type indicator. A single project is allowed to be a member of single regular perimeter, but multiple service perimeter bridges. A project cannot be a included in a perimeter bridge without being included in regular perimeter. For perimeter bridges, the restricted service list as well as access level lists must be empty. + */ + perimeterType?: string; + /** + * Current ServicePerimeter configuration. Specifies sets of resources, restricted services and access levels that determine perimeter content and boundaries. + */ + status?: Schema$GoogleIdentityAccesscontextmanagerV1ServicePerimeterConfig; + /** + * Human readable title. Must be unique within the Policy. + */ + title?: string; + /** + * Output only. Time the `ServicePerimeter` was updated in UTC. + */ + updateTime?: string; + } + /** + * `ServicePerimeterConfig` specifies a set of GCP resources that describe specific Service Perimeter configuration. + */ + export interface Schema$GoogleIdentityAccesscontextmanagerV1ServicePerimeterConfig { + /** + * A list of `AccessLevel` resource names that allow resources within the `ServicePerimeter` to be accessed from the internet. `AccessLevels` listed must be in the same policy as this `ServicePerimeter`. Referencing a nonexistent `AccessLevel` is a syntax error. If no `AccessLevel` names are listed, resources within the perimeter can only be accessed via GCP calls with request origins within the perimeter. Example: `"accessPolicies/MY_POLICY/accessLevels/MY_LEVEL"`. For Service Perimeter Bridge, must be empty. + */ + accessLevels?: string[]; + /** + * A list of GCP resources that are inside of the service perimeter. Currently only projects are allowed. Format: `projects/{project_number}` + */ + resources?: string[]; + /** + * GCP services that are subject to the Service Perimeter restrictions. For example, if `storage.googleapis.com` is specified, access to the storage buckets inside the perimeter must meet the perimeter's access restrictions. + */ + restrictedServices?: string[]; + } /** * This resource represents a long-running operation that is the result of a network API call. */ @@ -351,6 +563,10 @@ export namespace cloudasset_v1 { * Output configuration for export assets destination. */ export interface Schema$OutputConfig { + /** + * Destination on BigQuery. The output table stores the fields in asset proto as columns in BigQuery. The resource/iam_policy field is converted to a record with each field to a column, except metadata to a single JSON string. + */ + bigqueryDestination?: Schema$BigQueryDestination; /** * Destination on Cloud Storage. */ @@ -369,11 +585,11 @@ export namespace cloudasset_v1 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** - * Deprecated. + * Specifies the format of the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ version?: number; } diff --git a/src/apis/cloudasset/v1beta1.ts b/src/apis/cloudasset/v1beta1.ts index 66a7fb934f4..6a1026cc287 100644 --- a/src/apis/cloudasset/v1beta1.ts +++ b/src/apis/cloudasset/v1beta1.ts @@ -143,7 +143,7 @@ export namespace cloudasset_v1beta1 { resource?: Schema$Resource; } /** - * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "fooservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:bar@gmail.com" ] } ] } ] } For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts foo@gmail.com from DATA_READ logging, and bar@gmail.com from DATA_WRITE logging. + * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "sampleservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts jose@example.com from DATA_READ logging, and aliya@example.com from DATA_WRITE logging. */ export interface Schema$AuditConfig { /** @@ -156,7 +156,7 @@ export namespace cloudasset_v1beta1 { service?: string; } /** - * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting foo@gmail.com from DATA_READ logging. + * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ logging. */ export interface Schema$AuditLogConfig { /** @@ -186,7 +186,7 @@ export namespace cloudasset_v1beta1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -296,11 +296,11 @@ export namespace cloudasset_v1beta1 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** - * Deprecated. + * Specifies the format of the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ version?: number; } diff --git a/src/apis/cloudbilling/v1.ts b/src/apis/cloudbilling/v1.ts index d2bb4c51f5a..119730a6ba8 100644 --- a/src/apis/cloudbilling/v1.ts +++ b/src/apis/cloudbilling/v1.ts @@ -811,7 +811,7 @@ export namespace cloudbilling_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1430,7 +1430,7 @@ export namespace cloudbilling_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** diff --git a/src/apis/cloudbuild/v1.ts b/src/apis/cloudbuild/v1.ts index 10c19ff613c..550bcec594e 100644 --- a/src/apis/cloudbuild/v1.ts +++ b/src/apis/cloudbuild/v1.ts @@ -410,6 +410,10 @@ export namespace cloudbuild_v1 { * If any of the files altered in the commit pass the ignored_files filter and included_files is empty, then as far as this filter is concerned, we should trigger the build. If any of the files altered in the commit pass the ignored_files filter and included_files is not empty, then we make sure that at least one of those files matches a included_files glob. If not, then we do not trigger a build. */ includedFiles?: string[]; + /** + * User assigned name of the trigger. Must be unique within the project. + */ + name?: string; /** * Substitutions data for Build resource. */ @@ -581,11 +585,11 @@ export namespace cloudbuild_v1 { */ export interface Schema$PushFilter { /** - * Regexes of branches to match. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax + * Regexes matching branches to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax */ branch?: string; /** - * Regexes of tags to match. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax + * Regexes matching tags to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax */ tag?: string; } @@ -594,7 +598,7 @@ export namespace cloudbuild_v1 { */ export interface Schema$RepoSource { /** - * Name of the branch to build. + * Regex matching branches to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax */ branchName?: string; /** @@ -614,7 +618,7 @@ export namespace cloudbuild_v1 { */ repoName?: string; /** - * Name of the tag to build. + * Regex matching tags to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax */ tagName?: string; } diff --git a/src/apis/cloudbuild/v1alpha1.ts b/src/apis/cloudbuild/v1alpha1.ts index 248f2ab9080..8f41ff7b152 100644 --- a/src/apis/cloudbuild/v1alpha1.ts +++ b/src/apis/cloudbuild/v1alpha1.ts @@ -442,7 +442,7 @@ export namespace cloudbuild_v1alpha1 { */ export interface Schema$RepoSource { /** - * Name of the branch to build. + * Regex matching branches to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax */ branchName?: string; /** @@ -462,7 +462,7 @@ export namespace cloudbuild_v1alpha1 { */ repoName?: string; /** - * Name of the tag to build. + * Regex matching tags to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax */ tagName?: string; } diff --git a/src/apis/cloudfunctions/v1.ts b/src/apis/cloudfunctions/v1.ts index b2a5676c8de..68cac8cccb5 100644 --- a/src/apis/cloudfunctions/v1.ts +++ b/src/apis/cloudfunctions/v1.ts @@ -120,7 +120,7 @@ export namespace cloudfunctions_v1 { } /** - * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "fooservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:bar@gmail.com" ] } ] } ] } For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts foo@gmail.com from DATA_READ logging, and bar@gmail.com from DATA_WRITE logging. + * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "sampleservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts jose@example.com from DATA_READ logging, and aliya@example.com from DATA_WRITE logging. */ export interface Schema$AuditConfig { /** @@ -133,7 +133,7 @@ export namespace cloudfunctions_v1 { service?: string; } /** - * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting foo@gmail.com from DATA_READ logging. + * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ logging. */ export interface Schema$AuditLogConfig { /** @@ -154,7 +154,7 @@ export namespace cloudfunctions_v1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -189,7 +189,7 @@ export namespace cloudfunctions_v1 { result?: string; } /** - * Describes a Cloud Function that contains user computation executed in response to an event. It encapsulate function and triggers configurations. LINT.IfChange + * Describes a Cloud Function that contains user computation executed in response to an event. It encapsulate function and triggers configurations. */ export interface Schema$CloudFunction { /** @@ -229,15 +229,15 @@ export namespace cloudfunctions_v1 { */ name?: string; /** - * The VPC Network that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network resource. If the short network name is used, the network must belong to the same project. Otherwise, it must belong to a project within the same organization. The format of this field is either `projects/{project}/global/networks/{network}` or `{network}`, where {project} is a project id where the network is defined, and {network} is the short name of the network. This field is mutually exclusive with `vpc_connector` and will be replaced by it. See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for more information on connecting Cloud projects. This feature is currently in alpha, available only for whitelisted users. + * The VPC Network that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network resource. If the short network name is used, the network must belong to the same project. Otherwise, it must belong to a project within the same organization. The format of this field is either `projects/{project}/global/networks/{network}` or `{network}`, where {project} is a project id where the network is defined, and {network} is the short name of the network. This field is mutually exclusive with `vpc_connector` and will be replaced by it. See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for more information on connecting Cloud projects. */ network?: string; /** - * Required. The runtime in which the function is going to run. Choices: * `nodejs6`: Node.js 6 * `nodejs8`: Node.js 8 * `nodejs10`: Node.js 10 * `python37`: Python 3.7 * `go111`: Go 1.11 + * The runtime in which to run the function. Required when deploying a new function, optional when updating an existing function. For a complete list of possible choices, see the [`gcloud` command reference](/sdk/gcloud/reference/functions/deploy#--runtime). */ runtime?: string; /** - * The email of the function's service account. If empty, defaults to {project_id}@appspot.gserviceaccount.com. + * The email of the function's service account. If empty, defaults to `{project_id}@appspot.gserviceaccount.com`. */ serviceAccountEmail?: string; /** @@ -269,7 +269,7 @@ export namespace cloudfunctions_v1 { */ versionId?: string; /** - * The VPC Network Connector that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network connector resource. The format of this field is `projects/x/locations/x/connectors/x This field is mutually exclusive with `network` field and will eventually replace it. See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for more information on connecting Cloud projects. This feature is currently in alpha, available only for whitelisted users. + * The VPC Network Connector that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network connector resource. The format of this field is `projects/x/locations/x/connectors/x This field is mutually exclusive with `network` field and will eventually replace it. See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for more information on connecting Cloud projects. */ vpcConnector?: string; } @@ -516,7 +516,7 @@ export namespace cloudfunctions_v1 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** @@ -1375,6 +1375,7 @@ export namespace cloudfunctions_v1 { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1851,6 +1852,10 @@ export namespace cloudfunctions_v1 { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + 'options.requestedPolicyVersion'?: number; /** * REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. */ diff --git a/src/apis/cloudfunctions/v1beta2.ts b/src/apis/cloudfunctions/v1beta2.ts index a5e6becd08f..083c2c83cf1 100644 --- a/src/apis/cloudfunctions/v1beta2.ts +++ b/src/apis/cloudfunctions/v1beta2.ts @@ -186,15 +186,15 @@ export namespace cloudfunctions_v1beta2 { */ name?: string; /** - * The VPC Network that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network resource. If the short network name is used, the network must belong to the same project. Otherwise, it must belong to a project within the same organization. The format of this field is either `projects/{project}/global/networks/{network}` or `{network}`, where {project} is a project id where the network is defined, and {network} is the short name of the network. This field is mutually exclusive with `vpc_connector` and will be replaced by it. See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for more information on connecting Cloud projects. This feature is currently in alpha, available only for whitelisted users. + * The VPC Network that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network resource. If the short network name is used, the network must belong to the same project. Otherwise, it must belong to a project within the same organization. The format of this field is either `projects/{project}/global/networks/{network}` or `{network}`, where {project} is a project id where the network is defined, and {network} is the short name of the network. This field is mutually exclusive with `vpc_connector` and will be replaced by it. See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for more information on connecting Cloud projects. */ network?: string; /** - * Required. The runtime in which the function is going to run. Choices: * `nodejs6`: Node.js 6 * `nodejs8`: Node.js 8 * `nodejs10`: Node.js 10 * `python37`: Python 3.7 * `go111`: Go 1.11 + * The runtime in which to run the function. Required when deploying a new function, optional when updating an existing function. For a complete list of possible choices, see the [`gcloud` command reference](/sdk/gcloud/reference/functions/deploy#--runtime). */ runtime?: string; /** - * The email of the function's service account. If empty, defaults to {project_id}@appspot.gserviceaccount.com. + * The email of the function's service account. If empty, defaults to `{project_id}@appspot.gserviceaccount.com`. */ serviceAccount?: string; /** @@ -230,7 +230,7 @@ export namespace cloudfunctions_v1beta2 { */ versionId?: string; /** - * The VPC Network Connector that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network connector resource. The format of this field is `projects/x/locations/x/connectors/x This field is mutually exclusive with `network` field and will eventually replace it. See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for more information on connecting Cloud projects. This feature is currently in alpha, available only for whitelisted users. + * The VPC Network Connector that this cloud function can connect to. It can be either the fully-qualified URI, or the short name of the network connector resource. The format of this field is `projects/x/locations/x/connectors/x This field is mutually exclusive with `network` field and will eventually replace it. See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for more information on connecting Cloud projects. */ vpcConnector?: string; } diff --git a/src/apis/cloudiot/v1.ts b/src/apis/cloudiot/v1.ts index b9d7753ef2a..88b098048e5 100644 --- a/src/apis/cloudiot/v1.ts +++ b/src/apis/cloudiot/v1.ts @@ -143,7 +143,7 @@ export namespace cloudiot_v1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -381,7 +381,7 @@ export namespace cloudiot_v1 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ requestedPolicyVersion?: number; } @@ -469,11 +469,11 @@ export namespace cloudiot_v1 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** - * Deprecated. + * Specifies the format of the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ version?: number; } diff --git a/src/apis/cloudkms/v1.ts b/src/apis/cloudkms/v1.ts index 41ff0660dba..df782cedc2b 100644 --- a/src/apis/cloudkms/v1.ts +++ b/src/apis/cloudkms/v1.ts @@ -154,7 +154,7 @@ export namespace cloudkms_v1 { signature?: string; } /** - * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "fooservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:bar@gmail.com" ] } ] } ] } For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts foo@gmail.com from DATA_READ logging, and bar@gmail.com from DATA_WRITE logging. + * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "sampleservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts jose@example.com from DATA_READ logging, and aliya@example.com from DATA_WRITE logging. */ export interface Schema$AuditConfig { /** @@ -167,7 +167,7 @@ export namespace cloudkms_v1 { service?: string; } /** - * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting foo@gmail.com from DATA_READ logging. + * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ logging. */ export interface Schema$AuditLogConfig { /** @@ -188,7 +188,7 @@ export namespace cloudkms_v1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -364,7 +364,7 @@ export namespace cloudkms_v1 { */ ciphertext?: string; /** - * The resource name of the CryptoKeyVersion used in encryption. + * The resource name of the CryptoKeyVersion used in encryption. Check this field to verify that the intended resource was used for encryption. */ name?: string; } @@ -605,7 +605,7 @@ export namespace cloudkms_v1 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** @@ -1047,7 +1047,7 @@ export namespace cloudkms_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1120,8 +1120,8 @@ export namespace cloudkms_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.filter Optional. Only include resources that match the filter in the response (https://cloud.google.com/kms/docs/sorting-and-filtering). - * @param {string=} params.orderBy Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order (https://cloud.google.com/kms/docs/sorting-and-filtering). + * @param {string=} params.filter Optional. Only include resources that match the filter in the response. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). + * @param {string=} params.orderBy Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). * @param {integer=} params.pageSize Optional limit on the number of KeyRings to include in the response. Further KeyRings can subsequently be obtained by including the ListKeyRingsResponse.next_page_token in a subsequent request. If unspecified, the server will pick an appropriate default. * @param {string=} params.pageToken Optional pagination token, returned earlier via ListKeyRingsResponse.next_page_token. * @param {string} params.parent Required. The resource name of the location associated with the KeyRings, in the format `projects/x/locations/x`. @@ -1390,7 +1390,7 @@ export namespace cloudkms_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -1406,11 +1406,11 @@ export namespace cloudkms_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. Only include resources that match the filter in the response (https://cloud.google.com/kms/docs/sorting-and-filtering). + * Optional. Only include resources that match the filter in the response. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). */ filter?: string; /** - * Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order (https://cloud.google.com/kms/docs/sorting-and-filtering). + * Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). */ orderBy?: string; /** @@ -1776,7 +1776,7 @@ export namespace cloudkms_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1849,8 +1849,8 @@ export namespace cloudkms_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.filter Optional. Only include resources that match the filter in the response (https://cloud.google.com/kms/docs/sorting-and-filtering). - * @param {string=} params.orderBy Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order (https://cloud.google.com/kms/docs/sorting-and-filtering). + * @param {string=} params.filter Optional. Only include resources that match the filter in the response. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). + * @param {string=} params.orderBy Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). * @param {integer=} params.pageSize Optional limit on the number of CryptoKeys to include in the response. Further CryptoKeys can subsequently be obtained by including the ListCryptoKeysResponse.next_page_token in a subsequent request. If unspecified, the server will pick an appropriate default. * @param {string=} params.pageToken Optional pagination token, returned earlier via ListCryptoKeysResponse.next_page_token. * @param {string} params.parent Required. The resource name of the KeyRing to list, in the format `projects/x/locations/x/keyRings/x`. @@ -2308,7 +2308,7 @@ export namespace cloudkms_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -2324,11 +2324,11 @@ export namespace cloudkms_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. Only include resources that match the filter in the response (https://cloud.google.com/kms/docs/sorting-and-filtering). + * Optional. Only include resources that match the filter in the response. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). */ filter?: string; /** - * Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order (https://cloud.google.com/kms/docs/sorting-and-filtering). + * Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). */ orderBy?: string; /** @@ -2965,8 +2965,8 @@ export namespace cloudkms_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.filter Optional. Only include resources that match the filter in the response (https://cloud.google.com/kms/docs/sorting-and-filtering). - * @param {string=} params.orderBy Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order (https://cloud.google.com/kms/docs/sorting-and-filtering). + * @param {string=} params.filter Optional. Only include resources that match the filter in the response. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). + * @param {string=} params.orderBy Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). * @param {integer=} params.pageSize Optional limit on the number of CryptoKeyVersions to include in the response. Further CryptoKeyVersions can subsequently be obtained by including the ListCryptoKeyVersionsResponse.next_page_token in a subsequent request. If unspecified, the server will pick an appropriate default. * @param {string=} params.pageToken Optional pagination token, returned earlier via ListCryptoKeyVersionsResponse.next_page_token. * @param {string} params.parent Required. The resource name of the CryptoKey to list, in the format `projects/x/locations/x/keyRings/x/cryptoKeys/x`. @@ -3312,11 +3312,11 @@ export namespace cloudkms_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. Only include resources that match the filter in the response (https://cloud.google.com/kms/docs/sorting-and-filtering). + * Optional. Only include resources that match the filter in the response. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). */ filter?: string; /** - * Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order (https://cloud.google.com/kms/docs/sorting-and-filtering). + * Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). */ orderBy?: string; /** @@ -3535,7 +3535,7 @@ export namespace cloudkms_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3608,8 +3608,8 @@ export namespace cloudkms_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.filter Optional. Only include resources that match the filter in the response (https://cloud.google.com/kms/docs/sorting-and-filtering). - * @param {string=} params.orderBy Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order (https://cloud.google.com/kms/docs/sorting-and-filtering). + * @param {string=} params.filter Optional. Only include resources that match the filter in the response. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). + * @param {string=} params.orderBy Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). * @param {integer=} params.pageSize Optional limit on the number of ImportJobs to include in the response. Further ImportJobs can subsequently be obtained by including the ListImportJobsResponse.next_page_token in a subsequent request. If unspecified, the server will pick an appropriate default. * @param {string=} params.pageToken Optional pagination token, returned earlier via ListImportJobsResponse.next_page_token. * @param {string} params.parent Required. The resource name of the KeyRing to list, in the format `projects/x/locations/x/keyRings/x`. @@ -3878,7 +3878,7 @@ export namespace cloudkms_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -3894,11 +3894,11 @@ export namespace cloudkms_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. Only include resources that match the filter in the response (https://cloud.google.com/kms/docs/sorting-and-filtering). + * Optional. Only include resources that match the filter in the response. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). */ filter?: string; /** - * Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order (https://cloud.google.com/kms/docs/sorting-and-filtering). + * Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering). */ orderBy?: string; /** diff --git a/src/apis/cloudprivatecatalogproducer/v1beta1.ts b/src/apis/cloudprivatecatalogproducer/v1beta1.ts index 990e75c3f98..4b75a6a6b28 100644 --- a/src/apis/cloudprivatecatalogproducer/v1beta1.ts +++ b/src/apis/cloudprivatecatalogproducer/v1beta1.ts @@ -303,10 +303,6 @@ export namespace cloudprivatecatalogproducer_v1beta1 { * Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members. */ exemptedMembers?: string[]; - /** - * Specifies whether principals can be exempted for the same LogType in lower-level resource policies. If true, any lower-level exemptions will be ignored. - */ - ignoreChildExemptions?: boolean; /** * The log type that this config enables. */ @@ -755,7 +751,7 @@ export namespace cloudprivatecatalogproducer_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1345,7 +1341,7 @@ export namespace cloudprivatecatalogproducer_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** diff --git a/src/apis/cloudresourcemanager/v1.ts b/src/apis/cloudresourcemanager/v1.ts index d49265c8029..979970cb9c7 100644 --- a/src/apis/cloudresourcemanager/v1.ts +++ b/src/apis/cloudresourcemanager/v1.ts @@ -336,7 +336,7 @@ export namespace cloudresourcemanager_v1 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ requestedPolicyVersion?: number; } @@ -515,19 +515,19 @@ export namespace cloudresourcemanager_v1 { */ export interface Schema$Organization { /** - * Timestamp when the Organization was created. Assigned by the server. @OutputOnly + * Timestamp when the Organization was created. Assigned by the server. */ creationTime?: string; /** - * A human-readable string that refers to the Organization in the GCP Console UI. This string is set by the server and cannot be changed. The string will be set to the primary domain (for example, "google.com") of the G Suite customer that owns the organization. @OutputOnly + * A human-readable string that refers to the Organization in the GCP Console UI. This string is set by the server and cannot be changed. The string will be set to the primary domain (for example, "google.com") of the G Suite customer that owns the organization. */ displayName?: string; /** - * The organization's current lifecycle state. Assigned by the server. @OutputOnly + * The organization's current lifecycle state. Assigned by the server. */ lifecycleState?: string; /** - * Output Only. The resource name of the organization. This is the organization's relative path in the API. Its format is "organizations/[organization_id]". For example, "organizations/1234". + * Output only. The resource name of the organization. This is the organization's relative path in the API. Its format is "organizations/[organization_id]". For example, "organizations/1234". */ name?: string; /** @@ -594,7 +594,7 @@ export namespace cloudresourcemanager_v1 { */ etag?: string; /** - * Deprecated. + * Specifies the format of the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ version?: number; } @@ -5401,7 +5401,7 @@ export namespace cloudresourcemanager_v1 { /** * cloudresourcemanager.projects.setIamPolicy - * @desc Sets the IAM access control policy for the specified Project. Overwrites any existing policy. The following constraints apply when using `setIamPolicy()`: + Project does not support `allUsers` and `allAuthenticatedUsers` as `members` in a `Binding` of a `Policy`. + The owner role can be granted only to `user` and `serviceAccount`. + Service accounts can be made owners of a project directly without any restrictions. However, to be added as an owner, a user must be invited via Cloud Platform console and must accept the invitation. + A user cannot be granted the owner role using `setIamPolicy()`. The user must be granted the owner role using the Cloud Platform Console and must explicitly accept the invitation. + You can only grant ownership of a project to a member by using the GCP Console. Inviting a member will deliver an invitation email that they must accept. An invitation email is not generated if you are granting a role other than owner, or if both the member you are inviting and the project are part of your organization. + Membership changes that leave the project without any owners that have accepted the Terms of Service (ToS) will be rejected. + If the project is not part of an organization, there must be at least one owner who has accepted the Terms of Service (ToS) agreement in the policy. Calling `setIamPolicy()` to remove the last ToS-accepted owner from the policy will fail. This restriction also applies to legacy projects that no longer have owners who have accepted the ToS. Edits to IAM policies will be rejected until the lack of a ToS-accepting owner is rectified. + This method will replace the existing policy, and cannot be used to append additional IAM settings. Note: Removing service accounts from policies or changing their roles can render services completely inoperable. It is important to understand how the service account is being used before removing or updating its roles. Authorization requires the Google IAM permission `resourcemanager.projects.setIamPolicy` on the project + * @desc Sets the IAM access control policy for the specified Project. Overwrites any existing policy. The following constraints apply when using `setIamPolicy()`: + Project does not support `allUsers` and `allAuthenticatedUsers` as `members` in a `Binding` of a `Policy`. + The owner role can be granted to a `user`, `serviceAccount`, or a group that is part of an organization. For example, group@myownpersonaldomain.com could be added as an owner to a project in the myownpersonaldomain.com organization, but not the examplepetstore.com organization. + Service accounts can be made owners of a project directly without any restrictions. However, to be added as an owner, a user must be invited via Cloud Platform console and must accept the invitation. + A user cannot be granted the owner role using `setIamPolicy()`. The user must be granted the owner role using the Cloud Platform Console and must explicitly accept the invitation. + You can only grant ownership of a project to a member by using the GCP Console. Inviting a member will deliver an invitation email that they must accept. An invitation email is not generated if you are granting a role other than owner, or if both the member you are inviting and the project are part of your organization. + Membership changes that leave the project without any owners that have accepted the Terms of Service (ToS) will be rejected. + If the project is not part of an organization, there must be at least one owner who has accepted the Terms of Service (ToS) agreement in the policy. Calling `setIamPolicy()` to remove the last ToS-accepted owner from the policy will fail. This restriction also applies to legacy projects that no longer have owners who have accepted the ToS. Edits to IAM policies will be rejected until the lack of a ToS-accepting owner is rectified. + This method will replace the existing policy, and cannot be used to append additional IAM settings. Note: Removing service accounts from policies or changing their roles can render services completely inoperable. It is important to understand how the service account is being used before removing or updating its roles. Authorization requires the Google IAM permission `resourcemanager.projects.setIamPolicy` on the project * @example * * // BEFORE RUNNING: * // --------------- diff --git a/src/apis/cloudresourcemanager/v1beta1.ts b/src/apis/cloudresourcemanager/v1beta1.ts index bb2d91af787..377a505fa21 100644 --- a/src/apis/cloudresourcemanager/v1beta1.ts +++ b/src/apis/cloudresourcemanager/v1beta1.ts @@ -253,7 +253,7 @@ export namespace cloudresourcemanager_v1beta1 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ requestedPolicyVersion?: number; } @@ -288,19 +288,19 @@ export namespace cloudresourcemanager_v1beta1 { */ export interface Schema$Organization { /** - * Timestamp when the Organization was created. Assigned by the server. @OutputOnly + * Timestamp when the Organization was created. Assigned by the server. */ creationTime?: string; /** - * A human-readable string that refers to the Organization in the GCP Console UI. This string is set by the server and cannot be changed. The string will be set to the primary domain (for example, "google.com") of the G Suite customer that owns the organization. @OutputOnly + * A human-readable string that refers to the Organization in the GCP Console UI. This string is set by the server and cannot be changed. The string will be set to the primary domain (for example, "google.com") of the G Suite customer that owns the organization. */ displayName?: string; /** - * The organization's current lifecycle state. Assigned by the server. @OutputOnly + * The organization's current lifecycle state. Assigned by the server. */ lifecycleState?: string; /** - * Output Only. The resource name of the organization. This is the organization's relative path in the API. Its format is "organizations/[organization_id]". For example, "organizations/1234". + * Output only. The resource name of the organization. This is the organization's relative path in the API. Its format is "organizations/[organization_id]". For example, "organizations/1234". */ name?: string; /** @@ -338,7 +338,7 @@ export namespace cloudresourcemanager_v1beta1 { */ etag?: string; /** - * Deprecated. + * Specifies the format of the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ version?: number; } @@ -1152,7 +1152,7 @@ export namespace cloudresourcemanager_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Output Only. The resource name of the organization. This is the organization's relative path in the API. Its format is "organizations/[organization_id]". For example, "organizations/1234". + * @param {string} params.name Output only. The resource name of the organization. This is the organization's relative path in the API. Its format is "organizations/[organization_id]". For example, "organizations/1234". * @param {().Organization} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1314,7 +1314,7 @@ export namespace cloudresourcemanager_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Output Only. The resource name of the organization. This is the organization's relative path in the API. Its format is "organizations/[organization_id]". For example, "organizations/1234". + * Output only. The resource name of the organization. This is the organization's relative path in the API. Its format is "organizations/[organization_id]". For example, "organizations/1234". */ name?: string; @@ -2067,7 +2067,7 @@ export namespace cloudresourcemanager_v1beta1 { /** * cloudresourcemanager.projects.setIamPolicy - * @desc Sets the IAM access control policy for the specified Project. Overwrites any existing policy. The following constraints apply when using `setIamPolicy()`: + Project does not support `allUsers` and `allAuthenticatedUsers` as `members` in a `Binding` of a `Policy`. + The owner role can be granted only to `user` and `serviceAccount`. + Service accounts can be made owners of a project directly without any restrictions. However, to be added as an owner, a user must be invited via Cloud Platform console and must accept the invitation. + A user cannot be granted the owner role using `setIamPolicy()`. The user must be granted the owner role using the Cloud Platform Console and must explicitly accept the invitation. + Invitations to grant the owner role cannot be sent using `setIamPolicy()`; they must be sent only using the Cloud Platform Console. + Membership changes that leave the project without any owners that have accepted the Terms of Service (ToS) will be rejected. + If the project is not part of an organization, there must be at least one owner who has accepted the Terms of Service (ToS) agreement in the policy. Calling `setIamPolicy()` to remove the last ToS-accepted owner from the policy will fail. This restriction also applies to legacy projects that no longer have owners who have accepted the ToS. Edits to IAM policies will be rejected until the lack of a ToS-accepting owner is rectified. + This method will replace the existing policy, and cannot be used to append additional IAM settings. Note: Removing service accounts from policies or changing their roles can render services completely inoperable. It is important to understand how the service account is being used before removing or updating its roles. + * @desc Sets the IAM access control policy for the specified Project. Overwrites any existing policy. The following constraints apply when using `setIamPolicy()`: + Project does not support `allUsers` and `allAuthenticatedUsers` as `members` in a `Binding` of a `Policy`. + The owner role can be granted to a `user`, `serviceAccount`, or a group that is part of an organization. For example, group@myownpersonaldomain.com could be added as an owner to a project in the myownpersonaldomain.com organization, but not the examplepetstore.com organization. + Service accounts can be made owners of a project directly without any restrictions. However, to be added as an owner, a user must be invited via Cloud Platform console and must accept the invitation. + A user cannot be granted the owner role using `setIamPolicy()`. The user must be granted the owner role using the Cloud Platform Console and must explicitly accept the invitation. + Invitations to grant the owner role cannot be sent using `setIamPolicy()`; they must be sent only using the Cloud Platform Console. + Membership changes that leave the project without any owners that have accepted the Terms of Service (ToS) will be rejected. + If the project is not part of an organization, there must be at least one owner who has accepted the Terms of Service (ToS) agreement in the policy. Calling `setIamPolicy()` to remove the last ToS-accepted owner from the policy will fail. This restriction also applies to legacy projects that no longer have owners who have accepted the ToS. Edits to IAM policies will be rejected until the lack of a ToS-accepting owner is rectified. + This method will replace the existing policy, and cannot be used to append additional IAM settings. Note: Removing service accounts from policies or changing their roles can render services completely inoperable. It is important to understand how the service account is being used before removing or updating its roles. * @example * * // BEFORE RUNNING: * // --------------- diff --git a/src/apis/cloudresourcemanager/v2.ts b/src/apis/cloudresourcemanager/v2.ts index d8ea48e4330..d4007df0db3 100644 --- a/src/apis/cloudresourcemanager/v2.ts +++ b/src/apis/cloudresourcemanager/v2.ts @@ -252,7 +252,7 @@ export namespace cloudresourcemanager_v2 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ requestedPolicyVersion?: number; } diff --git a/src/apis/cloudresourcemanager/v2beta1.ts b/src/apis/cloudresourcemanager/v2beta1.ts index 46de74e3260..8c91e90f001 100644 --- a/src/apis/cloudresourcemanager/v2beta1.ts +++ b/src/apis/cloudresourcemanager/v2beta1.ts @@ -252,7 +252,7 @@ export namespace cloudresourcemanager_v2beta1 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ requestedPolicyVersion?: number; } diff --git a/src/apis/cloudscheduler/v1.ts b/src/apis/cloudscheduler/v1.ts index 8bda17819f3..02df4d02404 100644 --- a/src/apis/cloudscheduler/v1.ts +++ b/src/apis/cloudscheduler/v1.ts @@ -192,7 +192,7 @@ export namespace cloudscheduler_v1 { */ oidcToken?: Schema$OidcToken; /** - * Required. The full URI path that the request will be sent to. This string must begin with either "http://" or "https://". Some examples of valid values for uri are: `http://acme.com` and `https://acme.com/sales:8080`. Cloud Scheduler will encode some characters for safety and compatibility. The maximum allowed URL length is 2083 characters after encoding. + * Required. The full URI path that the request will be sent to. This string must begin with either "http://" or "https://". Some examples of valid values for uri are: `http://acme.com` and `https://acme.com/sales:8080`. Cloud Scheduler will encode some characters for safety and compatibility. The maximum allowed URL length is 2083 characters after encoding. */ uri?: string; } @@ -372,7 +372,7 @@ export namespace cloudscheduler_v1 { */ data?: string; /** - * Required. The name of the Cloud Pub/Sub topic to which messages will be published when a job is delivered. The topic name must be in the same format as required by PubSub's [PublishRequest.name](https://cloud.google.com/pubsub/docs/reference/rpc/google.pubsub.v1#publishrequest), for example `projects/PROJECT_ID/topics/TOPIC_ID`. The topic must be in the same project as the Cloud Scheduler job. + * Required. The name of the Cloud Pub/Sub topic to which messages will be published when a job is delivered. The topic name must be in the same format as required by PubSub's [PublishRequest.name](https://cloud.google.com/pubsub/docs/reference/rpc/google.pubsub.v1#publishrequest), for example `projects/PROJECT_ID/topics/TOPIC_ID`. The topic must be in the same project as the Cloud Scheduler job. */ topicName?: string; } @@ -802,7 +802,7 @@ export namespace cloudscheduler_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. + * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. * @param {().Job} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -918,7 +918,7 @@ export namespace cloudscheduler_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1036,7 +1036,7 @@ export namespace cloudscheduler_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1169,7 +1169,7 @@ export namespace cloudscheduler_v1 { * @param {object} params Parameters for request * @param {integer=} params.pageSize Requested page size. The maximum page size is 500. If unspecified, the page size will be the maximum. Fewer jobs than requested might be returned, even if more jobs exist; use next_page_token to determine if more jobs exist. * @param {string=} params.pageToken A token identifying a page of results the server will return. To request the first page results, page_token must be empty. To request the next page of results, page_token must be the value of next_page_token returned from the previous call to ListJobs. It is an error to switch the value of filter or order_by while iterating through pages. - * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. + * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1431,7 +1431,7 @@ export namespace cloudscheduler_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. * @param {().PauseJobRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1554,7 +1554,7 @@ export namespace cloudscheduler_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. * @param {().ResumeJobRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1677,7 +1677,7 @@ export namespace cloudscheduler_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. * @param {().RunJobRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1750,7 +1750,7 @@ export namespace cloudscheduler_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. + * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. */ parent?: string; @@ -1767,7 +1767,7 @@ export namespace cloudscheduler_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. */ name?: string; } @@ -1779,7 +1779,7 @@ export namespace cloudscheduler_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. */ name?: string; } @@ -1799,7 +1799,7 @@ export namespace cloudscheduler_v1 { */ pageToken?: string; /** - * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. + * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. */ parent?: string; } @@ -1832,7 +1832,7 @@ export namespace cloudscheduler_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. */ name?: string; @@ -1849,7 +1849,7 @@ export namespace cloudscheduler_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. */ name?: string; @@ -1866,7 +1866,7 @@ export namespace cloudscheduler_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. */ name?: string; diff --git a/src/apis/cloudscheduler/v1beta1.ts b/src/apis/cloudscheduler/v1beta1.ts index c036175e7bd..15d39c228e6 100644 --- a/src/apis/cloudscheduler/v1beta1.ts +++ b/src/apis/cloudscheduler/v1beta1.ts @@ -192,7 +192,7 @@ export namespace cloudscheduler_v1beta1 { */ oidcToken?: Schema$OidcToken; /** - * Required. The full URI path that the request will be sent to. This string must begin with either "http://" or "https://". Some examples of valid values for uri are: `http://acme.com` and `https://acme.com/sales:8080`. Cloud Scheduler will encode some characters for safety and compatibility. The maximum allowed URL length is 2083 characters after encoding. + * Required. The full URI path that the request will be sent to. This string must begin with either "http://" or "https://". Some examples of valid values for uri are: `http://acme.com` and `https://acme.com/sales:8080`. Cloud Scheduler will encode some characters for safety and compatibility. The maximum allowed URL length is 2083 characters after encoding. */ uri?: string; } @@ -372,7 +372,7 @@ export namespace cloudscheduler_v1beta1 { */ data?: string; /** - * Required. The name of the Cloud Pub/Sub topic to which messages will be published when a job is delivered. The topic name must be in the same format as required by PubSub's [PublishRequest.name](https://cloud.google.com/pubsub/docs/reference/rpc/google.pubsub.v1#publishrequest), for example `projects/PROJECT_ID/topics/TOPIC_ID`. The topic must be in the same project as the Cloud Scheduler job. + * Required. The name of the Cloud Pub/Sub topic to which messages will be published when a job is delivered. The topic name must be in the same format as required by PubSub's [PublishRequest.name](https://cloud.google.com/pubsub/docs/reference/rpc/google.pubsub.v1#publishrequest), for example `projects/PROJECT_ID/topics/TOPIC_ID`. The topic must be in the same project as the Cloud Scheduler job. */ topicName?: string; } @@ -802,7 +802,7 @@ export namespace cloudscheduler_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. + * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. * @param {().Job} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -921,7 +921,7 @@ export namespace cloudscheduler_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1039,7 +1039,7 @@ export namespace cloudscheduler_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1172,7 +1172,7 @@ export namespace cloudscheduler_v1beta1 { * @param {object} params Parameters for request * @param {integer=} params.pageSize Requested page size. The maximum page size is 500. If unspecified, the page size will be the maximum. Fewer jobs than requested might be returned, even if more jobs exist; use next_page_token to determine if more jobs exist. * @param {string=} params.pageToken A token identifying a page of results the server will return. To request the first page results, page_token must be empty. To request the next page of results, page_token must be the value of next_page_token returned from the previous call to ListJobs. It is an error to switch the value of filter or order_by while iterating through pages. - * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. + * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1437,7 +1437,7 @@ export namespace cloudscheduler_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. * @param {().PauseJobRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1563,7 +1563,7 @@ export namespace cloudscheduler_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. * @param {().ResumeJobRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1689,7 +1689,7 @@ export namespace cloudscheduler_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * @param {string} params.name Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. * @param {().RunJobRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1765,7 +1765,7 @@ export namespace cloudscheduler_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. + * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. */ parent?: string; @@ -1782,7 +1782,7 @@ export namespace cloudscheduler_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. */ name?: string; } @@ -1794,7 +1794,7 @@ export namespace cloudscheduler_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. */ name?: string; } @@ -1814,7 +1814,7 @@ export namespace cloudscheduler_v1beta1 { */ pageToken?: string; /** - * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. + * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID`. */ parent?: string; } @@ -1847,7 +1847,7 @@ export namespace cloudscheduler_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. */ name?: string; @@ -1864,7 +1864,7 @@ export namespace cloudscheduler_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. */ name?: string; @@ -1881,7 +1881,7 @@ export namespace cloudscheduler_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + * Required. The job name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. */ name?: string; diff --git a/src/apis/cloudsearch/v1.ts b/src/apis/cloudsearch/v1.ts index 2d011768030..941f2ff2c4d 100644 --- a/src/apis/cloudsearch/v1.ts +++ b/src/apis/cloudsearch/v1.ts @@ -1240,6 +1240,10 @@ export namespace cloudsearch_v1 { * Indicates that the property can be used for sorting. Cannot be true for properties that are repeatable. Cannot be true for properties whose type is object or user identifier. IsReturnable must be true to set this option. Only supported for Boolean, Date, Double, Integer, and Timestamp properties. */ isSortable?: boolean; + /** + * Indicates that the property can be used for generating query suggestions. + */ + isSuggestable?: boolean; /** * Indicates that users can perform wildcard search for this property. Only supported for Text properties. IsReturnable must be true to set this option. In a given datasource maximum of 5 properties can be marked as is_wildcard_searchable. Note: This is an alpha feature and is enabled for whitelisted users only. */ @@ -1311,7 +1315,7 @@ export namespace cloudsearch_v1 { export interface Schema$QueryInterpretation { interpretationType?: string; /** - * The interpretation of the query used in search. For example, query "email from john" will be interpreted as "from:john source:mail" + * The interpretation of the query used in search. For example, queries with natural language intent like "email from john" will be interpreted as "from:john source:mail". This field will not be filled when the reason is NO_RESULTS_FOUND_FOR_USER_QUERY. */ interpretedQuery?: string; } @@ -1806,10 +1810,6 @@ export namespace cloudsearch_v1 { * Set search results crowding limits. Crowding is a situation in which multiple results from the same source or host "crowd out" other results, diminishing the quality of search for users. To foster better search quality and source diversity in search results, you can set a condition to reduce repetitive results by source. */ export interface Schema$SourceCrowdingConfig { - /** - * Use a field to control results crowding. For example, if you want to control overly similar results from Gmail topics, use `thread_id`. For similar pages from Google Sites, you can use `webspace_id`. When matching query results contain the same field value in `GenericMetadata`, crowding limits are set on those records. - */ - field?: string; /** * Maximum number of results allowed from a source. No limits will be set on results if this value is less than or equal to 0. */ @@ -1818,10 +1818,6 @@ export namespace cloudsearch_v1 { * Maximum number of suggestions allowed from a source. No limits will be set on results if this value is less than or equal to 0. */ numSuggestions?: number; - /** - * Control results by content source. This option limits the total number of results from a given source and ignores field-based crowding control. - */ - source?: boolean; } /** * Per source result count information. @@ -3620,7 +3616,7 @@ export namespace cloudsearch_v1 { /** * cloudsearch.indexing.datasources.items.upload - * @desc Creates an upload session for uploading item content. For items smaller than 100 KiB, it's easier to embed the content inline within update. + * @desc Creates an upload session for uploading item content. For items smaller than 100 KB, it's easier to embed the content inline within an index request. * @alias cloudsearch.indexing.datasources.items.upload * @memberOf! () * @@ -3885,7 +3881,7 @@ export namespace cloudsearch_v1 { /** * cloudsearch.media.upload - * @desc Uploads media for indexing. The upload endpoint supports direct and resumable upload protocols and is intended for large items that can not be inlined during index requests. To index large content: 1. Call upload to begin a session and get the item reference. 1. Upload the content using the item reference's resource name. 1. Call index with the item reference as the content. For additional information, see [Create a content connector using the REST API](https://developers.google.com/cloud-search/docs/guides/content-connector#rest). + * @desc Uploads media for indexing. The upload endpoint supports direct and resumable upload protocols and is intended for large items that can not be [inlined during index requests](https://developers.google.com/cloud-search/docs/reference/rest/v1/indexing.datasources.items#itemcontent). To index large content: 1. Call indexing.datasources.items.upload with the resource name to begin an upload session and retrieve the UploadItemRef. 1. Call media.upload to upload the content using the same resource name from step 1. 1. Call indexing.datasources.items.index to index the item. Populate the [ItemContent](/cloud-search/docs/reference/rest/v1/indexing.datasources.items#ItemContent) with the UploadItemRef from step 1. For additional information, see [Create a content connector using the REST API](https://developers.google.com/cloud-search/docs/guides/content-connector#rest). * @alias cloudsearch.media.upload * @memberOf! () * diff --git a/src/apis/cloudshell/v1.ts b/src/apis/cloudshell/v1.ts index cd0f934a4d3..63b75922a2b 100644 --- a/src/apis/cloudshell/v1.ts +++ b/src/apis/cloudshell/v1.ts @@ -161,6 +161,10 @@ export namespace cloudshell_v1 { * Output only. Current execution state of this environment. */ state?: string; + /** + * Output only. Host to which clients can connect to initiate HTTPS or WSS connections with the environment. + */ + webHost?: string; } /** * The response message for Operations.ListOperations. diff --git a/src/apis/cloudshell/v1alpha1.ts b/src/apis/cloudshell/v1alpha1.ts index aaaf6112350..f5b59f3f3c7 100644 --- a/src/apis/cloudshell/v1alpha1.ts +++ b/src/apis/cloudshell/v1alpha1.ts @@ -183,6 +183,10 @@ export namespace cloudshell_v1alpha1 { * Output only. Current execution state of this environment. */ state?: string; + /** + * Output only. Host to which clients can connect to initiate HTTPS or WSS connections with the environment. + */ + webHost?: string; } /** * This resource represents a long-running operation that is the result of a network API call. diff --git a/src/apis/cloudtasks/v2.ts b/src/apis/cloudtasks/v2.ts index 5657d7426a2..2f35458b8a2 100644 --- a/src/apis/cloudtasks/v2.ts +++ b/src/apis/cloudtasks/v2.ts @@ -118,11 +118,11 @@ export namespace cloudtasks_v2 { } /** - * App Engine HTTP request. The message defines the HTTP request that is sent to an App Engine app when the task is dispatched. Using AppEngineHttpRequest requires [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control) Google IAM permission for the project and the following scope: `https://www.googleapis.com/auth/cloud-platform` The task will be delivered to the App Engine app which belongs to the same project as the queue. For more information, see [How Requests are Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed) and how routing is affected by [dispatch files](https://cloud.google.com/appengine/docs/python/config/dispatchref). Traffic is encrypted during transport and never leaves Google datacenters. Because this traffic is carried over a communication mechanism internal to Google, you cannot explicitly set the protocol (for example, HTTP or HTTPS). The request to the handler, however, will appear to have used the HTTP protocol. The AppEngineRouting used to construct the URL that the task is delivered to can be set at the queue-level or task-level: * If set, app_engine_routing_override is used for all tasks in the queue, no matter what the setting is for the task-level app_engine_routing. The `url` that the task will be sent to is: * `url =` host `+` relative_uri Tasks can be dispatched to secure app handlers, unsecure app handlers, and URIs restricted with [`login: admin`](https://cloud.google.com/appengine/docs/standard/python/config/appref). Because tasks are not run as any user, they cannot be dispatched to URIs restricted with [`login: required`](https://cloud.google.com/appengine/docs/standard/python/config/appref) Task dispatches also do not follow redirects. The task attempt has succeeded if the app's request handler returns an HTTP response code in the range [`200` - `299`]. The task attempt has failed if the app's handler returns a non-2xx response code or Cloud Tasks does not receive response before the deadline. Failed tasks will be retried according to the retry configuration. `503` (Service Unavailable) is considered an App Engine system error instead of an application error and will cause Cloud Tasks' traffic congestion control to temporarily throttle the queue's dispatches. Unlike other types of task targets, a `429` (Too Many Requests) response from an app handler does not cause traffic congestion control to throttle the queue. + * App Engine HTTP request. The message defines the HTTP request that is sent to an App Engine app when the task is dispatched. Using AppEngineHttpRequest requires [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control) Google IAM permission for the project and the following scope: `https://www.googleapis.com/auth/cloud-platform` The task will be delivered to the App Engine app which belongs to the same project as the queue. For more information, see [How Requests are Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed) and how routing is affected by [dispatch files](https://cloud.google.com/appengine/docs/python/config/dispatchref). Traffic is encrypted during transport and never leaves Google datacenters. Because this traffic is carried over a communication mechanism internal to Google, you cannot explicitly set the protocol (for example, HTTP or HTTPS). The request to the handler, however, will appear to have used the HTTP protocol. The AppEngineRouting used to construct the URL that the task is delivered to can be set at the queue-level or task-level: * If app_engine_routing_override is set on the queue, this value is used for all tasks in the queue, no matter what the setting is for the task-level app_engine_routing. The `url` that the task will be sent to is: * `url =` host `+` relative_uri Tasks can be dispatched to secure app handlers, unsecure app handlers, and URIs restricted with [`login: admin`](https://cloud.google.com/appengine/docs/standard/python/config/appref). Because tasks are not run as any user, they cannot be dispatched to URIs restricted with [`login: required`](https://cloud.google.com/appengine/docs/standard/python/config/appref) Task dispatches also do not follow redirects. The task attempt has succeeded if the app's request handler returns an HTTP response code in the range [`200` - `299`]. The task attempt has failed if the app's handler returns a non-2xx response code or Cloud Tasks does not receive response before the deadline. Failed tasks will be retried according to the retry configuration. `503` (Service Unavailable) is considered an App Engine system error instead of an application error and will cause Cloud Tasks' traffic congestion control to temporarily throttle the queue's dispatches. Unlike other types of task targets, a `429` (Too Many Requests) response from an app handler does not cause traffic congestion control to throttle the queue. */ export interface Schema$AppEngineHttpRequest { /** - * Task-level setting for App Engine routing. If set, app_engine_routing_override is used for all tasks in the queue, no matter what the setting is for the task-level app_engine_routing. + * Task-level setting for App Engine routing. * If app_engine_routing_override is set on the queue, this value is used for all tasks in the queue, no matter what the setting is for the task-level app_engine_routing. */ appEngineRouting?: Schema$AppEngineRouting; /** @@ -143,7 +143,7 @@ export namespace cloudtasks_v2 { relativeUri?: string; } /** - * App Engine Routing. Defines routing characteristics specific to App Engine - service, version, and instance. For more information about services, versions, and instances see [An Overview of App Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine), [Microservices Architecture on Google App Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine), [App Engine Standard request routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed), and [App Engine Flex request routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed). + * App Engine Routing. Defines routing characteristics specific to App Engine - service, version, and instance. For more information about services, versions, and instances see [An Overview of App Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine), [Microservices Architecture on Google App Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine), [App Engine Standard request routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed), and [App Engine Flex request routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed). Using AppEngineRouting requires [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control) Google IAM permission for the project and the following scope: `https://www.googleapis.com/auth/cloud-platform` */ export interface Schema$AppEngineRouting { /** @@ -193,7 +193,7 @@ export namespace cloudtasks_v2 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -210,7 +210,7 @@ export namespace cloudtasks_v2 { */ responseView?: string; /** - * Required. The task to add. Task names have the following format: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`. The user can optionally specify a task name. If a name is not specified then the system will generate a random unique task id, which will be set in the task returned in the response. If schedule_time is not set or is in the past then Cloud Tasks will set it to the current time. Task De-duplication: Explicitly specifying a task ID enables task de-duplication. If a task's ID is identical to that of an existing task or a task that was deleted or executed recently then the call will fail with ALREADY_EXISTS. If the task's queue was created using Cloud Tasks, then another task with the same name can't be created for ~1hour after the original task was deleted or executed. If the task's queue was created using queue.yaml or queue.xml, then another task with the same name can't be created for ~9days after the original task was deleted or executed. Because there is an extra lookup cost to identify duplicate task names, these CreateTask calls have significantly increased latency. Using hashed strings for the task id or for the prefix of the task id is recommended. Choosing task ids that are sequential or have sequential prefixes, for example using a timestamp, causes an increase in latency and error rates in all task commands. The infrastructure relies on an approximately uniform distribution of task ids to store and serve tasks efficiently. + * Required. The task to add. Task names have the following format: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`. The user can optionally specify a task name. If a name is not specified then the system will generate a random unique task id, which will be set in the task returned in the response. If schedule_time is not set or is in the past then Cloud Tasks will set it to the current time. Task De-duplication: Explicitly specifying a task ID enables task de-duplication. If a task's ID is identical to that of an existing task or a task that was deleted or executed recently then the call will fail with ALREADY_EXISTS. If the task's queue was created using Cloud Tasks, then another task with the same name can't be created for ~1hour after the original task was deleted or executed. If the task's queue was created using queue.yaml or queue.xml, then another task with the same name can't be created for ~9days after the original task was deleted or executed. Because there is an extra lookup cost to identify duplicate task names, these CreateTask calls have significantly increased latency. Using hashed strings for the task id or for the prefix of the task id is recommended. Choosing task ids that are sequential or have sequential prefixes, for example using a timestamp, causes an increase in latency and error rates in all task commands. The infrastructure relies on an approximately uniform distribution of task ids to store and serve tasks efficiently. */ task?: Schema$Task; } @@ -242,7 +242,21 @@ export namespace cloudtasks_v2 { /** * Request message for `GetIamPolicy` method. */ - export interface Schema$GetIamPolicyRequest {} + export interface Schema$GetIamPolicyRequest { + /** + * OPTIONAL: A `GetPolicyOptions` object for specifying options to `GetIamPolicy`. This field is only used by Cloud IAM. + */ + options?: Schema$GetPolicyOptions; + } + /** + * Encapsulates settings provided to GetIamPolicy. + */ + export interface Schema$GetPolicyOptions { + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + requestedPolicyVersion?: number; + } /** * The response message for Locations.ListLocations. */ @@ -320,7 +334,7 @@ export namespace cloudtasks_v2 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** @@ -366,7 +380,7 @@ export namespace cloudtasks_v2 { */ export interface Schema$RateLimits { /** - * Output only. The max burst size. Max burst size limits how fast tasks in queue are processed when many tasks are in the queue and the rate is high. This field allows the queue to have a high rate so processing starts shortly after a task is enqueued, but still limits resource usage when many tasks are enqueued in a short period of time. The [token bucket](https://wikipedia.org/wiki/Token_Bucket) algorithm is used to control the rate of task dispatches. Each queue has a token bucket that holds tokens, up to the maximum specified by `max_burst_size`. Each time a task is dispatched, a token is removed from the bucket. Tasks will be dispatched until the queue's bucket runs out of tokens. The bucket will be continuously refilled with new tokens based on max_dispatches_per_second. Cloud Tasks will pick the value of `max_burst_size` based on the value of max_dispatches_per_second. For App Engine queues that were created or updated using `queue.yaml/xml`, `max_burst_size` is equal to [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size). Since `max_burst_size` is output only, if UpdateQueue is called on a queue created by `queue.yaml/xml`, `max_burst_size` will be reset based on the value of max_dispatches_per_second, regardless of whether max_dispatches_per_second is updated. + * Output only. The max burst size. Max burst size limits how fast tasks in queue are processed when many tasks are in the queue and the rate is high. This field allows the queue to have a high rate so processing starts shortly after a task is enqueued, but still limits resource usage when many tasks are enqueued in a short period of time. The [token bucket](https://wikipedia.org/wiki/Token_Bucket) algorithm is used to control the rate of task dispatches. Each queue has a token bucket that holds tokens, up to the maximum specified by `max_burst_size`. Each time a task is dispatched, a token is removed from the bucket. Tasks will be dispatched until the queue's bucket runs out of tokens. The bucket will be continuously refilled with new tokens based on max_dispatches_per_second. Cloud Tasks will pick the value of `max_burst_size` based on the value of max_dispatches_per_second. For queues that were created or updated using `queue.yaml/xml`, `max_burst_size` is equal to [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size). Since `max_burst_size` is output only, if UpdateQueue is called on a queue created by `queue.yaml/xml`, `max_burst_size` will be reset based on the value of max_dispatches_per_second, regardless of whether max_dispatches_per_second is updated. */ maxBurstSize?: number; /** @@ -374,7 +388,7 @@ export namespace cloudtasks_v2 { */ maxConcurrentDispatches?: number; /** - * The maximum rate at which tasks are dispatched from this queue. If unspecified when the queue is created, Cloud Tasks will pick the default. * For App Engine queues, the maximum allowed value is 500. This field has the same meaning as [rate in queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate). + * The maximum rate at which tasks are dispatched from this queue. If unspecified when the queue is created, Cloud Tasks will pick the default. * The maximum allowed value is 500. This field has the same meaning as [rate in queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate). */ maxDispatchesPerSecond?: number; } @@ -479,7 +493,7 @@ export namespace cloudtasks_v2 { */ responseCount?: number; /** - * The time when the task is scheduled to be attempted. For App Engine queues, this is when the task will be attempted or retried. `schedule_time` will be truncated to the nearest microsecond. + * The time when the task is scheduled to be attempted or retried. `schedule_time` will be truncated to the nearest microsecond. */ scheduleTime?: string; /** @@ -884,7 +898,7 @@ export namespace cloudtasks_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The location name in which the queue will be created. For example: `projects/PROJECT_ID/locations/LOCATION_ID` The list of allowed locations can be obtained by calling Cloud Tasks' implementation of ListLocations. + * @param {string} params.parent Required. The location name in which the queue will be created. For example: `projects/PROJECT_ID/locations/LOCATION_ID` The list of allowed locations can be obtained by calling Cloud Tasks' implementation of ListLocations. * @param {().Queue} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1002,7 +1016,7 @@ export namespace cloudtasks_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1119,7 +1133,7 @@ export namespace cloudtasks_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the queue. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The resource name of the queue. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1376,7 +1390,7 @@ export namespace cloudtasks_v2 { * @param {string=} params.filter `filter` can be used to specify a subset of queues. Any Queue field can be used as a filter and several operators as supported. For example: `<=, <, >=, >, !=, =, :`. The filter syntax is the same as described in [Stackdriver's Advanced Logs Filters](https://cloud.google.com/logging/docs/view/advanced_filters). Sample filter "state: PAUSED". Note that using filters might cause fewer queues than the requested page_size to be returned. * @param {integer=} params.pageSize Requested page size. The maximum page size is 9800. If unspecified, the page size will be the maximum. Fewer queues than requested might be returned, even if more queues exist; use the next_page_token in the response to determine if more queues exist. * @param {string=} params.pageToken A token identifying the page of results to return. To request the first page results, page_token must be empty. To request the next page of results, page_token must be the value of next_page_token returned from the previous call to ListQueues method. It is an error to switch the value of the filter while iterating through pages. - * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID` + * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1640,7 +1654,7 @@ export namespace cloudtasks_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` * @param {().PauseQueueRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1762,7 +1776,7 @@ export namespace cloudtasks_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` * @param {().PurgeQueueRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1884,7 +1898,7 @@ export namespace cloudtasks_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` * @param {().ResumeQueueRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2213,7 +2227,7 @@ export namespace cloudtasks_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The location name in which the queue will be created. For example: `projects/PROJECT_ID/locations/LOCATION_ID` The list of allowed locations can be obtained by calling Cloud Tasks' implementation of ListLocations. + * Required. The location name in which the queue will be created. For example: `projects/PROJECT_ID/locations/LOCATION_ID` The list of allowed locations can be obtained by calling Cloud Tasks' implementation of ListLocations. */ parent?: string; @@ -2230,7 +2244,7 @@ export namespace cloudtasks_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` */ name?: string; } @@ -2242,7 +2256,7 @@ export namespace cloudtasks_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the queue. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * Required. The resource name of the queue. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` */ name?: string; } @@ -2283,7 +2297,7 @@ export namespace cloudtasks_v2 { */ pageToken?: string; /** - * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID` + * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID` */ parent?: string; } @@ -2316,7 +2330,7 @@ export namespace cloudtasks_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` */ name?: string; @@ -2333,7 +2347,7 @@ export namespace cloudtasks_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` */ name?: string; @@ -2350,7 +2364,7 @@ export namespace cloudtasks_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` */ name?: string; @@ -2460,7 +2474,7 @@ export namespace cloudtasks_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` The queue must already exist. + * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` The queue must already exist. * @param {().CreateTaskRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2578,7 +2592,7 @@ export namespace cloudtasks_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2695,7 +2709,7 @@ export namespace cloudtasks_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` * @param {string=} params.responseView The response_view specifies which subset of the Task will be returned. By default response_view is BASIC; not all information is retrieved by default because some data, such as payloads, might be desirable to return only when needed because of its large size or because of the sensitivity of data that it contains. Authorization for FULL requires `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/) permission on the Task resource. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2828,7 +2842,7 @@ export namespace cloudtasks_v2 { * @param {object} params Parameters for request * @param {integer=} params.pageSize Maximum page size. Fewer tasks than requested might be returned, even if more tasks exist; use next_page_token in the response to determine if more tasks exist. The maximum page size is 1000. If unspecified, the page size will be the maximum. * @param {string=} params.pageToken A token identifying the page of results to return. To request the first page results, page_token must be empty. To request the next page of results, page_token must be the value of next_page_token returned from the previous call to ListTasks method. The page token is valid for only 2 hours. - * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` * @param {string=} params.responseView The response_view specifies which subset of the Task will be returned. By default response_view is BASIC; not all information is retrieved by default because some data, such as payloads, might be desirable to return only when needed because of its large size or because of the sensitivity of data that it contains. Authorization for FULL requires `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/) permission on the Task resource. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2955,7 +2969,7 @@ export namespace cloudtasks_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` * @param {().RunTaskRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3027,7 +3041,7 @@ export namespace cloudtasks_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` The queue must already exist. + * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` The queue must already exist. */ parent?: string; @@ -3044,7 +3058,7 @@ export namespace cloudtasks_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` */ name?: string; } @@ -3056,7 +3070,7 @@ export namespace cloudtasks_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` */ name?: string; /** @@ -3080,7 +3094,7 @@ export namespace cloudtasks_v2 { */ pageToken?: string; /** - * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` */ parent?: string; /** @@ -3096,7 +3110,7 @@ export namespace cloudtasks_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` */ name?: string; diff --git a/src/apis/cloudtasks/v2beta2.ts b/src/apis/cloudtasks/v2beta2.ts index 8d1a32789ad..27db82eb170 100644 --- a/src/apis/cloudtasks/v2beta2.ts +++ b/src/apis/cloudtasks/v2beta2.ts @@ -122,7 +122,7 @@ export namespace cloudtasks_v2beta2 { */ export interface Schema$AcknowledgeTaskRequest { /** - * Required. The task's current schedule time, available in the schedule_time returned by LeaseTasks response or RenewLease response. This restriction is to ensure that your worker currently holds the lease. + * Required. The task's current schedule time, available in the schedule_time returned by LeaseTasks response or RenewLease response. This restriction is to ensure that your worker currently holds the lease. */ scheduleTime?: string; } @@ -211,7 +211,7 @@ export namespace cloudtasks_v2beta2 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -228,7 +228,7 @@ export namespace cloudtasks_v2beta2 { */ responseView?: string; /** - * Required. The task's current schedule time, available in the schedule_time returned by LeaseTasks response or RenewLease response. This restriction is to ensure that your worker currently holds the lease. + * Required. The task's current schedule time, available in the schedule_time returned by LeaseTasks response or RenewLease response. This restriction is to ensure that your worker currently holds the lease. */ scheduleTime?: string; } @@ -241,7 +241,7 @@ export namespace cloudtasks_v2beta2 { */ responseView?: string; /** - * Required. The task to add. Task names have the following format: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`. The user can optionally specify a task name. If a name is not specified then the system will generate a random unique task id, which will be set in the task returned in the response. If schedule_time is not set or is in the past then Cloud Tasks will set it to the current time. Task De-duplication: Explicitly specifying a task ID enables task de-duplication. If a task's ID is identical to that of an existing task or a task that was deleted or completed recently then the call will fail with ALREADY_EXISTS. If the task's queue was created using Cloud Tasks, then another task with the same name can't be created for ~1hour after the original task was deleted or completed. If the task's queue was created using queue.yaml or queue.xml, then another task with the same name can't be created for ~9days after the original task was deleted or completed. Because there is an extra lookup cost to identify duplicate task names, these CreateTask calls have significantly increased latency. Using hashed strings for the task id or for the prefix of the task id is recommended. Choosing task ids that are sequential or have sequential prefixes, for example using a timestamp, causes an increase in latency and error rates in all task commands. The infrastructure relies on an approximately uniform distribution of task ids to store and serve tasks efficiently. + * Required. The task to add. Task names have the following format: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`. The user can optionally specify a task name. If a name is not specified then the system will generate a random unique task id, which will be set in the task returned in the response. If schedule_time is not set or is in the past then Cloud Tasks will set it to the current time. Task De-duplication: Explicitly specifying a task ID enables task de-duplication. If a task's ID is identical to that of an existing task or a task that was deleted or completed recently then the call will fail with ALREADY_EXISTS. If the task's queue was created using Cloud Tasks, then another task with the same name can't be created for ~1hour after the original task was deleted or completed. If the task's queue was created using queue.yaml or queue.xml, then another task with the same name can't be created for ~9days after the original task was deleted or completed. Because there is an extra lookup cost to identify duplicate task names, these CreateTask calls have significantly increased latency. Using hashed strings for the task id or for the prefix of the task id is recommended. Choosing task ids that are sequential or have sequential prefixes, for example using a timestamp, causes an increase in latency and error rates in all task commands. The infrastructure relies on an approximately uniform distribution of task ids to store and serve tasks efficiently. */ task?: Schema$Task; } @@ -273,7 +273,21 @@ export namespace cloudtasks_v2beta2 { /** * Request message for `GetIamPolicy` method. */ - export interface Schema$GetIamPolicyRequest {} + export interface Schema$GetIamPolicyRequest { + /** + * OPTIONAL: A `GetPolicyOptions` object for specifying options to `GetIamPolicy`. This field is only used by Cloud IAM. + */ + options?: Schema$GetPolicyOptions; + } + /** + * Encapsulates settings provided to GetIamPolicy. + */ + export interface Schema$GetPolicyOptions { + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + requestedPolicyVersion?: number; + } /** * Request message for leasing tasks using LeaseTasks. */ @@ -283,7 +297,7 @@ export namespace cloudtasks_v2beta2 { */ filter?: string; /** - * Required. The duration of the lease. Each task returned in the response will have its schedule_time set to the current time plus the `lease_duration`. The task is leased until its schedule_time; thus, the task will not be returned to another LeaseTasks call before its schedule_time. After the worker has successfully finished the work associated with the task, the worker must call via AcknowledgeTask before the schedule_time. Otherwise the task will be returned to a later LeaseTasks call so that another worker can retry it. The maximum lease duration is 1 week. `lease_duration` will be truncated to the nearest second. + * Required. The duration of the lease. Each task returned in the response will have its schedule_time set to the current time plus the `lease_duration`. The task is leased until its schedule_time; thus, the task will not be returned to another LeaseTasks call before its schedule_time. After the worker has successfully finished the work associated with the task, the worker must call via AcknowledgeTask before the schedule_time. Otherwise the task will be returned to a later LeaseTasks call so that another worker can retry it. The maximum lease duration is 1 week. `lease_duration` will be truncated to the nearest second. */ leaseDuration?: string; /** @@ -381,7 +395,7 @@ export namespace cloudtasks_v2beta2 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** @@ -465,7 +479,7 @@ export namespace cloudtasks_v2beta2 { */ export interface Schema$RenewLeaseRequest { /** - * Required. The desired new lease duration, starting from now. The maximum lease duration is 1 week. `lease_duration` will be truncated to the nearest second. + * Required. The desired new lease duration, starting from now. The maximum lease duration is 1 week. `lease_duration` will be truncated to the nearest second. */ leaseDuration?: string; /** @@ -473,7 +487,7 @@ export namespace cloudtasks_v2beta2 { */ responseView?: string; /** - * Required. The task's current schedule time, available in the schedule_time returned by LeaseTasks response or RenewLease response. This restriction is to ensure that your worker currently holds the lease. + * Required. The task's current schedule time, available in the schedule_time returned by LeaseTasks response or RenewLease response. This restriction is to ensure that your worker currently holds the lease. */ scheduleTime?: string; } @@ -1008,7 +1022,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The location name in which the queue will be created. For example: `projects/PROJECT_ID/locations/LOCATION_ID` The list of allowed locations can be obtained by calling Cloud Tasks' implementation of ListLocations. + * @param {string} params.parent Required. The location name in which the queue will be created. For example: `projects/PROJECT_ID/locations/LOCATION_ID` The list of allowed locations can be obtained by calling Cloud Tasks' implementation of ListLocations. * @param {().Queue} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1130,7 +1144,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1251,7 +1265,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the queue. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The resource name of the queue. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1516,7 +1530,7 @@ export namespace cloudtasks_v2beta2 { * @param {string=} params.filter `filter` can be used to specify a subset of queues. Any Queue field can be used as a filter and several operators as supported. For example: `<=, <, >=, >, !=, =, :`. The filter syntax is the same as described in [Stackdriver's Advanced Logs Filters](https://cloud.google.com/logging/docs/view/advanced_filters). Sample filter "app_engine_http_target: *". Note that using filters might cause fewer queues than the requested_page size to be returned. * @param {integer=} params.pageSize Requested page size. The maximum page size is 9800. If unspecified, the page size will be the maximum. Fewer queues than requested might be returned, even if more queues exist; use the next_page_token in the response to determine if more queues exist. * @param {string=} params.pageToken A token identifying the page of results to return. To request the first page results, page_token must be empty. To request the next page of results, page_token must be the value of next_page_token returned from the previous call to ListQueues method. It is an error to switch the value of the filter while iterating through pages. - * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID` + * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1783,7 +1797,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` * @param {().PauseQueueRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1912,7 +1926,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` * @param {().PurgeQueueRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2041,7 +2055,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` * @param {().ResumeQueueRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2381,7 +2395,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The location name in which the queue will be created. For example: `projects/PROJECT_ID/locations/LOCATION_ID` The list of allowed locations can be obtained by calling Cloud Tasks' implementation of ListLocations. + * Required. The location name in which the queue will be created. For example: `projects/PROJECT_ID/locations/LOCATION_ID` The list of allowed locations can be obtained by calling Cloud Tasks' implementation of ListLocations. */ parent?: string; @@ -2398,7 +2412,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` */ name?: string; } @@ -2410,7 +2424,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the queue. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * Required. The resource name of the queue. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` */ name?: string; } @@ -2451,7 +2465,7 @@ export namespace cloudtasks_v2beta2 { */ pageToken?: string; /** - * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID` + * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID` */ parent?: string; } @@ -2484,7 +2498,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` */ name?: string; @@ -2501,7 +2515,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` */ name?: string; @@ -2518,7 +2532,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` */ name?: string; @@ -2628,7 +2642,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` * @param {().AcknowledgeTaskRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2757,7 +2771,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` * @param {().CancelLeaseRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2887,7 +2901,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` The queue must already exist. + * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` The queue must already exist. * @param {().CreateTaskRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3009,7 +3023,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -3130,7 +3144,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` * @param {string=} params.responseView The response_view specifies which subset of the Task will be returned. By default response_view is BASIC; not all information is retrieved by default because some data, such as payloads, might be desirable to return only when needed because of its large size or because of the sensitivity of data that it contains. Authorization for FULL requires `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/) permission on the Task resource. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3200,7 +3214,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` * @param {().LeaseTasksRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3342,7 +3356,7 @@ export namespace cloudtasks_v2beta2 { * @param {object} params Parameters for request * @param {integer=} params.pageSize Maximum page size. Fewer tasks than requested might be returned, even if more tasks exist; use next_page_token in the response to determine if more tasks exist. The maximum page size is 1000. If unspecified, the page size will be the maximum. * @param {string=} params.pageToken A token identifying the page of results to return. To request the first page results, page_token must be empty. To request the next page of results, page_token must be the value of next_page_token returned from the previous call to ListTasks method. The page token is valid for only 2 hours. - * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` * @param {string=} params.responseView The response_view specifies which subset of the Task will be returned. By default response_view is BASIC; not all information is retrieved by default because some data, such as payloads, might be desirable to return only when needed because of its large size or because of the sensitivity of data that it contains. Authorization for FULL requires `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/) permission on the Task resource. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3473,7 +3487,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` * @param {().RenewLeaseRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3602,7 +3616,7 @@ export namespace cloudtasks_v2beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` * @param {().RunTaskRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3677,7 +3691,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` */ name?: string; @@ -3694,7 +3708,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` */ name?: string; @@ -3711,7 +3725,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` The queue must already exist. + * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` The queue must already exist. */ parent?: string; @@ -3728,7 +3742,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` */ name?: string; } @@ -3740,7 +3754,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` */ name?: string; /** @@ -3756,7 +3770,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` */ parent?: string; @@ -3781,7 +3795,7 @@ export namespace cloudtasks_v2beta2 { */ pageToken?: string; /** - * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` */ parent?: string; /** @@ -3797,7 +3811,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` */ name?: string; @@ -3814,7 +3828,7 @@ export namespace cloudtasks_v2beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` */ name?: string; diff --git a/src/apis/cloudtasks/v2beta3.ts b/src/apis/cloudtasks/v2beta3.ts index fdf0e3cd68e..7973f96c9cc 100644 --- a/src/apis/cloudtasks/v2beta3.ts +++ b/src/apis/cloudtasks/v2beta3.ts @@ -202,7 +202,7 @@ export namespace cloudtasks_v2beta3 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -219,7 +219,7 @@ export namespace cloudtasks_v2beta3 { */ responseView?: string; /** - * Required. The task to add. Task names have the following format: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`. The user can optionally specify a task name. If a name is not specified then the system will generate a random unique task id, which will be set in the task returned in the response. If schedule_time is not set or is in the past then Cloud Tasks will set it to the current time. Task De-duplication: Explicitly specifying a task ID enables task de-duplication. If a task's ID is identical to that of an existing task or a task that was deleted or executed recently then the call will fail with ALREADY_EXISTS. If the task's queue was created using Cloud Tasks, then another task with the same name can't be created for ~1hour after the original task was deleted or executed. If the task's queue was created using queue.yaml or queue.xml, then another task with the same name can't be created for ~9days after the original task was deleted or executed. Because there is an extra lookup cost to identify duplicate task names, these CreateTask calls have significantly increased latency. Using hashed strings for the task id or for the prefix of the task id is recommended. Choosing task ids that are sequential or have sequential prefixes, for example using a timestamp, causes an increase in latency and error rates in all task commands. The infrastructure relies on an approximately uniform distribution of task ids to store and serve tasks efficiently. + * Required. The task to add. Task names have the following format: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`. The user can optionally specify a task name. If a name is not specified then the system will generate a random unique task id, which will be set in the task returned in the response. If schedule_time is not set or is in the past then Cloud Tasks will set it to the current time. Task De-duplication: Explicitly specifying a task ID enables task de-duplication. If a task's ID is identical to that of an existing task or a task that was deleted or executed recently then the call will fail with ALREADY_EXISTS. If the task's queue was created using Cloud Tasks, then another task with the same name can't be created for ~1hour after the original task was deleted or executed. If the task's queue was created using queue.yaml or queue.xml, then another task with the same name can't be created for ~9days after the original task was deleted or executed. Because there is an extra lookup cost to identify duplicate task names, these CreateTask calls have significantly increased latency. Using hashed strings for the task id or for the prefix of the task id is recommended. Choosing task ids that are sequential or have sequential prefixes, for example using a timestamp, causes an increase in latency and error rates in all task commands. The infrastructure relies on an approximately uniform distribution of task ids to store and serve tasks efficiently. */ task?: Schema$Task; } @@ -251,7 +251,21 @@ export namespace cloudtasks_v2beta3 { /** * Request message for `GetIamPolicy` method. */ - export interface Schema$GetIamPolicyRequest {} + export interface Schema$GetIamPolicyRequest { + /** + * OPTIONAL: A `GetPolicyOptions` object for specifying options to `GetIamPolicy`. This field is only used by Cloud IAM. + */ + options?: Schema$GetPolicyOptions; + } + /** + * Encapsulates settings provided to GetIamPolicy. + */ + export interface Schema$GetPolicyOptions { + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + requestedPolicyVersion?: number; + } /** * HTTP request. The task will be pushed to the worker as an HTTP request. If the worker or the redirected worker acknowledges the task by returning a successful HTTP response code ([`200` - `299`]), the task will removed from the queue. If any other HTTP response code is returned or no response is received, the task will be retried according to the following: * User-specified throttling: retry configuration, rate limits, and the queue's state. * System throttling: To prevent the worker from overloading, Cloud Tasks may temporarily reduce the queue's effective rate. User-specified settings will not be changed. System throttling happens because: * Cloud Tasks backoffs on all errors. Normally the backoff specified in rate limits will be used. But if the worker returns `429` (Too Many Requests), `503` (Service Unavailable), or the rate of errors is high, Cloud Tasks will use a higher backoff rate. The retry specified in the `Retry-After` HTTP response header is considered. * To prevent traffic spikes and to smooth sudden large traffic spikes, dispatches ramp up slowly when the queue is newly created or idle and if large numbers of tasks suddenly become available to dispatch (due to spikes in create task rates, the queue being unpaused, or many tasks that are scheduled at the same time). */ @@ -384,7 +398,7 @@ export namespace cloudtasks_v2beta3 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** @@ -965,7 +979,7 @@ export namespace cloudtasks_v2beta3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The location name in which the queue will be created. For example: `projects/PROJECT_ID/locations/LOCATION_ID` The list of allowed locations can be obtained by calling Cloud Tasks' implementation of ListLocations. + * @param {string} params.parent Required. The location name in which the queue will be created. For example: `projects/PROJECT_ID/locations/LOCATION_ID` The list of allowed locations can be obtained by calling Cloud Tasks' implementation of ListLocations. * @param {().Queue} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1083,7 +1097,7 @@ export namespace cloudtasks_v2beta3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1200,7 +1214,7 @@ export namespace cloudtasks_v2beta3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the queue. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The resource name of the queue. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1457,7 +1471,7 @@ export namespace cloudtasks_v2beta3 { * @param {string=} params.filter `filter` can be used to specify a subset of queues. Any Queue field can be used as a filter and several operators as supported. For example: `<=, <, >=, >, !=, =, :`. The filter syntax is the same as described in [Stackdriver's Advanced Logs Filters](https://cloud.google.com/logging/docs/view/advanced_filters). Sample filter "state: PAUSED". Note that using filters might cause fewer queues than the requested page_size to be returned. * @param {integer=} params.pageSize Requested page size. The maximum page size is 9800. If unspecified, the page size will be the maximum. Fewer queues than requested might be returned, even if more queues exist; use the next_page_token in the response to determine if more queues exist. * @param {string=} params.pageToken A token identifying the page of results to return. To request the first page results, page_token must be empty. To request the next page of results, page_token must be the value of next_page_token returned from the previous call to ListQueues method. It is an error to switch the value of the filter while iterating through pages. - * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID` + * @param {string} params.parent Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1721,7 +1735,7 @@ export namespace cloudtasks_v2beta3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` * @param {().PauseQueueRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1846,7 +1860,7 @@ export namespace cloudtasks_v2beta3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` * @param {().PurgeQueueRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1971,7 +1985,7 @@ export namespace cloudtasks_v2beta3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.name Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` * @param {().ResumeQueueRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2303,7 +2317,7 @@ export namespace cloudtasks_v2beta3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The location name in which the queue will be created. For example: `projects/PROJECT_ID/locations/LOCATION_ID` The list of allowed locations can be obtained by calling Cloud Tasks' implementation of ListLocations. + * Required. The location name in which the queue will be created. For example: `projects/PROJECT_ID/locations/LOCATION_ID` The list of allowed locations can be obtained by calling Cloud Tasks' implementation of ListLocations. */ parent?: string; @@ -2320,7 +2334,7 @@ export namespace cloudtasks_v2beta3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` */ name?: string; } @@ -2332,7 +2346,7 @@ export namespace cloudtasks_v2beta3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the queue. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * Required. The resource name of the queue. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` */ name?: string; } @@ -2373,7 +2387,7 @@ export namespace cloudtasks_v2beta3 { */ pageToken?: string; /** - * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID` + * Required. The location name. For example: `projects/PROJECT_ID/locations/LOCATION_ID` */ parent?: string; } @@ -2406,7 +2420,7 @@ export namespace cloudtasks_v2beta3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` */ name?: string; @@ -2423,7 +2437,7 @@ export namespace cloudtasks_v2beta3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` */ name?: string; @@ -2440,7 +2454,7 @@ export namespace cloudtasks_v2beta3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` */ name?: string; @@ -2550,7 +2564,7 @@ export namespace cloudtasks_v2beta3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` The queue must already exist. + * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` The queue must already exist. * @param {().CreateTaskRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2668,7 +2682,7 @@ export namespace cloudtasks_v2beta3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2785,7 +2799,7 @@ export namespace cloudtasks_v2beta3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` * @param {string=} params.responseView The response_view specifies which subset of the Task will be returned. By default response_view is BASIC; not all information is retrieved by default because some data, such as payloads, might be desirable to return only when needed because of its large size or because of the sensitivity of data that it contains. Authorization for FULL requires `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/) permission on the Task resource. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2918,7 +2932,7 @@ export namespace cloudtasks_v2beta3 { * @param {object} params Parameters for request * @param {integer=} params.pageSize Maximum page size. Fewer tasks than requested might be returned, even if more tasks exist; use next_page_token in the response to determine if more tasks exist. The maximum page size is 1000. If unspecified, the page size will be the maximum. * @param {string=} params.pageToken A token identifying the page of results to return. To request the first page results, page_token must be empty. To request the next page of results, page_token must be the value of next_page_token returned from the previous call to ListTasks method. The page token is valid for only 2 hours. - * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * @param {string} params.parent Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` * @param {string=} params.responseView The response_view specifies which subset of the Task will be returned. By default response_view is BASIC; not all information is retrieved by default because some data, such as payloads, might be desirable to return only when needed because of its large size or because of the sensitivity of data that it contains. Authorization for FULL requires `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/) permission on the Task resource. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3045,7 +3059,7 @@ export namespace cloudtasks_v2beta3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * @param {string} params.name Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` * @param {().RunTaskRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3120,7 +3134,7 @@ export namespace cloudtasks_v2beta3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` The queue must already exist. + * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` The queue must already exist. */ parent?: string; @@ -3137,7 +3151,7 @@ export namespace cloudtasks_v2beta3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` */ name?: string; } @@ -3149,7 +3163,7 @@ export namespace cloudtasks_v2beta3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` */ name?: string; /** @@ -3173,7 +3187,7 @@ export namespace cloudtasks_v2beta3 { */ pageToken?: string; /** - * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` + * Required. The queue name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` */ parent?: string; /** @@ -3189,7 +3203,7 @@ export namespace cloudtasks_v2beta3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` + * Required. The task name. For example: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` */ name?: string; diff --git a/src/apis/cloudtrace/v2.ts b/src/apis/cloudtrace/v2.ts index dedaa067b6a..68454994544 100644 --- a/src/apis/cloudtrace/v2.ts +++ b/src/apis/cloudtrace/v2.ts @@ -281,6 +281,10 @@ export namespace cloudtrace_v2 { * The [SPAN_ID] portion of the span's resource name. */ spanId?: string; + /** + * Distinguishes between spans generated in a particular context. For example, two spans with the same name may be distinguished using `CLIENT` (caller) and `SERVER` (callee) to identify an RPC call. + */ + spanKind?: string; /** * Stack trace captured at the start of the span. */ diff --git a/src/apis/commentanalyzer/v1alpha1.ts b/src/apis/commentanalyzer/v1alpha1.ts index 0b85f7ec769..e693dc1eb60 100644 --- a/src/apis/commentanalyzer/v1alpha1.ts +++ b/src/apis/commentanalyzer/v1alpha1.ts @@ -118,7 +118,7 @@ export namespace commentanalyzer_v1alpha1 { } /** - * The comment analysis request message. + * The comment analysis request message. LINT.IfChange */ export interface Schema$AnalyzeCommentRequest { /** diff --git a/src/apis/composer/v1.ts b/src/apis/composer/v1.ts index ab27ee8d947..6c143be9e7c 100644 --- a/src/apis/composer/v1.ts +++ b/src/apis/composer/v1.ts @@ -252,7 +252,7 @@ export namespace composer_v1 { */ location?: string; /** - * Optional. The Compute Engine [machine type](/compute/docs/machine-types) used for cluster instances, specified as a [relative resource name](/apis/design/resource_names#relative_resource_name). For example: "projects/{projectId}/zones/{zoneId}/machineTypes/{machineTypeId}". The `machineType` must belong to the enclosing environment's project and location. If both this field and `nodeConfig.location` are specified, this `machineType` must belong to the `nodeConfig.location`; if both are unspecified, the service will pick a zone in the Compute Engine region corresponding to the Cloud Composer location, and propagate that choice to both fields. If exactly one of this field and `nodeConfig.location` is specified, the location information from the specified field will be propagated to the unspecified field. If this field is unspecified, the `machineTypeId` defaults to "n1-standard-1". + * Optional. The Compute Engine [machine type](/compute/docs/machine-types) used for cluster instances, specified as a [relative resource name](/apis/design/resource_names#relative_resource_name). For example: "projects/{projectId}/zones/{zoneId}/machineTypes/{machineTypeId}". The `machineType` must belong to the enclosing environment's project and location. If both this field and `nodeConfig.location` are specified, this `machineType` must belong to the `nodeConfig.location`; if both are unspecified, the service will pick a zone in the Compute Engine region corresponding to the Cloud Composer location, and propagate that choice to both fields. If exactly one of this field and `nodeConfig.location` is specified, the location information from the specified field will be propagated to the unspecified field. The `machineTypeId` must not be a [shared-core machine type](/compute/docs/machine-types#sharedcore). If this field is unspecified, the `machineTypeId` defaults to "n1-standard-1". */ machineType?: string; /** diff --git a/src/apis/composer/v1beta1.ts b/src/apis/composer/v1beta1.ts index 7e04c264665..aaac303df3d 100644 --- a/src/apis/composer/v1beta1.ts +++ b/src/apis/composer/v1beta1.ts @@ -285,7 +285,7 @@ export namespace composer_v1beta1 { */ location?: string; /** - * Optional. The Compute Engine [machine type](/compute/docs/machine-types) used for cluster instances, specified as a [relative resource name](/apis/design/resource_names#relative_resource_name). For example: "projects/{projectId}/zones/{zoneId}/machineTypes/{machineTypeId}". The `machineType` must belong to the enclosing environment's project and location. If both this field and `nodeConfig.location` are specified, this `machineType` must belong to the `nodeConfig.location`; if both are unspecified, the service will pick a zone in the Compute Engine region corresponding to the Cloud Composer location, and propagate that choice to both fields. If exactly one of this field and `nodeConfig.location` is specified, the location information from the specified field will be propagated to the unspecified field. If this field is unspecified, the `machineTypeId` defaults to "n1-standard-1". + * Optional. The Compute Engine [machine type](/compute/docs/machine-types) used for cluster instances, specified as a [relative resource name](/apis/design/resource_names#relative_resource_name). For example: "projects/{projectId}/zones/{zoneId}/machineTypes/{machineTypeId}". The `machineType` must belong to the enclosing environment's project and location. If both this field and `nodeConfig.location` are specified, this `machineType` must belong to the `nodeConfig.location`; if both are unspecified, the service will pick a zone in the Compute Engine region corresponding to the Cloud Composer location, and propagate that choice to both fields. If exactly one of this field and `nodeConfig.location` is specified, the location information from the specified field will be propagated to the unspecified field. The `machineTypeId` must not be a [shared-core machine type](/compute/docs/machine-types#sharedcore). If this field is unspecified, the `machineTypeId` defaults to "n1-standard-1". */ machineType?: string; /** diff --git a/src/apis/compute/alpha.ts b/src/apis/compute/alpha.ts deleted file mode 100644 index 14869d24e95..00000000000 --- a/src/apis/compute/alpha.ts +++ /dev/null @@ -1,79284 +0,0 @@ -/** - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { - OAuth2Client, - JWT, - Compute, - UserRefreshClient, -} from 'google-auth-library'; -import { - GoogleConfigurable, - createAPIRequest, - MethodOptions, - GlobalOptions, - BodyResponseCallback, - APIRequestContext, -} from 'googleapis-common'; -import {GaxiosPromise} from 'gaxios'; - -// tslint:disable: no-any -// tslint:disable: class-name -// tslint:disable: variable-name -// tslint:disable: jsdoc-format -// tslint:disable: no-namespace - -export namespace compute_alpha { - export interface Options extends GlobalOptions { - version: 'alpha'; - } - - interface StandardParameters { - /** - * Data format for the response. - */ - alt?: string; - /** - * Selector specifying which fields to include in a partial response. - */ - fields?: string; - /** - * 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. - */ - key?: string; - /** - * OAuth 2.0 token for the current user. - */ - oauth_token?: string; - /** - * Returns response with indentations and line breaks. - */ - prettyPrint?: boolean; - /** - * An opaque string that represents a user for quota purposes. Must not exceed 40 characters. - */ - quotaUser?: string; - /** - * Deprecated. Please use quotaUser instead. - */ - userIp?: string; - } - - /** - * Compute Engine API - * - * Creates and runs virtual machines on Google Cloud Platform. - * - * @example - * const {google} = require('googleapis'); - * const compute = google.compute('alpha'); - * - * @namespace compute - * @type {Function} - * @version alpha - * @variation alpha - * @param {object=} options Options for Compute - */ - export class Compute { - context: APIRequestContext; - acceleratorTypes: Resource$Acceleratortypes; - addresses: Resource$Addresses; - autoscalers: Resource$Autoscalers; - backendBuckets: Resource$Backendbuckets; - backendServices: Resource$Backendservices; - disks: Resource$Disks; - diskTypes: Resource$Disktypes; - externalVpnGateways: Resource$Externalvpngateways; - firewalls: Resource$Firewalls; - forwardingRules: Resource$Forwardingrules; - globalAddresses: Resource$Globaladdresses; - globalForwardingRules: Resource$Globalforwardingrules; - globalNetworkEndpointGroups: Resource$Globalnetworkendpointgroups; - globalOperations: Resource$Globaloperations; - globalOrganizationOperations: Resource$Globalorganizationoperations; - healthChecks: Resource$Healthchecks; - httpHealthChecks: Resource$Httphealthchecks; - httpsHealthChecks: Resource$Httpshealthchecks; - images: Resource$Images; - instanceGroupManagers: Resource$Instancegroupmanagers; - instanceGroups: Resource$Instancegroups; - instances: Resource$Instances; - instanceTemplates: Resource$Instancetemplates; - interconnectAttachments: Resource$Interconnectattachments; - interconnectLocations: Resource$Interconnectlocations; - interconnects: Resource$Interconnects; - licenseCodes: Resource$Licensecodes; - licenses: Resource$Licenses; - machineImages: Resource$Machineimages; - machineTypes: Resource$Machinetypes; - networkEndpointGroups: Resource$Networkendpointgroups; - networks: Resource$Networks; - nodeGroups: Resource$Nodegroups; - nodeTemplates: Resource$Nodetemplates; - nodeTypes: Resource$Nodetypes; - organizationSecurityPolicies: Resource$Organizationsecuritypolicies; - packetMirrorings: Resource$Packetmirrorings; - projects: Resource$Projects; - regionAutoscalers: Resource$Regionautoscalers; - regionBackendServices: Resource$Regionbackendservices; - regionCommitments: Resource$Regioncommitments; - regionDisks: Resource$Regiondisks; - regionDiskTypes: Resource$Regiondisktypes; - regionHealthChecks: Resource$Regionhealthchecks; - regionHealthCheckServices: Resource$Regionhealthcheckservices; - regionInstanceGroupManagers: Resource$Regioninstancegroupmanagers; - regionInstanceGroups: Resource$Regioninstancegroups; - regionNotificationEndpoints: Resource$Regionnotificationendpoints; - regionOperations: Resource$Regionoperations; - regions: Resource$Regions; - regionSslCertificates: Resource$Regionsslcertificates; - regionTargetHttpProxies: Resource$Regiontargethttpproxies; - regionTargetHttpsProxies: Resource$Regiontargethttpsproxies; - regionUrlMaps: Resource$Regionurlmaps; - reservations: Resource$Reservations; - resourcePolicies: Resource$Resourcepolicies; - routers: Resource$Routers; - routes: Resource$Routes; - securityPolicies: Resource$Securitypolicies; - snapshots: Resource$Snapshots; - sslCertificates: Resource$Sslcertificates; - sslPolicies: Resource$Sslpolicies; - subnetworks: Resource$Subnetworks; - targetHttpProxies: Resource$Targethttpproxies; - targetHttpsProxies: Resource$Targethttpsproxies; - targetInstances: Resource$Targetinstances; - targetPools: Resource$Targetpools; - targetSslProxies: Resource$Targetsslproxies; - targetTcpProxies: Resource$Targettcpproxies; - targetVpnGateways: Resource$Targetvpngateways; - urlMaps: Resource$Urlmaps; - vpnGateways: Resource$Vpngateways; - vpnTunnels: Resource$Vpntunnels; - zoneOperations: Resource$Zoneoperations; - zones: Resource$Zones; - - constructor(options: GlobalOptions, google?: GoogleConfigurable) { - this.context = { - _options: options || {}, - google, - }; - - this.acceleratorTypes = new Resource$Acceleratortypes(this.context); - this.addresses = new Resource$Addresses(this.context); - this.autoscalers = new Resource$Autoscalers(this.context); - this.backendBuckets = new Resource$Backendbuckets(this.context); - this.backendServices = new Resource$Backendservices(this.context); - this.disks = new Resource$Disks(this.context); - this.diskTypes = new Resource$Disktypes(this.context); - this.externalVpnGateways = new Resource$Externalvpngateways(this.context); - this.firewalls = new Resource$Firewalls(this.context); - this.forwardingRules = new Resource$Forwardingrules(this.context); - this.globalAddresses = new Resource$Globaladdresses(this.context); - this.globalForwardingRules = new Resource$Globalforwardingrules( - this.context - ); - this.globalNetworkEndpointGroups = new Resource$Globalnetworkendpointgroups( - this.context - ); - this.globalOperations = new Resource$Globaloperations(this.context); - this.globalOrganizationOperations = new Resource$Globalorganizationoperations( - this.context - ); - this.healthChecks = new Resource$Healthchecks(this.context); - this.httpHealthChecks = new Resource$Httphealthchecks(this.context); - this.httpsHealthChecks = new Resource$Httpshealthchecks(this.context); - this.images = new Resource$Images(this.context); - this.instanceGroupManagers = new Resource$Instancegroupmanagers( - this.context - ); - this.instanceGroups = new Resource$Instancegroups(this.context); - this.instances = new Resource$Instances(this.context); - this.instanceTemplates = new Resource$Instancetemplates(this.context); - this.interconnectAttachments = new Resource$Interconnectattachments( - this.context - ); - this.interconnectLocations = new Resource$Interconnectlocations( - this.context - ); - this.interconnects = new Resource$Interconnects(this.context); - this.licenseCodes = new Resource$Licensecodes(this.context); - this.licenses = new Resource$Licenses(this.context); - this.machineImages = new Resource$Machineimages(this.context); - this.machineTypes = new Resource$Machinetypes(this.context); - this.networkEndpointGroups = new Resource$Networkendpointgroups( - this.context - ); - this.networks = new Resource$Networks(this.context); - this.nodeGroups = new Resource$Nodegroups(this.context); - this.nodeTemplates = new Resource$Nodetemplates(this.context); - this.nodeTypes = new Resource$Nodetypes(this.context); - this.organizationSecurityPolicies = new Resource$Organizationsecuritypolicies( - this.context - ); - this.packetMirrorings = new Resource$Packetmirrorings(this.context); - this.projects = new Resource$Projects(this.context); - this.regionAutoscalers = new Resource$Regionautoscalers(this.context); - this.regionBackendServices = new Resource$Regionbackendservices( - this.context - ); - this.regionCommitments = new Resource$Regioncommitments(this.context); - this.regionDisks = new Resource$Regiondisks(this.context); - this.regionDiskTypes = new Resource$Regiondisktypes(this.context); - this.regionHealthChecks = new Resource$Regionhealthchecks(this.context); - this.regionHealthCheckServices = new Resource$Regionhealthcheckservices( - this.context - ); - this.regionInstanceGroupManagers = new Resource$Regioninstancegroupmanagers( - this.context - ); - this.regionInstanceGroups = new Resource$Regioninstancegroups( - this.context - ); - this.regionNotificationEndpoints = new Resource$Regionnotificationendpoints( - this.context - ); - this.regionOperations = new Resource$Regionoperations(this.context); - this.regions = new Resource$Regions(this.context); - this.regionSslCertificates = new Resource$Regionsslcertificates( - this.context - ); - this.regionTargetHttpProxies = new Resource$Regiontargethttpproxies( - this.context - ); - this.regionTargetHttpsProxies = new Resource$Regiontargethttpsproxies( - this.context - ); - this.regionUrlMaps = new Resource$Regionurlmaps(this.context); - this.reservations = new Resource$Reservations(this.context); - this.resourcePolicies = new Resource$Resourcepolicies(this.context); - this.routers = new Resource$Routers(this.context); - this.routes = new Resource$Routes(this.context); - this.securityPolicies = new Resource$Securitypolicies(this.context); - this.snapshots = new Resource$Snapshots(this.context); - this.sslCertificates = new Resource$Sslcertificates(this.context); - this.sslPolicies = new Resource$Sslpolicies(this.context); - this.subnetworks = new Resource$Subnetworks(this.context); - this.targetHttpProxies = new Resource$Targethttpproxies(this.context); - this.targetHttpsProxies = new Resource$Targethttpsproxies(this.context); - this.targetInstances = new Resource$Targetinstances(this.context); - this.targetPools = new Resource$Targetpools(this.context); - this.targetSslProxies = new Resource$Targetsslproxies(this.context); - this.targetTcpProxies = new Resource$Targettcpproxies(this.context); - this.targetVpnGateways = new Resource$Targetvpngateways(this.context); - this.urlMaps = new Resource$Urlmaps(this.context); - this.vpnGateways = new Resource$Vpngateways(this.context); - this.vpnTunnels = new Resource$Vpntunnels(this.context); - this.zoneOperations = new Resource$Zoneoperations(this.context); - this.zones = new Resource$Zones(this.context); - } - } - - /** - * A specification of the type and number of accelerator cards attached to the instance. - */ - export interface Schema$AcceleratorConfig { - /** - * The number of the guest accelerator cards exposed to this instance. - */ - acceleratorCount?: number; - /** - * Full or partial URL of the accelerator type resource to attach to this instance. For example: projects/my-project/zones/us-central1-c/acceleratorTypes/nvidia-tesla-p100 If you are creating an instance template, specify only the accelerator name. See GPUs on Compute Engine for a full list of accelerator types. - */ - acceleratorType?: string; - } - /** - * Represents an Accelerator Type resource. Google Cloud Platform provides graphics processing units (accelerators) that you can add to VM instances to improve or accelerate performance when working with intensive workloads. For more information, read GPUs on Compute Engine. (== resource_for beta.acceleratorTypes ==) (== resource_for v1.acceleratorTypes ==) - */ - export interface Schema$AcceleratorType { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * [Output Only] The deprecation status associated with this accelerator type. - */ - deprecated?: Schema$DeprecationStatus; - /** - * [Output Only] An optional textual description of the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] The type of the resource. Always compute#acceleratorType for accelerator types. - */ - kind?: string; - /** - * [Output Only] Maximum accelerator cards allowed per instance. - */ - maximumCardsPerInstance?: number; - /** - * [Output Only] Name of the resource. - */ - name?: string; - /** - * [Output Only] Server-defined fully-qualified URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource's resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] The name of the zone where the accelerator type resides, such as us-central1-a. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - zone?: string; - } - export interface Schema$AcceleratorTypeAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of AcceleratorTypesScopedList resources. - */ - items?: {[key: string]: Schema$AcceleratorTypesScopedList}; - /** - * [Output Only] Type of resource. Always compute#acceleratorTypeAggregatedList for aggregated lists of accelerator types. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of accelerator types. - */ - export interface Schema$AcceleratorTypeList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of AcceleratorType resources. - */ - items?: Schema$AcceleratorType[]; - /** - * [Output Only] Type of resource. Always compute#acceleratorTypeList for lists of accelerator types. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$AcceleratorTypesScopedList { - /** - * [Output Only] A list of accelerator types contained in this scope. - */ - acceleratorTypes?: Schema$AcceleratorType[]; - /** - * [Output Only] An informational warning that appears when the accelerator types list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * An access configuration attached to an instance's network interface. Only one access config per instance is supported. - */ - export interface Schema$AccessConfig { - /** - * [Output Only] Type of the resource. Always compute#accessConfig for access configs. - */ - kind?: string; - /** - * The name of this access configuration. The default and recommended name is External NAT, but you can use any arbitrary string, such as My external IP or Network Access. - */ - name?: string; - /** - * An external IP address associated with this instance. Specify an unused static external IP address available to the project or leave this field undefined to use an IP from a shared ephemeral IP address pool. If you specify a static external IP address, it must live in the same region as the zone of the instance. - */ - natIP?: string; - /** - * This signifies the networking tier used for configuring this access configuration and can only take the following values: PREMIUM, STANDARD. If an AccessConfig is specified without a valid external IP address, an ephemeral IP will be created with this networkTier. If an AccessConfig with a valid external IP address is specified, it must match that of the networkTier associated with the Address resource owning that IP. - */ - networkTier?: string; - /** - * [Output Only] The public DNS domain name for the instance. - */ - publicDnsName?: string; - /** - * The DNS domain name for the public PTR record. You can set this field only if the `setPublicPtr` field is enabled. - */ - publicPtrDomainName?: string; - /** - * Specifies whether a public DNS ?A? record should be created for the external IP address of this access configuration. - */ - setPublicDns?: boolean; - /** - * Specifies whether a public DNS 'PTR' record should be created to map the external IP address of the instance to a DNS domain name. - */ - setPublicPtr?: boolean; - /** - * The type of configuration. The default and only option is ONE_TO_ONE_NAT. - */ - type?: string; - } - /** - * Represents an IP Address resource. An address resource represents a regional internal IP address. Regional internal IP addresses are RFC 1918 addresses that come from either a primary or secondary IP range of a subnet in a VPC network. Regional external IP addresses can be assigned to GCP VM instances, Cloud VPN gateways, regional external forwarding rules for network load balancers (in either Standard or Premium Tier), and regional external forwarding rules for HTTP(S), SSL Proxy, and TCP Proxy load balancers in Standard Tier. For more information, read IP addresses. A globalAddresses resource represent a global external IP address. Global external IP addresses are IPv4 or IPv6 addresses. They can only be assigned to global forwarding rules for HTTP(S), SSL Proxy, or TCP Proxy load balancers in Premium Tier. For more information, read Global resources. (== resource_for beta.addresses ==) (== resource_for v1.addresses ==) (== resource_for beta.globalAddresses ==) (== resource_for v1.globalAddresses ==) - */ - export interface Schema$Address { - /** - * The static IP address represented by this resource. - */ - address?: string; - /** - * The type of address to reserve, either INTERNAL or EXTERNAL. If unspecified, defaults to EXTERNAL. - */ - addressType?: string; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this field when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * The IP version that will be used by this address. Valid options are IPV4 or IPV6. This can only be specified for a global address. - */ - ipVersion?: string; - /** - * [Output Only] Type of the resource. Always compute#address for addresses. - */ - kind?: string; - /** - * A fingerprint for the labels being applied to this Address, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an Address. - */ - labelFingerprint?: string; - /** - * Labels to apply to this Address resource. These can be later modified by the setLabels method. Each label key/value must comply with RFC1035. Label values may be empty. - */ - labels?: {[key: string]: string}; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?`. The first character must be a lowercase letter, and all following characters (except for the last character) must be a dash, lowercase letter, or digit. The last character must be a lowercase letter or digit. - */ - name?: string; - /** - * The URL of the network in which to reserve the address. This field can only be used with INTERNAL type with the VPC_PEERING purpose. - */ - network?: string; - /** - * This signifies the networking tier used for configuring this address and can only take the following values: PREMIUM or STANDARD. Global forwarding rules can only be Premium Tier. Regional forwarding rules can be either Premium or Standard Tier. Standard Tier addresses applied to regional forwarding rules can be used with any external load balancer. Regional forwarding rules in Premium Tier can only be used with a network load balancer. If this field is not specified, it is assumed to be PREMIUM. - */ - networkTier?: string; - /** - * The prefix length if the resource reprensents an IP range. - */ - prefixLength?: number; - /** - * The purpose of this resource, which can be one of the following values: - `GCE_ENDPOINT` for addresses that are used by VM instances, alias IP ranges, internal load balancers, and similar resources. - `DNS_RESOLVER` for a DNS resolver address in a subnetwork - `VPC_PEERING` for addresses that are reserved for VPC peer networks. - `NAT_AUTO` for addresses that are external IP addresses automatically reserved for Cloud NAT. - */ - purpose?: string; - /** - * [Output Only] The URL of the region where the regional address resides. This field is not applicable to global addresses. You must specify this field as part of the HTTP request URL. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] The status of the address, which can be one of RESERVING, RESERVED, or IN_USE. An address that is RESERVING is currently in the process of being reserved. A RESERVED address is currently reserved and available to use. An IN_USE address is currently being used by another resource and is not available. - */ - status?: string; - /** - * The URL of the subnetwork in which to reserve the address. If an IP address is specified, it must be within the subnetwork's IP range. This field can only be used with INTERNAL type with a GCE_ENDPOINT or DNS_RESOLVER purpose. - */ - subnetwork?: string; - /** - * [Output Only] The URLs of the resources that are using this address. - */ - users?: string[]; - } - export interface Schema$AddressAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of AddressesScopedList resources. - */ - items?: {[key: string]: Schema$AddressesScopedList}; - /** - * [Output Only] Type of resource. Always compute#addressAggregatedList for aggregated lists of addresses. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$AddressesScopedList { - /** - * [Output Only] A list of addresses contained in this scope. - */ - addresses?: Schema$Address[]; - /** - * [Output Only] Informational warning which replaces the list of addresses when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of addresses. - */ - export interface Schema$AddressList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Address resources. - */ - items?: Schema$Address[]; - /** - * [Output Only] Type of resource. Always compute#addressList for lists of addresses. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * An alias IP range attached to an instance's network interface. - */ - export interface Schema$AliasIpRange { - /** - * The IP alias ranges to allocate for this interface. This IP CIDR range must belong to the specified subnetwork and cannot contain IP addresses reserved by system or used by other network interfaces. This range may be a single IP address (such as 10.2.3.4), a netmask (such as /24) or a CIDR-formatted string (such as 10.1.2.0/24). - */ - ipCidrRange?: string; - /** - * The name of a subnetwork secondary IP range from which to allocate an IP alias range. If not specified, the primary range of the subnetwork is used. - */ - subnetworkRangeName?: string; - } - export interface Schema$AllocationSpecificSKUAllocationAllocatedInstancePropertiesReservedDisk { - /** - * Specifies the size of the disk in base-2 GB. - */ - diskSizeGb?: string; - /** - * Specifies the disk interface to use for attaching this disk, which is either SCSI or NVME. The default is SCSI. For performance characteristics of SCSI over NVMe, see Local SSD performance. - */ - interface?: string; - } - /** - * Properties of the SKU instances being reserved. - */ - export interface Schema$AllocationSpecificSKUAllocationReservedInstanceProperties { - /** - * Specifies accelerator type and count. - */ - guestAccelerators?: Schema$AcceleratorConfig[]; - /** - * Specifies amount of local ssd to reserve with each instance. The type of disk is local-ssd. - */ - localSsds?: Schema$AllocationSpecificSKUAllocationAllocatedInstancePropertiesReservedDisk[]; - /** - * Specifies type of machine (name only) which has fixed number of vCPUs and fixed amount of memory. This also includes specifying custom machine type following custom-NUMBER_OF_CPUS-AMOUNT_OF_MEMORY pattern. - */ - machineType?: string; - /** - * Minimum cpu platform the reservation. - */ - minCpuPlatform?: string; - } - /** - * This reservation type allows to pre allocate specific instance configuration. - */ - export interface Schema$AllocationSpecificSKUReservation { - /** - * Specifies number of resources that are allocated. - */ - count?: string; - /** - * The instance properties for this specific sku reservation. - */ - instanceProperties?: Schema$AllocationSpecificSKUAllocationReservedInstanceProperties; - /** - * [OutputOnly] Indicates how many resource are in use. - */ - inUseCount?: string; - } - /** - * An instance-attached disk resource. - */ - export interface Schema$AttachedDisk { - /** - * Specifies whether the disk will be auto-deleted when the instance is deleted (but not when the disk is detached from the instance). - */ - autoDelete?: boolean; - /** - * Indicates that this is a boot disk. The virtual machine will use the first partition of the disk for its root filesystem. - */ - boot?: boolean; - /** - * Specifies a unique device name of your choice that is reflected into the /dev/disk/by-id/google-* tree of a Linux operating system running within the instance. This name can be used to reference the device for mounting, resizing, and so on, from within the instance. If not specified, the server chooses a default device name to apply to this disk, in the form persistent-disk-x, where x is a number assigned by Google Compute Engine. This field is only applicable for persistent disks. - */ - deviceName?: string; - /** - * Encrypts or decrypts a disk using a customer-supplied encryption key. If you are creating a new disk, this field encrypts the new disk using an encryption key that you provide. If you are attaching an existing disk that is already encrypted, this field decrypts the disk using the customer-supplied encryption key. If you encrypt a disk using a customer-supplied key, you must provide the same key again when you attempt to use this resource at a later time. For example, you must provide the key when you create a snapshot or an image from the disk or when you attach the disk to a virtual machine instance. If you do not provide an encryption key, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the disk later. Instance templates do not store customer-supplied encryption keys, so you cannot use your own keys to encrypt disks in a managed instance group. - */ - diskEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * The size of the disk in base-2 GB. This supersedes disk_size_gb in InitializeParams. - */ - diskSizeGb?: string; - /** - * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options. - */ - guestOsFeatures?: Schema$GuestOsFeature[]; - /** - * [Output Only] A zero-based index to this disk, where 0 is reserved for the boot disk. If you have many disks attached to an instance, each disk would have a unique index number. - */ - index?: number; - /** - * [Input Only] Specifies the parameters for a new disk that will be created alongside the new instance. Use initialization parameters to create boot disks or local SSDs attached to the new instance. This property is mutually exclusive with the source property; you can only define one or the other, but not both. - */ - initializeParams?: Schema$AttachedDiskInitializeParams; - /** - * Specifies the disk interface to use for attaching this disk, which is either SCSI or NVME. The default is SCSI. Persistent disks must always use SCSI and the request will fail if you attempt to attach a persistent disk in any other format than SCSI. Local SSDs can use either NVME or SCSI. For performance characteristics of SCSI over NVMe, see Local SSD performance. TODO(b/131765817): Update documentation when NVME is supported. - */ - interface?: string; - /** - * [Output Only] Type of the resource. Always compute#attachedDisk for attached disks. - */ - kind?: string; - /** - * [Output Only] Any valid publicly visible licenses. - */ - licenses?: string[]; - /** - * The mode in which to attach this disk, either READ_WRITE or READ_ONLY. If not specified, the default is to attach the disk in READ_WRITE mode. - */ - mode?: string; - /** - * For LocalSSD disks on VM Instances in STOPPED or SUSPENDED state, this field is set to PRESERVED if the LocalSSD data has been saved to a persistent location by customer request. (see the discard_local_ssd option on Stop/Suspend). Read-only in the api. - */ - savedState?: string; - /** - * [Output Only] shielded vm initial state stored on disk - */ - shieldedInstanceInitialState?: Schema$InitialStateConfig; - /** - * Specifies a valid partial or full URL to an existing Persistent Disk resource. When creating a new instance, one of initializeParams.sourceImage or disks.source is required except for local SSD. If desired, you can also attach existing non-root persistent disks using this property. This field is only applicable for persistent disks. Note that for InstanceTemplate, specify the disk name, not the URL for the disk. - */ - source?: string; - /** - * Specifies the type of the disk, either SCRATCH or PERSISTENT. If not specified, the default is PERSISTENT. - */ - type?: string; - } - /** - * [Input Only] Specifies the parameters for a new disk that will be created alongside the new instance. Use initialization parameters to create boot disks or local SSDs attached to the new instance. This property is mutually exclusive with the source property; you can only define one or the other, but not both. - */ - export interface Schema$AttachedDiskInitializeParams { - /** - * An optional description. Provide this property when creating the disk. - */ - description?: string; - /** - * Specifies the disk name. If not specified, the default is to use the name of the instance. If the disk with the instance name exists already in the given zone/region, a new name will be automatically generated. - */ - diskName?: string; - /** - * Specifies the size of the disk in base-2 GB. - */ - diskSizeGb?: string; - /** - * Specifies the disk type to use to create the instance. If not specified, the default is pd-standard, specified using the full URL. For example: https://www.googleapis.com/compute/v1/projects/project/zones/zone/diskTypes/pd-standard Other values include pd-ssd and local-ssd. If you define this field, you can provide either the full or partial URL. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone/diskTypes/diskType - projects/project/zones/zone/diskTypes/diskType - zones/zone/diskTypes/diskType Note that for InstanceTemplate, this is the name of the disk type, not URL. - */ - diskType?: string; - /** - * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options. Guest OS features are applied by merging initializeParams.guestOsFeatures and disks.guestOsFeatures - */ - guestOsFeatures?: Schema$GuestOsFeature[]; - /** - * Labels to apply to this disk. These can be later modified by the disks.setLabels method. This field is only applicable for persistent disks. - */ - labels?: {[key: string]: string}; - /** - * URLs of the zones where the disk should be replicated to. Only applicable for regional resources. - */ - replicaZones?: string[]; - /** - * Resource policies applied to this disk for automatic snapshot creations. Specified using the full or partial URL. For instance template, specify only the resource policy name. - */ - resourcePolicies?: string[]; - /** - * The source image to create this disk. When creating a new instance, one of initializeParams.sourceImage or disks.source is required except for local SSD. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family If the source image is deleted later, this field will not be set. - */ - sourceImage?: string; - /** - * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key. Instance templates do not store customer-supplied encryption keys, so you cannot create disks for instances in a managed instance group if the source images are encrypted with your own keys. - */ - sourceImageEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * The source snapshot to create this disk. When creating a new instance, one of initializeParams.sourceSnapshot or disks.source is required except for local SSD. To create a disk with a snapshot that you created, specify the snapshot name in the following format: global/snapshots/my-backup If the source snapshot is deleted later, this field will not be set. - */ - sourceSnapshot?: string; - /** - * The customer-supplied encryption key of the source snapshot. - */ - sourceSnapshotEncryptionKey?: Schema$CustomerEncryptionKey; - } - /** - * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "fooservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:bar@gmail.com" ] } ] } ] } For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts foo@gmail.com from DATA_READ logging, and bar@gmail.com from DATA_WRITE logging. - */ - export interface Schema$AuditConfig { - /** - * The configuration for logging of each type of permission. - */ - auditLogConfigs?: Schema$AuditLogConfig[]; - exemptedMembers?: string[]; - /** - * Specifies a service that will be enabled for audit logging. For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. `allServices` is a special value that covers all services. - */ - service?: string; - } - /** - * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting foo@gmail.com from DATA_READ logging. - */ - export interface Schema$AuditLogConfig { - /** - * Specifies the identities that do not cause logging for this type of permission. Follows the same format of [Binding.members][]. - */ - exemptedMembers?: string[]; - /** - * The log type that this config enables. - */ - logType?: string; - } - /** - * The authentication settings for the backend service. - */ - export interface Schema$AuthenticationPolicy { - /** - * List of authentication methods that can be used for origin authentication. Similar to peers, these will be evaluated in order the first valid one will be used to set origin identity. If none of these methods pass, the request will be rejected with authentication failed error (401). Leave the list empty if origin authentication is not required. - */ - origins?: Schema$OriginAuthenticationMethod[]; - /** - * List of authentication methods that can be used for peer authentication. They will be evaluated in order the first valid one will be used to set peer identity. If none of these methods pass, the request will be rejected with authentication failed error (401). Leave the list empty if peer authentication is not required. - */ - peers?: Schema$PeerAuthenticationMethod[]; - /** - * Define whether peer or origin identity should be used for principal. Default value is USE_PEER. If peer (or origin) identity is not available, either because peer/origin authentication is not defined, or failed, principal will be left unset. In other words, binding rule does not affect the decision to accept or reject request. This field can be set to one of the following: USE_PEER: Principal will be set to the identity from peer authentication. USE_ORIGIN: Principal will be set to the identity from origin authentication. - */ - principalBinding?: string; - /** - * Configures the mechanism to obtain server-side security certificates and identity information. - */ - serverTlsContext?: Schema$TlsContext; - } - /** - * Authorization configuration provides service-level and method-level access control for a service. - */ - export interface Schema$AuthorizationConfig { - /** - * List of RbacPolicies. - */ - policies?: Schema$RbacPolicy[]; - } - /** - * Authorization-related information used by Cloud Audit Logging. - */ - export interface Schema$AuthorizationLoggingOptions { - /** - * The type of the permission that was checked. - */ - permissionType?: string; - } - /** - * Represents an Autoscaler resource. Use autoscalers to automatically add or delete instances from a managed instance group according to your defined autoscaling policy. For more information, read Autoscaling Groups of Instances. For zonal managed instance groups resource, use the autoscaler resource. For regional managed instance groups, use the regionAutoscalers resource. (== resource_for beta.autoscalers ==) (== resource_for v1.autoscalers ==) (== resource_for beta.regionAutoscalers ==) (== resource_for v1.regionAutoscalers ==) - */ - export interface Schema$Autoscaler { - /** - * The configuration parameters for the autoscaling algorithm. You can define one or more of the policies for an autoscaler: cpuUtilization, customMetricUtilizations, and loadBalancingUtilization. If none of these are specified, the default will be to autoscale based on cpuUtilization to 0.6 or 60%. - */ - autoscalingPolicy?: Schema$AutoscalingPolicy; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#autoscaler for autoscalers. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * [Output Only] Target recommended MIG size (number of instances) computed by autoscaler. Autoscaler calculates recommended MIG size even when autoscaling policy mode is different from ON. This field is empty when autoscaler is not connected to the existing managed instance group or autoscaler did not generate its prediction. - */ - recommendedSize?: number; - /** - * [Output Only] URL of the region where the instance group resides (for autoscalers living in regional scope). - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] The status of the autoscaler configuration. - */ - status?: string; - /** - * [Output Only] Human-readable details about the current state of the autoscaler. Read the documentation for Commonly returned status messages for examples of status messages you might encounter. - */ - statusDetails?: Schema$AutoscalerStatusDetails[]; - /** - * URL of the managed instance group that this autoscaler will scale. - */ - target?: string; - /** - * [Output Only] URL of the zone where the instance group resides (for autoscalers living in zonal scope). - */ - zone?: string; - } - export interface Schema$AutoscalerAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of AutoscalersScopedList resources. - */ - items?: {[key: string]: Schema$AutoscalersScopedList}; - /** - * [Output Only] Type of resource. Always compute#autoscalerAggregatedList for aggregated lists of autoscalers. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of Autoscaler resources. - */ - export interface Schema$AutoscalerList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Autoscaler resources. - */ - items?: Schema$Autoscaler[]; - /** - * [Output Only] Type of resource. Always compute#autoscalerList for lists of autoscalers. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$AutoscalersScopedList { - /** - * [Output Only] A list of autoscalers contained in this scope. - */ - autoscalers?: Schema$Autoscaler[]; - /** - * [Output Only] Informational warning which replaces the list of autoscalers when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$AutoscalerStatusDetails { - /** - * The status message. - */ - message?: string; - /** - * The type of error returned. - */ - type?: string; - } - /** - * Cloud Autoscaler policy. - */ - export interface Schema$AutoscalingPolicy { - /** - * The number of seconds that the autoscaler should wait before it starts collecting information from a new instance. This prevents the autoscaler from collecting information when the instance is initializing, during which the collected usage would not be reliable. The default time autoscaler waits is 60 seconds. Virtual machine initialization times might vary because of numerous factors. We recommend that you test how long an instance may take to initialize. To do this, create an instance and time the startup process. - */ - coolDownPeriodSec?: number; - /** - * Defines the CPU utilization policy that allows the autoscaler to scale based on the average CPU utilization of a managed instance group. - */ - cpuUtilization?: Schema$AutoscalingPolicyCpuUtilization; - /** - * Configuration parameters of autoscaling based on a custom metric. - */ - customMetricUtilizations?: Schema$AutoscalingPolicyCustomMetricUtilization[]; - /** - * Configuration parameters of autoscaling based on load balancer. - */ - loadBalancingUtilization?: Schema$AutoscalingPolicyLoadBalancingUtilization; - /** - * The maximum number of instances that the autoscaler can scale up to. This is required when creating or updating an autoscaler. The maximum number of replicas should not be lower than minimal number of replicas. - */ - maxNumReplicas?: number; - /** - * The minimum number of replicas that the autoscaler can scale down to. This cannot be less than 0. If not provided, autoscaler will choose a default value depending on maximum number of instances allowed. - */ - minNumReplicas?: number; - /** - * Defines operating mode for this policy. - */ - mode?: string; - /** - * Configuration parameters of autoscaling based on queuing system. - */ - queueBasedScaling?: Schema$AutoscalingPolicyQueueBasedScaling; - scaleDownControl?: Schema$AutoscalingPolicyScaleDownControl; - } - /** - * CPU utilization policy. - */ - export interface Schema$AutoscalingPolicyCpuUtilization { - /** - * The target CPU utilization that the autoscaler should maintain. Must be a float value in the range (0, 1]. If not specified, the default is 0.6. If the CPU level is below the target utilization, the autoscaler scales down the number of instances until it reaches the minimum number of instances you specified or until the average CPU of your instances reaches the target utilization. If the average CPU is above the target utilization, the autoscaler scales up until it reaches the maximum number of instances you specified or until the average utilization reaches the target utilization. - */ - utilizationTarget?: number; - } - /** - * Custom utilization metric policy. - */ - export interface Schema$AutoscalingPolicyCustomMetricUtilization { - /** - * A filter string, compatible with a Stackdriver Monitoring filter string for TimeSeries.list API call. This filter is used to select a specific TimeSeries for the purpose of autoscaling and to determine whether the metric is exporting per-instance or per-group data. For the filter to be valid for autoscaling purposes, the following rules apply: - You can only use the AND operator for joining selectors. - You can only use direct equality comparison operator (=) without any functions for each selector. - You can specify the metric in both the filter string and in the metric field. However, if specified in both places, the metric must be identical. - The monitored resource type determines what kind of values are expected for the metric. If it is a gce_instance, the autoscaler expects the metric to include a separate TimeSeries for each instance in a group. In such a case, you cannot filter on resource labels. If the resource type is any other value, the autoscaler expects this metric to contain values that apply to the entire autoscaled instance group and resource label filtering can be performed to point autoscaler at the correct TimeSeries to scale upon. This is called a per-group metric for the purpose of autoscaling. If not specified, the type defaults to gce_instance. You should provide a filter that is selective enough to pick just one TimeSeries for the autoscaled group or for each of the instances (if you are using gce_instance resource type). If multiple TimeSeries are returned upon the query execution, the autoscaler will sum their respective values to obtain its scaling value. - */ - filter?: string; - /** - * The identifier (type) of the Stackdriver Monitoring metric. The metric cannot have negative values. The metric must have a value type of INT64 or DOUBLE. - */ - metric?: string; - /** - * If scaling is based on a per-group metric value that represents the total amount of work to be done or resource usage, set this value to an amount assigned for a single instance of the scaled group. Autoscaler will keep the number of instances proportional to the value of this metric, the metric itself should not change value due to group resizing. A good metric to use with the target is for example pubsub.googleapis.com/subscription/num_undelivered_messages or a custom metric exporting the total number of requests coming to your instances. A bad example would be a metric exporting an average or median latency, since this value can't include a chunk assignable to a single instance, it could be better used with utilization_target instead. - */ - singleInstanceAssignment?: number; - /** - * The target value of the metric that autoscaler should maintain. This must be a positive value. A utilization metric scales number of virtual machines handling requests to increase or decrease proportionally to the metric. For example, a good metric to use as a utilization_target is compute.googleapis.com/instance/network/received_bytes_count. The autoscaler will work to keep this value constant for each of the instances. - */ - utilizationTarget?: number; - /** - * Defines how target utilization value is expressed for a Stackdriver Monitoring metric. Either GAUGE, DELTA_PER_SECOND, or DELTA_PER_MINUTE. - */ - utilizationTargetType?: string; - } - /** - * Configuration parameters of autoscaling based on load balancing. - */ - export interface Schema$AutoscalingPolicyLoadBalancingUtilization { - /** - * Fraction of backend capacity utilization (set in HTTP(S) load balancing configuration) that autoscaler should maintain. Must be a positive float value. If not defined, the default is 0.8. - */ - utilizationTarget?: number; - } - /** - * Configuration parameters of autoscaling based on queuing system. - */ - export interface Schema$AutoscalingPolicyQueueBasedScaling { - /** - * Scaling based on the average number of tasks in the queue per each active instance. The autoscaler keeps the average number of tasks per instance below this number, based on data collected in the last couple of minutes. The autoscaler will also take into account incoming tasks when calculating when to scale. - */ - acceptableBacklogPerInstance?: number; - /** - * Configuration for Cloud Pub/Sub subscription queue. - */ - cloudPubSub?: Schema$AutoscalingPolicyQueueBasedScalingCloudPubSub; - /** - * The scaling algorithm will also calculate throughput estimates on its own; if you explicitly provide this value, the autoscaler will take into account your value as well as automatic estimates when deciding how to scale. - */ - singleWorkerThroughputPerSec?: number; - } - /** - * Configuration parameters for scaling based on Cloud Pub/Sub subscription queue. - */ - export interface Schema$AutoscalingPolicyQueueBasedScalingCloudPubSub { - /** - * Cloud Pub/Sub subscription used for scaling. Provide the partial URL (starting with projects/) or just the subscription name. The subscription must be assigned to the topic specified in topicName and must be in a pull configuration. The subscription must belong to the same project as the Autoscaler. - */ - subscription?: string; - /** - * Cloud Pub/Sub topic used for scaling. Provide the partial URL or partial URL (starting with projects/) or just the topic name. The topic must belong to the same project as the Autoscaler resource. - */ - topic?: string; - } - /** - * Configuration that allows for slower scale down so that even if Autoscaler recommends an abrupt scale down of a MIG, it will be throttled as specified by the parameters below. - */ - export interface Schema$AutoscalingPolicyScaleDownControl { - /** - * Maximum allowed number (or %) of VMs that can be deducted from the peak recommendation during the window autoscaler looks at when computing recommendations. Possibly all these VMs can be deleted at once so user service needs to be prepared to lose that many VMs in one step. - */ - maxScaledDownReplicas?: Schema$FixedOrPercent; - /** - * How long back autoscaling should look when computing recommendations to include directives regarding slower scale down, as described above. - */ - timeWindowSec?: number; - } - /** - * Message containing information of one individual backend. - */ - export interface Schema$Backend { - /** - * Specifies the balancing mode for the backend. When choosing a balancing mode, you need to consider the loadBalancingScheme, and protocol for the backend service, as well as the type of backend (instance group or NEG). - If the load balancing mode is CONNECTION, then the load is spread based on how many concurrent connections the backend can handle. The CONNECTION balancing mode is only available if the protocol for the backend service is SSL, TCP, or UDP. If the loadBalancingScheme for the backend service is EXTERNAL (SSL Proxy and TCP Proxy load balancers), you must also specify exactly one of the following parameters: maxConnections, maxConnectionsPerInstance, or maxConnectionsPerEndpoint. If the loadBalancingScheme for the backend service is INTERNAL (internal TCP/UDP load balancers), you cannot specify any additional parameters. - If the load balancing mode is RATE, then the load is spread based on the rate of HTTP requests per second (RPS). The RATE balancing mode is only available if the protocol for the backend service is HTTP or HTTPS. You must specify exactly one of the following parameters: maxRate, maxRatePerInstance, or maxRatePerEndpoint. - If the load balancing mode is UTILIZATION, then the load is spread based on the CPU utilization of instances in an instance group. The UTILIZATION balancing mode is only available if the loadBalancingScheme of the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED and the backend is made up of instance groups. There are no restrictions on the backend service protocol. - */ - balancingMode?: string; - /** - * A multiplier applied to the group's maximum servicing capacity (based on UTILIZATION, RATE or CONNECTION). Default value is 1, which means the group will serve up to 100% of its configured capacity (depending on balancingMode). A setting of 0 means the group is completely drained, offering 0% of its available Capacity. Valid range is [0.0,1.0]. This cannot be used for internal load balancing. - */ - capacityScaler?: number; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * This field designates whether this is a failover backend. More than one failover backend can be configured for a given BackendService. - */ - failover?: boolean; - /** - * The fully-qualified URL of an instance group or network endpoint group (NEG) resource. The type of backend that a backend service supports depends on the backend service's loadBalancingScheme. - When the loadBalancingScheme for the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED, the backend can be either an instance group or a NEG. The backends on the backend service must be either all instance groups or all NEGs. You cannot mix instance group and NEG backends on the same backend service. - When the loadBalancingScheme for the backend service is INTERNAL, the backend must be an instance group in the same region as the backend service. NEGs are not supported. You must use the fully-qualified URL (starting with https://www.googleapis.com/) to specify the instance group or NEG. Partial URLs are not supported. - */ - group?: string; - /** - * Defines a maximum target for simultaneous connections for the entire backend (instance group or NEG). If the backend's balancingMode is UTILIZATION, this is an optional parameter. If the backend's balancingMode is CONNECTION, and backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnectionsPerInstance, or maxConnectionsPerEndpoint. Not available if the backend's balancingMode is RATE. If the loadBalancingScheme is INTERNAL, then maxConnections is not supported, even though the backend requires a balancing mode of CONNECTION. - */ - maxConnections?: number; - /** - * Defines a maximum target for simultaneous connections for an endpoint of a NEG. This is multiplied by the number of endpoints in the NEG to implicitly calculate a maximum number of target maximum simultaneous connections for the NEG. If the backend's balancingMode is CONNECTION, and the backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnections, or maxConnectionsPerInstance. Not available if the backend's balancingMode is RATE. Internal TCP/UDP load balancing does not support setting maxConnectionsPerEndpoint even though its backends require a balancing mode of CONNECTION. - */ - maxConnectionsPerEndpoint?: number; - /** - * Defines a maximum target for simultaneous connections for a single VM in a backend instance group. This is multiplied by the number of instances in the instance group to implicitly calculate a target maximum number of simultaneous connections for the whole instance group. If the backend's balancingMode is UTILIZATION, this is an optional parameter. If the backend's balancingMode is CONNECTION, and backend is attached to a backend service whose loadBalancingScheme is EXTERNAL, you must specify either this parameter, maxConnections, or maxConnectionsPerEndpoint. Not available if the backend's balancingMode is RATE. Internal TCP/UDP load balancing does not support setting maxConnectionsPerInstance even though its backends require a balancing mode of CONNECTION. - */ - maxConnectionsPerInstance?: number; - /** - * The max requests per second (RPS) of the group. Can be used with either RATE or UTILIZATION balancing modes, but required if RATE mode. For RATE mode, either maxRate or maxRatePerInstance must be set. This cannot be used for internal load balancing. - */ - maxRate?: number; - /** - * Defines a maximum target for requests per second (RPS) for an endpoint of a NEG. This is multiplied by the number of endpoints in the NEG to implicitly calculate a target maximum rate for the NEG. If the backend's balancingMode is RATE, you must specify either this parameter, maxRate, or maxRatePerInstance. Not available if the backend's balancingMode is CONNECTION. - */ - maxRatePerEndpoint?: number; - /** - * Defines a maximum target for requests per second (RPS) for a single VM in a backend instance group. This is multiplied by the number of instances in the instance group to implicitly calculate a target maximum rate for the whole instance group. If the backend's balancingMode is UTILIZATION, this is an optional parameter. If the backend's balancingMode is RATE, you must specify either this parameter, maxRate, or maxRatePerEndpoint. Not available if the backend's balancingMode is CONNECTION. - */ - maxRatePerInstance?: number; - /** - * Defines the maximum average CPU utilization of a backend VM in an instance group. The valid range is [0.0, 1.0]. This is an optional parameter if the backend's balancingMode is UTILIZATION. This parameter can be used in conjunction with maxRate, maxRatePerInstance, maxConnections, or maxConnectionsPerInstance. - */ - maxUtilization?: number; - } - /** - * Represents a Cloud Storage Bucket resource. This Cloud Storage bucket resource is referenced by a URL map of a load balancer. For more information, read Backend Buckets. - */ - export interface Schema$BackendBucket { - /** - * Cloud Storage bucket name. - */ - bucketName?: string; - /** - * Cloud CDN configuration for this BackendBucket. - */ - cdnPolicy?: Schema$BackendBucketCdnPolicy; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional textual description of the resource; provided by the client when the resource is created. - */ - description?: string; - /** - * If true, enable Cloud CDN for this BackendBucket. - */ - enableCdn?: boolean; - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * Type of the resource. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - } - /** - * Message containing Cloud CDN configuration for a backend bucket. - */ - export interface Schema$BackendBucketCdnPolicy { - /** - * Maximum number of seconds the response to a signed URL request will be considered fresh. After this time period, the response will be revalidated before being served. Defaults to 1hr (3600s). When serving responses to signed URL requests, Cloud CDN will internally behave as though all responses from this backend had a "Cache-Control: public, max-age=[TTL]" header, regardless of any existing Cache-Control header. The actual headers served in responses will not be altered. - */ - signedUrlCacheMaxAgeSec?: string; - /** - * [Output Only] Names of the keys for signing request URLs. - */ - signedUrlKeyNames?: string[]; - } - /** - * Contains a list of BackendBucket resources. - */ - export interface Schema$BackendBucketList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of BackendBucket resources. - */ - items?: Schema$BackendBucket[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents a Backend Service resource. Backend services must have an associated health check. Backend services also store information about session affinity. For more information, read Backend Services. A backendServices resource represents a global backend service. Global backend services are used for HTTP(S), SSL Proxy, TCP Proxy load balancing and Traffic Director. A regionBackendServices resource represents a regional backend service. Regional backend services are used for internal TCP/UDP load balancing. For more information, read Internal TCP/UDP Load balancing. (== resource_for v1.backendService ==) (== resource_for beta.backendService ==) - */ - export interface Schema$BackendService { - /** - * If set to 0, the cookie is non-persistent and lasts only until the end of the browser session (or equivalent). The maximum allowed value is one day (86,400). - */ - affinityCookieTtlSec?: number; - /** - * The list of backends that serve this BackendService. - */ - backends?: Schema$Backend[]; - /** - * Cloud CDN configuration for this BackendService. - */ - cdnPolicy?: Schema$BackendServiceCdnPolicy; - /** - * Settings controlling the volume of connections to a backend service. This field is applicable to either: - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED. - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED. - */ - circuitBreakers?: Schema$CircuitBreakers; - connectionDraining?: Schema$ConnectionDraining; - /** - * Consistent Hash-based load balancing can be used to provide soft session affinity based on HTTP headers, cookies or other properties. This load balancing policy is applicable only for HTTP connections. The affinity to a particular destination host will be lost when one or more hosts are added/removed from the destination service. This field specifies parameters that control consistent hashing. This field is only applicable when localityLbPolicy is set to MAGLEV or RING_HASH. This field is applicable to either: - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED. - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED. - */ - consistentHash?: Schema$ConsistentHashLoadBalancerSettings; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * Headers that the HTTP/S load balancer should add to proxied requests. - */ - customRequestHeaders?: string[]; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * If true, enables Cloud CDN for the backend service. Only applicable if the loadBalancingScheme is EXTERNAL and the protocol is HTTP or HTTPS. - */ - enableCDN?: boolean; - /** - * Applicable only to Failover for Internal TCP/UDP Load Balancing. Requires at least one backend instance group to be defined as a backup (failover) backend. - */ - failoverPolicy?: Schema$BackendServiceFailoverPolicy; - /** - * Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a BackendService. An up-to-date fingerprint must be provided in order to update the BackendService, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a BackendService. - */ - fingerprint?: string; - /** - * The list of URLs to the HttpHealthCheck or HttpsHealthCheck resource for health checking this BackendService. Currently at most one health check can be specified, and a health check is required for Compute Engine backend services. A health check must not be specified for App Engine backend and Cloud Function backend. For internal load balancing, a URL to a HealthCheck resource must be specified instead. - */ - healthChecks?: string[]; - iap?: Schema$BackendServiceIAP; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of resource. Always compute#backendService for backend services. - */ - kind?: string; - /** - * Indicates whether the backend service will be used with internal or external load balancing. A backend service created for one type of load balancing cannot be used with the other. Possible values are INTERNAL and EXTERNAL. - */ - loadBalancingScheme?: string; - /** - * The load balancing algorithm used within the scope of the locality. The possible values are: - ROUND_ROBIN: This is a simple policy in which each healthy backend is selected in round robin order. This is the default. - LEAST_REQUEST: An O(1) algorithm which selects two random healthy hosts and picks the host which has fewer active requests. - RING_HASH: The ring/modulo hash load balancer implements consistent hashing to backends. The algorithm has the property that the addition/removal of a host from a set of N hosts only affects 1/N of the requests. - RANDOM: The load balancer selects a random healthy host. - ORIGINAL_DESTINATION: Backend host is selected based on the client connection metadata, i.e., connections are opened to the same address as the destination address of the incoming connection before the connection was redirected to the load balancer. - MAGLEV: used as a drop in replacement for the ring hash load balancer. Maglev is not as stable as ring hash but has faster table lookup build times and host selection times. For more information about Maglev, refer to https://ai.google/research/pubs/pub44824 This field is applicable to either: - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED. - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED. - */ - localityLbPolicy?: string; - /** - * This field denotes the logging options for the load balancer traffic served by this backend service. If logging is enabled, logs will be exported to Stackdriver. - */ - logConfig?: Schema$BackendServiceLogConfig; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * The URL of the network to which this backend service belongs. This field can only be spcified when the load balancing scheme is set to INTERNAL. - */ - network?: string; - /** - * Settings controlling eviction of unhealthy hosts from the load balancing pool. This field is applicable to either: - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED. - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED. - */ - outlierDetection?: Schema$OutlierDetection; - /** - * Deprecated in favor of portName. The TCP port to connect on the backend. The default value is 80. This cannot be used if the loadBalancingScheme is INTERNAL (Internal TCP/UDP Load Balancing). - */ - port?: number; - /** - * A named port on a backend instance group representing the port for communication to the backend VMs in that group. Required when the loadBalancingScheme is EXTERNAL and the backends are instance groups. The named port must be defined on each backend instance group. This parameter has no meaning if the backends are NEGs. Must be omitted when the loadBalancingScheme is INTERNAL (Internal TCP/UDP Load Blaancing). - */ - portName?: string; - /** - * The protocol this BackendService uses to communicate with backends. Possible values are HTTP, HTTPS, TCP, SSL, or UDP, depending on the chosen load balancer or Traffic Director configuration. Refer to the documentation for the load balancer or for Traffic director for more information. - */ - protocol?: string; - /** - * [Output Only] URL of the region where the regional backend service resides. This field is not applicable to global backend services. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - region?: string; - /** - * [Output Only] The resource URL for the security policy associated with this backend service. - */ - securityPolicy?: string; - /** - * This field specifies the security policy that applies to this backend service. This field is applicable to either: - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED. - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED. - */ - securitySettings?: Schema$SecuritySettings; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * Type of session affinity to use. The default is NONE. Session affinity is not applicable if the --protocol is UDP. When the loadBalancingScheme is EXTERNAL, possible values are NONE, CLIENT_IP, or GENERATED_COOKIE. GENERATED_COOKIE is only available if the protocol is HTTP or HTTPS. When the loadBalancingScheme is INTERNAL, possible values are NONE, CLIENT_IP, CLIENT_IP_PROTO, or CLIENT_IP_PORT_PROTO. When the loadBalancingScheme is INTERNAL_SELF_MANAGED, possible values are NONE, CLIENT_IP, GENERATED_COOKIE, HEADER_FIELD, or HTTP_COOKIE. - */ - sessionAffinity?: string; - /** - * The backend service timeout has a different meaning depending on the type of load balancer. For more information read, Backend service settings The default is 30 seconds. - */ - timeoutSec?: number; - } - /** - * Contains a list of BackendServicesScopedList. - */ - export interface Schema$BackendServiceAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of BackendServicesScopedList resources. - */ - items?: {[key: string]: Schema$BackendServicesScopedList}; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Message containing Cloud CDN configuration for a backend service. - */ - export interface Schema$BackendServiceCdnPolicy { - /** - * The CacheKeyPolicy for this CdnPolicy. - */ - cacheKeyPolicy?: Schema$CacheKeyPolicy; - /** - * Maximum number of seconds the response to a signed URL request will be considered fresh. After this time period, the response will be revalidated before being served. Defaults to 1hr (3600s). When serving responses to signed URL requests, Cloud CDN will internally behave as though all responses from this backend had a "Cache-Control: public, max-age=[TTL]" header, regardless of any existing Cache-Control header. The actual headers served in responses will not be altered. - */ - signedUrlCacheMaxAgeSec?: string; - /** - * [Output Only] Names of the keys for signing request URLs. - */ - signedUrlKeyNames?: string[]; - } - export interface Schema$BackendServiceFailoverPolicy { - /** - * This can be set to true only if the protocol is TCP. The default is false. - */ - disableConnectionDrainOnFailover?: boolean; - /** - * Applicable only to Failover for Internal TCP/UDP Load Balancing. If set to true, connections to the load balancer are dropped when all primary and all backup backend VMs are unhealthy. If set to false, connections are distributed among all primary VMs when all primary and all backup backend VMs are unhealthy. The default is false. - */ - dropTrafficIfUnhealthy?: boolean; - /** - * Applicable only to Failover for Internal TCP/UDP Load Balancing. The value of the field must be in the range [0, 1]. If the value is 0, the load balancer performs a failover when the number of healthy primary VMs equals zero. For all other values, the load balancer performs a failover when the total number of healthy primary VMs is less than this ratio. - */ - failoverRatio?: number; - } - export interface Schema$BackendServiceGroupHealth { - /** - * Metadata defined as annotations on the network endpoint group. - */ - annotations?: {[key: string]: string}; - /** - * Health state of the backend instances or endpoints in requested instance or network endpoint group, determined based on configured health checks. - */ - healthStatus?: Schema$HealthStatus[]; - /** - * [Output Only] Type of resource. Always compute#backendServiceGroupHealth for the health of backend services. - */ - kind?: string; - } - /** - * Identity-Aware Proxy - */ - export interface Schema$BackendServiceIAP { - enabled?: boolean; - oauth2ClientId?: string; - /** - * [Input Only] OAuth client info required to generate client id to be used for IAP. - */ - oauth2ClientInfo?: Schema$BackendServiceIAPOAuth2ClientInfo; - oauth2ClientSecret?: string; - /** - * [Output Only] SHA256 hash value for the field oauth2_client_secret above. - */ - oauth2ClientSecretSha256?: string; - } - export interface Schema$BackendServiceIAPOAuth2ClientInfo { - /** - * Application name to be used in OAuth consent screen. - */ - applicationName?: string; - /** - * Name of the client to be generated. Optional - If not provided, the name will be autogenerated by the backend. - */ - clientName?: string; - /** - * Developer's information to be used in OAuth consent screen. - */ - developerEmailAddress?: string; - } - /** - * Contains a list of BackendService resources. - */ - export interface Schema$BackendServiceList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of BackendService resources. - */ - items?: Schema$BackendService[]; - /** - * [Output Only] Type of resource. Always compute#backendServiceList for lists of backend services. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * The available logging options for the load balancer traffic served by this backend service. - */ - export interface Schema$BackendServiceLogConfig { - /** - * This field denotes whether to enable logging for the load balancer traffic served by this backend service. - */ - enable?: boolean; - /** - * This field can only be specified if logging is enabled for this backend service. The value of the field must be in [0, 1]. This configures the sampling rate of requests to the load balancer where 1.0 means all logged requests are reported and 0.0 means no logged requests are reported. The default value is 1.0. - */ - sampleRate?: number; - } - export interface Schema$BackendServiceReference { - backendService?: string; - } - export interface Schema$BackendServicesScopedList { - /** - * A list of BackendServices contained in this scope. - */ - backendServices?: Schema$BackendService[]; - /** - * Informational warning which replaces the list of backend services when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$BfdPacket { - /** - * The Authentication Present bit of the BFD packet. This is specified in section 4.1 of RFC5880 - */ - authenticationPresent?: boolean; - /** - * The Control Plane Independent bit of the BFD packet. This is specified in section 4.1 of RFC5880 - */ - controlPlaneIndependent?: boolean; - /** - * The demand bit of the BFD packet. This is specified in section 4.1 of RFC5880 - */ - demand?: boolean; - /** - * The diagnostic code specifies the local system's reason for the last change in session state. This allows remote systems to determine the reason that the previous session failed, for example. These diagnostic codes are specified in section 4.1 of RFC5880 - */ - diagnostic?: string; - /** - * The Final bit of the BFD packet. This is specified in section 4.1 of RFC5880 - */ - final?: boolean; - /** - * The length of the BFD Control packet in bytes. This is specified in section 4.1 of RFC5880 - */ - length?: number; - /** - * The Required Min Echo RX Interval value in the BFD packet. This is specified in section 4.1 of RFC5880 - */ - minEchoRxIntervalMs?: number; - /** - * The Required Min RX Interval value in the BFD packet. This is specified in section 4.1 of RFC5880 - */ - minRxIntervalMs?: number; - /** - * The Desired Min TX Interval value in the BFD packet. This is specified in section 4.1 of RFC5880 - */ - minTxIntervalMs?: number; - /** - * The detection time multiplier of the BFD packet. This is specified in section 4.1 of RFC5880 - */ - multiplier?: number; - /** - * The multipoint bit of the BFD packet. This is specified in section 4.1 of RFC5880 - */ - multipoint?: boolean; - /** - * The My Discriminator value in the BFD packet. This is specified in section 4.1 of RFC5880 - */ - myDiscriminator?: number; - /** - * The Poll bit of the BFD packet. This is specified in section 4.1 of RFC5880 - */ - poll?: boolean; - /** - * The current BFD session state as seen by the transmitting system. These states are specified in section 4.1 of RFC5880 - */ - state?: string; - /** - * The version number of the BFD protocol, as specified in section 4.1 of RFC5880. - */ - version?: number; - /** - * The Your Discriminator value in the BFD packet. This is specified in section 4.1 of RFC5880 - */ - yourDiscriminator?: number; - } - /** - * Next free: 15 - */ - export interface Schema$BfdStatus { - /** - * The BFD session initialization mode for this BGP peer. If set to ACTIVE, the Cloud Router will initiate the BFD session for this BGP peer. If set to PASSIVE, the Cloud Router will wait for the peer router to initiate the BFD session for this BGP peer. If set to DISABLED, BFD is disabled for this BGP peer. - */ - bfdSessionInitializationMode?: string; - /** - * Unix timestamp of the most recent config update. - */ - configUpdateTimestampMicros?: string; - /** - * Control packet counts for the current BFD session. - */ - controlPacketCounts?: Schema$BfdStatusPacketCounts; - /** - * Inter-packet time interval statistics for control packets. - */ - controlPacketIntervals?: Schema$PacketIntervals[]; - /** - * Echo packet counts for the current BFD session. - */ - echoPacketCounts?: Schema$BfdStatusPacketCounts; - /** - * Inter-packet time interval statistics for echo packets. - */ - echoPacketIntervals?: Schema$PacketIntervals[]; - /** - * The diagnostic code specifies the local system's reason for the last change in session state. This allows remote systems to determine the reason that the previous session failed, for example. These diagnostic codes are specified in section 4.1 of RFC5880 - */ - localDiagnostic?: string; - /** - * The current BFD session state as seen by the transmitting system. These states are specified in section 4.1 of RFC5880 - */ - localState?: string; - /** - * Negotiated transmit interval for control packets. When echo mode is enabled this will reflect the negotiated slow timer interval. - */ - negotiatedLocalControlTxIntervalMs?: number; - /** - * Negotiated transmit interval for echo packets. - */ - negotiatedLocalEchoTxIntervalMs?: number; - /** - * The most recent Rx control packet for this BFD session. - */ - rxPacket?: Schema$BfdPacket; - /** - * The most recent Tx control packet for this BFD session. - */ - txPacket?: Schema$BfdPacket; - /** - * Session uptime in milliseconds. Value will be 0 if session is not up. - */ - uptimeMs?: string; - /** - * Indicates if echo mode is currently being used. - */ - usingEchoMode?: boolean; - } - export interface Schema$BfdStatusPacketCounts { - /** - * Number of packets received since the beginning of the current BFD session. - */ - numRx?: number; - /** - * Number of packets received that were rejected because of errors since the beginning of the current BFD session. - */ - numRxRejected?: number; - /** - * Number of packets received that were successfully processed since the beginning of the current BFD session. - */ - numRxSuccessful?: number; - /** - * Number of packets transmitted since the beginning of the current BFD session. - */ - numTx?: number; - } - /** - * Associates `members` with a `role`. - */ - export interface Schema$Binding { - /** - * The condition that is associated with this binding. NOTE: An unsatisfied condition will not allow user access via current binding. Different bindings, including their conditions, are examined independently. - */ - condition?: Schema$Expr; - /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. - */ - members?: string[]; - /** - * Role that is assigned to `members`. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - */ - role?: string; - } - export interface Schema$CacheInvalidationRule { - /** - * If set, this invalidation rule will only apply to requests with a Host header matching host. - */ - host?: string; - path?: string; - } - /** - * Message containing what to include in the cache key for a request for Cloud CDN. - */ - export interface Schema$CacheKeyPolicy { - /** - * If true, requests to different hosts will be cached separately. - */ - includeHost?: boolean; - /** - * If true, http and https requests will be cached separately. - */ - includeProtocol?: boolean; - /** - * If true, include query string parameters in the cache key according to query_string_whitelist and query_string_blacklist. If neither is set, the entire query string will be included. If false, the query string will be excluded from the cache key entirely. - */ - includeQueryString?: boolean; - /** - * Names of query string parameters to exclude in cache keys. All other parameters will be included. Either specify query_string_whitelist or query_string_blacklist, not both. '&' and '=' will be percent encoded and not treated as delimiters. - */ - queryStringBlacklist?: string[]; - /** - * Names of query string parameters to include in cache keys. All other parameters will be excluded. Either specify query_string_whitelist or query_string_blacklist, not both. '&' and '=' will be percent encoded and not treated as delimiters. - */ - queryStringWhitelist?: string[]; - } - /** - * gRPC call credentials to access the SDS server. - */ - export interface Schema$CallCredentials { - /** - * The type of call credentials to use for GRPC requests to the SDS server. This field can be set to one of the following: ACCESS_TOKEN: An access token is used as call credentials for the SDS server. GCE_VM: The local GCE VM service account credentials are used to access the SDS server. JWT_SERVICE_TOKEN: The user provisioned service account credentials are used to access the SDS server. FROM_PLUGIN: Custom authenticator credentials are used to access the SDS server. - */ - callCredentialType?: string; - /** - * Custom authenticator credentials. - */ - fromPlugin?: Schema$MetadataCredentialsFromPlugin; - } - /** - * gRPC channel credentials to access the SDS server. - */ - export interface Schema$ChannelCredentials { - /** - * The call credentials to access the SDS server. - */ - certificates?: Schema$TlsCertificatePaths; - /** - * The channel credentials to access the SDS server. This field can be set to one of the following: CERTIFICATES: Use TLS certificates to access the SDS server. GCE_VM: Use local GCE VM credentials to access the SDS server. - */ - channelCredentialType?: string; - } - /** - * Settings controlling the volume of connections to a backend service. - */ - export interface Schema$CircuitBreakers { - /** - * The timeout for new network connections to hosts. - */ - connectTimeout?: Schema$Duration; - /** - * The maximum number of connections to the backend cluster. If not specified, the default is 1024. - */ - maxConnections?: number; - /** - * The maximum number of pending requests allowed to the backend cluster. If not specified, the default is 1024. - */ - maxPendingRequests?: number; - /** - * The maximum number of parallel requests that allowed to the backend cluster. If not specified, the default is 1024. - */ - maxRequests?: number; - /** - * Maximum requests for a single backend connection. This parameter is respected by both the HTTP/1.1 and HTTP/2 implementations. If not specified, there is no limit. Setting this parameter to 1 will effectively disable keep alive. - */ - maxRequestsPerConnection?: number; - /** - * The maximum number of parallel retries allowed to the backend cluster. If not specified, the default is 3. - */ - maxRetries?: number; - } - /** - * The client side authentication settings for connection originating from the backend service. - */ - export interface Schema$ClientTlsSettings { - /** - * Configures the mechanism to obtain client-side security certificates and identity information. This field is only applicable when mode is set to MUTUAL. - */ - clientTlsContext?: Schema$TlsContext; - /** - * Indicates whether connections to this port should be secured using TLS. The value of this field determines how TLS is enforced. This can be set to one of the following values: DISABLE: Do not setup a TLS connection to the backends. SIMPLE: Originate a TLS connection to the backends. MUTUAL: Secure connections to the backends using mutual TLS by presenting client certificates for authentication. - */ - mode?: string; - /** - * SNI string to present to the server during TLS handshake. This field is applicable only when mode is SIMPLE or MUTUAL. - */ - sni?: string; - /** - * A list of alternate names to verify the subject identity in the certificate.If specified, the proxy will verify that the server certificate's subject alt name matches one of the specified values. This field is applicable only when mode is SIMPLE or MUTUAL. - */ - subjectAltNames?: string[]; - } - /** - * Represents a regional Commitment resource. Creating a commitment resource means that you are purchasing a committed use contract with an explicit start and end time. You can create commitments based on vCPUs and memory usage and receive discounted rates. For full details, read Signing Up for Committed Use Discounts. (== resource_for beta.regionCommitments ==) (== resource_for v1.regionCommitments ==) - */ - export interface Schema$Commitment { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] Commitment end time in RFC3339 text format. - */ - endTimestamp?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#commitment for commitments. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * The plan for this commitment, which determines duration and discount rate. The currently supported plans are TWELVE_MONTH (1 year), and THIRTY_SIX_MONTH (3 years). - */ - plan?: string; - /** - * [Output Only] URL of the region where this commitment may be used. - */ - region?: string; - /** - * List of reservations for this commitment. - */ - reservations?: Schema$Reservation[]; - /** - * A list of commitment amounts for particular resources. Note that VCPU and MEMORY resource commitments must occur together. - */ - resources?: Schema$ResourceCommitment[]; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] Commitment start time in RFC3339 text format. - */ - startTimestamp?: string; - /** - * [Output Only] Status of the commitment with regards to eventual expiration (each commitment has an end date defined). One of the following values: NOT_YET_ACTIVE, ACTIVE, EXPIRED. - */ - status?: string; - /** - * [Output Only] An optional, human-readable explanation of the status. - */ - statusMessage?: string; - /** - * The type of commitment, which affects the discount rate and the eligible resources. Type MEMORY_OPTIMIZED specifies a commitment that will only apply to memory optimized machines. - */ - type?: string; - } - export interface Schema$CommitmentAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of CommitmentsScopedList resources. - */ - items?: {[key: string]: Schema$CommitmentsScopedList}; - /** - * [Output Only] Type of resource. Always compute#commitmentAggregatedList for aggregated lists of commitments. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of Commitment resources. - */ - export interface Schema$CommitmentList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Commitment resources. - */ - items?: Schema$Commitment[]; - /** - * [Output Only] Type of resource. Always compute#commitmentList for lists of commitments. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$CommitmentsScopedList { - /** - * [Output Only] A list of commitments contained in this scope. - */ - commitments?: Schema$Commitment[]; - /** - * [Output Only] Informational warning which replaces the list of commitments when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * A condition to be met. - */ - export interface Schema$Condition { - /** - * Trusted attributes supplied by the IAM system. - */ - iam?: string; - /** - * An operator to apply the subject with. - */ - op?: string; - /** - * Trusted attributes discharged by the service. - */ - svc?: string; - /** - * Trusted attributes supplied by any service that owns resources and uses the IAM system for access control. - */ - sys?: string; - /** - * The objects of the condition. - */ - values?: string[]; - } - /** - * Message containing connection draining configuration. - */ - export interface Schema$ConnectionDraining { - /** - * The amount of time in seconds to allow existing connections to persist while on unhealthy backend VMs. Only applicable if the protocol is not UDP. The valid range is [0, 3600]. - */ - drainingTimeoutSec?: number; - } - /** - * This message defines settings for a consistent hash style load balancer. - */ - export interface Schema$ConsistentHashLoadBalancerSettings { - /** - * Hash is based on HTTP Cookie. This field describes a HTTP cookie that will be used as the hash key for the consistent hash load balancer. If the cookie is not present, it will be generated. This field is applicable if the sessionAffinity is set to HTTP_COOKIE. - */ - httpCookie?: Schema$ConsistentHashLoadBalancerSettingsHttpCookie; - /** - * The hash based on the value of the specified header field. This field is applicable if the sessionAffinity is set to HEADER_FIELD. - */ - httpHeaderName?: string; - /** - * The minimum number of virtual nodes to use for the hash ring. Defaults to 1024. Larger ring sizes result in more granular load distributions. If the number of hosts in the load balancing pool is larger than the ring size, each host will be assigned a single virtual node. - */ - minimumRingSize?: string; - } - /** - * The information about the HTTP Cookie on which the hash function is based for load balancing policies that use a consistent hash. - */ - export interface Schema$ConsistentHashLoadBalancerSettingsHttpCookie { - /** - * Name of the cookie. - */ - name?: string; - /** - * Path to set for the cookie. - */ - path?: string; - /** - * Lifetime of the cookie. - */ - ttl?: Schema$Duration; - } - /** - * The specification for allowing client side cross-origin requests. Please see W3C Recommendation for Cross Origin Resource Sharing - */ - export interface Schema$CorsPolicy { - /** - * In response to a preflight request, setting this to true indicates that the actual request can include user credentials. This translates to the Access-Control-Allow-Credentials header. Default is false. - */ - allowCredentials?: boolean; - /** - * Specifies the content for the Access-Control-Allow-Headers header. - */ - allowHeaders?: string[]; - /** - * Specifies the content for the Access-Control-Allow-Methods header. - */ - allowMethods?: string[]; - /** - * Specifies the regualar expression patterns that match allowed origins. For regular expression grammar please see en.cppreference.com/w/cpp/regex/ecmascript An origin is allowed if it matches either allow_origins or allow_origin_regex. - */ - allowOriginRegexes?: string[]; - /** - * Specifies the list of origins that will be allowed to do CORS requests. An origin is allowed if it matches either allow_origins or allow_origin_regex. - */ - allowOrigins?: string[]; - /** - * If true, specifies the CORS policy is disabled. The default value of false, which indicates that the CORS policy is in effect. - */ - disabled?: boolean; - /** - * Specifies the content for the Access-Control-Expose-Headers header. - */ - exposeHeaders?: string[]; - /** - * Specifies how long the results of a preflight request can be cached. This translates to the content for the Access-Control-Max-Age header. - */ - maxAge?: number; - } - /** - * Represents a customer-supplied encryption key - */ - export interface Schema$CustomerEncryptionKey { - /** - * The name of the encryption key that is stored in Google Cloud KMS. - */ - kmsKeyName?: string; - kmsKeyServiceAccount?: string; - /** - * Specifies a 256-bit customer-supplied encryption key, encoded in RFC 4648 base64 to either encrypt or decrypt this resource. - */ - rawKey?: string; - /** - * Specifies an RFC 4648 base64 encoded, RSA-wrapped 2048-bit customer-supplied encryption key to either encrypt or decrypt this resource. The key must meet the following requirements before you can provide it to Compute Engine: - The key is wrapped using a RSA public key certificate provided by Google. - After being wrapped, the key must be encoded in RFC 4648 base64 encoding. Gets the RSA public key certificate provided by Google at: https://cloud-certs.storage.googleapis.com/google-cloud-csek-ingress.pem - */ - rsaEncryptedKey?: string; - /** - * [Output only] The RFC 4648 base64 encoded SHA-256 hash of the customer-supplied encryption key that protects this resource. - */ - sha256?: string; - } - export interface Schema$CustomerEncryptionKeyProtectedDisk { - /** - * Decrypts data associated with the disk with a customer-supplied encryption key. - */ - diskEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * Specifies a valid partial or full URL to an existing Persistent Disk resource. This field is only applicable for persistent disks. - */ - source?: string; - } - /** - * Deprecation status for a public resource. - */ - export interface Schema$DeprecationStatus { - /** - * An optional RFC3339 timestamp on or after which the state of this resource is intended to change to DELETED. This is only informational and the status will not change unless the client explicitly changes it. - */ - deleted?: string; - /** - * An optional RFC3339 timestamp on or after which the state of this resource is intended to change to DEPRECATED. This is only informational and the status will not change unless the client explicitly changes it. - */ - deprecated?: string; - /** - * An optional RFC3339 timestamp on or after which the state of this resource is intended to change to OBSOLETE. This is only informational and the status will not change unless the client explicitly changes it. - */ - obsolete?: string; - /** - * The URL of the suggested replacement for a deprecated resource. The suggested replacement resource must be the same kind of resource as the deprecated resource. - */ - replacement?: string; - /** - * The deprecation state of this resource. This can be ACTIVE, DEPRECATED, OBSOLETE, or DELETED. Operations which communicate the end of life date for an image, can use ACTIVE. Operations which create a new resource using a DEPRECATED resource will return successfully, but with a warning indicating the deprecated resource and recommending its replacement. Operations which use OBSOLETE or DELETED resources will be rejected and result in an error. - */ - state?: string; - } - /** - * Represents a Persistent Disk resource. Persistent disks are required for running your VM instances. Create both boot and non-boot (data) persistent disks. For more information, read Persistent Disks. For more storage options, read Storage options. The disks resource represents a zonal persistent disk. For more information, read Zonal persistent disks. The regionDisks resource represents a regional persistent disk. For more information, read Regional resources. (== resource_for beta.disks ==) (== resource_for v1.disks ==) (== resource_for v1.regionDisks ==) (== resource_for beta.regionDisks ==) - */ - export interface Schema$Disk { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * Encrypts the disk using a customer-supplied encryption key. After you encrypt a disk with a customer-supplied key, you must provide the same key if you use the disk later (e.g. to create a disk snapshot, to create a disk image, to create a machine image, or to attach the disk to a virtual machine). Customer-supplied encryption keys do not protect access to metadata of the disk. If you do not provide an encryption key when creating the disk, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the disk later. - */ - diskEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * Specifies whether the disk restored from a source snapshot should erase Windows specific VSS signature. - */ - eraseWindowsVssSignature?: boolean; - /** - * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options. - */ - guestOsFeatures?: Schema$GuestOsFeature[]; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#disk for disks. - */ - kind?: string; - /** - * A fingerprint for the labels being applied to this disk, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a disk. - */ - labelFingerprint?: string; - /** - * Labels to apply to this disk. These can be later modified by the setLabels method. - */ - labels?: {[key: string]: string}; - /** - * [Output Only] Last attach timestamp in RFC3339 text format. - */ - lastAttachTimestamp?: string; - /** - * [Output Only] Last detach timestamp in RFC3339 text format. - */ - lastDetachTimestamp?: string; - /** - * Integer license codes indicating which licenses are attached to this disk. - */ - licenseCodes?: string[]; - /** - * A list of publicly visible licenses. Reserved for Google's use. - */ - licenses?: string[]; - /** - * Indicates whether or not the disk can be read/write attached to more than one instance. - */ - multiWriter?: boolean; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * Internal use only. - */ - options?: string; - /** - * Physical block size of the persistent disk, in bytes. If not present in a request, a default value is used. Currently supported sizes are 4096 and 16384, other sizes may be added in the future. If an unsupported value is requested, the error message will list the supported values for the caller's project. - */ - physicalBlockSizeBytes?: string; - /** - * [Output Only] URL of the region where the disk resides. Only applicable for regional resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - region?: string; - /** - * URLs of the zones where the disk should be replicated to. Only applicable for regional resources. - */ - replicaZones?: string[]; - /** - * Resource policies applied to this disk for automatic snapshot creations. - */ - resourcePolicies?: string[]; - /** - * [Output Only] Server-defined fully-qualified URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource's resource id. - */ - selfLinkWithId?: string; - /** - * Size of the persistent disk, specified in GB. You can specify this field when creating a persistent disk using the sourceImage or sourceSnapshot parameter, or specify it alone to create an empty persistent disk. If you specify this field along with sourceImage or sourceSnapshot, the value of sizeGb must not be less than the size of the sourceImage or the size of the snapshot. Acceptable values are 1 to 65536, inclusive. - */ - sizeGb?: string; - /** - * The source disk used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone/disks/disk - projects/project/zones/zone/disks/disk - zones/zone/disks/disk - */ - sourceDisk?: string; - /** - * [Output Only] The unique ID of the disk used to create this disk. This value identifies the exact disk that was used to create this persistent disk. For example, if you created the persistent disk from a disk that was later deleted and recreated under the same name, the source disk ID would identify the exact version of the disk that was used. - */ - sourceDiskId?: string; - /** - * The source image used to create this disk. If the source image is deleted, this field will not be set. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family - */ - sourceImage?: string; - /** - * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key. - */ - sourceImageEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * [Output Only] The ID value of the image used to create this disk. This value identifies the exact image that was used to create this persistent disk. For example, if you created the persistent disk from an image that was later deleted and recreated under the same name, the source image ID would identify the exact version of the image that was used. - */ - sourceImageId?: string; - /** - * The source snapshot used to create this disk. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/global/snapshots/snapshot - projects/project/global/snapshots/snapshot - global/snapshots/snapshot - */ - sourceSnapshot?: string; - /** - * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key. - */ - sourceSnapshotEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * [Output Only] The unique ID of the snapshot used to create this disk. This value identifies the exact snapshot that was used to create this persistent disk. For example, if you created the persistent disk from a snapshot that was later deleted and recreated under the same name, the source snapshot ID would identify the exact version of the snapshot that was used. - */ - sourceSnapshotId?: string; - /** - * [Output Only] The status of disk creation. - */ - status?: string; - /** - * [Deprecated] Storage type of the persistent disk. - */ - storageType?: string; - /** - * URL of the disk type resource describing which disk type to use to create the disk. Provide this when creating the disk. For example: projects/project/zones/zone/diskTypes/pd-standard or pd-ssd - */ - type?: string; - /** - * [Output Only] Links to the users of the disk (attached instances) in form: projects/project/zones/zone/instances/instance - */ - users?: string[]; - /** - * [Output Only] URL of the zone where the disk resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - zone?: string; - } - export interface Schema$DiskAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of DisksScopedList resources. - */ - items?: {[key: string]: Schema$DisksScopedList}; - /** - * [Output Only] Type of resource. Always compute#diskAggregatedList for aggregated lists of persistent disks. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * A specification of the desired way to instantiate a disk in the instance template when its created from a source instance. - */ - export interface Schema$DiskInstantiationConfig { - /** - * Specifies whether the disk will be auto-deleted when the instance is deleted (but not when the disk is detached from the instance). - */ - autoDelete?: boolean; - /** - * The custom source image to be used to restore this disk when instantiating this instance template. - */ - customImage?: string; - /** - * Specifies the device name of the disk to which the configurations apply to. - */ - deviceName?: string; - /** - * Specifies whether to include the disk and what image to use. Possible values are: - source-image: to use the same image that was used to create the source instance's corresponding disk. Applicable to the boot disk and additional read-write disks. - source-image-family: to use the same image family that was used to create the source instance's corresponding disk. Applicable to the boot disk and additional read-write disks. - custom-image: to use a user-provided image url for disk creation. Applicable to the boot disk and additional read-write disks. - attach-read-only: to attach a read-only disk. Applicable to read-only disks. - do-not-include: to exclude a disk from the template. Applicable to additional read-write disks, local SSDs, and read-only disks. - */ - instantiateFrom?: string; - } - /** - * A list of Disk resources. - */ - export interface Schema$DiskList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Disk resources. - */ - items?: Schema$Disk[]; - /** - * [Output Only] Type of resource. Always compute#diskList for lists of disks. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$DiskMoveRequest { - /** - * The URL of the destination zone to move the disk. This can be a full or partial URL. For example, the following are all valid URLs to a zone: - https://www.googleapis.com/compute/v1/projects/project/zones/zone - projects/project/zones/zone - zones/zone - */ - destinationZone?: string; - /** - * The URL of the target disk to move. This can be a full or partial URL. For example, the following are all valid URLs to a disk: - https://www.googleapis.com/compute/v1/projects/project/zones/zone/disks/disk - projects/project/zones/zone/disks/disk - zones/zone/disks/disk - */ - targetDisk?: string; - } - export interface Schema$DisksAddResourcePoliciesRequest { - /** - * Resource policies to be added to this disk. - */ - resourcePolicies?: string[]; - } - export interface Schema$DisksRemoveResourcePoliciesRequest { - /** - * Resource policies to be removed from this disk. - */ - resourcePolicies?: string[]; - } - export interface Schema$DisksResizeRequest { - /** - * The new size of the persistent disk, which is specified in GB. - */ - sizeGb?: string; - } - export interface Schema$DisksScopedList { - /** - * [Output Only] A list of disks contained in this scope. - */ - disks?: Schema$Disk[]; - /** - * [Output Only] Informational warning which replaces the list of disks when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents a Disk Type resource. You can choose from a variety of disk types based on your needs. For more information, read Storage options. The diskTypes resource represents disk types for a zonal persistent disk. For more information, read Zonal persistent disks. The regionDiskTypes resource represents disk types for a regional persistent disk. For more information, read Regional persistent disks. (== resource_for beta.diskTypes ==) (== resource_for v1.diskTypes ==) (== resource_for v1.regionDiskTypes ==) (== resource_for beta.regionDiskTypes ==) - */ - export interface Schema$DiskType { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * [Output Only] Server-defined default disk size in GB. - */ - defaultDiskSizeGb?: string; - /** - * [Output Only] The deprecation status associated with this disk type. - */ - deprecated?: Schema$DeprecationStatus; - /** - * [Output Only] An optional description of this resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#diskType for disk types. - */ - kind?: string; - /** - * [Output Only] Name of the resource. - */ - name?: string; - /** - * [Output Only] URL of the region where the disk type resides. Only applicable for regional resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] An optional textual description of the valid disk size, such as "10GB-10TB". - */ - validDiskSize?: string; - /** - * [Output Only] URL of the zone where the disk type resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - zone?: string; - } - export interface Schema$DiskTypeAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of DiskTypesScopedList resources. - */ - items?: {[key: string]: Schema$DiskTypesScopedList}; - /** - * [Output Only] Type of resource. Always compute#diskTypeAggregatedList. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of disk types. - */ - export interface Schema$DiskTypeList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of DiskType resources. - */ - items?: Schema$DiskType[]; - /** - * [Output Only] Type of resource. Always compute#diskTypeList for disk types. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$DiskTypesScopedList { - /** - * [Output Only] A list of disk types contained in this scope. - */ - diskTypes?: Schema$DiskType[]; - /** - * [Output Only] Informational warning which replaces the list of disk types when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * A set of Display Device options - */ - export interface Schema$DisplayDevice { - /** - * Defines whether the instance has Display enabled. - */ - enableDisplay?: boolean; - } - export interface Schema$DistributionPolicy { - /** - * Zones where the regional managed instance group will create and manage instances. - */ - zones?: Schema$DistributionPolicyZoneConfiguration[]; - } - export interface Schema$DistributionPolicyZoneConfiguration { - /** - * The URL of the zone. The zone must exist in the region where the managed instance group is located. - */ - zone?: string; - } - /** - * A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like "day" or "month". Range is approximately 10,000 years. - */ - export interface Schema$Duration { - /** - * Span of time that's a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive. - */ - nanos?: number; - /** - * Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years - */ - seconds?: string; - } - export interface Schema$ExchangedPeeringRoute { - /** - * The destination range of the route. - */ - destRange?: string; - /** - * True if the peering route has been imported from a peer. The actual import happens if the field networkPeering.importCustomRoutes is true for this network, and networkPeering.exportCustomRoutes is true for the peer network, and the import does not result in a route conflict. - */ - imported?: boolean; - /** - * The region of peering route next hop, only applies to dynamic routes. - */ - nextHopRegion?: string; - /** - * The priority of the peering route. - */ - priority?: number; - /** - * The type of the peering route. - */ - type?: string; - } - export interface Schema$ExchangedPeeringRoutesList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of ExchangedPeeringRoute resources. - */ - items?: Schema$ExchangedPeeringRoute[]; - /** - * [Output Only] Type of resource. Always compute#exchangedPeeringRoutesList for exchanged peering routes lists. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents an expression text. Example: title: "User account presence" description: "Determines whether the request has a user account" expression: "size(request.user) > 0" - */ - export interface Schema$Expr { - /** - * An optional description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI. - */ - description?: string; - /** - * Textual representation of an expression in Common Expression Language syntax. The application context of the containing message determines which well-known feature set of CEL is supported. - */ - expression?: string; - /** - * An optional string indicating the location of the expression for error reporting, e.g. a file name and a position in the file. - */ - location?: string; - /** - * An optional title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression. - */ - title?: string; - } - /** - * External VPN gateway is the on-premises VPN gateway(s) or another cloud provider?s VPN gateway that connects to your Google Cloud VPN gateway. To create a highly available VPN from Google Cloud to your on-premises side or another Cloud provider's VPN gateway, you must create a external VPN gateway resource in GCP, which provides the information to GCP about your external VPN gateway. - */ - export interface Schema$ExternalVpnGateway { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * List of interfaces for this external VPN gateway. - */ - interfaces?: Schema$ExternalVpnGatewayInterface[]; - /** - * [Output Only] Type of the resource. Always compute#externalVpnGateway for externalVpnGateways. - */ - kind?: string; - /** - * A fingerprint for the labels being applied to this ExternalVpnGateway, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an ExternalVpnGateway. - */ - labelFingerprint?: string; - /** - * Labels to apply to this ExternalVpnGateway resource. These can be later modified by the setLabels method. Each label key/value must comply with RFC1035. Label values may be empty. - */ - labels?: {[key: string]: string}; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * Indicates the user-supplied redundancy type of this external VPN gateway. - */ - redundancyType?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - } - /** - * The interface for the external VPN gateway. - */ - export interface Schema$ExternalVpnGatewayInterface { - /** - * The numeric ID of this interface. The allowed input values for this id for different redundancy types of external VPN gateway: SINGLE_IP_INTERNALLY_REDUNDANT - 0 TWO_IPS_REDUNDANCY - 0, 1 FOUR_IPS_REDUNDANCY - 0, 1, 2, 3 - */ - id?: number; - /** - * IP address of the interface in the external VPN gateway. Only IPv4 is supported. This IP address can be either from your on-premise gateway or another Cloud provider?s VPN gateway, it cannot be an IP address from Google Compute Engine. - */ - ipAddress?: string; - } - /** - * Response to the list request, and contains a list of externalVpnGateways. - */ - export interface Schema$ExternalVpnGatewayList { - etag?: string; - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of ExternalVpnGateway resources. - */ - items?: Schema$ExternalVpnGateway[]; - /** - * [Output Only] Type of resource. Always compute#externalVpnGatewayList for lists of externalVpnGateways. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$FileContentBuffer { - /** - * The raw content in the secure keys file. - */ - content?: string; - fileType?: string; - } - /** - * Represents a Firewall Rule resource. Firewall rules allow or deny ingress traffic to, and egress traffic from your instances. For more information, read Firewall rules. - */ - export interface Schema$Firewall { - /** - * The list of ALLOW rules specified by this firewall. Each rule specifies a protocol and port-range tuple that describes a permitted connection. - */ - allowed?: Array<{IPProtocol?: string; ports?: string[]}>; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * The list of DENY rules specified by this firewall. Each rule specifies a protocol and port-range tuple that describes a denied connection. - */ - denied?: Array<{IPProtocol?: string; ports?: string[]}>; - /** - * An optional description of this resource. Provide this field when you create the resource. - */ - description?: string; - /** - * If destination ranges are specified, the firewall rule applies only to traffic that has destination IP address in these ranges. These ranges must be expressed in CIDR format. Only IPv4 is supported. - */ - destinationRanges?: string[]; - /** - * Direction of traffic to which this firewall applies, either `INGRESS` or `EGRESS`. The default is `INGRESS`. For `INGRESS` traffic, you cannot specify the destinationRanges field, and for `EGRESS` traffic, you cannot specify the sourceRanges or sourceTags fields. - */ - direction?: string; - /** - * Denotes whether the firewall rule is disabled. When set to true, the firewall rule is not enforced and the network behaves as if it did not exist. If this is unspecified, the firewall rule will be enabled. - */ - disabled?: boolean; - /** - * Deprecated in favor of enable in LogConfig. This field denotes whether to enable logging for a particular firewall rule. If logging is enabled, logs will be exported to Stackdriver. - */ - enableLogging?: boolean; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#firewall for firewall rules. - */ - kind?: string; - /** - * This field denotes the logging options for a particular firewall rule. If logging is enabled, logs will be exported to Stackdriver. - */ - logConfig?: Schema$FirewallLogConfig; - /** - * Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?. The first character must be a lowercase letter, and all following characters (except for the last character) must be a dash, lowercase letter, or digit. The last character must be a lowercase letter or digit. - */ - name?: string; - /** - * URL of the network resource for this firewall rule. If not specified when creating a firewall rule, the default network is used: global/networks/default If you choose to specify this field, you can specify the network as a full or partial URL. For example, the following are all valid URLs: - https://www.googleapis.com/compute/v1/projects/myproject/global/networks/my-network - projects/myproject/global/networks/my-network - global/networks/default - */ - network?: string; - /** - * Priority for this rule. This is an integer between `0` and `65535`, both inclusive. The default value is `1000`. Relative priorities determine which rule takes effect if multiple rules apply. Lower values indicate higher priority. For example, a rule with priority `0` has higher precedence than a rule with priority `1`. DENY rules take precedence over ALLOW rules if they have equal priority. Note that VPC networks have implied rules with a priority of `65535`. To avoid conflicts with the implied rules, use a priority number less than `65535`. - */ - priority?: number; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * If source ranges are specified, the firewall rule applies only to traffic that has a source IP address in these ranges. These ranges must be expressed in CIDR format. One or both of sourceRanges and sourceTags may be set. If both fields are set, the rule applies to traffic that has a source IP address within sourceRanges OR a source IP from a resource with a matching tag listed in the sourceTags field. The connection does not need to match both fields for the rule to apply. Only IPv4 is supported. - */ - sourceRanges?: string[]; - /** - * If source service accounts are specified, the firewall rules apply only to traffic originating from an instance with a service account in this list. Source service accounts cannot be used to control traffic to an instance's external IP address because service accounts are associated with an instance, not an IP address. sourceRanges can be set at the same time as sourceServiceAccounts. If both are set, the firewall applies to traffic that has a source IP address within the sourceRanges OR a source IP that belongs to an instance with service account listed in sourceServiceAccount. The connection does not need to match both fields for the firewall to apply. sourceServiceAccounts cannot be used at the same time as sourceTags or targetTags. - */ - sourceServiceAccounts?: string[]; - /** - * If source tags are specified, the firewall rule applies only to traffic with source IPs that match the primary network interfaces of VM instances that have the tag and are in the same VPC network. Source tags cannot be used to control traffic to an instance's external IP address, it only applies to traffic between instances in the same virtual network. Because tags are associated with instances, not IP addresses. One or both of sourceRanges and sourceTags may be set. If both fields are set, the firewall applies to traffic that has a source IP address within sourceRanges OR a source IP from a resource with a matching tag listed in the sourceTags field. The connection does not need to match both fields for the firewall to apply. - */ - sourceTags?: string[]; - /** - * A list of service accounts indicating sets of instances located in the network that may make network connections as specified in allowed[]. targetServiceAccounts cannot be used at the same time as targetTags or sourceTags. If neither targetServiceAccounts nor targetTags are specified, the firewall rule applies to all instances on the specified network. - */ - targetServiceAccounts?: string[]; - /** - * A list of tags that controls which instances the firewall rule applies to. If targetTags are specified, then the firewall rule applies only to instances in the VPC network that have one of those tags. If no targetTags are specified, the firewall rule applies to all instances on the specified network. - */ - targetTags?: string[]; - } - /** - * Contains a list of firewalls. - */ - export interface Schema$FirewallList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Firewall resources. - */ - items?: Schema$Firewall[]; - /** - * [Output Only] Type of resource. Always compute#firewallList for lists of firewalls. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * The available logging options for a firewall rule. - */ - export interface Schema$FirewallLogConfig { - /** - * This field denotes whether to enable logging for a particular firewall rule. - */ - enable?: boolean; - /** - * This field can only be specified for a particular firewall rule if logging is enabled for that rule. This field denotes whether to include or exclude metadata for firewall logs. - */ - metadata?: string; - } - /** - * Encapsulates numeric value that can be either absolute or relative. - */ - export interface Schema$FixedOrPercent { - /** - * [Output Only] Absolute value of VM instances calculated based on the specific mode. - If the value is fixed, then the calculated value is equal to the fixed value. - If the value is a percent, then the calculated value is percent/100 * targetSize. For example, the calculated value of a 80% of a managed instance group with 150 instances would be (80/100 * 150) = 120 VM instances. If there is a remainder, the number is rounded up. - */ - calculated?: number; - /** - * Specifies a fixed number of VM instances. This must be a positive integer. - */ - fixed?: number; - /** - * Specifies a percentage of instances between 0 to 100%, inclusive. For example, specify 80 for 80%. - */ - percent?: number; - } - /** - * Represents a Forwarding Rule resource. A forwardingRules resource represents a regional forwarding rule. Regional external forwarding rules can reference any of the following resources: - A target instance - A Cloud VPN Classic gateway (targetVpnGateway), - A target pool for a Network Load Balancer - A global target HTTP(S) proxy for an HTTP(S) load balancer using Standard Tier - A target SSL proxy for a SSL Proxy load balancer using Standard Tier - A target TCP proxy for a TCP Proxy load balancer using Standard Tier. Regional internal forwarding rules can reference the backend service of an internal TCP/UDP load balancer. For regional internal forwarding rules, the following applies: - If the loadBalancingScheme for the load balancer is INTERNAL, then the forwarding rule references a regional internal backend service. - If the loadBalancingScheme for the load balancer is INTERNAL_MANAGED, then the forwarding rule must reference a regional target HTTP(S) proxy. For more information, read Using Forwarding rules. A globalForwardingRules resource represents a global forwarding rule. Global forwarding rules are only used by load balancers that use Premium Tier. (== resource_for beta.forwardingRules ==) (== resource_for v1.forwardingRules ==) (== resource_for beta.globalForwardingRules ==) (== resource_for v1.globalForwardingRules ==) (== resource_for beta.regionForwardingRules ==) (== resource_for v1.regionForwardingRules ==) - */ - export interface Schema$ForwardingRule { - /** - * This field is used along with the backend_service field for internal load balancing or with the target field for internal TargetInstance. If the field is set to TRUE, clients can access ILB from all regions. Otherwise only allows access from clients in the same region as the internal load balancer. - */ - allowGlobalAccess?: boolean; - /** - * This field is used along with the backend_service field for internal load balancing or with the target field for internal TargetInstance. This field cannot be used with port or portRange fields. When the load balancing scheme is INTERNAL and protocol is TCP/UDP, specify this field to allow packets addressed to any ports will be forwarded to the backends configured with this forwarding rule. - */ - allPorts?: boolean; - /** - * This field is only used for INTERNAL load balancing. For internal load balancing, this field identifies the BackendService resource to receive the matched traffic. - */ - backendService?: string; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a ForwardingRule. Include the fingerprint in patch request to ensure that you do not overwrite changes that were applied from another concurrent request. To see the latest fingerprint, make a get() request to retrieve a ForwardingRule. - */ - fingerprint?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * The IP address that this forwarding rule is serving on behalf of. Addresses are restricted based on the forwarding rule's load balancing scheme (EXTERNAL or INTERNAL) and scope (global or regional). When the load balancing scheme is EXTERNAL, for global forwarding rules, the address must be a global IP, and for regional forwarding rules, the address must live in the same region as the forwarding rule. If this field is empty, an ephemeral IPv4 address from the same scope (global or regional) will be assigned. A regional forwarding rule supports IPv4 only. A global forwarding rule supports either IPv4 or IPv6. When the load balancing scheme is INTERNAL_SELF_MANAGED, this must be a URL reference to an existing Address resource ( internal regional static IP address), with a purpose of GCE_END_POINT and address_type of INTERNAL. When the load balancing scheme is INTERNAL, this can only be an RFC 1918 IP address belonging to the network/subnet configured for the forwarding rule. By default, if this field is empty, an ephemeral internal IP address will be automatically allocated from the IP range of the subnet or network configured for this forwarding rule. An address can be specified either by a literal IP address or a URL reference to an existing Address resource. The following examples are all valid: - 100.1.2.3 - https://www.googleapis.com/compute/v1/projects/project/regions/region/addresses/address - projects/project/regions/region/addresses/address - regions/region/addresses/address - global/addresses/address - address - */ - IPAddress?: string; - /** - * The IP protocol to which this rule applies. Valid options are TCP, UDP, ESP, AH, SCTP or ICMP. When the load balancing scheme is INTERNAL, only TCP and UDP are valid. When the load balancing scheme is INTERNAL_SELF_MANAGED, only TCPis valid. - */ - IPProtocol?: string; - /** - * The IP Version that will be used by this forwarding rule. Valid options are IPV4 or IPV6. This can only be specified for an external global forwarding rule. - */ - ipVersion?: string; - /** - * Indicates whether or not this load balancer can be used as a collector for packet mirroring. To prevent mirroring loops, instances behind this load balancer will not have their traffic mirrored even if a PacketMirroring rule applies to them. This can only be set to true for load balancers that have their loadBalancingScheme set to INTERNAL. - */ - isMirroringCollector?: boolean; - /** - * [Output Only] Type of the resource. Always compute#forwardingRule for Forwarding Rule resources. - */ - kind?: string; - /** - * A fingerprint for the labels being applied to this resource, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a ForwardingRule. - */ - labelFingerprint?: string; - /** - * Labels to apply to this resource. These can be later modified by the setLabels method. Each label key/value pair must comply with RFC1035. Label values may be empty. - */ - labels?: {[key: string]: string}; - /** - * This signifies what the ForwardingRule will be used for and can only take the following values: INTERNAL, INTERNAL_SELF_MANAGED, EXTERNAL. The value of INTERNAL means that this will be used for Internal Network Load Balancing (TCP, UDP). The value of INTERNAL_SELF_MANAGED means that this will be used for Internal Global HTTP(S) LB. The value of EXTERNAL means that this will be used for External Load Balancing (HTTP(S) LB, External TCP/UDP LB, SSL Proxy) - */ - loadBalancingScheme?: string; - /** - * Opaque filter criteria used by Loadbalancer to restrict routing configuration to a limited set xDS compliant clients. In their xDS requests to Loadbalancer, xDS clients present node metadata. If a match takes place, the relevant routing configuration is made available to those proxies. For each metadataFilter in this list, if its filterMatchCriteria is set to MATCH_ANY, at least one of the filterLabels must match the corresponding label provided in the metadata. If its filterMatchCriteria is set to MATCH_ALL, then all of its filterLabels must match with corresponding labels in the provided metadata. metadataFilters specified here can be overridden by those specified in the UrlMap that this ForwardingRule references. metadataFilters only applies to Loadbalancers that have their loadBalancingScheme set to INTERNAL_SELF_MANAGED. - */ - metadataFilters?: Schema$MetadataFilter[]; - /** - * Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * This field is not used for external load balancing. For INTERNAL and INTERNAL_SELF_MANAGED load balancing, this field identifies the network that the load balanced IP should belong to for this Forwarding Rule. If this field is not specified, the default network will be used. - */ - network?: string; - /** - * This signifies the networking tier used for configuring this load balancer and can only take the following values: PREMIUM , STANDARD. For regional ForwardingRule, the valid values are PREMIUM and STANDARD. For GlobalForwardingRule, the valid value is PREMIUM. If this field is not specified, it is assumed to be PREMIUM. If IPAddress is specified, this value must be equal to the networkTier of the Address. - */ - networkTier?: string; - /** - * This field is used along with the target field for TargetHttpProxy, TargetHttpsProxy, TargetSslProxy, TargetTcpProxy, TargetVpnGateway, TargetPool, TargetInstance. Applicable only when IPProtocol is TCP, UDP, or SCTP, only packets addressed to ports in the specified range will be forwarded to target. Forwarding rules with the same [IPAddress, IPProtocol] pair must have disjoint port ranges. Some types of forwarding target have constraints on the acceptable ports: - TargetHttpProxy: 80, 8080 - TargetHttpsProxy: 443 - TargetTcpProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 - TargetSslProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 - TargetVpnGateway: 500, 4500 - */ - portRange?: string; - /** - * This field is used along with the backend_service field for internal load balancing. When the load balancing scheme is INTERNAL, a list of ports can be configured, for example, ['80'], ['8000','9000'] etc. Only packets addressed to these ports will be forwarded to the backends configured with this forwarding rule. You may specify a maximum of up to 5 ports. - */ - ports?: string[]; - /** - * [Output Only] URL of the region where the regional forwarding rule resides. This field is not applicable to global forwarding rules. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * An optional prefix to the service name for this Forwarding Rule. If specified, will be the first label of the fully qualified service name. The label must be 1-63 characters long, and comply with RFC1035. Specifically, the label must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. This field is only used for internal load balancing. - */ - serviceLabel?: string; - /** - * [Output Only] The internal fully qualified service name for this Forwarding Rule. This field is only used for internal load balancing. - */ - serviceName?: string; - /** - * This field is only used for INTERNAL load balancing. For internal load balancing, this field identifies the subnetwork that the load balanced IP should belong to for this Forwarding Rule. If the network specified is in auto subnet mode, this field is optional. However, if the network is in custom subnet mode, a subnetwork must be specified. - */ - subnetwork?: string; - /** - * The URL of the target resource to receive the matched traffic. For regional forwarding rules, this target must live in the same region as the forwarding rule. For global forwarding rules, this target must be a global load balancing resource. The forwarded traffic must be of a type appropriate to the target object. For INTERNAL_SELF_MANAGED load balancing, only HTTP and HTTPS targets are valid. - */ - target?: string; - } - export interface Schema$ForwardingRuleAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of ForwardingRulesScopedList resources. - */ - items?: {[key: string]: Schema$ForwardingRulesScopedList}; - /** - * [Output Only] Type of resource. Always compute#forwardingRuleAggregatedList for lists of forwarding rules. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of ForwardingRule resources. - */ - export interface Schema$ForwardingRuleList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of ForwardingRule resources. - */ - items?: Schema$ForwardingRule[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$ForwardingRuleReference { - forwardingRule?: string; - } - export interface Schema$ForwardingRulesScopedList { - /** - * A list of forwarding rules contained in this scope. - */ - forwardingRules?: Schema$ForwardingRule[]; - /** - * Informational warning which replaces the list of forwarding rules when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$GlobalNetworkEndpointGroupsAttachEndpointsRequest { - /** - * The list of network endpoints to be attached. - */ - networkEndpoints?: Schema$NetworkEndpoint[]; - } - export interface Schema$GlobalNetworkEndpointGroupsDetachEndpointsRequest { - /** - * The list of network endpoints to be detached. - */ - networkEndpoints?: Schema$NetworkEndpoint[]; - } - export interface Schema$GlobalSetLabelsRequest { - /** - * The fingerprint of the previous set of labels for this resource, used to detect conflicts. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash when updating or changing labels, otherwise the request will fail with error 412 conditionNotMet. Make a get() request to the resource to get the latest fingerprint. - */ - labelFingerprint?: string; - /** - * A list of labels to apply for this resource. Each label key & value must comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. For example, "webserver-frontend": "images". A label value can also be empty (e.g. "my-label": ""). - */ - labels?: {[key: string]: string}; - } - export interface Schema$GlobalSetPolicyRequest { - /** - * Flatten Policy to create a backward compatible wire-format. Deprecated. Use 'policy' to specify bindings. - */ - bindings?: Schema$Binding[]; - /** - * Flatten Policy to create a backward compatible wire-format. Deprecated. Use 'policy' to specify the etag. - */ - etag?: string; - /** - * REQUIRED: The complete policy to be applied to the 'resource'. The size of the policy is limited to a few 10s of KB. An empty policy is in general a valid policy but certain services (like Projects) might reject them. - */ - policy?: Schema$Policy; - } - /** - * gRPC config to access the SDS server. - */ - export interface Schema$GrpcServiceConfig { - /** - * The call credentials to access the SDS server. - */ - callCredentials?: Schema$CallCredentials; - /** - * The channel credentials to access the SDS server. - */ - channelCredentials?: Schema$ChannelCredentials; - /** - * The target URI of the SDS server. - */ - targetUri?: string; - } - /** - * A guest attributes entry. - */ - export interface Schema$GuestAttributes { - /** - * [Output Only] Type of the resource. Always compute#guestAttributes for guest attributes entry. - */ - kind?: string; - /** - * The path to be queried. This can be the default namespace ('/') or a nested namespace ('//') or a specified key ('//') - */ - queryPath?: string; - /** - * [Output Only] The value of the requested queried path. - */ - queryValue?: Schema$GuestAttributesValue; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * The key to search for. - */ - variableKey?: string; - /** - * [Output Only] The value found for the requested key. - */ - variableValue?: string; - } - /** - * A guest attributes namespace/key/value entry. - */ - export interface Schema$GuestAttributesEntry { - /** - * Key for the guest attribute entry. - */ - key?: string; - /** - * Namespace for the guest attribute entry. - */ - namespace?: string; - /** - * Value for the guest attribute entry. - */ - value?: string; - } - /** - * Array of guest attribute namespace/key/value tuples. - */ - export interface Schema$GuestAttributesValue { - items?: Schema$GuestAttributesEntry[]; - } - /** - * Guest OS features. - */ - export interface Schema$GuestOsFeature { - /** - * The ID of a supported feature. Read Enabling guest operating system features to see a list of available options. - */ - type?: string; - } - /** - * Represents a Health Check resource. Health checks are used for most GCP load balancers and managed instance group auto-healing. For more information, read Health Check Concepts. To perform health checks on network load balancers, you must use either httpHealthChecks or httpsHealthChecks. - */ - export interface Schema$HealthCheck { - /** - * How often (in seconds) to send a health check. The default value is 5 seconds. - */ - checkIntervalSec?: number; - /** - * [Output Only] Creation timestamp in 3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * A so-far unhealthy instance will be marked healthy after this many consecutive successes. The default value is 2. - */ - healthyThreshold?: number; - http2HealthCheck?: Schema$HTTP2HealthCheck; - httpHealthCheck?: Schema$HTTPHealthCheck; - httpsHealthCheck?: Schema$HTTPSHealthCheck; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * Type of the resource. - */ - kind?: string; - /** - * Configure logging on this health check. - */ - logConfig?: Schema$HealthCheckLogConfig; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * [Output Only] Region where the health check resides. Not applicable to global health checks. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - sslHealthCheck?: Schema$SSLHealthCheck; - tcpHealthCheck?: Schema$TCPHealthCheck; - /** - * How long (in seconds) to wait before claiming failure. The default value is 5 seconds. It is invalid for timeoutSec to have greater value than checkIntervalSec. - */ - timeoutSec?: number; - /** - * Specifies the type of the healthCheck, either TCP, SSL, HTTP, HTTPS or HTTP2. If not specified, the default is TCP. Exactly one of the protocol-specific health check field must be specified, which must match type field. - */ - type?: string; - udpHealthCheck?: Schema$UDPHealthCheck; - /** - * A so-far healthy instance will be marked unhealthy after this many consecutive failures. The default value is 2. - */ - unhealthyThreshold?: number; - } - /** - * Contains a list of HealthCheck resources. - */ - export interface Schema$HealthCheckList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of HealthCheck resources. - */ - items?: Schema$HealthCheck[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Configuration of logging on a health check. If logging is enabled, logs will be exported to Stackdriver. - */ - export interface Schema$HealthCheckLogConfig { - /** - * Indicates whether or not to export logs. This is false by default, which means no health check logging will be done. - */ - enable?: boolean; - /** - * Specifies the desired filtering of logs on this health check. If this is unspecified and enable is true, logs are exported with LOG_TRANSITION filter. - */ - filter?: string; - } - /** - * A full or valid partial URL to a health check. For example, the following are valid URLs: - https://www.googleapis.com/compute/beta/projects/project-id/global/httpHealthChecks/health-check - projects/project-id/global/httpHealthChecks/health-check - global/httpHealthChecks/health-check - */ - export interface Schema$HealthCheckReference { - healthCheck?: string; - } - export interface Schema$HealthChecksAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of HealthChecksScopedList resources. - */ - items?: {[key: string]: Schema$HealthChecksScopedList}; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * A HealthCheckService defines a set of backends on which to perform periodic health checks and an endpoint to which to send notification of changes in the health status of the backends. - */ - export interface Schema$HealthCheckService { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * List of URLs to the HealthCheck resources. Must have at least one HealthCheck, and not more than 10. HealthCheck resources must have portSpecification=USE_SERVING_PORT. For regional HealthCheckService, the HealthCheck must be regional and in the same region. For global HealthCheckService, HealthCheck must be global. Mix of regional and global HealthChecks is not supported. Multiple regional HealthChecks must belong to the same region. Regional HealthChecks</code? must belong to the same region as zones of NEGs. - */ - healthChecks?: string[]; - /** - * Policy for how the results from multiple health checks for the same endpoint are aggregated. - NO_AGGREGATION. An EndpointHealth message is returned for each backend in the health check service. - AND. If any backend's health check reports UNHEALTHY, then UNHEALTHY is the HealthState of the entire health check service. If all backend's are healthy, the HealthState of the health check service is HEALTHY. . - */ - healthStatusAggregationStrategy?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output only] Type of the resource. Always compute#healthCheckServicefor health check services. - */ - kind?: string; - /** - * Name of the resource. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * List of URLs to the NetworkEndpointGroup resources. Must not have more than 100. For regional HealthCheckService, NEGs must be in zones in the region of the HealthCheckService. - */ - networkEndpointGroups?: string[]; - /** - * List of URLs to the NotificationEndpoint resources. Must not have more than 10. A list of endpoints for receiving notifications of change in health status. For regional HealthCheckService, NotificationEndpoint must be regional and in the same region. For global HealthCheckService, NotificationEndpoint must be global. - */ - notificationEndpoints?: string[]; - /** - * [Output Only] URL of the region where the health check service resides. This field is not applicable to global health check services. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL with id for the resource. - */ - selfLinkWithId?: string; - } - /** - * A full or valid partial URL to a health check service. For example, the following are valid URLs: - https://www.googleapis.com/compute/beta/projects/project-id/regions/us-west1/healthCheckServices/health-check-service - projects/project-id/regions/us-west1/healthCheckServices/health-check-service - regions/us-west1/healthCheckServices/health-check-service - */ - export interface Schema$HealthCheckServiceReference { - healthCheckService?: string; - } - export interface Schema$HealthCheckServicesList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of HealthCheckService resources. - */ - items?: Schema$HealthCheckService[]; - /** - * [Output Only] Type of the resource. Always compute#healthCheckServicesList for lists of HealthCheckServices. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$HealthChecksScopedList { - /** - * A list of HealthChecks contained in this scope. - */ - healthChecks?: Schema$HealthCheck[]; - /** - * Informational warning which replaces the list of backend services when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$HealthStatus { - /** - * Metadata defined as annotations for network endpoint. - */ - annotations?: {[key: string]: string}; - /** - * Health state of the instance. - */ - healthState?: string; - /** - * URL of the instance resource. - */ - instance?: string; - /** - * The IP address represented by this resource. - */ - ipAddress?: string; - /** - * The port on the instance. - */ - port?: number; - } - export interface Schema$HealthStatusForNetworkEndpoint { - /** - * URL of the backend service associated with the health state of the network endpoint. - */ - backendService?: Schema$BackendServiceReference; - /** - * URL of the forwarding rule associated with the health state of the network endpoint. - */ - forwardingRule?: Schema$ForwardingRuleReference; - /** - * URL of the health check associated with the health state of the network endpoint. - */ - healthCheck?: Schema$HealthCheckReference; - /** - * URL of the health check service associated with the health state of the network endpoint. - */ - healthCheckService?: Schema$HealthCheckServiceReference; - /** - * Health state of the network endpoint determined based on the health checks configured. - */ - healthState?: string; - } - /** - * UrlMaps A host-matching rule for a URL. If matched, will use the named PathMatcher to select the BackendService. - */ - export interface Schema$HostRule { - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * The list of host patterns to match. They must be valid hostnames, except * will match any string of ([a-z0-9-.]*). In that case, * must be the first character and must be followed in the pattern by either - or .. - */ - hosts?: string[]; - /** - * The name of the PathMatcher to use to match the path portion of the URL if the hostRule matches the URL's host portion. - */ - pathMatcher?: string; - } - export interface Schema$HTTP2HealthCheck { - /** - * The value of the host header in the HTTP/2 health check request. If left empty (default value), the IP on behalf of which this health check is performed will be used. - */ - host?: string; - /** - * The TCP port number for the health check request. The default value is 443. Valid values are 1 through 65535. - */ - port?: number; - /** - * Port name as defined in InstanceGroup#NamedPort#name. If both port and port_name are defined, port takes precedence. - */ - portName?: string; - /** - * Specifies how port is selected for health checking, can be one of following values: USE_FIXED_PORT: The port number in port is used for health checking. USE_NAMED_PORT: The portName is used for health checking. USE_SERVING_PORT: For NetworkEndpointGroup, the port specified for each network endpoint is used for health checking. For other backends, the port or named port specified in the Backend Service is used for health checking. If not specified, HTTP2 health check follows behavior specified in port and portName fields. - */ - portSpecification?: string; - /** - * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. - */ - proxyHeader?: string; - /** - * The request path of the HTTP/2 health check request. The default value is /. - */ - requestPath?: string; - /** - * The string to match anywhere in the first 1024 bytes of the response body. If left empty (the default value), the status code determines health. The response data can only be ASCII. - */ - response?: string; - } - /** - * Specification for how requests are aborted as part of fault injection. - */ - export interface Schema$HttpFaultAbort { - /** - * The HTTP status code used to abort the request. The value must be between 200 and 599 inclusive. - */ - httpStatus?: number; - /** - * The percentage of traffic (connections/operations/requests) which will be aborted as part of fault injection. The value must be between 0.0 and 100.0 inclusive. - */ - percentage?: number; - } - /** - * Specifies the delay introduced by Loadbalancer before forwarding the request to the backend service as part of fault injection. - */ - export interface Schema$HttpFaultDelay { - /** - * Specifies the value of the fixed delay interval. - */ - fixedDelay?: Schema$Duration; - /** - * The percentage of traffic (connections/operations/requests) on which delay will be introduced as part of fault injection. The value must be between 0.0 and 100.0 inclusive. - */ - percentage?: number; - } - /** - * The specification for fault injection introduced into traffic to test the resiliency of clients to backend service failure. As part of fault injection, when clients send requests to a backend service, delays can be introduced by Loadbalancer on a percentage of requests before sending those request to the backend service. Similarly requests from clients can be aborted by the Loadbalancer for a percentage of requests. - */ - export interface Schema$HttpFaultInjection { - /** - * The specification for how client requests are aborted as part of fault injection. - */ - abort?: Schema$HttpFaultAbort; - /** - * The specification for how client requests are delayed as part of fault injection, before being sent to a backend service. - */ - delay?: Schema$HttpFaultDelay; - } - /** - * The request and response header transformations that take effect before the request is passed along to the selected backendService. - */ - export interface Schema$HttpHeaderAction { - /** - * Headers to add to a matching request prior to forwarding the request to the backendService. - */ - requestHeadersToAdd?: Schema$HttpHeaderOption[]; - /** - * A list of header names for headers that need to be removed from the request prior to forwarding the request to the backendService. - */ - requestHeadersToRemove?: string[]; - /** - * Headers to add the response prior to sending the response back to the client. - */ - responseHeadersToAdd?: Schema$HttpHeaderOption[]; - /** - * A list of header names for headers that need to be removed from the response prior to sending the response back to the client. - */ - responseHeadersToRemove?: string[]; - } - /** - * matchRule criteria for request header matches. - */ - export interface Schema$HttpHeaderMatch { - /** - * The value should exactly match contents of exactMatch. Only one of exactMatch, prefixMatch, suffixMatch, regexMatch, presentMatch or rangeMatch must be set. - */ - exactMatch?: string; - /** - * The name of the HTTP header to match. For matching against the HTTP request's authority, use a headerMatch with the header name ":authority". For matching a request's method, use the headerName ":method". - */ - headerName?: string; - /** - * If set to false, the headerMatch is considered a match if the match criteria above are met. If set to true, the headerMatch is considered a match if the match criteria above are NOT met. The default setting is false. - */ - invertMatch?: boolean; - /** - * The value of the header must start with the contents of prefixMatch. Only one of exactMatch, prefixMatch, suffixMatch, regexMatch, presentMatch or rangeMatch must be set. - */ - prefixMatch?: string; - /** - * A header with the contents of headerName must exist. The match takes place whether or not the request's header has a value or not. Only one of exactMatch, prefixMatch, suffixMatch, regexMatch, presentMatch or rangeMatch must be set. - */ - presentMatch?: boolean; - /** - * The header value must be an integer and its value must be in the range specified in rangeMatch. If the header does not contain an integer, number or is empty, the match fails. For example for a range [-5, 0] - -3 will match. - 0 will not match. - 0.25 will not match. - -3someString will not match. Only one of exactMatch, prefixMatch, suffixMatch, regexMatch, presentMatch or rangeMatch must be set. - */ - rangeMatch?: Schema$Int64RangeMatch; - /** - * The value of the header must match the regualar expression specified in regexMatch. For regular expression grammar, please see: en.cppreference.com/w/cpp/regex/ecmascript For matching against a port specified in the HTTP request, use a headerMatch with headerName set to PORT and a regular expression that satisfies the RFC2616 Host header's port specifier. Only one of exactMatch, prefixMatch, suffixMatch, regexMatch, presentMatch or rangeMatch must be set. - */ - regexMatch?: string; - /** - * The value of the header must end with the contents of suffixMatch. Only one of exactMatch, prefixMatch, suffixMatch, regexMatch, presentMatch or rangeMatch must be set. - */ - suffixMatch?: string; - } - /** - * Specification determining how headers are added to requests or responses. - */ - export interface Schema$HttpHeaderOption { - /** - * The name of the header. - */ - headerName?: string; - /** - * The value of the header to add. - */ - headerValue?: string; - /** - * If false, headerValue is appended to any values that already exist for the header. If true, headerValue is set for the header, discarding any values that were set for that header. The default value is false. - */ - replace?: boolean; - } - export interface Schema$HTTPHealthCheck { - /** - * The value of the host header in the HTTP health check request. If left empty (default value), the IP on behalf of which this health check is performed will be used. - */ - host?: string; - /** - * The TCP port number for the health check request. The default value is 80. Valid values are 1 through 65535. - */ - port?: number; - /** - * Port name as defined in InstanceGroup#NamedPort#name. If both port and port_name are defined, port takes precedence. - */ - portName?: string; - /** - * Specifies how port is selected for health checking, can be one of following values: USE_FIXED_PORT: The port number in port is used for health checking. USE_NAMED_PORT: The portName is used for health checking. USE_SERVING_PORT: For NetworkEndpointGroup, the port specified for each network endpoint is used for health checking. For other backends, the port or named port specified in the Backend Service is used for health checking. If not specified, HTTP health check follows behavior specified in port and portName fields. - */ - portSpecification?: string; - /** - * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. - */ - proxyHeader?: string; - /** - * The request path of the HTTP health check request. The default value is /. - */ - requestPath?: string; - /** - * The string to match anywhere in the first 1024 bytes of the response body. If left empty (the default value), the status code determines health. The response data can only be ASCII. - */ - response?: string; - } - /** - * Represents a legacy HTTP Health Check resource. Legacy health checks are required by network load balancers. For more information, read Health Check Concepts. - */ - export interface Schema$HttpHealthCheck { - /** - * How often (in seconds) to send a health check. The default value is 5 seconds. - */ - checkIntervalSec?: number; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * A so-far unhealthy instance will be marked healthy after this many consecutive successes. The default value is 2. - */ - healthyThreshold?: number; - /** - * The value of the host header in the HTTP health check request. If left empty (default value), the public IP on behalf of which this health check is performed will be used. - */ - host?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#httpHealthCheck for HTTP health checks. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * The TCP port number for the HTTP health check request. The default value is 80. - */ - port?: number; - /** - * The request path of the HTTP health check request. The default value is /. This field does not support query parameters. - */ - requestPath?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * How long (in seconds) to wait before claiming failure. The default value is 5 seconds. It is invalid for timeoutSec to have greater value than checkIntervalSec. - */ - timeoutSec?: number; - /** - * A so-far healthy instance will be marked unhealthy after this many consecutive failures. The default value is 2. - */ - unhealthyThreshold?: number; - } - /** - * Contains a list of HttpHealthCheck resources. - */ - export interface Schema$HttpHealthCheckList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of HttpHealthCheck resources. - */ - items?: Schema$HttpHealthCheck[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * HttpRouteRuleMatch criteria for a request's query parameter. - */ - export interface Schema$HttpQueryParameterMatch { - /** - * The queryParameterMatch matches if the value of the parameter exactly matches the contents of exactMatch. Only one of presentMatch, exactMatch and regexMatch must be set. - */ - exactMatch?: string; - /** - * The name of the query parameter to match. The query parameter must exist in the request, in the absence of which the request match fails. - */ - name?: string; - /** - * Specifies that the queryParameterMatch matches if the request contains the query parameter, irrespective of whether the parameter has a value or not. Only one of presentMatch, exactMatch and regexMatch must be set. - */ - presentMatch?: boolean; - /** - * The queryParameterMatch matches if the value of the parameter matches the regular expression specified by regexMatch. For the regular expression grammar, please see en.cppreference.com/w/cpp/regex/ecmascript Only one of presentMatch, exactMatch and regexMatch must be set. - */ - regexMatch?: string; - } - /** - * Specifies settings for an HTTP redirect. - */ - export interface Schema$HttpRedirectAction { - /** - * The host that will be used in the redirect response instead of the one that was supplied in the request. The value must be between 1 and 255 characters. - */ - hostRedirect?: string; - /** - * If set to true, the URL scheme in the redirected request is set to https. If set to false, the URL scheme of the redirected request will remain the same as that of the request. This must only be set for UrlMaps used in TargetHttpProxys. Setting this true for TargetHttpsProxy is not permitted. The default is set to false. - */ - httpsRedirect?: boolean; - /** - * The path that will be used in the redirect response instead of the one that was supplied in the request. Only one of pathRedirect or prefixRedirect must be specified. The value must be between 1 and 1024 characters. - */ - pathRedirect?: string; - /** - * The prefix that replaces the prefixMatch specified in the HttpRouteRuleMatch, retaining the remaining portion of the URL before redirecting the request. - */ - prefixRedirect?: string; - /** - * The HTTP Status code to use for this RedirectAction. Supported values are: - MOVED_PERMANENTLY_DEFAULT, which is the default value and corresponds to 301. - FOUND, which corresponds to 302. - SEE_OTHER which corresponds to 303. - TEMPORARY_REDIRECT, which corresponds to 307. In this case, the request method will be retained. - PERMANENT_REDIRECT, which corresponds to 308. In this case, the request method will be retained. - */ - redirectResponseCode?: string; - /** - * If set to true, any accompanying query portion of the original URL is removed prior to redirecting the request. If set to false, the query portion of the original URL is retained. The default is set to false. - */ - stripQuery?: boolean; - } - /** - * The retry policy associates with HttpRouteRule - */ - export interface Schema$HttpRetryPolicy { - /** - * Specifies the allowed number retries. This number must be > 0. - */ - numRetries?: number; - /** - * Specifies a non-zero timeout per retry attempt. - */ - perTryTimeout?: Schema$Duration; - /** - * Specfies one or more conditions when this retry rule applies. Valid values are: - 5xx: Loadbalancer will attempt a retry if the backend service responds with any 5xx response code, or if the backend service does not respond at all, example: disconnects, reset, read timeout, connection failure, and refused streams. - gateway-error: Similar to 5xx, but only applies to response codes 502, 503 or 504. - - connect-failure: Loadbalancer will retry on failures connecting to backend services, for example due to connection timeouts. - retriable-4xx: Loadbalancer will retry for retriable 4xx response codes. Currently the only retriable error supported is 409. - refused-stream:Loadbalancer will retry if the backend service resets the stream with a REFUSED_STREAM error code. This reset type indicates that it is safe to retry. - cancelledLoadbalancer will retry if the gRPC status code in the response header is set to cancelled - deadline-exceeded: Loadbalancer will retry if the gRPC status code in the response header is set to deadline-exceeded - resource-exhausted: Loadbalancer will retry if the gRPC status code in the response header is set to resource-exhausted - unavailable: Loadbalancer will retry if the gRPC status code in the response header is set to unavailable - */ - retryConditions?: string[]; - } - export interface Schema$HttpRouteAction { - /** - * The specification for allowing client side cross-origin requests. Please see W3C Recommendation for Cross Origin Resource Sharing - */ - corsPolicy?: Schema$CorsPolicy; - /** - * The specification for fault injection introduced into traffic to test the resiliency of clients to backend service failure. As part of fault injection, when clients send requests to a backend service, delays can be introduced by Loadbalancer on a percentage of requests before sending those request to the backend service. Similarly requests from clients can be aborted by the Loadbalancer for a percentage of requests. timeout and retry_policy will be ignored by clients that are configured with a fault_injection_policy. - */ - faultInjectionPolicy?: Schema$HttpFaultInjection; - /** - * Specifies the policy on how requests intended for the route's backends are shadowed to a separate mirrored backend service. Loadbalancer does not wait for responses from the shadow service. Prior to sending traffic to the shadow service, the host / authority header is suffixed with -shadow. - */ - requestMirrorPolicy?: Schema$RequestMirrorPolicy; - /** - * Specifies the retry policy associated with this route. - */ - retryPolicy?: Schema$HttpRetryPolicy; - /** - * Specifies the timeout for the selected route. Timeout is computed from the time the request is has been fully processed (i.e. end-of-stream) up until the response has been completely processed. Timeout includes all retries. If not specified, the default value is 15 seconds. - */ - timeout?: Schema$Duration; - /** - * The spec to modify the URL of the request, prior to forwarding the request to the matched service - */ - urlRewrite?: Schema$UrlRewrite; - /** - * A list of weighted backend services to send traffic to when a route match occurs. The weights determine the fraction of traffic that flows to their corresponding backend service. If all traffic needs to go to a single backend service, there must be one weightedBackendService with weight set to a non 0 number. Once a backendService is identified and before forwarding the request to the backend service, advanced routing actions like Url rewrites and header transformations are applied depending on additional settings specified in this HttpRouteAction. - */ - weightedBackendServices?: Schema$WeightedBackendService[]; - } - /** - * An HttpRouteRule specifies how to match an HTTP request and the corresponding routing action that load balancing proxies will perform. - */ - export interface Schema$HttpRouteRule { - /** - * Specifies changes to request and response headers that need to take effect for the selected backendService. The headerAction specified here are applied before the matching pathMatchers[].headerAction and after pathMatchers[].routeRules[].routeAction.weightedBackendService.backendServiceWeightAction[].headerAction - */ - headerAction?: Schema$HttpHeaderAction; - matchRules?: Schema$HttpRouteRuleMatch[]; - /** - * In response to a matching matchRule, the load balancer performs advanced routing actions like URL rewrites, header transformations, etc. prior to forwarding the request to the selected backend. If routeAction specifies any weightedBackendServices, service must not be set. Conversely if service is set, routeAction cannot contain any weightedBackendServices. Only one of routeAction or urlRedirect must be set. - */ - routeAction?: Schema$HttpRouteAction; - /** - * The full or partial URL of the backend service resource to which traffic is directed if this rule is matched. If routeAction is additionally specified, advanced routing actions like URL Rewrites, etc. take effect prior to sending the request to the backend. However, if service is specified, routeAction cannot contain any weightedBackendService s. Conversely, if routeAction specifies any weightedBackendServices, service must not be specified. Only one of urlRedirect, service or routeAction.weightedBackendService must be set. - */ - service?: string; - /** - * When this rule is matched, the request is redirected to a URL specified by urlRedirect. If urlRedirect is specified, service or routeAction must not be set. - */ - urlRedirect?: Schema$HttpRedirectAction; - } - /** - * HttpRouteRuleMatch specifies a set of criteria for matching requests to an HttpRouteRule. All specified criteria must be satisfied for a match to occur. - */ - export interface Schema$HttpRouteRuleMatch { - /** - * For satifying the matchRule condition, the path of the request must exactly match the value specified in fullPathMatch after removing any query parameters and anchor that may be part of the original URL. FullPathMatch must be between 1 and 1024 characters. Only one of prefixMatch, fullPathMatch or regexMatch must be specified. - */ - fullPathMatch?: string; - /** - * Specifies a list of header match criteria, all of which must match corresponding headers in the request. - */ - headerMatches?: Schema$HttpHeaderMatch[]; - /** - * Specifies that prefixMatch and fullPathMatch matches are case sensitive. The default value is false. caseSensitive must not be used with regexMatch. - */ - ignoreCase?: boolean; - /** - * Opaque filter criteria used by Loadbalancer to restrict routing configuration to a limited set xDS compliant clients. In their xDS requests to Loadbalancer, xDS clients present node metadata. If a match takes place, the relevant routing configuration is made available to those proxies. For each metadataFilter in this list, if its filterMatchCriteria is set to MATCH_ANY, at least one of the filterLabels must match the corresponding label provided in the metadata. If its filterMatchCriteria is set to MATCH_ALL, then all of its filterLabels must match with corresponding labels in the provided metadata. metadataFilters specified here can be overrides those specified in ForwardingRule that refers to this UrlMap. metadataFilters only applies to Loadbalancers that have their loadBalancingScheme set to INTERNAL_SELF_MANAGED. - */ - metadataFilters?: Schema$MetadataFilter[]; - /** - * For satifying the matchRule condition, the request's path must begin with the specified prefixMatch. prefixMatch must begin with a /. The value must be between 1 and 1024 characters. Only one of prefixMatch, fullPathMatch or regexMatch must be specified. - */ - prefixMatch?: string; - /** - * Specifies a list of query parameter match criteria, all of which must match corresponding query parameters in the request. - */ - queryParameterMatches?: Schema$HttpQueryParameterMatch[]; - /** - * For satifying the matchRule condition, the path of the request must satisfy the regular expression specified in regexMatch after removing any query parameters and anchor supplied with the original URL. For regular expression grammar please see en.cppreference.com/w/cpp/regex/ecmascript Only one of prefixMatch, fullPathMatch or regexMatch must be specified. - */ - regexMatch?: string; - } - export interface Schema$HTTPSHealthCheck { - /** - * The value of the host header in the HTTPS health check request. If left empty (default value), the IP on behalf of which this health check is performed will be used. - */ - host?: string; - /** - * The TCP port number for the health check request. The default value is 443. Valid values are 1 through 65535. - */ - port?: number; - /** - * Port name as defined in InstanceGroup#NamedPort#name. If both port and port_name are defined, port takes precedence. - */ - portName?: string; - /** - * Specifies how port is selected for health checking, can be one of following values: USE_FIXED_PORT: The port number in port is used for health checking. USE_NAMED_PORT: The portName is used for health checking. USE_SERVING_PORT: For NetworkEndpointGroup, the port specified for each network endpoint is used for health checking. For other backends, the port or named port specified in the Backend Service is used for health checking. If not specified, HTTPS health check follows behavior specified in port and portName fields. - */ - portSpecification?: string; - /** - * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. - */ - proxyHeader?: string; - /** - * The request path of the HTTPS health check request. The default value is /. - */ - requestPath?: string; - /** - * The string to match anywhere in the first 1024 bytes of the response body. If left empty (the default value), the status code determines health. The response data can only be ASCII. - */ - response?: string; - } - /** - * Represents a legacy HTTPS Health Check resource. Legacy health checks are required by network load balancers. For more information, read Health Check Concepts. - */ - export interface Schema$HttpsHealthCheck { - /** - * How often (in seconds) to send a health check. The default value is 5 seconds. - */ - checkIntervalSec?: number; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * A so-far unhealthy instance will be marked healthy after this many consecutive successes. The default value is 2. - */ - healthyThreshold?: number; - /** - * The value of the host header in the HTTPS health check request. If left empty (default value), the public IP on behalf of which this health check is performed will be used. - */ - host?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * Type of the resource. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * The TCP port number for the HTTPS health check request. The default value is 443. - */ - port?: number; - /** - * The request path of the HTTPS health check request. The default value is "/". - */ - requestPath?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * How long (in seconds) to wait before claiming failure. The default value is 5 seconds. It is invalid for timeoutSec to have a greater value than checkIntervalSec. - */ - timeoutSec?: number; - /** - * A so-far healthy instance will be marked unhealthy after this many consecutive failures. The default value is 2. - */ - unhealthyThreshold?: number; - } - /** - * Contains a list of HttpsHealthCheck resources. - */ - export interface Schema$HttpsHealthCheckList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of HttpsHealthCheck resources. - */ - items?: Schema$HttpsHealthCheck[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents an Image resource. You can use images to create boot disks for your VM instances. For more information, read Images. (== resource_for beta.images ==) (== resource_for v1.images ==) - */ - export interface Schema$Image { - /** - * Size of the image tar.gz archive stored in Google Cloud Storage (in bytes). - */ - archiveSizeBytes?: string; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * The deprecation status associated with this image. - */ - deprecated?: Schema$DeprecationStatus; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * Size of the image when restored onto a persistent disk (in GB). - */ - diskSizeGb?: string; - /** - * The name of the image family to which this image belongs. You can create disks by specifying an image family instead of a specific image name. The image family always returns its latest image that is not deprecated. The name of the image family must comply with RFC1035. - */ - family?: string; - /** - * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options. - */ - guestOsFeatures?: Schema$GuestOsFeature[]; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * Encrypts the image using a customer-supplied encryption key. After you encrypt an image with a customer-supplied key, you must provide the same key if you use the image later (e.g. to create a disk from the image). Customer-supplied encryption keys do not protect access to metadata of the disk. If you do not provide an encryption key when creating the image, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the image later. - */ - imageEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * [Output Only] Type of the resource. Always compute#image for images. - */ - kind?: string; - /** - * A fingerprint for the labels being applied to this image, which is essentially a hash of the labels used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an image. - */ - labelFingerprint?: string; - /** - * Labels to apply to this image. These can be later modified by the setLabels method. - */ - labels?: {[key: string]: string}; - /** - * Integer license codes indicating which licenses are attached to this image. - */ - licenseCodes?: string[]; - /** - * Any applicable license URI. - */ - licenses?: string[]; - /** - * Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * The parameters of the raw disk image. - */ - rawDisk?: {containerType?: string; sha1Checksum?: string; source?: string}; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource's resource id. - */ - selfLinkWithId?: string; - /** - * Set the secure boot keys of shielded instance. - */ - shieldedInstanceInitialState?: Schema$InitialStateConfig; - /** - * URL of the source disk used to create this image. This can be a full or valid partial URL. You must provide either this property or the rawDisk.source property but not both to create an image. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone/disks/disk - projects/project/zones/zone/disks/disk - zones/zone/disks/disk - */ - sourceDisk?: string; - /** - * The customer-supplied encryption key of the source disk. Required if the source disk is protected by a customer-supplied encryption key. - */ - sourceDiskEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * [Output Only] The ID value of the disk used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given disk name. - */ - sourceDiskId?: string; - /** - * URL of the source image used to create this image. This can be a full or valid partial URL. You must provide exactly one of: - this property, or - the rawDisk.source property, or - the sourceDisk property in order to create an image. - */ - sourceImage?: string; - /** - * The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key. - */ - sourceImageEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * [Output Only] The ID value of the image used to create this image. This value may be used to determine whether the image was taken from the current or a previous instance of a given image name. - */ - sourceImageId?: string; - /** - * URL of the source snapshot used to create this image. This can be a full or valid partial URL. You must provide exactly one of: - this property, or - the sourceImage property, or - the rawDisk.source property, or - the sourceDisk property in order to create an image. - */ - sourceSnapshot?: string; - /** - * The customer-supplied encryption key of the source snapshot. Required if the source snapshot is protected by a customer-supplied encryption key. - */ - sourceSnapshotEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * [Output Only] The ID value of the snapshot used to create this image. This value may be used to determine whether the snapshot was taken from the current or a previous instance of a given snapshot name. - */ - sourceSnapshotId?: string; - /** - * The type of the image used to create this disk. The default and only value is RAW - */ - sourceType?: string; - /** - * [Output Only] The status of the image. An image can be used to create other resources, such as instances, only after the image has been successfully created and the status is set to READY. Possible values are FAILED, PENDING, or READY. - */ - status?: string; - /** - * GCS bucket storage location of the image (regional or multi-regional). - */ - storageLocations?: string[]; - } - /** - * Contains a list of images. - */ - export interface Schema$ImageList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Image resources. - */ - items?: Schema$Image[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Initial State for shielded instance, these are public keys which are safe to store in public - */ - export interface Schema$InitialStateConfig { - /** - * The Key Database (db). - */ - dbs?: Schema$FileContentBuffer[]; - /** - * The forbidden key database (dbx). - */ - dbxs?: Schema$FileContentBuffer[]; - /** - * The Key Exchange Key (KEK). - */ - keks?: Schema$FileContentBuffer[]; - /** - * The Platform Key (PK). - */ - pk?: Schema$FileContentBuffer; - } - /** - * Represents an Instance resource. An instance is a virtual machine that is hosted on Google Cloud Platform. For more information, read Virtual Machine Instances. (== resource_for beta.instances ==) (== resource_for v1.instances ==) - */ - export interface Schema$Instance { - /** - * Allows this instance to send and receive packets with non-matching destination or source IPs. This is required if you plan to use this instance to forward routes. For more information, see Enabling IP Forwarding. - */ - canIpForward?: boolean; - /** - * [Output Only] The CPU platform used by this instance. - */ - cpuPlatform?: string; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * Whether the resource should be protected against deletion. - */ - deletionProtection?: boolean; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * Array of disks associated with this instance. Persistent disks must be created before you can assign them. - */ - disks?: Schema$AttachedDisk[]; - /** - * Enables display device for the instance. - */ - displayDevice?: Schema$DisplayDevice; - /** - * Specifies whether the disks restored from source snapshots or source machine image should erase Windows specific VSS signature. - */ - eraseWindowsVssSignature?: boolean; - /** - * A list of the type and count of accelerator cards attached to the instance. - */ - guestAccelerators?: Schema$AcceleratorConfig[]; - hostname?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * Encrypts or decrypts data for an instance with a customer-supplied encryption key. If you are creating a new instance, this field encrypts the local SSD and in-memory contents of the instance using a key that you provide. If you are restarting an instance protected with a customer-supplied encryption key, you must provide the correct key in order to successfully restart the instance. If you do not provide an encryption key when creating the instance, then the local SSD and in-memory contents will be encrypted using an automatically generated key and you do not need to provide a key to start the instance later. Instance templates do not store customer-supplied encryption keys, so you cannot use your own keys to encrypt local SSDs and in-memory content in a managed instance group. - */ - instanceEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * [Output Only] Type of the resource. Always compute#instance for instances. - */ - kind?: string; - /** - * A fingerprint for this request, which is essentially a hash of the label's contents and used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels. To see the latest fingerprint, make get() request to the instance. - */ - labelFingerprint?: string; - /** - * Labels to apply to this instance. These can be later modified by the setLabels method. - */ - labels?: {[key: string]: string}; - /** - * Full or partial URL of the machine type resource to use for this instance, in the format: zones/zone/machineTypes/machine-type. This is provided by the client when the instance is created. For example, the following is a valid partial url to a predefined machine type: zones/us-central1-f/machineTypes/n1-standard-1 To create a custom machine type, provide a URL to a machine type in the following format, where CPUS is 1 or an even number up to 32 (2, 4, 6, ... 24, etc), and MEMORY is the total memory for this instance. Memory must be a multiple of 256 MB and must be supplied in MB (e.g. 5 GB of memory is 5120 MB): zones/zone/machineTypes/custom-CPUS-MEMORY For example: zones/us-central1-f/machineTypes/custom-4-5120 For a full list of restrictions, read the Specifications for custom machine types. - */ - machineType?: string; - /** - * The metadata key/value pairs assigned to this instance. This includes custom metadata and predefined keys. - */ - metadata?: Schema$Metadata; - /** - * Specifies a minimum CPU platform for the VM instance. Applicable values are the friendly names of CPU platforms, such as minCpuPlatform: "Intel Haswell" or minCpuPlatform: "Intel Sandy Bridge". - */ - minCpuPlatform?: string; - /** - * The name of the resource, provided by the client when initially creating the resource. The resource name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * An array of network configurations for this instance. These specify how interfaces are configured to interact with other network services, such as connecting to the internet. Multiple interfaces are supported per instance. - */ - networkInterfaces?: Schema$NetworkInterface[]; - /** - * Total amount of preserved state for SUSPENDED instances. Read-only in the api. - */ - preservedStateSizeGb?: string; - /** - * Specifies the reservations that this instance can consume from. - */ - reservationAffinity?: Schema$ReservationAffinity; - /** - * Resource policies applied to this instance. - */ - resourcePolicies?: string[]; - /** - * Sets the scheduling options for this instance. - */ - scheduling?: Schema$Scheduling; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * A list of service accounts, with their specified scopes, authorized for this instance. Only one service account per VM instance is supported. Service accounts generate access tokens that can be accessed through the metadata server and used to authenticate applications on the instance. See Service Accounts for more information. - */ - serviceAccounts?: Schema$ServiceAccount[]; - shieldedInstanceConfig?: Schema$ShieldedInstanceConfig; - shieldedInstanceIntegrityPolicy?: Schema$ShieldedInstanceIntegrityPolicy; - shieldedVmConfig?: Schema$ShieldedVmConfig; - shieldedVmIntegrityPolicy?: Schema$ShieldedVmIntegrityPolicy; - /** - * Source machine image - */ - sourceMachineImage?: string; - /** - * Source GMI encryption key when creating an instance from GMI. - */ - sourceMachineImageEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * [Output Only] Whether a VM has been restricted for start because Compute Engine has detected suspicious activity. - */ - startRestricted?: boolean; - /** - * [Output Only] The status of the instance. One of the following values: PROVISIONING, STAGING, RUNNING, STOPPING, STOPPED, SUSPENDING, SUSPENDED, and TERMINATED. - */ - status?: string; - /** - * [Output Only] An optional, human-readable explanation of the status. - */ - statusMessage?: string; - /** - * Tags to apply to this instance. Tags are used to identify valid sources or targets for network firewalls and are specified by the client during instance creation. The tags can be later modified by the setTags method. Each tag within the list must comply with RFC1035. Multiple tags can be specified via the 'tags.items' field. - */ - tags?: Schema$Tags; - /** - * [Output Only] URL of the zone where the instance resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - zone?: string; - } - export interface Schema$InstanceAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * An object that contains a list of instances scoped by zone. - */ - items?: {[key: string]: Schema$InstancesScopedList}; - /** - * [Output Only] Type of resource. Always compute#instanceAggregatedList for aggregated lists of Instance resources. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents an unmanaged Instance Group resource. Use unmanaged instance groups if you need to apply load balancing to groups of heterogeneous instances or if you need to manage the instances yourself. For more information, read Instance groups. For zonal unmanaged Instance Group, use instanceGroups resource. For regional unmanaged Instance Group, use regionInstanceGroups resource. (== resource_for beta.instanceGroups ==) (== resource_for v1.instanceGroups ==) (== resource_for beta.regionInstanceGroups ==) (== resource_for v1.regionInstanceGroups ==) - */ - export interface Schema$InstanceGroup { - /** - * [Output Only] The creation timestamp for this instance group in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The fingerprint of the named ports. The system uses this fingerprint to detect conflicts when multiple users change the named ports concurrently. - */ - fingerprint?: string; - /** - * [Output Only] A unique identifier for this instance group, generated by the server. - */ - id?: string; - /** - * [Output Only] The resource type, which is always compute#instanceGroup for instance groups. - */ - kind?: string; - /** - * The name of the instance group. The name must be 1-63 characters long, and comply with RFC1035. - */ - name?: string; - /** - * Assigns a name to a port number. For example: {name: "http", port: 80} This allows the system to reference ports by the assigned name instead of a port number. Named ports can also contain multiple ports. For example: [{name: "http", port: 80},{name: "http", port: 8080}] Named ports apply to all instances in this instance group. - */ - namedPorts?: Schema$NamedPort[]; - /** - * The URL of the network to which all instances in the instance group belong. - */ - network?: string; - /** - * [Output Only] The URL of the region where the instance group is located (for regional resources). - */ - region?: string; - /** - * [Output Only] The URL for this instance group. The server generates this URL. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] The total number of instances in the instance group. - */ - size?: number; - /** - * [Output Only] The URL of the subnetwork to which all instances in the instance group belong. - */ - subnetwork?: string; - /** - * [Output Only] The URL of the zone where the instance group is located (for zonal resources). - */ - zone?: string; - } - export interface Schema$InstanceGroupAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InstanceGroupsScopedList resources. - */ - items?: {[key: string]: Schema$InstanceGroupsScopedList}; - /** - * [Output Only] The resource type, which is always compute#instanceGroupAggregatedList for aggregated lists of instance groups. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * A list of InstanceGroup resources. - */ - export interface Schema$InstanceGroupList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InstanceGroup resources. - */ - items?: Schema$InstanceGroup[]; - /** - * [Output Only] The resource type, which is always compute#instanceGroupList for instance group lists. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents a Managed Instance Group resource. An instance group is a collection of VM instances that you can manage as a single entity. For more information, read Instance groups. For zonal Managed Instance Group, use the instanceGroupManagers resource. For regional Managed Instance Group, use the regionInstanceGroupManagers resource. (== resource_for beta.instanceGroupManagers ==) (== resource_for v1.instanceGroupManagers ==) (== resource_for beta.regionInstanceGroupManagers ==) (== resource_for v1.regionInstanceGroupManagers ==) - */ - export interface Schema$InstanceGroupManager { - /** - * The autohealing policy for this managed instance group. You can specify only one value. - */ - autoHealingPolicies?: Schema$InstanceGroupManagerAutoHealingPolicy[]; - /** - * The base instance name to use for instances in this group. The value must be 1-58 characters long. Instances are named by appending a hyphen and a random four-character string to the base instance name. The base instance name must comply with RFC1035. - */ - baseInstanceName?: string; - /** - * [Output Only] The creation timestamp for this managed instance group in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * [Output Only] The list of instance actions and the number of instances in this managed instance group that are scheduled for each of those actions. - */ - currentActions?: Schema$InstanceGroupManagerActionsSummary; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * Policy specifying intended distribution of instances in regional managed instance group. - */ - distributionPolicy?: Schema$DistributionPolicy; - /** - * The action to perform in case of zone failure. Only one value is supported, NO_FAILOVER. The default is NO_FAILOVER. - */ - failoverAction?: string; - /** - * Fingerprint of this resource. This field may be used in optimistic locking. It will be ignored when inserting an InstanceGroupManager. An up-to-date fingerprint must be provided in order to update the InstanceGroupManager, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an InstanceGroupManager. - */ - fingerprint?: string; - /** - * [Output Only] A unique identifier for this resource type. The server generates this identifier. - */ - id?: string; - /** - * [Output Only] The URL of the Instance Group resource. - */ - instanceGroup?: string; - /** - * The URL of the instance template that is specified for this managed instance group. The group uses this template to create all new instances in the managed instance group. - */ - instanceTemplate?: string; - /** - * [Output Only] The resource type, which is always compute#instanceGroupManager for managed instance groups. - */ - kind?: string; - /** - * The name of the managed instance group. The name must be 1-63 characters long, and comply with RFC1035. - */ - name?: string; - /** - * Named ports configured for the Instance Groups complementary to this Instance Group Manager. - */ - namedPorts?: Schema$NamedPort[]; - /** - * [Deprecated] This field is deprecated and will be removed. Prefer using the status field instead. Please contact cloud-updater-feedback@google.com to leave feedback if your workload relies on this field. [Output Only] The list of instance actions and the number of instances in this managed instance group that are pending for each of those actions. - */ - pendingActions?: Schema$InstanceGroupManagerPendingActionsSummary; - /** - * [Output Only] The URL of the region where the managed instance group resides (for regional resources). - */ - region?: string; - /** - * [Output Only] The URL for this managed instance group. The server defines this URL. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * The service account to be used as credentials for all operations performed by the managed instance group on instances. The service accounts needs all permissions required to create and delete instances. By default, the service account {projectNumber}@cloudservices.gserviceaccount.com is used. - */ - serviceAccount?: string; - /** - * Stateful configuration for this Instanced Group Manager - */ - statefulPolicy?: Schema$StatefulPolicy; - /** - * [Output Only] The status of this managed instance group. - */ - status?: Schema$InstanceGroupManagerStatus; - /** - * The URLs for all TargetPool resources to which instances in the instanceGroup field are added. The target pools automatically apply to all of the instances in the managed instance group. - */ - targetPools?: string[]; - /** - * The target number of running instances for this managed instance group. Deleting or abandoning instances reduces this number. Resizing the group changes this number. - */ - targetSize?: number; - /** - * The update policy for this managed instance group. - */ - updatePolicy?: Schema$InstanceGroupManagerUpdatePolicy; - /** - * Specifies the instance templates used by this managed instance group to create instances. Each version is defined by an instanceTemplate and a name. Every version can appear at most once per instance group. This field overrides the top-level instanceTemplate field. Read more about the relationships between these fields. Exactly one version must leave the targetSize field unset. That version will be applied to all remaining instances. For more information, read about canary updates. - */ - versions?: Schema$InstanceGroupManagerVersion[]; - /** - * [Output Only] The URL of the zone where the managed instance group is located (for zonal resources). - */ - zone?: string; - } - export interface Schema$InstanceGroupManagerActionsSummary { - /** - * [Output Only] The total number of instances in the managed instance group that are scheduled to be abandoned. Abandoning an instance removes it from the managed instance group without deleting it. - */ - abandoning?: number; - /** - * [Output Only] The number of instances in the managed instance group that are scheduled to be created or are currently being created. If the group fails to create any of these instances, it tries again until it creates the instance successfully. If you have disabled creation retries, this field will not be populated; instead, the creatingWithoutRetries field will be populated. - */ - creating?: number; - /** - * [Output Only] The number of instances that the managed instance group will attempt to create. The group attempts to create each instance only once. If the group fails to create any of these instances, it decreases the group's targetSize value accordingly. - */ - creatingWithoutRetries?: number; - /** - * [Output Only] The number of instances in the managed instance group that are scheduled to be deleted or are currently being deleted. - */ - deleting?: number; - /** - * [Output Only] The number of instances in the managed instance group that are running and have no scheduled actions. - */ - none?: number; - /** - * [Output Only] The number of instances in the managed instance group that are scheduled to be recreated or are currently being being recreated. Recreating an instance deletes the existing root persistent disk and creates a new disk from the image that is defined in the instance template. - */ - recreating?: number; - /** - * [Output Only] The number of instances in the managed instance group that are being reconfigured with properties that do not require a restart or a recreate action. For example, setting or removing target pools for the instance. - */ - refreshing?: number; - /** - * [Output Only] The number of instances in the managed instance group that are scheduled to be restarted or are currently being restarted. - */ - restarting?: number; - /** - * [Output Only] The number of instances in the managed instance group that are being verified. See the managedInstances[].currentAction property in the listManagedInstances method documentation. - */ - verifying?: number; - } - export interface Schema$InstanceGroupManagerAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InstanceGroupManagersScopedList resources. - */ - items?: {[key: string]: Schema$InstanceGroupManagersScopedList}; - /** - * [Output Only] The resource type, which is always compute#instanceGroupManagerAggregatedList for an aggregated list of managed instance groups. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$InstanceGroupManagerAutoHealingPolicy { - /** - * The URL for the health check that signals autohealing. - */ - healthCheck?: string; - /** - * The number of seconds that the managed instance group waits before it applies autohealing policies to new instances or recently recreated instances. This initial delay allows instances to initialize and run their startup scripts before the instance group determines that they are UNHEALTHY. This prevents the managed instance group from recreating its instances prematurely. This value must be from range [0, 3600]. - */ - initialDelaySec?: number; - /** - * Maximum number of instances that can be unavailable when autohealing. When 'percent' is used, the value is rounded UP. The instance is considered available if all of the following conditions are satisfied: 1. Instance's status is RUNNING. 2. Instance's currentAction is NONE (in particular its liveness health check result was observed to be HEALTHY at least once as it passed VERIFYING). 3. There is no outgoing action on an instance triggered by IGM. By default, number of concurrently autohealed instances is smaller than the managed instance group target size. However, if a zonal managed instance group has only one instance, or a regional managed instance group has only one instance per zone, autohealing will recreate these instances when they become unhealthy. - */ - maxUnavailable?: Schema$FixedOrPercent; - } - /** - * [Output Only] A list of managed instance groups. - */ - export interface Schema$InstanceGroupManagerList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InstanceGroupManager resources. - */ - items?: Schema$InstanceGroupManager[]; - /** - * [Output Only] The resource type, which is always compute#instanceGroupManagerList for a list of managed instance groups. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$InstanceGroupManagerPendingActionsSummary { - /** - * [Deprecated] This field is deprecated and will be removed. Prefer using the status field instead. Please contact cloud-updater-feedback@google.com to leave feedback if your workload relies on this field. [Output Only] The number of instances in the managed instance group that are pending to be created. - */ - creating?: number; - /** - * [Deprecated] This field is deprecated and will be removed. Prefer using the status field instead. Please contact cloud-updater-feedback@google.com to leave feedback if your workload relies on this field. [Output Only] The number of instances in the managed instance group that are pending to be deleted. - */ - deleting?: number; - /** - * [Deprecated] This field is deprecated and will be removed. Prefer using the status field instead. Please contact cloud-updater-feedback@google.com to leave feedback if your workload relies on this field. [Output Only] The number of instances in the managed instance group that are pending to be recreated. - */ - recreating?: number; - /** - * [Deprecated] This field is deprecated and will be removed. Prefer using the status field instead. Please contact cloud-updater-feedback@google.com to leave feedback if your workload relies on this field. [Output Only] The number of instances in the managed instance group that are pending to be restarted. - */ - restarting?: number; - } - export interface Schema$InstanceGroupManagersAbandonInstancesRequest { - /** - * The URLs of one or more instances to abandon. This can be a full URL or a partial URL, such as zones/[ZONE]/instances/[INSTANCE_NAME]. - */ - instances?: string[]; - } - /** - * InstanceGroupManagers.applyUpdatesToInstances - */ - export interface Schema$InstanceGroupManagersApplyUpdatesRequest { - /** - * The list of URLs of one or more instances for which you want to apply updates. Each URL can be a full URL or a partial URL, such as zones/[ZONE]/instances/[INSTANCE_NAME]. - */ - instances?: string[]; - /** - * The maximal action that should be performed on the instances. By default REPLACE. This field is deprecated, please use most_disruptive_allowed_action. - */ - maximalAction?: string; - /** - * The minimal action that you want to perform on each instance during the update: - REPLACE: At minimum, delete the instance and create it again. - RESTART: Stop the instance and start it again. - REFRESH: Do not stop the instance. - NONE: Do not disrupt the instance at all. By default, the minimum action is NONE. If your update requires a more disruptive action than you set with this flag, the necessary action is performed to execute the update. - */ - minimalAction?: string; - /** - * The most disruptive action that you want to perform on each instance during the update: - REPLACE: Delete the instance and create it again. - RESTART: Stop the instance and start it again. - REFRESH: Do not stop the instance. - NONE: Do not disrupt the instance at all. By default, the most disruptive allowed action is REPLACE. If your update requires a more disruptive action than you set with this flag, the update request will fail. - */ - mostDisruptiveAllowedAction?: string; - } - /** - * InstanceGroupManagers.createInstances - */ - export interface Schema$InstanceGroupManagersCreateInstancesRequest { - /** - * [Required] List of specifications of per-instance configs. - */ - instances?: Schema$PerInstanceConfig[]; - } - export interface Schema$InstanceGroupManagersDeleteInstancesRequest { - /** - * The URLs of one or more instances to delete. This can be a full URL or a partial URL, such as zones/[ZONE]/instances/[INSTANCE_NAME]. - */ - instances?: string[]; - } - /** - * InstanceGroupManagers.deletePerInstanceConfigs - */ - export interface Schema$InstanceGroupManagersDeletePerInstanceConfigsReq { - /** - * The list of instances for which we want to delete per-instance configs on this managed instance group. - */ - instances?: string[]; - /** - * The list of instance names for which we want to delete per-instance configs on this managed instance group. - */ - names?: string[]; - } - export interface Schema$InstanceGroupManagersListErrorsResponse { - /** - * [Output Only] The list of errors of the managed instance group. - */ - items?: Schema$InstanceManagedByIgmError[]; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - } - export interface Schema$InstanceGroupManagersListManagedInstancesResponse { - /** - * [Output Only] The list of instances in the managed instance group. - */ - managedInstances?: Schema$ManagedInstance[]; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - } - export interface Schema$InstanceGroupManagersListPerInstanceConfigsResp { - /** - * [Output Only] The list of PerInstanceConfig. - */ - items?: Schema$PerInstanceConfig[]; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * InstanceGroupManagers.patchPerInstanceConfigs - */ - export interface Schema$InstanceGroupManagersPatchPerInstanceConfigsReq { - /** - * The list of per-instance configs to insert or patch on this managed instance group. - */ - perInstanceConfigs?: Schema$PerInstanceConfig[]; - } - export interface Schema$InstanceGroupManagersRecreateInstancesRequest { - /** - * The URLs of one or more instances to recreate. This can be a full URL or a partial URL, such as zones/[ZONE]/instances/[INSTANCE_NAME]. - */ - instances?: string[]; - } - export interface Schema$InstanceGroupManagersResizeAdvancedRequest { - /** - * If this flag is true, the managed instance group attempts to create all instances initiated by this resize request only once. If there is an error during creation, the managed instance group does not retry create this instance, and we will decrease the targetSize of the request instead. If the flag is false, the group attempts to recreate each instance continuously until it succeeds. This flag matters only in the first attempt of creation of an instance. After an instance is successfully created while this flag is enabled, the instance behaves the same way as all the other instances created with a regular resize request. In particular, if a running instance dies unexpectedly at a later time and needs to be recreated, this mode does not affect the recreation behavior in that scenario. This flag is applicable only to the current resize request. It does not influence other resize requests in any way. You can see which instances is being creating in which mode by calling the get or listManagedInstances API. - */ - noCreationRetries?: boolean; - /** - * The number of running instances that the managed instance group should maintain at any given time. The group automatically adds or removes instances to maintain the number of instances specified by this parameter. - */ - targetSize?: number; - } - export interface Schema$InstanceGroupManagersScopedList { - /** - * [Output Only] The list of managed instance groups that are contained in the specified project and zone. - */ - instanceGroupManagers?: Schema$InstanceGroupManager[]; - /** - * [Output Only] The warning that replaces the list of managed instance groups when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$InstanceGroupManagersSetAutoHealingRequest { - autoHealingPolicies?: Schema$InstanceGroupManagerAutoHealingPolicy[]; - } - export interface Schema$InstanceGroupManagersSetInstanceTemplateRequest { - /** - * The URL of the instance template that is specified for this managed instance group. The group uses this template to create all new instances in the managed instance group. - */ - instanceTemplate?: string; - } - export interface Schema$InstanceGroupManagersSetTargetPoolsRequest { - /** - * The fingerprint of the target pools information. Use this optional property to prevent conflicts when multiple users change the target pools settings concurrently. Obtain the fingerprint with the instanceGroupManagers.get method. Then, include the fingerprint in your request to ensure that you do not overwrite changes that were applied from another concurrent request. - */ - fingerprint?: string; - /** - * The list of target pool URLs that instances in this managed instance group belong to. The managed instance group applies these target pools to all of the instances in the group. Existing instances and new instances in the group all receive these target pool settings. - */ - targetPools?: string[]; - } - export interface Schema$InstanceGroupManagerStatus { - /** - * [Output Only] A bit indicating whether the managed instance group is in a stable state. A stable state means that: none of the instances in the managed instance group is currently undergoing any type of change (for example, creation, restart, or deletion); no future changes are scheduled for instances in the managed instance group; and the managed instance group itself is not being modified. - */ - isStable?: boolean; - /** - * [Output Only] Stateful status of the given Instance Group Manager. - */ - stateful?: Schema$InstanceGroupManagerStatusStateful; - /** - * [Output Only] A status of consistency of Instances' versions with their target version specified by version field on Instance Group Manager. - */ - versionTarget?: Schema$InstanceGroupManagerStatusVersionTarget; - } - export interface Schema$InstanceGroupManagerStatusStateful { - /** - * [Output Only] A bit indicating whether the managed instance group is stateful, i.e. has any disks in Stateful Policy or at least one per-instance config. This is determined based on the user intent, the group may be reported as not stateful even when there is still some preserved state on managed instances. - */ - isStateful?: boolean; - } - export interface Schema$InstanceGroupManagerStatusVersionTarget { - /** - * [Output Only] A bit indicating whether version target has been reached in this managed instance group, i.e. all instances are in their target version. Instances' target version are specified by version field on Instance Group Manager. - */ - isReached?: boolean; - } - /** - * InstanceGroupManagers.updatePerInstanceConfigs - */ - export interface Schema$InstanceGroupManagersUpdatePerInstanceConfigsReq { - /** - * The list of per-instance configs to insert or patch on this managed instance group. - */ - perInstanceConfigs?: Schema$PerInstanceConfig[]; - } - export interface Schema$InstanceGroupManagerUpdatePolicy { - instanceRedistributionType?: string; - /** - * The maximum number of instances that can be created above the specified targetSize during the update process. By default, a fixed value of 1 is used. This value can be either a fixed number or a percentage if the instance group has 10 or more instances. If you set a percentage, the number of instances will be rounded up if necessary. At least one of either maxSurge or maxUnavailable must be greater than 0. Learn more about maxSurge. - */ - maxSurge?: Schema$FixedOrPercent; - /** - * The maximum number of instances that can be unavailable during the update process. An instance is considered available if all of the following conditions are satisfied: - The instance's status is RUNNING. - If there is a health check on the instance group, the instance's liveness health check result must be HEALTHY at least once. If there is no health check on the group, then the instance only needs to have a status of RUNNING to be considered available. By default, a fixed value of 1 is used. This value can be either a fixed number or a percentage if the instance group has 10 or more instances. If you set a percentage, the number of instances will be rounded up if necessary. At least one of either maxSurge or maxUnavailable must be greater than 0. Learn more about maxUnavailable. - */ - maxUnavailable?: Schema$FixedOrPercent; - /** - * Minimal action to be taken on an instance. You can specify either RESTART to restart existing instances or REPLACE to delete and create new instances from the target template. If you specify a RESTART, the Updater will attempt to perform that action only. However, if the Updater determines that the minimal action you specify is not enough to perform the update, it might perform a more disruptive action. - */ - minimalAction?: string; - /** - * Minimum number of seconds to wait for after a newly created instance becomes available. This value must be from range [0, 3600]. - */ - minReadySec?: number; - /** - * What action should be used to replace instances. See minimal_action.REPLACE - */ - replacementMethod?: string; - /** - * The type of update process. You can specify either PROACTIVE so that the instance group manager proactively executes actions in order to bring instances to their target versions or OPPORTUNISTIC so that no action is proactively executed but the update will be performed as part of other actions (for example, resizes or recreateInstances calls). - */ - type?: string; - } - export interface Schema$InstanceGroupManagerVersion { - /** - * The URL of the instance template that is specified for this managed instance group. The group uses this template to create new instances in the managed instance group until the `targetSize` for this version is reached. - */ - instanceTemplate?: string; - /** - * Name of the version. Unique among all versions in the scope of this managed instance group. - */ - name?: string; - /** - * Tag describing the version. Used to trigger rollout of a target version even if instance_template remains unchanged. Deprecated in favor of 'name'. - */ - tag?: string; - /** - * Specifies the intended number of instances to be created from the instanceTemplate. The final number of instances created from the template will be equal to: - If expressed as a fixed number, the minimum of either targetSize.fixed or instanceGroupManager.targetSize is used. - if expressed as a percent, the targetSize would be (targetSize.percent/100 * InstanceGroupManager.targetSize) If there is a remainder, the number is rounded up. If unset, this version will update any remaining instances not updated by another version. Read Starting a canary update for more information. - */ - targetSize?: Schema$FixedOrPercent; - } - export interface Schema$InstanceGroupsAddInstancesRequest { - /** - * The list of instances to add to the instance group. - */ - instances?: Schema$InstanceReference[]; - } - export interface Schema$InstanceGroupsListInstances { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InstanceWithNamedPorts resources. - */ - items?: Schema$InstanceWithNamedPorts[]; - /** - * [Output Only] The resource type, which is always compute#instanceGroupsListInstances for the list of instances in the specified instance group. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$InstanceGroupsListInstancesRequest { - /** - * A filter for the state of the instances in the instance group. Valid options are ALL or RUNNING. If you do not specify this parameter the list includes all instances regardless of their state. - */ - instanceState?: string; - } - export interface Schema$InstanceGroupsRemoveInstancesRequest { - /** - * The list of instances to remove from the instance group. - */ - instances?: Schema$InstanceReference[]; - } - export interface Schema$InstanceGroupsScopedList { - /** - * [Output Only] The list of instance groups that are contained in this scope. - */ - instanceGroups?: Schema$InstanceGroup[]; - /** - * [Output Only] An informational warning that replaces the list of instance groups when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$InstanceGroupsSetNamedPortsRequest { - /** - * The fingerprint of the named ports information for this instance group. Use this optional property to prevent conflicts when multiple users change the named ports settings concurrently. Obtain the fingerprint with the instanceGroups.get method. Then, include the fingerprint in your request to ensure that you do not overwrite changes that were applied from another concurrent request. A request with an incorrect fingerprint will fail with error 412 conditionNotMet. - */ - fingerprint?: string; - /** - * The list of named ports to set for this instance group. - */ - namedPorts?: Schema$NamedPort[]; - } - /** - * Contains a list of instances. - */ - export interface Schema$InstanceList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Instance resources. - */ - items?: Schema$Instance[]; - /** - * [Output Only] Type of resource. Always compute#instanceList for lists of Instance resources. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of instance referrers. - */ - export interface Schema$InstanceListReferrers { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Reference resources. - */ - items?: Schema$Reference[]; - /** - * [Output Only] Type of resource. Always compute#instanceListReferrers for lists of Instance referrers. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$InstanceManagedByIgmError { - /** - * [Output Only] Contents of the error. - */ - error?: Schema$InstanceManagedByIgmErrorManagedInstanceError; - /** - * [Output Only] Details of the instance action that triggered this error. May be null, if the error was not caused by an action on an instance. This field is optional. - */ - instanceActionDetails?: Schema$InstanceManagedByIgmErrorInstanceActionDetails; - /** - * [Output Only] The time that this error occurred. This value is in RFC3339 text format. - */ - timestamp?: string; - } - export interface Schema$InstanceManagedByIgmErrorInstanceActionDetails { - /** - * [Output Only] Action that managed instance group was executing on the instance when the error occurred. Possible values: - */ - action?: string; - /** - * [Output Only] The URL of the instance. The URL can be set even if the instance has not yet been created. - */ - instance?: string; - /** - * [Output Only] Version this instance was created from, or was being created from, but the creation failed. Corresponds to one of the versions that were set on the Instance Group Manager resource at the time this instance was being created. - */ - version?: Schema$ManagedInstanceVersion; - } - export interface Schema$InstanceManagedByIgmErrorManagedInstanceError { - /** - * [Output Only] Error code. - */ - code?: string; - /** - * [Output Only] Error message. - */ - message?: string; - } - export interface Schema$InstanceMoveRequest { - /** - * The URL of the destination zone to move the instance. This can be a full or partial URL. For example, the following are all valid URLs to a zone: - https://www.googleapis.com/compute/v1/projects/project/zones/zone - projects/project/zones/zone - zones/zone - */ - destinationZone?: string; - /** - * The URL of the target instance to move. This can be a full or partial URL. For example, the following are all valid URLs to an instance: - https://www.googleapis.com/compute/v1/projects/project/zones/zone/instances/instance - projects/project/zones/zone/instances/instance - zones/zone/instances/instance - */ - targetInstance?: string; - } - export interface Schema$InstanceProperties { - /** - * Enables instances created based on this template to send packets with source IP addresses other than their own and receive packets with destination IP addresses other than their own. If these instances will be used as an IP gateway or it will be set as the next-hop in a Route resource, specify true. If unsure, leave this set to false. See the Enable IP forwarding documentation for more information. - */ - canIpForward?: boolean; - /** - * An optional text description for the instances that are created from this instance template. - */ - description?: string; - /** - * An array of disks that are associated with the instances that are created from this template. - */ - disks?: Schema$AttachedDisk[]; - /** - * Display Device properties to enable support for remote display products like: Teradici, VNC and TeamViewer - */ - displayDevice?: Schema$DisplayDevice; - /** - * A list of guest accelerator cards' type and count to use for instances created from the instance template. - */ - guestAccelerators?: Schema$AcceleratorConfig[]; - /** - * Labels to apply to instances that are created from this template. - */ - labels?: {[key: string]: string}; - /** - * The machine type to use for instances that are created from this template. - */ - machineType?: string; - /** - * The metadata key/value pairs to assign to instances that are created from this template. These pairs can consist of custom metadata or predefined keys. See Project and instance metadata for more information. - */ - metadata?: Schema$Metadata; - /** - * Minimum cpu/platform to be used by this instance. The instance may be scheduled on the specified or newer cpu/platform. Applicable values are the friendly names of CPU platforms, such as minCpuPlatform: "Intel Haswell" or minCpuPlatform: "Intel Sandy Bridge". For more information, read Specifying a Minimum CPU Platform. - */ - minCpuPlatform?: string; - /** - * An array of network access configurations for this interface. - */ - networkInterfaces?: Schema$NetworkInterface[]; - /** - * Specifies the reservations that this instance can consume from. - */ - reservationAffinity?: Schema$ReservationAffinity; - /** - * Specifies the scheduling options for the instances that are created from this template. - */ - scheduling?: Schema$Scheduling; - /** - * A list of service accounts with specified scopes. Access tokens for these service accounts are available to the instances that are created from this template. Use metadata queries to obtain the access tokens for these instances. - */ - serviceAccounts?: Schema$ServiceAccount[]; - shieldedInstanceConfig?: Schema$ShieldedInstanceConfig; - /** - * Specifies the Shielded VM options for the instances that are created from this template. - */ - shieldedVmConfig?: Schema$ShieldedVmConfig; - /** - * A list of tags to apply to the instances that are created from this template. The tags identify valid sources or targets for network firewalls. The setTags method can modify this list of tags. Each tag within the list must comply with RFC1035. - */ - tags?: Schema$Tags; - } - export interface Schema$InstanceReference { - /** - * The URL for a specific instance. - */ - instance?: string; - } - export interface Schema$InstancesAddResourcePoliciesRequest { - /** - * Resource policies to be added to this instance. - */ - resourcePolicies?: string[]; - } - export interface Schema$InstancesGetEffectiveFirewallsResponse { - /** - * Effective firewalls on the instance. - */ - firewalls?: Schema$Firewall[]; - /** - * Effective firewalls from organization policies. - */ - organizationFirewalls?: Schema$InstancesGetEffectiveFirewallsResponseOrganizationFirewallPolicy[]; - } - /** - * A pruned SecurityPolicy containing ID and any applicable firewall rules. - */ - export interface Schema$InstancesGetEffectiveFirewallsResponseOrganizationFirewallPolicy { - /** - * The unique identifier for the security policy. This identifier is defined by the server. - */ - id?: string; - /** - * The rules that apply to the network. - */ - rules?: Schema$SecurityPolicyRule[]; - } - export interface Schema$InstancesRemoveResourcePoliciesRequest { - /** - * Resource policies to be removed from this instance. - */ - resourcePolicies?: string[]; - } - export interface Schema$InstancesResumeRequest { - /** - * Array of disks associated with this instance that are protected with a customer-supplied encryption key. In order to resume the instance, the disk url and its corresponding key must be provided. If the disk is not protected with a customer-supplied encryption key it should not be specified. - */ - disks?: Schema$CustomerEncryptionKeyProtectedDisk[]; - /** - * Decrypts data associated with an instance that is protected with a customer-supplied encryption key. If the instance you are starting is protected with a customer-supplied encryption key, the correct key must be provided otherwise the instance resume will not succeed. - */ - instanceEncryptionKey?: Schema$CustomerEncryptionKey; - } - export interface Schema$InstancesScopedList { - /** - * [Output Only] A list of instances contained in this scope. - */ - instances?: Schema$Instance[]; - /** - * [Output Only] Informational warning which replaces the list of instances when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$InstancesSetLabelsRequest { - /** - * Fingerprint of the previous set of labels for this resource, used to prevent conflicts. Provide the latest fingerprint value when making a request to add or change labels. - */ - labelFingerprint?: string; - labels?: {[key: string]: string}; - } - export interface Schema$InstancesSetMachineResourcesRequest { - /** - * A list of the type and count of accelerator cards attached to the instance. - */ - guestAccelerators?: Schema$AcceleratorConfig[]; - } - export interface Schema$InstancesSetMachineTypeRequest { - /** - * Full or partial URL of the machine type resource. See Machine Types for a full list of machine types. For example: zones/us-central1-f/machineTypes/n1-standard-1 - */ - machineType?: string; - } - export interface Schema$InstancesSetMinCpuPlatformRequest { - /** - * Minimum cpu/platform this instance should be started at. - */ - minCpuPlatform?: string; - } - export interface Schema$InstancesSetNameRequest { - /** - * The current name of this resource, used to prevent conflicts. Provide the latest name when making a request to change name. - */ - currentName?: string; - /** - * The name to be applied to the instance. Needs to be RFC 1035 compliant. - */ - name?: string; - } - export interface Schema$InstancesSetServiceAccountRequest { - /** - * Email address of the service account. - */ - email?: string; - /** - * The list of scopes to be made available for this service account. - */ - scopes?: string[]; - } - export interface Schema$InstancesStartWithEncryptionKeyRequest { - /** - * Array of disks associated with this instance that are protected with a customer-supplied encryption key. In order to start the instance, the disk url and its corresponding key must be provided. If the disk is not protected with a customer-supplied encryption key it should not be specified. - */ - disks?: Schema$CustomerEncryptionKeyProtectedDisk[]; - /** - * Decrypts data associated with an instance that is protected with a customer-supplied encryption key. If the instance you are starting is protected with a customer-supplied encryption key, the correct key must be provided otherwise the instance start will not succeed. - */ - instanceEncryptionKey?: Schema$CustomerEncryptionKey; - } - /** - * Represents an Instance Template resource. You can use instance templates to create VM instances and managed instance groups. For more information, read Instance Templates. (== resource_for beta.instanceTemplates ==) (== resource_for v1.instanceTemplates ==) - */ - export interface Schema$InstanceTemplate { - /** - * [Output Only] The creation timestamp for this instance template in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] A unique identifier for this instance template. The server defines this identifier. - */ - id?: string; - /** - * [Output Only] The resource type, which is always compute#instanceTemplate for instance templates. - */ - kind?: string; - /** - * Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * The instance properties for this instance template. - */ - properties?: Schema$InstanceProperties; - /** - * [Output Only] The URL for this instance template. The server defines this URL. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * The source instance used to create the template. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone/instances/instance - projects/project/zones/zone/instances/instance - */ - sourceInstance?: string; - /** - * The source instance params to use to create this instance template. - */ - sourceInstanceParams?: Schema$SourceInstanceParams; - } - /** - * A list of instance templates. - */ - export interface Schema$InstanceTemplateList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InstanceTemplate resources. - */ - items?: Schema$InstanceTemplate[]; - /** - * [Output Only] The resource type, which is always compute#instanceTemplatesListResponse for instance template lists. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$InstanceWithNamedPorts { - /** - * [Output Only] The URL of the instance. - */ - instance?: string; - /** - * [Output Only] The named ports that belong to this instance group. - */ - namedPorts?: Schema$NamedPort[]; - /** - * [Output Only] The status of the instance. - */ - status?: string; - } - /** - * HttpRouteRuleMatch criteria for field values that must stay within the specified integer range. - */ - export interface Schema$Int64RangeMatch { - /** - * The end of the range (exclusive) in signed long integer format. - */ - rangeEnd?: string; - /** - * The start of the range (inclusive) in signed long integer format. - */ - rangeStart?: string; - } - /** - * Represents an Interconnect resource. An Interconnect resource is a dedicated connection between the GCP network and your on-premises network. For more information, read the Dedicated Interconnect Overview. (== resource_for v1.interconnects ==) (== resource_for beta.interconnects ==) - */ - export interface Schema$Interconnect { - /** - * Administrative status of the interconnect. When this is set to true, the Interconnect is functional and can carry traffic. When set to false, no packets can be carried over the interconnect and no BGP routes are exchanged over it. By default, the status is set to true. - */ - adminEnabled?: boolean; - /** - * [Output Only] A list of CircuitInfo objects, that describe the individual circuits in this LAG. - */ - circuitInfos?: Schema$InterconnectCircuitInfo[]; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * Customer name, to put in the Letter of Authorization as the party authorized to request a crossconnect. - */ - customerName?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] A list of outages expected for this Interconnect. - */ - expectedOutages?: Schema$InterconnectOutageNotification[]; - /** - * [Output Only] IP address configured on the Google side of the Interconnect link. This can be used only for ping tests. - */ - googleIpAddress?: string; - /** - * [Output Only] Google reference ID to be used when raising support tickets with Google or otherwise to debug backend connectivity issues. - */ - googleReferenceId?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] A list of the URLs of all InterconnectAttachments configured to use this Interconnect. - */ - interconnectAttachments?: string[]; - /** - * Type of interconnect, which can take one of the following values: - PARTNER: A partner-managed interconnection shared between customers though a partner. - DEDICATED: A dedicated physical interconnection with the customer. Note that a value IT_PRIVATE has been deprecated in favor of DEDICATED. - */ - interconnectType?: string; - /** - * [Output Only] Type of the resource. Always compute#interconnect for interconnects. - */ - kind?: string; - /** - * A fingerprint for the labels being applied to this Interconnect, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an Interconnect. - */ - labelFingerprint?: string; - /** - * Labels to apply to this Interconnect resource. These can be later modified by the setLabels method. Each label key/value must comply with RFC1035. Label values may be empty. - */ - labels?: {[key: string]: string}; - /** - * Type of link requested, which can take one of the following values: - LINK_TYPE_ETHERNET_10G_LR: A 10G Ethernet with LR optics - LINK_TYPE_ETHERNET_100G_LR: A 100G Ethernet with LR optics. Note that this field indicates the speed of each of the links in the bundle, not the speed of the entire bundle. - */ - linkType?: string; - /** - * URL of the InterconnectLocation object that represents where this connection is to be provisioned. - */ - location?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * Email address to contact the customer NOC for operations and maintenance notifications regarding this Interconnect. If specified, this will be used for notifications in addition to all other forms described, such as Stackdriver logs alerting and Cloud Notifications. - */ - nocContactEmail?: string; - /** - * [Output Only] The current status of this Interconnect's functionality, which can take one of the following values: - OS_ACTIVE: A valid Interconnect, which is turned up and is ready to use. Attachments may be provisioned on this Interconnect. - OS_UNPROVISIONED: An Interconnect that has not completed turnup. No attachments may be provisioned on this Interconnect. - OS_UNDER_MAINTENANCE: An Interconnect that is undergoing internal maintenance. No attachments may be provisioned or updated on this Interconnect. - */ - operationalStatus?: string; - /** - * [Output Only] IP address configured on the customer side of the Interconnect link. The customer should configure this IP address during turnup when prompted by Google NOC. This can be used only for ping tests. - */ - peerIpAddress?: string; - /** - * [Output Only] Number of links actually provisioned in this interconnect. - */ - provisionedLinkCount?: number; - /** - * Target number of physical links in the link bundle, as requested by the customer. - */ - requestedLinkCount?: number; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] The current state of Interconnect functionality, which can take one of the following values: - ACTIVE: The Interconnect is valid, turned up and ready to use. Attachments may be provisioned on this Interconnect. - UNPROVISIONED: The Interconnect has not completed turnup. No attachments may be provisioned on this Interconnect. - UNDER_MAINTENANCE: The Interconnect is undergoing internal maintenance. No attachments may be provisioned or updated on this Interconnect. - */ - state?: string; - } - /** - * Represents an Interconnect Attachment (VLAN) resource. You can use Interconnect attachments (VLANS) to connect your Virtual Private Cloud networks to your on-premises networks through an Interconnect. For more information, read Creating VLAN Attachments. (== resource_for beta.interconnectAttachments ==) (== resource_for v1.interconnectAttachments ==) - */ - export interface Schema$InterconnectAttachment { - /** - * Determines whether this Attachment will carry packets. Not present for PARTNER_PROVIDER. - */ - adminEnabled?: boolean; - /** - * Provisioned bandwidth capacity for the interconnect attachment. For attachments of type DEDICATED, the user can set the bandwidth. For attachments of type PARTNER, the Google Partner that is operating the interconnect must set the bandwidth. Output only for PARTNER type, mutable for PARTNER_PROVIDER and DEDICATED, and can take one of the following values: - BPS_50M: 50 Mbit/s - BPS_100M: 100 Mbit/s - BPS_200M: 200 Mbit/s - BPS_300M: 300 Mbit/s - BPS_400M: 400 Mbit/s - BPS_500M: 500 Mbit/s - BPS_1G: 1 Gbit/s - BPS_2G: 2 Gbit/s - BPS_5G: 5 Gbit/s - BPS_10G: 10 Gbit/s - */ - bandwidth?: string; - /** - * Up to 16 candidate prefixes that can be used to restrict the allocation of cloudRouterIpAddress and customerRouterIpAddress for this attachment. All prefixes must be within link-local address space (169.254.0.0/16) and must be /29 or shorter (/28, /27, etc). Google will attempt to select an unused /29 from the supplied candidate prefix(es). The request will fail if all possible /29s are in use on Google?s edge. If not supplied, Google will randomly select an unused /29 from all of link-local space. - */ - candidateSubnets?: string[]; - /** - * [Output Only] IPv4 address + prefix length to be configured on Cloud Router Interface for this interconnect attachment. - */ - cloudRouterIpAddress?: string; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * [Output Only] IPv4 address + prefix length to be configured on the customer router subinterface for this interconnect attachment. - */ - customerRouterIpAddress?: string; - /** - * An optional description of this resource. - */ - description?: string; - /** - * Desired availability domain for the attachment. Only available for type PARTNER, at creation time, and can take one of the following values: - AVAILABILITY_DOMAIN_ANY - AVAILABILITY_DOMAIN_1 - AVAILABILITY_DOMAIN_2 For improved reliability, customers should configure a pair of attachments, one per availability domain. The selected availability domain will be provided to the Partner via the pairing key, so that the provisioned circuit will lie in the specified domain. If not specified, the value will default to AVAILABILITY_DOMAIN_ANY. - */ - edgeAvailabilityDomain?: string; - /** - * [Output Only] Google reference ID, to be used when raising support tickets with Google or otherwise to debug backend connectivity issues. [Deprecated] This field is not used. - */ - googleReferenceId?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * URL of the underlying Interconnect object that this attachment's traffic will traverse through. - */ - interconnect?: string; - /** - * [Output Only] Type of the resource. Always compute#interconnectAttachment for interconnect attachments. - */ - kind?: string; - /** - * A fingerprint for the labels being applied to this InterconnectAttachment, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an InterconnectAttachment. - */ - labelFingerprint?: string; - /** - * Labels to apply to this InterconnectAttachment resource. These can be later modified by the setLabels method. Each label key/value must comply with RFC1035. Label values may be empty. - */ - labels?: {[key: string]: string}; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * [Output Only] The current status of whether or not this interconnect attachment is functional, which can take one of the following values: - OS_ACTIVE: The attachment has been turned up and is ready to use. - OS_UNPROVISIONED: The attachment is not ready to use yet, because turnup is not complete. - */ - operationalStatus?: string; - /** - * [Output only for type PARTNER. Input only for PARTNER_PROVIDER. Not present for DEDICATED]. The opaque identifier of an PARTNER attachment used to initiate provisioning with a selected partner. Of the form "XXXXX/region/domain" - */ - pairingKey?: string; - /** - * Optional BGP ASN for the router supplied by a Layer 3 Partner if they configured BGP on behalf of the customer. Output only for PARTNER type, input only for PARTNER_PROVIDER, not available for DEDICATED. - */ - partnerAsn?: string; - /** - * Informational metadata about Partner attachments from Partners to display to customers. Output only for for PARTNER type, mutable for PARTNER_PROVIDER, not available for DEDICATED. - */ - partnerMetadata?: Schema$InterconnectAttachmentPartnerMetadata; - /** - * [Output Only] Information specific to an InterconnectAttachment. This property is populated if the interconnect that this is attached to is of type DEDICATED. - */ - privateInterconnectInfo?: Schema$InterconnectAttachmentPrivateInfo; - /** - * [Output Only] URL of the region where the regional interconnect attachment resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - region?: string; - /** - * URL of the Cloud Router to be used for dynamic routing. This router must be in the same region as this InterconnectAttachment. The InterconnectAttachment will automatically connect the Interconnect to the network & region within which the Cloud Router is configured. - */ - router?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] The current state of this attachment's functionality. Enum values ACTIVE and UNPROVISIONED are shared by DEDICATED/PRIVATE, PARTNER, and PARTNER_PROVIDER interconnect attachments, while enum values PENDING_PARTNER, PARTNER_REQUEST_RECEIVED, and PENDING_CUSTOMER are used for only PARTNER and PARTNER_PROVIDER interconnect attachments. This state can take one of the following values: - ACTIVE: The attachment has been turned up and is ready to use. - UNPROVISIONED: The attachment is not ready to use yet, because turnup is not complete. - PENDING_PARTNER: A newly-created PARTNER attachment that has not yet been configured on the Partner side. - PARTNER_REQUEST_RECEIVED: A PARTNER attachment is in the process of provisioning after a PARTNER_PROVIDER attachment was created that references it. - PENDING_CUSTOMER: A PARTNER or PARTNER_PROVIDER attachment that is waiting for a customer to activate it. - DEFUNCT: The attachment was deleted externally and is no longer functional. This could be because the associated Interconnect was removed, or because the other side of a Partner attachment was deleted. - */ - state?: string; - /** - * The type of interconnect attachment this is, which can take one of the following values: - DEDICATED: an attachment to a Dedicated Interconnect. - PARTNER: an attachment to a Partner Interconnect, created by the customer. - PARTNER_PROVIDER: an attachment to a Partner Interconnect, created by the partner. - */ - type?: string; - /** - * The IEEE 802.1Q VLAN tag for this attachment, in the range 2-4094. Only specified at creation time. - */ - vlanTag8021q?: number; - } - export interface Schema$InterconnectAttachmentAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InterconnectAttachmentsScopedList resources. - */ - items?: {[key: string]: Schema$InterconnectAttachmentsScopedList}; - /** - * [Output Only] Type of resource. Always compute#interconnectAttachmentAggregatedList for aggregated lists of interconnect attachments. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Response to the list request, and contains a list of interconnect attachments. - */ - export interface Schema$InterconnectAttachmentList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InterconnectAttachment resources. - */ - items?: Schema$InterconnectAttachment[]; - /** - * [Output Only] Type of resource. Always compute#interconnectAttachmentList for lists of interconnect attachments. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Informational metadata about Partner attachments from Partners to display to customers. These fields are propagated from PARTNER_PROVIDER attachments to their corresponding PARTNER attachments. - */ - export interface Schema$InterconnectAttachmentPartnerMetadata { - /** - * Plain text name of the Interconnect this attachment is connected to, as displayed in the Partner?s portal. For instance "Chicago 1". This value may be validated to match approved Partner values. - */ - interconnectName?: string; - /** - * Plain text name of the Partner providing this attachment. This value may be validated to match approved Partner values. - */ - partnerName?: string; - /** - * URL of the Partner?s portal for this Attachment. Partners may customise this to be a deep link to the specific resource on the Partner portal. This value may be validated to match approved Partner values. - */ - portalUrl?: string; - } - /** - * Information for an interconnect attachment when this belongs to an interconnect of type DEDICATED. - */ - export interface Schema$InterconnectAttachmentPrivateInfo { - /** - * [Output Only] 802.1q encapsulation tag to be used for traffic between Google and the customer, going to and from this network and region. - */ - tag8021q?: number; - } - export interface Schema$InterconnectAttachmentsScopedList { - /** - * A list of interconnect attachments contained in this scope. - */ - interconnectAttachments?: Schema$InterconnectAttachment[]; - /** - * Informational warning which replaces the list of addresses when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Describes a single physical circuit between the Customer and Google. CircuitInfo objects are created by Google, so all fields are output only. Next id: 4 - */ - export interface Schema$InterconnectCircuitInfo { - /** - * Customer-side demarc ID for this circuit. - */ - customerDemarcId?: string; - /** - * Google-assigned unique ID for this circuit. Assigned at circuit turn-up. - */ - googleCircuitId?: string; - /** - * Google-side demarc ID for this circuit. Assigned at circuit turn-up and provided by Google to the customer in the LOA. - */ - googleDemarcId?: string; - } - /** - * Diagnostics information about interconnect, contains detailed and current technical information about Google?s side of the connection. - */ - export interface Schema$InterconnectDiagnostics { - /** - * A list of InterconnectDiagnostics.ARPEntry objects, describing individual neighbors currently seen by the Google router in the ARP cache for the Interconnect. This will be empty when the Interconnect is not bundled. - */ - arpCaches?: Schema$InterconnectDiagnosticsARPEntry[]; - /** - * A list of InterconnectDiagnostics.LinkStatus objects, describing the status for each link on the Interconnect. - */ - links?: Schema$InterconnectDiagnosticsLinkStatus[]; - /** - * The MAC address of the Interconnect's bundle interface. - */ - macAddress?: string; - } - /** - * Describing the ARP neighbor entries seen on this link - */ - export interface Schema$InterconnectDiagnosticsARPEntry { - /** - * The IP address of this ARP neighbor. - */ - ipAddress?: string; - /** - * The MAC address of this ARP neighbor. - */ - macAddress?: string; - } - export interface Schema$InterconnectDiagnosticsLinkLACPStatus { - /** - * System ID of the port on Google?s side of the LACP exchange. - */ - googleSystemId?: string; - /** - * System ID of the port on the neighbor?s side of the LACP exchange. - */ - neighborSystemId?: string; - /** - * The state of a LACP link, which can take one of the following values: - ACTIVE: The link is configured and active within the bundle. - DETACHED: The link is not configured within the bundle. This means that the rest of the object should be empty. - */ - state?: string; - } - export interface Schema$InterconnectDiagnosticsLinkOpticalPower { - /** - * The status of the current value when compared to the warning and alarm levels for the receiving or transmitting transceiver. Possible states include: - OK: The value has not crossed a warning threshold. - LOW_WARNING: The value has crossed below the low warning threshold. - HIGH_WARNING: The value has crossed above the high warning threshold. - LOW_ALARM: The value has crossed below the low alarm threshold. - HIGH_ALARM: The value has crossed above the high alarm threshold. - */ - state?: string; - /** - * Value of the current receiving or transmitting optical power, read in dBm. Take a known good optical value, give it a 10% margin and trigger warnings relative to that value. In general, a -7dBm warning and a -11dBm alarm are good optical value estimates for most links. - */ - value?: number; - } - export interface Schema$InterconnectDiagnosticsLinkStatus { - /** - * A list of InterconnectDiagnostics.ARPEntry objects, describing the ARP neighbor entries seen on this link. This will be empty if the link is bundled - */ - arpCaches?: Schema$InterconnectDiagnosticsARPEntry[]; - /** - * The unique ID for this link assigned during turn up by Google. - */ - circuitId?: string; - /** - * The Demarc address assigned by Google and provided in the LoA. - */ - googleDemarc?: string; - lacpStatus?: Schema$InterconnectDiagnosticsLinkLACPStatus; - /** - * An InterconnectDiagnostics.LinkOpticalPower object, describing the current value and status of the received light level. - */ - receivingOpticalPower?: Schema$InterconnectDiagnosticsLinkOpticalPower; - /** - * An InterconnectDiagnostics.LinkOpticalPower object, describing the current value and status of the transmitted light level. - */ - transmittingOpticalPower?: Schema$InterconnectDiagnosticsLinkOpticalPower; - } - /** - * Response to the list request, and contains a list of interconnects. - */ - export interface Schema$InterconnectList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Interconnect resources. - */ - items?: Schema$Interconnect[]; - /** - * [Output Only] Type of resource. Always compute#interconnectList for lists of interconnects. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents an Interconnect Attachment (VLAN) Location resource. You can use this resource to find location details about an Interconnect attachment (VLAN). For more information about interconnect attachments, read Creating VLAN Attachments. - */ - export interface Schema$InterconnectLocation { - /** - * [Output Only] The postal address of the Point of Presence, each line in the address is separated by a newline character. - */ - address?: string; - /** - * [Output Only] Availability zone for this InterconnectLocation. Within a metropolitan area (metro), maintenance will not be simultaneously scheduled in more than one availability zone. Example: "zone1" or "zone2". - */ - availabilityZone?: string; - /** - * [Output Only] Metropolitan area designator that indicates which city an interconnect is located. For example: "Chicago, IL", "Amsterdam, Netherlands". - */ - city?: string; - /** - * [Output Only] Continent for this location, which can take one of the following values: - AFRICA - ASIA_PAC - EUROPE - NORTH_AMERICA - SOUTH_AMERICA - */ - continent?: string; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * [Output Only] An optional description of the resource. - */ - description?: string; - /** - * [Output Only] The name of the provider for this facility (e.g., EQUINIX). - */ - facilityProvider?: string; - /** - * [Output Only] A provider-assigned Identifier for this facility (e.g., Ashburn-DC1). - */ - facilityProviderFacilityId?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#interconnectLocation for interconnect locations. - */ - kind?: string; - /** - * [Output Only] Name of the resource. - */ - name?: string; - /** - * [Output Only] The peeringdb identifier for this facility (corresponding with a netfac type in peeringdb). - */ - peeringdbFacilityId?: string; - /** - * [Output Only] A list of InterconnectLocation.RegionInfo objects, that describe parameters pertaining to the relation between this InterconnectLocation and various Google Cloud regions. - */ - regionInfos?: Schema$InterconnectLocationRegionInfo[]; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] The status of this InterconnectLocation, which can take one of the following values: - CLOSED: The InterconnectLocation is closed and is unavailable for provisioning new Interconnects. - AVAILABLE: The InterconnectLocation is available for provisioning new Interconnects. - */ - status?: string; - } - /** - * Response to the list request, and contains a list of interconnect locations. - */ - export interface Schema$InterconnectLocationList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InterconnectLocation resources. - */ - items?: Schema$InterconnectLocation[]; - /** - * [Output Only] Type of resource. Always compute#interconnectLocationList for lists of interconnect locations. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Information about any potential InterconnectAttachments between an Interconnect at a specific InterconnectLocation, and a specific Cloud Region. - */ - export interface Schema$InterconnectLocationRegionInfo { - /** - * Expected round-trip time in milliseconds, from this InterconnectLocation to a VM in this region. - */ - expectedRttMs?: string; - /** - * Identifies the network presence of this location. - */ - locationPresence?: string; - /** - * URL for the region of this location. - */ - region?: string; - } - /** - * Description of a planned outage on this Interconnect. Next id: 9 - */ - export interface Schema$InterconnectOutageNotification { - /** - * If issue_type is IT_PARTIAL_OUTAGE, a list of the Google-side circuit IDs that will be affected. - */ - affectedCircuits?: string[]; - /** - * A description about the purpose of the outage. - */ - description?: string; - /** - * Scheduled end time for the outage (milliseconds since Unix epoch). - */ - endTime?: string; - /** - * Form this outage is expected to take, which can take one of the following values: - OUTAGE: The Interconnect may be completely out of service for some or all of the specified window. - PARTIAL_OUTAGE: Some circuits comprising the Interconnect as a whole should remain up, but with reduced bandwidth. Note that the versions of this enum prefixed with "IT_" have been deprecated in favor of the unprefixed values. - */ - issueType?: string; - /** - * Unique identifier for this outage notification. - */ - name?: string; - /** - * The party that generated this notification, which can take the following value: - GOOGLE: this notification as generated by Google. Note that the value of NSRC_GOOGLE has been deprecated in favor of GOOGLE. - */ - source?: string; - /** - * Scheduled start time for the outage (milliseconds since Unix epoch). - */ - startTime?: string; - /** - * State of this notification, which can take one of the following values: - ACTIVE: This outage notification is active. The event could be in the past, present, or future. See start_time and end_time for scheduling. - CANCELLED: The outage associated with this notification was cancelled before the outage was due to start. Note that the versions of this enum prefixed with "NS_" have been deprecated in favor of the unprefixed values. - */ - state?: string; - } - /** - * Response for the InterconnectsGetDiagnosticsRequest. - */ - export interface Schema$InterconnectsGetDiagnosticsResponse { - result?: Schema$InterconnectDiagnostics; - } - export interface Schema$InternalIpAddress { - /** - * IP CIDR address or range. - */ - cidr?: string; - /** - * The owner of the internal IP address. - */ - owner?: string; - /** - * The purpose of the internal IP address if applicable. - */ - purpose?: string; - /** - * The region of the internal IP address if applicable. - */ - region?: string; - /** - * The type of the internal IP address. - */ - type?: string; - } - export interface Schema$InternalIpOwner { - /** - * IP CIDR range being owned. - */ - ipCidrRange?: string; - /** - * URLs of the IP owners of the IP CIDR range. - */ - owners?: string[]; - /** - * Whether this IP CIDR range is reserved for system use. - */ - systemOwned?: boolean; - } - export interface Schema$IpAddressesList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InternalIpAddress resources. - */ - items?: Schema$InternalIpAddress[]; - /** - * [Output Only] Type of resource. Always compute#ipAddressesList for IP addresses lists. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of IP owners. - */ - export interface Schema$IpOwnerList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InternalIpOwner resources. - */ - items?: Schema$InternalIpOwner[]; - /** - * [Output Only] Type of resource. Always compute#ipOwnerList for lists of IP owners. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * JWT configuration for origin authentication. - */ - export interface Schema$Jwt { - /** - * A JWT containing any of these audiences will be accepted. The service name will be accepted if audiences is empty. Examples: bookstore_android.apps.googleusercontent.com, bookstore_web.apps.googleusercontent.com - */ - audiences?: string[]; - /** - * Identifies the issuer that issued the JWT, which is usually a URL or an email address. Examples: https://securetoken.google.com, 1234567-compute@developer.gserviceaccount.com - */ - issuer?: string; - /** - * The provider?s public key set to validate the signature of the JWT. - */ - jwksPublicKeys?: string; - /** - * jwt_headers and jwt_params define where to extract the JWT from an HTTP request. If no explicit location is specified, the following default locations are tried in order: 1. The Authorization header using the Bearer schema. See `here `_. Example: Authorization: Bearer . 2. `access_token` query parameter. See `this `_ Multiple JWTs can be verified for a request. Each JWT has to be extracted from the locations its issuer specified or from the default locations. This field is set if JWT is sent in a request header. This field specifies the header name. For example, if `header=x-goog-iap-jwt-assertion`, the header format will be x-goog-iap-jwt-assertion: . - */ - jwtHeaders?: Schema$JwtHeader[]; - /** - * This field is set if JWT is sent in a query parameter. This field specifies the query parameter name. For example, if jwt_params[0] is jwt_token, the JWT format in the query parameter is /path?jwt_token=. - */ - jwtParams?: string[]; - } - /** - * This message specifies a header location to extract JWT token. - */ - export interface Schema$JwtHeader { - /** - * The HTTP header name. - */ - name?: string; - /** - * The value prefix. The value format is "value_prefix" For example, for "Authorization: Bearer ", value_prefix="Bearer " with a space at the end. - */ - valuePrefix?: string; - } - /** - * A license resource. - */ - export interface Schema$License { - /** - * [Output Only] Deprecated. This field no longer reflects whether a license charges a usage fee. - */ - chargesUseFee?: boolean; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional textual description of the resource; provided by the client when the resource is created. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of resource. Always compute#license for licenses. - */ - kind?: string; - /** - * [Output Only] The unique code used to attach this license to images, snapshots, and disks. - */ - licenseCode?: string; - /** - * Name of the resource. The name must be 1-63 characters long and comply with RFC1035. - */ - name?: string; - resourceRequirements?: Schema$LicenseResourceRequirements; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * If false, licenses will not be copied from the source resource when creating an image from a disk, disk from snapshot, or snapshot from disk. - */ - transferable?: boolean; - } - export interface Schema$LicenseCode { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * [Output Only] Description of this License Code. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of resource. Always compute#licenseCode for licenses. - */ - kind?: string; - /** - * [Output Only] URL and description aliases of Licenses with the same License Code. - */ - licenseAlias?: Schema$LicenseCodeLicenseAlias[]; - /** - * [Output Only] Name of the resource. The name is 1-20 characters long and must be a valid 64 bit integer. - */ - name?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Current state of this License Code. - */ - state?: string; - /** - * [Output Only] If true, the license will remain attached when creating images or snapshots from disks. Otherwise, the license is not transferred. - */ - transferable?: boolean; - } - export interface Schema$LicenseCodeLicenseAlias { - /** - * [Output Only] Description of this License Code. - */ - description?: string; - /** - * [Output Only] URL of license corresponding to this License Code. - */ - selfLink?: string; - } - export interface Schema$LicenseResourceRequirements { - /** - * Minimum number of guest cpus required to use the Instance. Enforced at Instance creation and Instance start. - */ - minGuestCpuCount?: number; - /** - * Minimum memory required to use the Instance. Enforced at Instance creation and Instance start. - */ - minMemoryMb?: number; - } - export interface Schema$LicensesListResponse { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of License resources. - */ - items?: Schema$License[]; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$LocalDisk { - /** - * Specifies the number of such disks. - */ - diskCount?: string; - /** - * Specifies the size of the disk in base-2 GB. - */ - diskSizeGb?: string; - /** - * Specifies the desired disk type on the node. This disk type must be a local storage type (e.g.: local-ssd). Note that for nodeTemplates, this should be the name of the disk type and not its URL. - */ - diskType?: string; - } - /** - * Specifies what kind of log the caller must write - */ - export interface Schema$LogConfig { - /** - * Cloud audit options. - */ - cloudAudit?: Schema$LogConfigCloudAuditOptions; - /** - * Counter options. - */ - counter?: Schema$LogConfigCounterOptions; - /** - * Data access options. - */ - dataAccess?: Schema$LogConfigDataAccessOptions; - } - /** - * Write a Cloud Audit log - */ - export interface Schema$LogConfigCloudAuditOptions { - /** - * Information used by the Cloud Audit Logging pipeline. - */ - authorizationLoggingOptions?: Schema$AuthorizationLoggingOptions; - /** - * The log_name to populate in the Cloud Audit Record. - */ - logName?: string; - } - /** - * Increment a streamz counter with the specified metric and field names. Metric names should start with a '/', generally be lowercase-only, and end in "_count". Field names should not contain an initial slash. The actual exported metric names will have "/iam/policy" prepended. Field names correspond to IAM request parameters and field values are their respective values. Supported field names: - "authority", which is "[token]" if IAMContext.token is present, otherwise the value of IAMContext.authority_selector if present, and otherwise a representation of IAMContext.principal; or - "iam_principal", a representation of IAMContext.principal even if a token or authority selector is present; or - "" (empty string), resulting in a counter with no fields. Examples: counter { metric: "/debug_access_count" field: "iam_principal" } ==> increment counter /iam/policy/backend_debug_access_count {iam_principal=[value of IAMContext.principal]} At this time we do not support multiple field names (though this may be supported in the future). - */ - export interface Schema$LogConfigCounterOptions { - /** - * The field value to attribute. - */ - field?: string; - /** - * The metric to update. - */ - metric?: string; - } - /** - * Write a Data Access (Gin) log - */ - export interface Schema$LogConfigDataAccessOptions { - /** - * Whether Gin logging should happen in a fail-closed manner at the caller. This is relevant only in the LocalIAM implementation, for now. - */ - logMode?: string; - } - /** - * Machine image resource. - */ - export interface Schema$MachineImage { - /** - * [Output Only] The creation timestamp for this machine image in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Input Only] Specifies to create an application consistent machine image by informing the OS to prepare for the snapshot process. Currently only supported on Windows instances using the Volume Shadow Copy Service (VSS). - */ - guestFlush?: boolean; - /** - * [Output Only] A unique identifier for this machine image. The server defines this identifier. - */ - id?: string; - /** - * [Output Only] The resource type, which is always compute#machineImage for machine image. - */ - kind?: string; - /** - * Encrypts the machine image using a customer-supplied encryption key. After you encrypt a machine image using a customer-supplied key, you must provide the same key if you use the machine image later. For example, you must provide the encryption key when you create an instance from the encrypted machine image in a future request. Customer-supplied encryption keys do not protect access to metadata of the machine image. If you do not provide an encryption key when creating the machine image, then the machine image will be encrypted using an automatically generated key and you do not need to provide a key to use the machine image later. - */ - machineImageEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * [Output Only] The URL for this machine image. The server defines this URL. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Input Only] The customer-supplied encryption key of the disks attached to the source instance. Required if the source disk is protected by a customer-supplied encryption key. - */ - sourceDiskEncryptionKeys?: Schema$SourceDiskEncryptionKey[]; - /** - * The source instance used to create the machine image. You can provide this as a partial or full URL to the resource. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone/instances/instance - projects/project/zones/zone/instances/instance - */ - sourceInstance?: string; - /** - * [Output Only] Properties of source instance. - */ - sourceInstanceProperties?: Schema$SourceInstanceProperties; - /** - * [Output Only] The status of the machine image. One of the following values: INVALID, CREATING, READY, DELETING, and UPLOADING. - */ - status?: string; - /** - * GCS bucket storage location of the machine image (regional or multi-regional). - */ - storageLocations?: string[]; - } - /** - * A list of machine images. - */ - export interface Schema$MachineImageList { - etag?: string; - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of MachineImage resources. - */ - items?: Schema$MachineImage[]; - /** - * [Output Only] The resource type, which is always compute#machineImagesListResponse for machine image lists. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents a Machine Type resource. You can use specific machine types for your VM instances based on performance and pricing requirements. For more information, read Machine Types. (== resource_for v1.machineTypes ==) (== resource_for beta.machineTypes ==) - */ - export interface Schema$MachineType { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * [Output Only] The deprecation status associated with this machine type. - */ - deprecated?: Schema$DeprecationStatus; - /** - * [Output Only] An optional textual description of the resource. - */ - description?: string; - /** - * [Output Only] The number of virtual CPUs that are available to the instance. - */ - guestCpus?: number; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Whether this machine type has a shared CPU. See Shared-core machine types for more information. - */ - isSharedCpu?: boolean; - /** - * [Output Only] The type of the resource. Always compute#machineType for machine types. - */ - kind?: string; - /** - * [Output Only] Maximum persistent disks allowed. - */ - maximumPersistentDisks?: number; - /** - * [Output Only] Maximum total persistent disks size (GB) allowed. - */ - maximumPersistentDisksSizeGb?: string; - /** - * [Output Only] The amount of physical memory available to the instance, defined in MB. - */ - memoryMb?: number; - /** - * [Output Only] Name of the resource. - */ - name?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] The name of the zone where the machine type resides, such as us-central1-a. - */ - zone?: string; - } - export interface Schema$MachineTypeAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of MachineTypesScopedList resources. - */ - items?: {[key: string]: Schema$MachineTypesScopedList}; - /** - * [Output Only] Type of resource. Always compute#machineTypeAggregatedList for aggregated lists of machine types. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of machine types. - */ - export interface Schema$MachineTypeList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of MachineType resources. - */ - items?: Schema$MachineType[]; - /** - * [Output Only] Type of resource. Always compute#machineTypeList for lists of machine types. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$MachineTypesScopedList { - /** - * [Output Only] A list of machine types contained in this scope. - */ - machineTypes?: Schema$MachineType[]; - /** - * [Output Only] An informational warning that appears when the machine types list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * A Managed Instance resource. - */ - export interface Schema$ManagedInstance { - /** - * [Output Only] The current action that the managed instance group has scheduled for the instance. Possible values: - NONE The instance is running, and the managed instance group does not have any scheduled actions for this instance. - CREATING The managed instance group is creating this instance. If the group fails to create this instance, it will try again until it is successful. - CREATING_WITHOUT_RETRIES The managed instance group is attempting to create this instance only once. If the group fails to create this instance, it does not try again and the group's targetSize value is decreased instead. - RECREATING The managed instance group is recreating this instance. - DELETING The managed instance group is permanently deleting this instance. - ABANDONING The managed instance group is abandoning this instance. The instance will be removed from the instance group and from any target pools that are associated with this group. - RESTARTING The managed instance group is restarting the instance. - REFRESHING The managed instance group is applying configuration changes to the instance without stopping it. For example, the group can update the target pool list for an instance without stopping that instance. - VERIFYING The managed instance group has created the instance and it is in the process of being verified. - */ - currentAction?: string; - /** - * [Output only] The unique identifier for this resource. This field is empty when instance does not exist. - */ - id?: string; - /** - * [Output Only] The URL of the instance. The URL can exist even if the instance has not yet been created. - */ - instance?: string; - /** - * [Output Only] Health state of the instance per health-check. - */ - instanceHealth?: Schema$ManagedInstanceInstanceHealth[]; - /** - * [Output Only] The status of the instance. This field is empty when the instance does not exist. - */ - instanceStatus?: string; - /** - * [Output Only] The intended template of the instance. This field is empty when current_action is one of { DELETING, ABANDONING }. - */ - instanceTemplate?: string; - /** - * [Output Only] Information about the last attempt to create or delete the instance. - */ - lastAttempt?: Schema$ManagedInstanceLastAttempt; - /** - * [Output Only] Preserved state applied from per-instance config for this instance. - */ - preservedStateFromConfig?: Schema$PreservedState; - /** - * [Output Only] Preserved state generated based on stateful policy for this instance. - */ - preservedStateFromPolicy?: Schema$PreservedState; - /** - * [Output Only] Tag describing the version. - */ - tag?: string; - /** - * [Output Only] Intended version of this instance. - */ - version?: Schema$ManagedInstanceVersion; - } - export interface Schema$ManagedInstanceInstanceHealth { - /** - * [Output Only] The current detailed instance health state. - */ - detailedHealthState?: string; - /** - * [Output Only] The URL for the health check that verifies whether the instance is healthy. - */ - healthCheck?: string; - /** - * [Output Only] The current instance health state. - */ - healthState?: string; - } - export interface Schema$ManagedInstanceLastAttempt { - /** - * [Output Only] Encountered errors during the last attempt to create or delete the instance. - */ - errors?: { - errors?: Array<{code?: string; location?: string; message?: string}>; - }; - } - export interface Schema$ManagedInstanceVersion { - /** - * [Output Only] The intended template of the instance. This field is empty when current_action is one of { DELETING, ABANDONING }. - */ - instanceTemplate?: string; - /** - * [Output Only] Name of the version. - */ - name?: string; - } - /** - * A metadata key/value entry. - */ - export interface Schema$Metadata { - /** - * Specifies a fingerprint for this request, which is essentially a hash of the metadata's contents and used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update metadata. You must always provide an up-to-date fingerprint hash in order to update or change metadata, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve the resource. - */ - fingerprint?: string; - /** - * Array of key/value pairs. The total size of all keys and values must be less than 512 KB. - */ - items?: Array<{key?: string; value?: string}>; - /** - * [Output Only] Type of the resource. Always compute#metadata for metadata. - */ - kind?: string; - } - /** - * Custom authenticator credentials. - */ - export interface Schema$MetadataCredentialsFromPlugin { - /** - * Plugin name. - */ - name?: string; - /** - * A text proto that conforms to a Struct type definition interpreted by the plugin. - */ - structConfig?: string; - } - /** - * Opaque filter criteria used by loadbalancers to restrict routing configuration to a limited set of loadbalancing proxies. Proxies and sidecars involved in loadbalancing would typically present metadata to the loadbalancers which need to match criteria specified here. If a match takes place, the relevant routing configuration is made available to those proxies. For each metadataFilter in this list, if its filterMatchCriteria is set to MATCH_ANY, at least one of the filterLabels must match the corresponding label provided in the metadata. If its filterMatchCriteria is set to MATCH_ALL, then all of its filterLabels must match with corresponding labels in the provided metadata. An example for using metadataFilters would be: if loadbalancing involves Envoys, they will only receive routing configuration when values in metadataFilters match values supplied in <a href="https://www.envoyproxy.io/docs/envoy/latest/api-v2/api/v2/core/base.proto#envoy-api-msg-core-node" Node metadata of their XDS requests to loadbalancers. - */ - export interface Schema$MetadataFilter { - /** - * The list of label value pairs that must match labels in the provided metadata based on filterMatchCriteria This list must not be empty and can have at the most 64 entries. - */ - filterLabels?: Schema$MetadataFilterLabelMatch[]; - /** - * Specifies how individual filterLabel matches within the list of filterLabels contribute towards the overall metadataFilter match. Supported values are: - MATCH_ANY: At least one of the filterLabels must have a matching label in the provided metadata. - MATCH_ALL: All filterLabels must have matching labels in the provided metadata. - */ - filterMatchCriteria?: string; - } - /** - * MetadataFilter label name value pairs that are expected to match corresponding labels presented as metadata to the loadbalancer. - */ - export interface Schema$MetadataFilterLabelMatch { - /** - * Name of metadata label. The name can have a maximum length of 1024 characters and must be at least 1 character long. - */ - name?: string; - /** - * The value of the label must match the specified value. value can have a maximum length of 1024 characters. - */ - value?: string; - } - /** - * Configuration for the mutual Tls mode for peer authentication. - */ - export interface Schema$MutualTls { - /** - * Specifies if the server TLS is configured to be strict or permissive. This field can be set to one of the following: STRICT: Client certificate must be presented, connection is in TLS. PERMISSIVE: Client certificate can be omitted, connection can be either plaintext or TLS. - */ - mode?: string; - } - /** - * The named port. For example: . - */ - export interface Schema$NamedPort { - /** - * The name for this named port. The name must be 1-63 characters long, and comply with RFC1035. - */ - name?: string; - /** - * The port number, which can be a value between 1 and 65535. - */ - port?: number; - } - /** - * Represents a VPC Network resource. Networks connect resources to each other and to the internet. For more information, read Virtual Private Cloud (VPC) Network. (== resource_for v1.networks ==) (== resource_for beta.networks ==) - */ - export interface Schema$Network { - /** - * When set to true, the VPC network is created in "auto" mode. When set to false, the VPC network is created in "custom" mode. An auto mode VPC network starts with one subnet per region. Each subnet has a predetermined range as described in Auto mode VPC network IP ranges. - */ - autoCreateSubnetworks?: boolean; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * [Output Only] Type of VM-to-VM traffic encryption for this network. - */ - crossVmEncryption?: string; - /** - * An optional description of this resource. Provide this field when you create the resource. - */ - description?: string; - /** - * [Output Only] The gateway address for default routing out of the network, selected by GCP. - */ - gatewayIPv4?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * Deprecated in favor of subnet mode networks. The range of internal addresses that are legal on this network. This range is a CIDR specification, for example: 192.168.0.0/16. Provided by the client when the network is created. - */ - IPv4Range?: string; - /** - * [Output Only] Type of the resource. Always compute#network for networks. - */ - kind?: string; - /** - * [Output Only] Type of LB-to-VM traffic encryption for this network. - */ - loadBalancerVmEncryption?: string; - /** - * Maximum Transmission Unit in bytes. The minimum value for this field is 1460 and the maximum value is 1600 bytes. - */ - mtu?: number; - /** - * The multicast mode for this network. If set to ZONAL, multicast is allowed within a zone. If set to DISABLED, multicast is disabled for this network. The default is DISABLED. - */ - multicastMode?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?. The first character must be a lowercase letter, and all following characters (except for the last character) must be a dash, lowercase letter, or digit. The last character must be a lowercase letter or digit. - */ - name?: string; - /** - * [Output Only] A list of network peerings for the resource. - */ - peerings?: Schema$NetworkPeering[]; - /** - * The network-level routing configuration for this network. Used by Cloud Router to determine what type of network-wide routing behavior to enforce. - */ - routingConfig?: Schema$NetworkRoutingConfig; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] Server-defined fully-qualified URLs for all subnetworks in this VPC network. - */ - subnetworks?: string[]; - } - /** - * The network endpoint. - */ - export interface Schema$NetworkEndpoint { - /** - * Metadata defined as annotations on the network endpoint. - */ - annotations?: {[key: string]: string}; - /** - * Optional fully qualified domain name of network endpoint. This can only be specified when NetworkEndpointGroup.network_endpoint_type is NON_GCP_FQDN_PORT. - */ - fqdn?: string; - /** - * The name for a specific VM instance that the IP address belongs to. This is required for network endpoints of type GCE_VM_IP_PORT. The instance must be in the same zone of network endpoint group. The name must be 1-63 characters long, and comply with RFC1035. - */ - instance?: string; - /** - * Optional IPv4 address of network endpoint. The IP address must belong to a VM in GCE (either the primary IP or as part of an aliased IP range). If the IP address is not specified, then the primary IP address for the VM instance in the network that the network endpoint group belongs to will be used. - */ - ipAddress?: string; - /** - * Optional port number of network endpoint. If not specified and the NetworkEndpointGroup.network_endpoint_type is GCE_IP_PORT, the defaultPort for the network endpoint group will be used. - */ - port?: number; - } - /** - * Represents a collection of network endpoints. - */ - export interface Schema$NetworkEndpointGroup { - /** - * Metadata defined as annotations on the network endpoint group. - */ - annotations?: {[key: string]: string}; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * The default port used if the port number is not specified in the network endpoint. - */ - defaultPort?: number; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#networkEndpointGroup for network endpoint group. - */ - kind?: string; - /** - * This field is only valid when the network endpoint group is used for load balancing. [Deprecated] This field is deprecated. - */ - loadBalancer?: Schema$NetworkEndpointGroupLbNetworkEndpointGroup; - /** - * Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * The URL of the network to which all network endpoints in the NEG belong. Uses "default" project network if unspecified. - */ - network?: string; - /** - * Type of network endpoints in this network endpoint group. Currently the only supported value is GCE_VM_IP_PORT. - */ - networkEndpointType?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output only] Number of network endpoints in the network endpoint group. - */ - size?: number; - /** - * Optional URL of the subnetwork to which all network endpoints in the NEG belong. - */ - subnetwork?: string; - /** - * Specify the type of this network endpoint group. Only LOAD_BALANCING is valid for now. - */ - type?: string; - /** - * [Output Only] The URL of the zone where the network endpoint group is located. - */ - zone?: string; - } - export interface Schema$NetworkEndpointGroupAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of NetworkEndpointGroupsScopedList resources. - */ - items?: {[key: string]: Schema$NetworkEndpointGroupsScopedList}; - /** - * [Output Only] The resource type, which is always compute#networkEndpointGroupAggregatedList for aggregated lists of network endpoint groups. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Load balancing specific fields for network endpoint group. - */ - export interface Schema$NetworkEndpointGroupLbNetworkEndpointGroup { - /** - * The default port used if the port number is not specified in the network endpoint. [Deprecated] This field is deprecated. - */ - defaultPort?: number; - /** - * The URL of the network to which all network endpoints in the NEG belong. Uses "default" project network if unspecified. [Deprecated] This field is deprecated. - */ - network?: string; - /** - * Optional URL of the subnetwork to which all network endpoints in the NEG belong. [Deprecated] This field is deprecated. - */ - subnetwork?: string; - /** - * [Output Only] The URL of the zone where the network endpoint group is located. [Deprecated] This field is deprecated. - */ - zone?: string; - } - export interface Schema$NetworkEndpointGroupList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of NetworkEndpointGroup resources. - */ - items?: Schema$NetworkEndpointGroup[]; - /** - * [Output Only] The resource type, which is always compute#networkEndpointGroupList for network endpoint group lists. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$NetworkEndpointGroupsAttachEndpointsRequest { - /** - * The list of network endpoints to be attached. - */ - networkEndpoints?: Schema$NetworkEndpoint[]; - } - export interface Schema$NetworkEndpointGroupsDetachEndpointsRequest { - /** - * The list of network endpoints to be detached. - */ - networkEndpoints?: Schema$NetworkEndpoint[]; - } - export interface Schema$NetworkEndpointGroupsListEndpointsRequest { - /** - * Optional list of endpoints to query. This is a more efficient but also limited version of filter parameter. Endpoints in the filter must have ip_address and port fields populated, other fields are not supported. - */ - endpointFilters?: Schema$NetworkEndpointGroupsListEndpointsRequestNetworkEndpointFilter[]; - /** - * Optional query parameter for showing the health status of each network endpoint. Valid options are SKIP or SHOW. If you don't specifiy this parameter, the health status of network endpoints will not be provided. - */ - healthStatus?: string; - } - export interface Schema$NetworkEndpointGroupsListEndpointsRequestNetworkEndpointFilter { - networkEndpoint?: Schema$NetworkEndpoint; - } - export interface Schema$NetworkEndpointGroupsListNetworkEndpoints { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of NetworkEndpointWithHealthStatus resources. - */ - items?: Schema$NetworkEndpointWithHealthStatus[]; - /** - * [Output Only] The resource type, which is always compute#networkEndpointGroupsListNetworkEndpoints for the list of network endpoints in the specified network endpoint group. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$NetworkEndpointGroupsScopedList { - /** - * [Output Only] The list of network endpoint groups that are contained in this scope. - */ - networkEndpointGroups?: Schema$NetworkEndpointGroup[]; - /** - * [Output Only] An informational warning that replaces the list of network endpoint groups when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$NetworkEndpointWithHealthStatus { - /** - * [Output only] The health status of network endpoint; - */ - healths?: Schema$HealthStatusForNetworkEndpoint[]; - /** - * [Output only] The network endpoint; - */ - networkEndpoint?: Schema$NetworkEndpoint; - } - /** - * A network interface resource attached to an instance. - */ - export interface Schema$NetworkInterface { - /** - * An array of configurations for this interface. Currently, only one access config, ONE_TO_ONE_NAT, is supported. If there are no accessConfigs specified, then this instance will have no external internet access. - */ - accessConfigs?: Schema$AccessConfig[]; - /** - * An array of alias IP ranges for this network interface. You can only specify this field for network interfaces in VPC networks. - */ - aliasIpRanges?: Schema$AliasIpRange[]; - /** - * Fingerprint hash of contents stored in this network interface. This field will be ignored when inserting an Instance or adding a NetworkInterface. An up-to-date fingerprint must be provided in order to update the NetworkInterface, otherwise the request will fail with error 412 conditionNotMet. - */ - fingerprint?: string; - /** - * [Output Only] An IPv6 internal network address for this network interface. - */ - ipv6Address?: string; - /** - * [Output Only] Type of the resource. Always compute#networkInterface for network interfaces. - */ - kind?: string; - /** - * [Output Only] The name of the network interface, which is generated by the server. For network devices, these are eth0, eth1, etc. - */ - name?: string; - /** - * URL of the network resource for this instance. When creating an instance, if neither the network nor the subnetwork is specified, the default network global/networks/default is used; if the network is not specified but the subnetwork is specified, the network is inferred. If you specify this property, you can specify the network as a full or partial URL. For example, the following are all valid URLs: - https://www.googleapis.com/compute/v1/projects/project/global/networks/network - projects/project/global/networks/network - global/networks/default - */ - network?: string; - /** - * An IPv4 internal IP address to assign to the instance for this network interface. If not specified by the user, an unused internal IP is assigned by the system. - */ - networkIP?: string; - /** - * The URL of the Subnetwork resource for this instance. If the network resource is in legacy mode, do not specify this field. If the network is in auto subnet mode, specifying the subnetwork is optional. If the network is in custom subnet mode, specifying the subnetwork is required. If you specify this field, you can specify the subnetwork as a full or partial URL. For example, the following are all valid URLs: - https://www.googleapis.com/compute/v1/projects/project/regions/region/subnetworks/subnetwork - regions/region/subnetworks/subnetwork - */ - subnetwork?: string; - } - /** - * Contains a list of networks. - */ - export interface Schema$NetworkList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Network resources. - */ - items?: Schema$Network[]; - /** - * [Output Only] Type of resource. Always compute#networkList for lists of networks. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * A network peering attached to a network resource. The message includes the peering name, peer network, peering state, and a flag indicating whether Google Compute Engine should automatically create routes for the peering. - */ - export interface Schema$NetworkPeering { - /** - * Whether Cloud Routers in this network can automatically advertise subnets from the peer network. - */ - advertisePeerSubnetsViaRouters?: boolean; - /** - * This field will be deprecated soon. Use the exchange_subnet_routes field instead. Indicates whether full mesh connectivity is created and managed automatically between peered networks. Currently this field should always be true since Google Compute Engine will automatically create and manage subnetwork routes between two networks when peering state is ACTIVE. - */ - autoCreateRoutes?: boolean; - /** - * Indicates whether full mesh connectivity is created and managed automatically between peered networks. Currently this field should always be true since Google Compute Engine will automatically create and manage subnetwork routes between two networks when peering state is ACTIVE. - */ - exchangeSubnetRoutes?: boolean; - /** - * Whether to export the custom routes to peer network. - */ - exportCustomRoutes?: boolean; - /** - * Whether subnet routes with public IP range are exported. The default value is true, all subnet routes are exported. The IPv4 special-use ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always exported to peers and are not controlled by this field. - */ - exportSubnetRoutesWithPublicIp?: boolean; - /** - * Whether to import the custom routes from peer network. - */ - importCustomRoutes?: boolean; - /** - * Whether subnet routes with public IP range are imported. The default value is false. The IPv4 special-use ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always imported from peers and are not controlled by this field. - */ - importSubnetRoutesWithPublicIp?: boolean; - /** - * Name of this peering. Provided by the client when the peering is created. The name must comply with RFC1035. Specifically, the name must be 1-63 characters long and match regular expression `[a-z]([-a-z0-9]*[a-z0-9])?`. The first character must be a lowercase letter, and all the following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * The URL of the peer network. It can be either full URL or partial URL. The peer network may belong to a different project. If the partial URL does not contain project, it is assumed that the peer network is in the same project as the current network. - */ - network?: string; - /** - * Maximum Transmission Unit in bytes. - */ - peerMtu?: number; - /** - * [Output Only] State for the peering, either `ACTIVE` or `INACTIVE`. The peering is `ACTIVE` when there's a matching configuration in the peer network. - */ - state?: string; - /** - * [Output Only] Details about the current state of the peering. - */ - stateDetails?: string; - } - /** - * A routing configuration attached to a network resource. The message includes the list of routers associated with the network, and a flag indicating the type of routing behavior to enforce network-wide. - */ - export interface Schema$NetworkRoutingConfig { - /** - * The network-wide routing mode to use. If set to REGIONAL, this network's Cloud Routers will only advertise routes with subnets of this network in the same region as the router. If set to GLOBAL, this network's Cloud Routers will advertise routes with all subnets of this network, across regions. - */ - routingMode?: string; - } - export interface Schema$NetworksAddPeeringRequest { - /** - * This field will be deprecated soon. Use exchange_subnet_routes in network_peering instead. Indicates whether full mesh connectivity is created and managed automatically between peered networks. Currently this field should always be true since Google Compute Engine will automatically create and manage subnetwork routes between two networks when peering state is ACTIVE. - */ - autoCreateRoutes?: boolean; - /** - * This field will be deprecated soon. Use export_custom_routes in network_peering instead. Whether to export the custom routes to peer network. - */ - exportCustomRoutes?: boolean; - /** - * This field will be deprecated soon. Use import_custom_routes in network_peering instead. Whether to import the custom routes from peer network. - */ - importCustomRoutes?: boolean; - /** - * Name of the peering, which should conform to RFC1035. - */ - name?: string; - /** - * Network peering parameters. In order to specify route policies for peering using import and export custom routes, you must specify all peering related parameters (name, peer network, exchange_subnet_routes) in the network_peering field. The corresponding fields in NetworksAddPeeringRequest will be deprecated soon. - */ - networkPeering?: Schema$NetworkPeering; - /** - * URL of the peer network. It can be either full URL or partial URL. The peer network may belong to a different project. If the partial URL does not contain project, it is assumed that the peer network is in the same project as the current network. - */ - peerNetwork?: string; - } - export interface Schema$NetworksGetEffectiveFirewallsResponse { - /** - * Effective firewalls on the network. - */ - firewalls?: Schema$Firewall[]; - /** - * Effective firewalls from organization policies. - */ - organizationFirewalls?: Schema$NetworksGetEffectiveFirewallsResponseOrganizationFirewallPolicy[]; - } - /** - * A pruned SecurityPolicy containing ID and any applicable firewall rules. - */ - export interface Schema$NetworksGetEffectiveFirewallsResponseOrganizationFirewallPolicy { - /** - * [Output Only] The unique identifier for the security policy. This identifier is defined by the server. - */ - id?: string; - /** - * The rules that apply to the network. - */ - rules?: Schema$SecurityPolicyRule[]; - } - export interface Schema$NetworksRemovePeeringRequest { - /** - * Name of the peering, which should conform to RFC1035. - */ - name?: string; - } - export interface Schema$NetworksUpdatePeeringRequest { - networkPeering?: Schema$NetworkPeering; - } - /** - * Represent a sole-tenant Node Group resource. A sole-tenant node is a physical server that is dedicated to hosting VM instances only for your specific project. Use sole-tenant nodes to keep your instances physically separated from instances in other projects, or to group your instances together on the same host hardware. For more information, read Sole-tenant nodes. (== resource_for beta.nodeGroups ==) (== resource_for v1.nodeGroups ==) NextID: 15 - */ - export interface Schema$NodeGroup { - autoscalingPolicy?: Schema$NodeGroupAutoscalingPolicy; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] The type of the resource. Always compute#nodeGroup for node group. - */ - kind?: string; - maintenancePolicy?: string; - /** - * The name of the resource, provided by the client when initially creating the resource. The resource name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * The URL of the node template to which this node group belongs. - */ - nodeTemplate?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] The total number of nodes in the node group. - */ - size?: number; - status?: string; - /** - * [Output Only] The name of the zone where the node group resides, such as us-central1-a. - */ - zone?: string; - } - export interface Schema$NodeGroupAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of NodeGroupsScopedList resources. - */ - items?: {[key: string]: Schema$NodeGroupsScopedList}; - /** - * [Output Only] Type of resource.Always compute#nodeGroupAggregatedList for aggregated lists of node groups. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$NodeGroupAutoscalingPolicy { - maxSize?: number; - minSize?: number; - } - /** - * Contains a list of nodeGroups. - */ - export interface Schema$NodeGroupList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of NodeGroup resources. - */ - items?: Schema$NodeGroup[]; - /** - * [Output Only] Type of resource.Always compute#nodeGroupList for lists of node groups. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$NodeGroupNode { - /** - * Local disk configurations. - */ - disks?: Schema$LocalDisk[]; - /** - * Instances scheduled on this node. - */ - instances?: string[]; - /** - * The name of the node. - */ - name?: string; - /** - * The type of this node. - */ - nodeType?: string; - /** - * Binding properties for the physical server. - */ - serverBinding?: Schema$ServerBinding; - status?: string; - } - export interface Schema$NodeGroupsAddNodesRequest { - /** - * Count of additional nodes to be added to the node group. - */ - additionalNodeCount?: number; - } - export interface Schema$NodeGroupsDeleteNodesRequest { - nodes?: string[]; - } - export interface Schema$NodeGroupsListNodes { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Node resources. - */ - items?: Schema$NodeGroupNode[]; - /** - * [Output Only] The resource type, which is always compute.nodeGroupsListNodes for the list of nodes in the specified node group. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$NodeGroupsScopedList { - /** - * [Output Only] A list of node groups contained in this scope. - */ - nodeGroups?: Schema$NodeGroup[]; - /** - * [Output Only] An informational warning that appears when the nodeGroup list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$NodeGroupsSetAutoscalingPolicyRequest { - autoscalingPolicy?: Schema$NodeGroupAutoscalingPolicy; - } - export interface Schema$NodeGroupsSetNodeTemplateRequest { - /** - * Full or partial URL of the node template resource to be updated for this node group. - */ - nodeTemplate?: string; - } - /** - * Represent a sole-tenant Node Template resource. You can use a template to define properties for nodes in a node group. For more information, read Creating node groups and instances. (== resource_for beta.nodeTemplates ==) (== resource_for v1.nodeTemplates ==) (== NextID: 16 ==) - */ - export interface Schema$NodeTemplate { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - disks?: Schema$LocalDisk[]; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] The type of the resource. Always compute#nodeTemplate for node templates. - */ - kind?: string; - /** - * The name of the resource, provided by the client when initially creating the resource. The resource name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * Labels to use for node affinity, which will be used in instance scheduling. - */ - nodeAffinityLabels?: {[key: string]: string}; - /** - * The node type to use for nodes group that are created from this template. - */ - nodeType?: string; - /** - * The flexible properties of the desired node type. Node groups that use this node template will create nodes of a type that matches these properties. This field is mutually exclusive with the node_type property; you can only define one or the other, but not both. - */ - nodeTypeFlexibility?: Schema$NodeTemplateNodeTypeFlexibility; - /** - * [Output Only] The name of the region where the node template resides, such as us-central1. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * Sets the binding properties for the physical server. Valid values include: - [Default] RESTART_NODE_ON_ANY_SERVER: Restarts VMs on any available physical server - RESTART_NODE_ON_MINIMAL_SERVER: Restarts VMs on the same physical server whenever possible See Sole-tenant node options for more information. - */ - serverBinding?: Schema$ServerBinding; - /** - * [Output Only] The status of the node template. One of the following values: CREATING, READY, and DELETING. - */ - status?: string; - /** - * [Output Only] An optional, human-readable explanation of the status. - */ - statusMessage?: string; - } - export interface Schema$NodeTemplateAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of NodeTemplatesScopedList resources. - */ - items?: {[key: string]: Schema$NodeTemplatesScopedList}; - /** - * [Output Only] Type of resource.Always compute#nodeTemplateAggregatedList for aggregated lists of node templates. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of node templates. - */ - export interface Schema$NodeTemplateList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of NodeTemplate resources. - */ - items?: Schema$NodeTemplate[]; - /** - * [Output Only] Type of resource.Always compute#nodeTemplateList for lists of node templates. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$NodeTemplateNodeTypeFlexibility { - cpus?: string; - localSsd?: string; - memory?: string; - } - export interface Schema$NodeTemplatesScopedList { - /** - * [Output Only] A list of node templates contained in this scope. - */ - nodeTemplates?: Schema$NodeTemplate[]; - /** - * [Output Only] An informational warning that appears when the node templates list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represent a sole-tenant Node Type resource. Each node within a node group must have a node type. A node type specifies the total amount of cores and memory for that node. Currently, the only available node type is n1-node-96-624 node type that has 96 vCPUs and 624 GB of memory, available in multiple zones. For more information read Node types. (== resource_for beta.nodeTypes ==) (== resource_for v1.nodeTypes ==) - */ - export interface Schema$NodeType { - /** - * [Output Only] The CPU platform used by this node type. - */ - cpuPlatform?: string; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * [Output Only] The deprecation status associated with this node type. - */ - deprecated?: Schema$DeprecationStatus; - /** - * [Output Only] An optional textual description of the resource. - */ - description?: string; - /** - * [Output Only] The number of virtual CPUs that are available to the node type. - */ - guestCpus?: number; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] The type of the resource. Always compute#nodeType for node types. - */ - kind?: string; - /** - * [Output Only] Local SSD available to the node type, defined in GB. - */ - localSsdGb?: number; - /** - * [Output Only] The amount of physical memory available to the node type, defined in MB. - */ - memoryMb?: number; - /** - * [Output Only] Name of the resource. - */ - name?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] The name of the zone where the node type resides, such as us-central1-a. - */ - zone?: string; - } - export interface Schema$NodeTypeAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of NodeTypesScopedList resources. - */ - items?: {[key: string]: Schema$NodeTypesScopedList}; - /** - * [Output Only] Type of resource.Always compute#nodeTypeAggregatedList for aggregated lists of node types. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of node types. - */ - export interface Schema$NodeTypeList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of NodeType resources. - */ - items?: Schema$NodeType[]; - /** - * [Output Only] Type of resource.Always compute#nodeTypeList for lists of node types. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$NodeTypesScopedList { - /** - * [Output Only] A list of node types contained in this scope. - */ - nodeTypes?: Schema$NodeType[]; - /** - * [Output Only] An informational warning that appears when the node types list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * A notification endpoint resource defines an endpoint to receive notifications when there are status changes detected by the associated health check service. - */ - export interface Schema$NotificationEndpoint { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * Settings of the gRPC notification endpoint including the endpoint URL and the retry duration. - */ - grpcSettings?: Schema$NotificationEndpointGrpcSettings; - /** - * [Output Only] A unique identifier for this resource type. The server generates this identifier. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#notificationEndpoint for notification endpoints. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * [Output Only] URL of the region where the notification endpoint resides. This field applies only to the regional resource. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - } - /** - * Represents a gRPC setting that describes one gRPC notification endpoint and the retry duration attempting to send notification to this endpoint. - */ - export interface Schema$NotificationEndpointGrpcSettings { - /** - * Optional. If specified, this field is used to set the authority header by the sender of notifications. See https://tools.ietf.org/html/rfc7540#section-8.1.2.3 - */ - authority?: string; - /** - * Endpoint to which gRPC notifications are sent. This must be a valid gRPCLB DNS name. - */ - endpoint?: string; - /** - * Optional. If specified, this field is used to populate the ?name? field in gRPC requests. - */ - payloadName?: string; - /** - * How much time (in seconds) is spent attempting notification retries until a successful response is received. Default is 30s. Limit is 20m (1200s). Must be a positive number. - */ - retryDurationSec?: number; - } - export interface Schema$NotificationEndpointList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of NotificationEndpoint resources. - */ - items?: Schema$NotificationEndpoint[]; - /** - * [Output Only] Type of the resource. Always compute#notificationEndpoint for notification endpoints. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents an Operation resource. You can use an operation resource to manage asynchronous API requests. For more information, read Handling API responses. Operations can be global, regional or zonal. - For global operations, use the globalOperations resource. - For regional operations, use the regionOperations resource. - For zonal operations, use the zonalOperations resource. For more information, read Global, Regional, and Zonal Resources. (== resource_for v1.globalOperations ==) (== resource_for beta.globalOperations ==) (== resource_for v1.regionOperations ==) (== resource_for beta.regionOperations ==) (== resource_for v1.zoneOperations ==) (== resource_for beta.zoneOperations ==) - */ - export interface Schema$Operation { - /** - * [Output Only] The value of `requestId` if you provided it in the request. Not present otherwise. - */ - clientOperationId?: string; - /** - * [Deprecated] This field is deprecated. - */ - creationTimestamp?: string; - /** - * [Output Only] A textual description of the operation, which is set when the operation is created. - */ - description?: string; - /** - * [Output Only] The time that this operation was completed. This value is in RFC3339 text format. - */ - endTime?: string; - /** - * [Output Only] If errors are generated during processing of the operation, this field will be populated. - */ - error?: { - errors?: Array<{code?: string; location?: string; message?: string}>; - }; - /** - * [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND. - */ - httpErrorMessage?: string; - /** - * [Output Only] If the operation fails, this field contains the HTTP error status code that was returned. For example, a 404 means the resource was not found. - */ - httpErrorStatusCode?: number; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] The time that this operation was requested. This value is in RFC3339 text format. - */ - insertTime?: string; - /** - * [Output Only] Type of the resource. Always compute#operation for Operation resources. - */ - kind?: string; - /** - * [Output Only] Name of the resource. - */ - name?: string; - /** - * [Output Only] The type of operation, such as insert, update, or delete, and so on. - */ - operationType?: string; - /** - * [Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess when the operation will be complete. This number should monotonically increase as the operation progresses. - */ - progress?: number; - /** - * [Output Only] The URL of the region where the operation resides. Only applicable when performing regional operations. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format. - */ - startTime?: string; - /** - * [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE. - */ - status?: string; - /** - * [Output Only] An optional textual description of the current status of the operation. - */ - statusMessage?: string; - /** - * [Output Only] The unique target ID, which identifies a specific incarnation of the target resource. - */ - targetId?: string; - /** - * [Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from. - */ - targetLink?: string; - /** - * [Output Only] User who requested the operation, for example: user@example.com. - */ - user?: string; - /** - * [Output Only] If warning messages are generated during processing of the operation, this field will be populated. - */ - warnings?: Array<{ - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }>; - /** - * [Output Only] The URL of the zone where the operation resides. Only applicable when performing per-zone operations. - */ - zone?: string; - } - export interface Schema$OperationAggregatedList { - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] A map of scoped operation lists. - */ - items?: {[key: string]: Schema$OperationsScopedList}; - /** - * [Output Only] Type of resource. Always compute#operationAggregatedList for aggregated lists of operations. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of Operation resources. - */ - export interface Schema$OperationList { - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] A list of Operation resources. - */ - items?: Schema$Operation[]; - /** - * [Output Only] Type of resource. Always compute#operations for Operations resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$OperationsScopedList { - /** - * [Output Only] A list of operations contained in this scope. - */ - operations?: Schema$Operation[]; - /** - * [Output Only] Informational warning which replaces the list of operations when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$OrganizationSecurityPoliciesListAssociationsResponse { - /** - * A list of associations. - */ - associations?: Schema$SecurityPolicyAssociation[]; - /** - * [Output Only] Type of securityPolicy associations. Always compute#organizationSecurityPoliciesListAssociations for lists of securityPolicy associations. - */ - kind?: string; - } - /** - * Configuration for the origin authentication method. - */ - export interface Schema$OriginAuthenticationMethod { - jwt?: Schema$Jwt; - } - /** - * Settings controlling eviction of unhealthy hosts from the load balancing pool. - */ - export interface Schema$OutlierDetection { - /** - * The base time that a host is ejected for. The real time is equal to the base time multiplied by the number of times the host has been ejected. Defaults to 30000ms or 30s. - */ - baseEjectionTime?: Schema$Duration; - /** - * Number of errors before a host is ejected from the connection pool. When the backend host is accessed over HTTP, a 5xx return code qualifies as an error. Defaults to 5. - */ - consecutiveErrors?: number; - /** - * The number of consecutive gateway failures (502, 503, 504 status or connection errors that are mapped to one of those status codes) before a consecutive gateway failure ejection occurs. Defaults to 5. - */ - consecutiveGatewayFailure?: number; - /** - * The percentage chance that a host will be actually ejected when an outlier status is detected through consecutive 5xx. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 100. - */ - enforcingConsecutiveErrors?: number; - /** - * The percentage chance that a host will be actually ejected when an outlier status is detected through consecutive gateway failures. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 0. - */ - enforcingConsecutiveGatewayFailure?: number; - /** - * The percentage chance that a host will be actually ejected when an outlier status is detected through success rate statistics. This setting can be used to disable ejection or to ramp it up slowly. Defaults to 100. - */ - enforcingSuccessRate?: number; - /** - * Time interval between ejection sweep analysis. This can result in both new ejections as well as hosts being returned to service. Defaults to 10 seconds. - */ - interval?: Schema$Duration; - /** - * Maximum percentage of hosts in the load balancing pool for the backend service that can be ejected. Defaults to 10%. - */ - maxEjectionPercent?: number; - /** - * The number of hosts in a cluster that must have enough request volume to detect success rate outliers. If the number of hosts is less than this setting, outlier detection via success rate statistics is not performed for any host in the cluster. Defaults to 5. - */ - successRateMinimumHosts?: number; - /** - * The minimum number of total requests that must be collected in one interval (as defined by the interval duration above) to include this host in success rate based outlier detection. If the volume is lower than this setting, outlier detection via success rate statistics is not performed for that host. Defaults to 100. - */ - successRateRequestVolume?: number; - /** - * This factor is used to determine the ejection threshold for success rate outlier ejection. The ejection threshold is the difference between the mean success rate, and the product of this factor and the standard deviation of the mean success rate: mean - (stdev * success_rate_stdev_factor). This factor is divided by a thousand to get a double. That is, if the desired factor is 1.9, the runtime value should be 1900. Defaults to 1900. - */ - successRateStdevFactor?: number; - } - /** - * Next free: 7 - */ - export interface Schema$PacketIntervals { - /** - * Average observed inter-packet interval in milliseconds. - */ - avgMs?: string; - /** - * From how long ago in the past these intervals were observed. - */ - duration?: string; - /** - * Maximum observed inter-packet interval in milliseconds. - */ - maxMs?: string; - /** - * Minimum observed inter-packet interval in milliseconds. - */ - minMs?: string; - /** - * Number of inter-packet intervals from which these statistics were derived. - */ - numIntervals?: string; - /** - * The type of packets for which inter-packet intervals were computed. - */ - type?: string; - } - /** - * Represents a PacketMirroring resource. - */ - export interface Schema$PacketMirroring { - /** - * The Forwarding Rule resource of type loadBalancingScheme=INTERNAL that will be used as collector for mirrored traffic. The specified forwarding rule must have isMirroringCollector set to true. - */ - collectorIlb?: Schema$PacketMirroringForwardingRuleInfo; - /** - * PacketMirroring collectorInfos. Each collectorInfo specifies a set of collector VM instances, preferably in the same zone as the mirrored VM(s) - */ - collectors?: Schema$PacketMirroringCollectorInfo; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * Indicates whether or not this packet mirroring takes effect. If set to FALSE, this packet mirroring policy will not be enforced on the network. The default is TRUE. - */ - enable?: string; - /** - * Filter for mirrored traffic. If unspecified, all traffic is mirrored. - */ - filter?: Schema$PacketMirroringFilter; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#packetMirroring for packet mirrorings. - */ - kind?: string; - /** - * PacketMirroring mirroredResourceInfos. Each mirroredResourceInfo specifies a set of mirrored VM instances and/or a set of subnetworks for which traffic from/to all VM instances will be mirrored. - */ - mirroredResources?: Schema$PacketMirroringMirroredResourceInfo; - /** - * Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * Specifies the mirrored VPC network. Only packets in this network will be mirrored. All mirrored VMs should have a NIC in the given network. All mirrored subnetworks should belong to the given network. - */ - network?: Schema$PacketMirroringNetworkInfo; - /** - * PacketMirroring packetMatchers. Each packetMatcher specifies a CIRD filter that will apply to the source or destination IP in the IP header for the mirrored VM traffic. - */ - packetMatchers?: Schema$PacketMirroringPacketMatcher[]; - /** - * The priority of applying this configuration. Priority is used to break ties in cases where there is more than one matching rule. In the case of two rules that apply for a given Instance, the one with the lowest-numbered priority value wins. Default value is 1000. Valid range is 0 through 65535. - */ - priority?: number; - /** - * [Output Only] URI of the region where the packetMirroring resides. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - } - /** - * Contains a list of packetMirrorings. - */ - export interface Schema$PacketMirroringAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of PacketMirroring resources. - */ - items?: {[key: string]: Schema$PacketMirroringsScopedList}; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$PacketMirroringCollectorInfo { - /** - * A set of virtual machines configured as destination of the mirrored traffic. They must live in zones contained in the same region as this packetMirroring. - */ - instances?: Schema$PacketMirroringCollectorInfoInstanceInfo[]; - } - export interface Schema$PacketMirroringCollectorInfoInstanceInfo { - /** - * Resource URL to the virtual machine instance configured as destination of the mirrored traffic. - */ - url?: string; - } - export interface Schema$PacketMirroringFilter { - /** - * IP CIDR ranges that apply as filter on the source (ingress) or destination (egress) IP in the IP header. Only IPv4 is supported. If no ranges are specified, all traffic that matches the specified IPProtocols is mirrored. If neither cidrRanges nor IPProtocols is specified, all traffic is mirrored. - */ - cidrRanges?: string[]; - /** - * Protocols that apply as filter on mirrored traffic. If no protocols are specified, all traffic that matches the specified CIDR ranges is mirrored. If neither cidrRanges nor IPProtocols is specified, all traffic is mirrored. - */ - IPProtocols?: string[]; - } - export interface Schema$PacketMirroringForwardingRuleInfo { - /** - * [Output Only] Unique identifier for the forwarding rule; defined by the server. - */ - canonicalUrl?: string; - /** - * Resource URL to the forwarding rule representing the ILB configured as destination of the mirrored traffic. - */ - url?: string; - } - /** - * Contains a list of PacketMirroring resources. - */ - export interface Schema$PacketMirroringList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of PacketMirroring resources. - */ - items?: Schema$PacketMirroring[]; - /** - * [Output Only] Type of resource. Always compute#packetMirroring for packetMirrorings. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$PacketMirroringMirroredResourceInfo { - /** - * A set of virtual machine instances that are being mirrored. They must live in zones contained in the same region as this packetMirroring. Note that this config will apply only to those network interfaces of the Instances that belong to the network specified in this packetMirroring. You may specify a maximum of 50 Instances. - */ - instances?: Schema$PacketMirroringMirroredResourceInfoInstanceInfo[]; - /** - * A set of subnetworks for which traffic from/to all VM instances will be mirrored. They must live in zones contained in the same region as this packetMirroring. You may specify a maximum of 5 subnetworks. - */ - subnetworks?: Schema$PacketMirroringMirroredResourceInfoSubnetInfo[]; - /** - * A set of mirrored tags. Traffic from/to all VM instances that have one or more of these tags will be mirrored. - */ - tags?: string[]; - } - export interface Schema$PacketMirroringMirroredResourceInfoInstanceInfo { - /** - * [Output Only] Unique identifier for the instance; defined by the server. - */ - canonicalUrl?: string; - /** - * Resource URL to the virtual machine instance which is being mirrored. - */ - url?: string; - } - export interface Schema$PacketMirroringMirroredResourceInfoSubnetInfo { - /** - * [Output Only] Unique identifier for the subnetwork; defined by the server. - */ - canonicalUrl?: string; - /** - * Resource URL to the subnetwork for which traffic from/to all VM instances will be mirrored. - */ - url?: string; - } - export interface Schema$PacketMirroringNetworkInfo { - /** - * [Output Only] Unique identifier for the network; defined by the server. - */ - canonicalUrl?: string; - /** - * URL of the network resource. - */ - url?: string; - } - export interface Schema$PacketMirroringPacketMatcher { - /** - * IP CIDR range that applies as filter on the source or destination IP in the IP header. Only IPv4 is supported. - */ - cidrRange?: string; - } - export interface Schema$PacketMirroringsScopedList { - /** - * A list of packetMirrorings contained in this scope. - */ - packetMirrorings?: Schema$PacketMirroring[]; - /** - * Informational warning which replaces the list of packetMirrorings when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * A matcher for the path portion of the URL. The BackendService from the longest-matched rule will serve the URL. If no rule was matched, the default service will be used. - */ - export interface Schema$PathMatcher { - /** - * defaultRouteAction takes effect when none of the pathRules or routeRules match. The load balancer performs advanced routing actions like URL rewrites, header transformations, etc. prior to forwarding the request to the selected backend. If defaultRouteAction specifies any weightedBackendServices, defaultService must not be set. Conversely if defaultService is set, defaultRouteAction cannot contain any weightedBackendServices. Only one of defaultRouteAction or defaultUrlRedirect must be set. - */ - defaultRouteAction?: Schema$HttpRouteAction; - /** - * The full or partial URL to the BackendService resource. This will be used if none of the pathRules or routeRules defined by this PathMatcher are matched. For example, the following are all valid URLs to a BackendService resource: - https://www.googleapis.com/compute/v1/projects/project/global/backendServices/backendService - compute/v1/projects/project/global/backendServices/backendService - global/backendServices/backendService If defaultRouteAction is additionally specified, advanced routing actions like URL Rewrites, etc. take effect prior to sending the request to the backend. However, if defaultService is specified, defaultRouteAction cannot contain any weightedBackendServices. Conversely, if defaultRouteAction specifies any weightedBackendServices, defaultService must not be specified. Only one of defaultService, defaultUrlRedirect or defaultRouteAction.weightedBackendService must be set. Authorization requires one or more of the following Google IAM permissions on the specified resource default_service: - compute.backendBuckets.use - compute.backendServices.use - */ - defaultService?: string; - /** - * When when none of the specified pathRules or routeRules match, the request is redirected to a URL specified by defaultUrlRedirect. If defaultUrlRedirect is specified, defaultService or defaultRouteAction must not be set. - */ - defaultUrlRedirect?: Schema$HttpRedirectAction; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * Specifies changes to request and response headers that need to take effect for the selected backendService. HeaderAction specified here are applied after the matching HttpRouteRule HeaderAction and before the HeaderAction in the UrlMap - */ - headerAction?: Schema$HttpHeaderAction; - /** - * The name to which this PathMatcher is referred by the HostRule. - */ - name?: string; - /** - * The list of path rules. Use this list instead of routeRules when routing based on simple path matching is all that's required. The order by which path rules are specified does not matter. Matches are always done on the longest-path-first basis. For example: a pathRule with a path /a/b/c/* will match before /a/b/* irrespective of the order in which those paths appear in this list. Only one of pathRules or routeRules must be set. - */ - pathRules?: Schema$PathRule[]; - /** - * The list of ordered HTTP route rules. Use this list instead of pathRules when advanced route matching and routing actions are desired. The order of specifying routeRules matters: the first rule that matches will cause its specified routing action to take effect. Only one of pathRules or routeRules must be set. - */ - routeRules?: Schema$HttpRouteRule[]; - } - /** - * A path-matching rule for a URL. If matched, will use the specified BackendService to handle the traffic arriving at this URL. - */ - export interface Schema$PathRule { - /** - * The list of path patterns to match. Each must start with / and the only place a * is allowed is at the end following a /. The string fed to the path matcher does not include any text after the first ? or #, and those chars are not allowed here. - */ - paths?: string[]; - /** - * In response to a matching path, the load balancer performs advanced routing actions like URL rewrites, header transformations, etc. prior to forwarding the request to the selected backend. If routeAction specifies any weightedBackendServices, service must not be set. Conversely if service is set, routeAction cannot contain any weightedBackendServices. Only one of routeAction or urlRedirect must be set. - */ - routeAction?: Schema$HttpRouteAction; - /** - * The full or partial URL of the backend service resource to which traffic is directed if this rule is matched. If routeAction is additionally specified, advanced routing actions like URL Rewrites, etc. take effect prior to sending the request to the backend. However, if service is specified, routeAction cannot contain any weightedBackendService s. Conversely, if routeAction specifies any weightedBackendServices, service must not be specified. Only one of urlRedirect, service or routeAction.weightedBackendService must be set. - */ - service?: string; - /** - * When a path pattern is matched, the request is redirected to a URL specified by urlRedirect. If urlRedirect is specified, service or routeAction must not be set. - */ - urlRedirect?: Schema$HttpRedirectAction; - } - /** - * Configuration for the peer authentication method. - */ - export interface Schema$PeerAuthenticationMethod { - /** - * Set if mTLS is used for peer authentication. - */ - mtls?: Schema$MutualTls; - } - export interface Schema$PerInstanceConfig { - /** - * Fingerprint of this per-instance config. This field may be used in optimistic locking. It will be ignored when inserting a per-instance config. An up-to-date fingerprint must be provided in order to update an existing per-instance config or the field needs to be unset. - */ - fingerprint?: string; - /** - * The name of the per-instance config and the corresponding instance. Serves as a merge key during UpdatePerInstanceConfigs operation, i.e. if per-instance config with the same name exists then it will be updated, otherwise a new one will be created for the VM instance with the same name. An attempt to create a per-instance config for a VM instance that either doesn't exist or is not part of the group will result in a failure. - */ - name?: string; - /** - * Intended preserved state for the given instance. Does not contain state generated based on Stateful Policy. - */ - preservedState?: Schema$PreservedState; - } - /** - * All fields defined in a permission are ANDed. - */ - export interface Schema$Permission { - /** - * Extra custom constraints. The constraints are ANDed together. - */ - constraints?: Schema$PermissionConstraint[]; - /** - * Used in Ingress or Egress Gateway cases to specify hosts that the policy applies to. Exact match, prefix match, and suffix match are supported. - */ - hosts?: string[]; - /** - * HTTP method. - */ - methods?: string[]; - /** - * Negate of hosts. Specifies exclusions. - */ - notHosts?: string[]; - /** - * Negate of methods. Specifies exclusions. - */ - notMethods?: string[]; - /** - * Negate of paths. Specifies exclusions. - */ - notPaths?: string[]; - /** - * Negate of ports. Specifies exclusions. - */ - notPorts?: string[]; - /** - * HTTP request paths or gRPC methods. Exact match, prefix match, and suffix match are supported. - */ - paths?: string[]; - /** - * Port names or numbers. - */ - ports?: string[]; - } - /** - * Custom constraint that specifies a key and a list of allowed values for Istio attributes. - */ - export interface Schema$PermissionConstraint { - /** - * Key of the constraint. - */ - key?: string; - /** - * A list of allowed values. - */ - values?: string[]; - } - /** - * Defines an Identity and Access Management (IAM) policy. It is used to specify access control policies for Cloud Platform resources. A `Policy` consists of a list of `bindings`. A `binding` binds a list of `members` to a `role`, where the members can be user accounts, Google groups, Google domains, and service accounts. A `role` is a named list of permissions defined by IAM. **JSON Example** { "bindings": [ { "role": "roles/owner", "members": [ "user:mike@example.com", "group:admins@example.com", "domain:google.com", "serviceAccount:my-other-app@appspot.gserviceaccount.com" ] }, { "role": "roles/viewer", "members": ["user:sean@example.com"] } ] } **YAML Example** bindings: - members: - user:mike@example.com - group:admins@example.com - domain:google.com - serviceAccount:my-other-app@appspot.gserviceaccount.com role: roles/owner - members: - user:sean@example.com role: roles/viewer For a description of IAM and its features, see the [IAM developer's guide](https://cloud.google.com/iam/docs). - */ - export interface Schema$Policy { - /** - * Specifies cloud audit logging configuration for this policy. - */ - auditConfigs?: Schema$AuditConfig[]; - /** - * Associates a list of `members` to a `role`. `bindings` with no members will result in an error. - */ - bindings?: Schema$Binding[]; - /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. - */ - etag?: string; - iamOwned?: boolean; - /** - * If more than one rule is specified, the rules are applied in the following manner: - All matching LOG rules are always applied. - If any DENY/DENY_WITH_LOG rule matches, permission is denied. Logging will be applied if one or more matching rule requires logging. - Otherwise, if any ALLOW/ALLOW_WITH_LOG rule matches, permission is granted. Logging will be applied if one or more matching rule requires logging. - Otherwise, if no rule applies, permission is denied. - */ - rules?: Schema$Rule[]; - /** - * Deprecated. - */ - version?: number; - } - export interface Schema$PreconfiguredWafSet { - /** - * List of entities that are currently supported for WAF rules. - */ - expressionSets?: Schema$WafExpressionSet[]; - } - /** - * Preserved state for a given instance. - */ - export interface Schema$PreservedState { - /** - * Preserved disks defined for this instance. This map is keyed with the device names of the disks. - */ - disks?: {[key: string]: Schema$PreservedStatePreservedDisk}; - /** - * Preserved metadata defined for this instance. - */ - metadata?: {[key: string]: string}; - } - export interface Schema$PreservedStatePreservedDisk { - /** - * These stateful disks will never be deleted during autohealing, update, instance recreate operations. This flag is used to configure if the disk should be deleted after it is no longer used by the group, e.g. when the given instance or the whole MIG is deleted. Note: disks attached in READ_ONLY mode cannot be auto-deleted. - */ - autoDelete?: string; - /** - * The mode in which to attach this disk, either READ_WRITE or READ_ONLY. If not specified, the default is to attach the disk in READ_WRITE mode. - */ - mode?: string; - /** - * The URL of the disk resource that is stateful and should be attached to the VM instance. - */ - source?: string; - } - /** - * All fields defined in a principal are ANDed. - */ - export interface Schema$Principal { - /** - * An expression to specify custom condition. - */ - condition?: string; - /** - * The groups the principal belongs to. Exact match, prefix match, and suffix match are supported. - */ - groups?: string[]; - /** - * IPv4 or IPv6 address or range (In CIDR format) - */ - ips?: string[]; - /** - * The namespaces. Exact match, prefix match, and suffix match are supported. - */ - namespaces?: string[]; - /** - * Negate of groups. Specifies exclusions. - */ - notGroups?: string[]; - /** - * Negate of IPs. Specifies exclusions. - */ - notIps?: string[]; - /** - * Negate of namespaces. Specifies exclusions. - */ - notNamespaces?: string[]; - /** - * Negate of users. Specifies exclusions. - */ - notUsers?: string[]; - /** - * A map of Istio attribute to expected values. Exact match, prefix match, and suffix match are supported for values. For example, `request.headers[version]: ?v1?`. The properties are ANDed together. - */ - properties?: {[key: string]: string}; - /** - * The user names/IDs or service accounts. Exact match, prefix match, and suffix match are supported. - */ - users?: string[]; - } - /** - * Represents a Project resource. A project is used to organize resources in a Google Cloud Platform environment. For more information, read about the Resource Hierarchy. (== resource_for v1.projects ==) (== resource_for beta.projects ==) - */ - export interface Schema$Project { - /** - * Metadata key/value pairs available to all instances contained in this project. See Custom metadata for more information. - */ - commonInstanceMetadata?: Schema$Metadata; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * This signifies the default network tier used for configuring resources of the project and can only take the following values: PREMIUM, STANDARD. Initially the default network tier is PREMIUM. - */ - defaultNetworkTier?: string; - /** - * [Output Only] Default service account used by VMs running in this project. - */ - defaultServiceAccount?: string; - /** - * An optional textual description of the resource. - */ - description?: string; - /** - * Restricted features enabled for use on this project. - */ - enabledFeatures?: string[]; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. This is not the project ID, and is just a unique ID used by Compute Engine to identify resources. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#project for projects. - */ - kind?: string; - /** - * The project ID. For example: my-example-project. Use the project ID to make requests to Compute Engine. - */ - name?: string; - /** - * [Output Only] Quotas assigned to this project. - */ - quotas?: Schema$Quota[]; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * The naming prefix for daily usage reports and the Google Cloud Storage bucket where they are stored. - */ - usageExportLocation?: Schema$UsageExportLocation; - /** - * [Output Only] The role this project has in a shared VPC configuration. Currently only HOST projects are differentiated. - */ - xpnProjectStatus?: string; - } - export interface Schema$ProjectsDisableXpnResourceRequest { - /** - * Service resource (a.k.a service project) ID. - */ - xpnResource?: Schema$XpnResourceId; - } - export interface Schema$ProjectsEnableXpnResourceRequest { - /** - * Service resource (a.k.a service project) ID. - */ - xpnResource?: Schema$XpnResourceId; - } - export interface Schema$ProjectsGetXpnResources { - /** - * [Output Only] Type of resource. Always compute#projectsGetXpnResources for lists of service resources (a.k.a service projects) - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * Service resources (a.k.a service projects) attached to this project as their shared VPC host. - */ - resources?: Schema$XpnResourceId[]; - } - export interface Schema$ProjectsListXpnHostsRequest { - /** - * Optional organization ID managed by Cloud Resource Manager, for which to list shared VPC host projects. If not specified, the organization will be inferred from the project. - */ - organization?: string; - } - export interface Schema$ProjectsSetDefaultNetworkTierRequest { - /** - * Default network tier to be set. - */ - networkTier?: string; - } - export interface Schema$ProjectsSetDefaultServiceAccountRequest { - /** - * Email address of the service account. - */ - email?: string; - } - /** - * A quotas entry. - */ - export interface Schema$Quota { - /** - * [Output Only] Quota limit for this metric. - */ - limit?: number; - /** - * [Output Only] Name of the quota metric. - */ - metric?: string; - /** - * [Output Only] Owning resource. This is the resource on which this quota is applied. - */ - owner?: string; - /** - * [Output Only] Current usage of this metric. - */ - usage?: number; - } - export interface Schema$RbacPolicy { - /** - * Name of the RbacPolicy. - */ - name?: string; - /** - * The list of permissions. - */ - permissions?: Schema$Permission[]; - /** - * The list of principals. - */ - principals?: Schema$Principal[]; - } - /** - * Represents a reference to a resource. - */ - export interface Schema$Reference { - /** - * [Output Only] Type of the resource. Always compute#reference for references. - */ - kind?: string; - /** - * A description of the reference type with no implied semantics. Possible values include: - MEMBER_OF - */ - referenceType?: string; - /** - * URL of the resource which refers to the target. - */ - referrer?: string; - /** - * URL of the resource to which this reference points. - */ - target?: string; - } - /** - * Represents a Region resource. A region is a geographical area where a resource is located. For more information, read Regions and Zones. (== resource_for beta.regions ==) (== resource_for v1.regions ==) - */ - export interface Schema$Region { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * [Output Only] The deprecation status associated with this region. - */ - deprecated?: Schema$DeprecationStatus; - /** - * [Output Only] Textual description of the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#region for regions. - */ - kind?: string; - /** - * [Output Only] Name of the resource. - */ - name?: string; - /** - * [Output Only] Quotas assigned to this region. - */ - quotas?: Schema$Quota[]; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] Status of the region, either UP or DOWN. - */ - status?: string; - /** - * [Output Only] A list of zones available in this region, in the form of resource URLs. - */ - zones?: string[]; - } - /** - * Contains a list of autoscalers. - */ - export interface Schema$RegionAutoscalerList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Autoscaler resources. - */ - items?: Schema$Autoscaler[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$RegionCommitmentsUpdateReservationsRequest { - /** - * List of reservations for the capacity move of VMs with accelerators and local ssds. - */ - reservations?: Schema$Reservation[]; - } - export interface Schema$RegionDisksAddResourcePoliciesRequest { - /** - * Resource policies to be added to this disk. - */ - resourcePolicies?: string[]; - } - export interface Schema$RegionDisksRemoveResourcePoliciesRequest { - /** - * Resource policies to be removed from this disk. - */ - resourcePolicies?: string[]; - } - export interface Schema$RegionDisksResizeRequest { - /** - * The new size of the regional persistent disk, which is specified in GB. - */ - sizeGb?: string; - } - export interface Schema$RegionDiskTypeList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of DiskType resources. - */ - items?: Schema$DiskType[]; - /** - * [Output Only] Type of resource. Always compute#regionDiskTypeList for region disk types. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of InstanceGroup resources. - */ - export interface Schema$RegionInstanceGroupList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InstanceGroup resources. - */ - items?: Schema$InstanceGroup[]; - /** - * The resource type. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * RegionInstanceGroupManagers.deletePerInstanceConfigs - */ - export interface Schema$RegionInstanceGroupManagerDeleteInstanceConfigReq { - /** - * The list of instances for which we want to delete per-instance configs on this managed instance group. - */ - instances?: string[]; - /** - * The list of instance names for which we want to delete per-instance configs on this managed instance group. - */ - names?: string[]; - } - /** - * Contains a list of managed instance groups. - */ - export interface Schema$RegionInstanceGroupManagerList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InstanceGroupManager resources. - */ - items?: Schema$InstanceGroupManager[]; - /** - * [Output Only] The resource type, which is always compute#instanceGroupManagerList for a list of managed instance groups that exist in th regional scope. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * RegionInstanceGroupManagers.patchPerInstanceConfigs - */ - export interface Schema$RegionInstanceGroupManagerPatchInstanceConfigReq { - /** - * The list of per-instance configs to insert or patch on this managed instance group. - */ - perInstanceConfigs?: Schema$PerInstanceConfig[]; - } - export interface Schema$RegionInstanceGroupManagersAbandonInstancesRequest { - /** - * The URLs of one or more instances to abandon. This can be a full URL or a partial URL, such as zones/[ZONE]/instances/[INSTANCE_NAME]. - */ - instances?: string[]; - } - /** - * InstanceGroupManagers.applyUpdatesToInstances - */ - export interface Schema$RegionInstanceGroupManagersApplyUpdatesRequest { - /** - * The list of URLs of one or more instances for which you want to apply updates. Each URL can be a full URL or a partial URL, such as zones/[ZONE]/instances/[INSTANCE_NAME]. - */ - instances?: string[]; - /** - * The maximal action that should be performed on the instances. By default REPLACE. This field is deprecated, please use most_disruptive_allowed_action. - */ - maximalAction?: string; - /** - * The minimal action that you want to perform on each instance during the update: - REPLACE: At minimum, delete the instance and create it again. - RESTART: Stop the instance and start it again. - REFRESH: Do not stop the instance. - NONE: Do not disrupt the instance at all. By default, the minimum action is NONE. If your update requires a more disruptive action than you set with this flag, the necessary action is performed to execute the update. - */ - minimalAction?: string; - /** - * The most disruptive action that you want to perform on each instance during the update: - REPLACE: Delete the instance and create it again. - RESTART: Stop the instance and start it again. - REFRESH: Do not stop the instance. - NONE: Do not disrupt the instance at all. By default, the most disruptive allowed action is REPLACE. If your update requires a more disruptive action than you set with this flag, the update request will fail. - */ - mostDisruptiveAllowedAction?: string; - } - /** - * RegionInstanceGroupManagers.createInstances - */ - export interface Schema$RegionInstanceGroupManagersCreateInstancesRequest { - /** - * [Required] List of specifications of per-instance configs. - */ - instances?: Schema$PerInstanceConfig[]; - } - export interface Schema$RegionInstanceGroupManagersDeleteInstancesRequest { - /** - * The URLs of one or more instances to delete. This can be a full URL or a partial URL, such as zones/[ZONE]/instances/[INSTANCE_NAME]. - */ - instances?: string[]; - } - export interface Schema$RegionInstanceGroupManagersListErrorsResponse { - /** - * [Output Only] The list of errors of the managed instance group. - */ - items?: Schema$InstanceManagedByIgmError[]; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - } - export interface Schema$RegionInstanceGroupManagersListInstanceConfigsResp { - /** - * [Output Only] The list of PerInstanceConfig. - */ - items?: Schema$PerInstanceConfig[]; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$RegionInstanceGroupManagersListInstancesResponse { - /** - * A list of managed instances. - */ - managedInstances?: Schema$ManagedInstance[]; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - } - export interface Schema$RegionInstanceGroupManagersRecreateRequest { - /** - * The URLs of one or more instances to recreate. This can be a full URL or a partial URL, such as zones/[ZONE]/instances/[INSTANCE_NAME]. - */ - instances?: string[]; - } - export interface Schema$RegionInstanceGroupManagersSetAutoHealingRequest { - autoHealingPolicies?: Schema$InstanceGroupManagerAutoHealingPolicy[]; - } - export interface Schema$RegionInstanceGroupManagersSetTargetPoolsRequest { - /** - * Fingerprint of the target pools information, which is a hash of the contents. This field is used for optimistic locking when you update the target pool entries. This field is optional. - */ - fingerprint?: string; - /** - * The URL of all TargetPool resources to which instances in the instanceGroup field are added. The target pools automatically apply to all of the instances in the managed instance group. - */ - targetPools?: string[]; - } - export interface Schema$RegionInstanceGroupManagersSetTemplateRequest { - /** - * URL of the InstanceTemplate resource from which all new instances will be created. - */ - instanceTemplate?: string; - } - /** - * RegionInstanceGroupManagers.updatePerInstanceConfigs - */ - export interface Schema$RegionInstanceGroupManagerUpdateInstanceConfigReq { - /** - * The list of per-instance configs to insert or patch on this managed instance group. - */ - perInstanceConfigs?: Schema$PerInstanceConfig[]; - } - export interface Schema$RegionInstanceGroupsListInstances { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of InstanceWithNamedPorts resources. - */ - items?: Schema$InstanceWithNamedPorts[]; - /** - * The resource type. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$RegionInstanceGroupsListInstancesRequest { - /** - * Instances in which state should be returned. Valid options are: 'ALL', 'RUNNING'. By default, it lists all instances. - */ - instanceState?: string; - /** - * Name of port user is interested in. It is optional. If it is set, only information about this ports will be returned. If it is not set, all the named ports will be returned. Always lists all instances. - */ - portName?: string; - } - export interface Schema$RegionInstanceGroupsSetNamedPortsRequest { - /** - * The fingerprint of the named ports information for this instance group. Use this optional property to prevent conflicts when multiple users change the named ports settings concurrently. Obtain the fingerprint with the instanceGroups.get method. Then, include the fingerprint in your request to ensure that you do not overwrite changes that were applied from another concurrent request. - */ - fingerprint?: string; - /** - * The list of named ports to set for this instance group. - */ - namedPorts?: Schema$NamedPort[]; - } - /** - * Contains a list of region resources. - */ - export interface Schema$RegionList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Region resources. - */ - items?: Schema$Region[]; - /** - * [Output Only] Type of resource. Always compute#regionList for lists of regions. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$RegionSetLabelsRequest { - /** - * The fingerprint of the previous set of labels for this resource, used to detect conflicts. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels. Make a get() request to the resource to get the latest fingerprint. - */ - labelFingerprint?: string; - /** - * The labels to set for this resource. - */ - labels?: {[key: string]: string}; - } - export interface Schema$RegionSetPolicyRequest { - /** - * Flatten Policy to create a backwacd compatible wire-format. Deprecated. Use 'policy' to specify bindings. - */ - bindings?: Schema$Binding[]; - /** - * Flatten Policy to create a backward compatible wire-format. Deprecated. Use 'policy' to specify the etag. - */ - etag?: string; - /** - * REQUIRED: The complete policy to be applied to the 'resource'. The size of the policy is limited to a few 10s of KB. An empty policy is in general a valid policy but certain services (like Projects) might reject them. - */ - policy?: Schema$Policy; - } - export interface Schema$RegionTargetHttpsProxiesSetSslCertificatesRequest { - /** - * New set of SslCertificate resources to associate with this TargetHttpsProxy resource. Currently exactly one SslCertificate resource must be specified. - */ - sslCertificates?: string[]; - } - export interface Schema$RegionUrlMapsValidateRequest { - /** - * Content of the UrlMap to be validated. - */ - resource?: Schema$UrlMap; - } - /** - * A policy that specifies how requests intended for the route's backends are shadowed to a separate mirrored backend service. Loadbalancer does not wait for responses from the shadow service. Prior to sending traffic to the shadow service, the host / authority header is suffixed with -shadow. - */ - export interface Schema$RequestMirrorPolicy { - /** - * The full or partial URL to the BackendService resource being mirrored to. - */ - backendService?: string; - } - /** - * Represents a reservation resource. A reservation ensures that capacity is held in a specific zone even if the reserved VMs are not running. For more information, read Reserving zonal resources. (== resource_for beta.reservations ==) (== resource_for v1.reservations ==) (== NextID: 13 ==) - */ - export interface Schema$Reservation { - /** - * [OutputOnly] Full or partial url for parent commitment for reservations which are tied to a commitment. - */ - commitment?: string; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#reservations for reservations. - */ - kind?: string; - /** - * The name of the resource, provided by the client when initially creating the resource. The resource name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * [Output Only] Server-defined fully-qualified URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * Reservation for instances with specific machine shapes. - */ - specificReservation?: Schema$AllocationSpecificSKUReservation; - /** - * Indicates whether the reservation can be consumed by VMs with affinity for "any" reservation. If the field is set, then only VMs that target the reservation by name can consume from this reservation. - */ - specificReservationRequired?: boolean; - /** - * [Output Only] The status of the reservation. - */ - status?: string; - /** - * Zone in which the reservation resides, must be provided if reservation is created with commitment creation. - */ - zone?: string; - } - /** - * Specifies the reservations that this instance can consume from. - */ - export interface Schema$ReservationAffinity { - /** - * Specifies the type of reservation from which this instance can consume resources: ANY_RESERVATION (default), SPECIFIC_RESERVATION, or NO_RESERVATION. See Consuming reserved instances for examples. - */ - consumeReservationType?: string; - /** - * Corresponds to the label key of a reservation resource. To target a SPECIFIC_RESERVATION by name, specify googleapis.com/reservation-name as the key and specify the name of your reservation as its value. - */ - key?: string; - /** - * Corresponds to the label values of a reservation resource. - */ - values?: string[]; - } - /** - * Contains a list of reservations. - */ - export interface Schema$ReservationAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Allocation resources. - */ - items?: {[key: string]: Schema$ReservationsScopedList}; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$ReservationList { - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] A list of Allocation resources. - */ - items?: Schema$Reservation[]; - /** - * [Output Only] Type of resource.Always compute#reservationsList for listsof reservations - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$ReservationsResizeRequest { - /** - * Number of allocated resources can be resized with minimum = 1 and maximum = 1000. - */ - specificSkuCount?: string; - } - export interface Schema$ReservationsScopedList { - /** - * A list of reservations contained in this scope. - */ - reservations?: Schema$Reservation[]; - /** - * Informational warning which replaces the list of reservations when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Commitment for a particular resource (a Commitment is composed of one or more of these). - */ - export interface Schema$ResourceCommitment { - /** - * Name of the accelerator type resource. Applicable only when the type is ACCELERATOR. - */ - acceleratorType?: string; - /** - * The amount of the resource purchased (in a type-dependent unit, such as bytes). For vCPUs, this can just be an integer. For memory, this must be provided in MB. Memory must be a multiple of 256 MB, with up to 6.5GB of memory per every vCPU. - */ - amount?: string; - /** - * Type of resource for which this commitment applies. Possible values are VCPU and MEMORY - */ - type?: string; - } - export interface Schema$ResourceGroupReference { - /** - * A URI referencing one of the instance groups or network endpoint groups listed in the backend service. - */ - group?: string; - } - export interface Schema$ResourcePoliciesScopedList { - /** - * A list of resourcePolicies contained in this scope. - */ - resourcePolicies?: Schema$ResourcePolicy[]; - /** - * Informational warning which replaces the list of resourcePolicies when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$ResourcePolicy { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - description?: string; - /** - * Resource policy for instacnes for placement configuration. - */ - groupPlacementPolicy?: Schema$ResourcePolicyGroupPlacementPolicy; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#resource_policies for resource policies. - */ - kind?: string; - /** - * The name of the resource, provided by the client when initially creating the resource. The resource name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - region?: string; - /** - * [Output Only] Server-defined fully-qualified URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * Resource policy for persistent disks for creating snapshots. - */ - snapshotSchedulePolicy?: Schema$ResourcePolicySnapshotSchedulePolicy; - /** - * [Output Only] The status of resource policy creation. - */ - status?: string; - /** - * Resource policy applicable to VMs for infrastructure maintenance. - */ - vmMaintenancePolicy?: Schema$ResourcePolicyVmMaintenancePolicy; - } - /** - * Contains a list of resourcePolicies. - */ - export interface Schema$ResourcePolicyAggregatedList { - etag?: string; - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of ResourcePolicy resources. - */ - items?: {[key: string]: Schema$ResourcePoliciesScopedList}; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Time window specified for daily operations. - */ - export interface Schema$ResourcePolicyDailyCycle { - /** - * Defines a schedule that runs every nth day of the month. - */ - daysInCycle?: number; - /** - * [Output only] A predetermined duration for the window, automatically chosen to be the smallest possible in the given scenario. - */ - duration?: string; - /** - * Start time of the window. This must be in UTC format that resolves to one of 00:00, 04:00, 08:00, 12:00, 16:00, or 20:00. For example, both 13:00-5 and 08:00 are valid. - */ - startTime?: string; - } - /** - * A GroupPlacementPolicy specifies resource placement configuration. It specifies the failure bucket separation as well as network locality - */ - export interface Schema$ResourcePolicyGroupPlacementPolicy { - /** - * Specifies network locality - */ - locality?: string; - /** - * Specifies instances to hosts placement relationship - */ - style?: string; - /** - * Number of vms in this placement group - */ - vmCount?: number; - } - /** - * Time window specified for hourly operations. - */ - export interface Schema$ResourcePolicyHourlyCycle { - /** - * [Output only] Duration of the time window, automatically chosen to be smallest possible in the given scenario. - */ - duration?: string; - /** - * Allows to define schedule that runs every nth hour. - */ - hoursInCycle?: number; - /** - * Time within the window to start the operations. It must be in format "HH:MM", where HH : [00-23] and MM : [00-00] GMT. - */ - startTime?: string; - } - export interface Schema$ResourcePolicyList { - etag?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] A list of ResourcePolicy resources. - */ - items?: Schema$ResourcePolicy[]; - /** - * [Output Only] Type of resource.Always compute#resourcePoliciesList for listsof resourcePolicies - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * A snapshot schedule policy specifies when and how frequently snapshots are to be created for the target disk. Also specifies how many and how long these scheduled snapshots should be retained. - */ - export interface Schema$ResourcePolicySnapshotSchedulePolicy { - /** - * Retention policy applied to snapshots created by this resource policy. - */ - retentionPolicy?: Schema$ResourcePolicySnapshotSchedulePolicyRetentionPolicy; - /** - * A Vm Maintenance Policy specifies what kind of infrastructure maintenance we are allowed to perform on this VM and when. Schedule that is applied to disks covered by this policy. - */ - schedule?: Schema$ResourcePolicySnapshotSchedulePolicySchedule; - /** - * Properties with which snapshots are created such as labels, encryption keys. - */ - snapshotProperties?: Schema$ResourcePolicySnapshotSchedulePolicySnapshotProperties; - } - /** - * Policy for retention of scheduled snapshots. - */ - export interface Schema$ResourcePolicySnapshotSchedulePolicyRetentionPolicy { - /** - * Maximum age of the snapshot that is allowed to be kept. - */ - maxRetentionDays?: number; - /** - * Specifies the behavior to apply to existing, scheduled snapshots snapshots if the policy is changed. - */ - onPolicySwitch?: string; - /** - * Specifies the behavior to apply to scheduled snapshots when the source disk is deleted. - */ - onSourceDiskDelete?: string; - } - /** - * A schedule for disks where the schedueled operations are performed. - */ - export interface Schema$ResourcePolicySnapshotSchedulePolicySchedule { - dailySchedule?: Schema$ResourcePolicyDailyCycle; - hourlySchedule?: Schema$ResourcePolicyHourlyCycle; - weeklySchedule?: Schema$ResourcePolicyWeeklyCycle; - } - /** - * Specified snapshot properties for scheduled snapshots created by this policy. - */ - export interface Schema$ResourcePolicySnapshotSchedulePolicySnapshotProperties { - /** - * Indication to perform a ?guest aware? snapshot. - */ - guestFlush?: boolean; - /** - * Labels to apply to scheduled snapshots. These can be later modified by the setLabels method. Label values may be empty. - */ - labels?: {[key: string]: string}; - /** - * GCS bucket storage location of the auto snapshot (regional or multi-regional). - */ - storageLocations?: string[]; - } - export interface Schema$ResourcePolicyVmMaintenancePolicy { - concurrencyControlGroup?: Schema$ResourcePolicyVmMaintenancePolicyConcurrencyControl; - /** - * Maintenance windows that are applied to VMs covered by this policy. - */ - maintenanceWindow?: Schema$ResourcePolicyVmMaintenancePolicyMaintenanceWindow; - } - /** - * A concurrency control configuration. Defines a group config that, when attached to an instance, recognizes that instance as part of a group of instances where only up the concurrency_limit of instances in that group can undergo simultaneous maintenance. For more information: go/concurrency-control-design-doc - */ - export interface Schema$ResourcePolicyVmMaintenancePolicyConcurrencyControl { - concurrencyLimit?: number; - } - /** - * A maintenance window for VMs. When set, we restrict our maintenance operations to this window. - */ - export interface Schema$ResourcePolicyVmMaintenancePolicyMaintenanceWindow { - dailyMaintenanceWindow?: Schema$ResourcePolicyDailyCycle; - } - /** - * Time window specified for weekly operations. - */ - export interface Schema$ResourcePolicyWeeklyCycle { - /** - * Up to 7 intervals/windows, one for each day of the week. - */ - dayOfWeeks?: Schema$ResourcePolicyWeeklyCycleDayOfWeek[]; - } - export interface Schema$ResourcePolicyWeeklyCycleDayOfWeek { - /** - * Allows to define schedule that runs specified day of the week. - */ - day?: string; - /** - * [Output only] Duration of the time window, automatically chosen to be smallest possible in the given scenario. - */ - duration?: string; - /** - * Time within the window to start the operations. It must be in format "HH:MM", where HH : [00-23] and MM : [00-00] GMT. - */ - startTime?: string; - } - /** - * Represents a Route resource. A route defines a path from VM instances in the VPC network to a specific destination. This destination can be inside or outside the VPC network. For more information, read the Routes overview. (== resource_for beta.routes ==) (== resource_for v1.routes ==) - */ - export interface Schema$Route { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this field when you create the resource. - */ - description?: string; - /** - * The destination range of outgoing packets that this route applies to. Only IPv4 is supported. - */ - destRange?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of this resource. Always compute#routes for Route resources. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?`. The first character must be a lowercase letter, and all following characters (except for the last character) must be a dash, lowercase letter, or digit. The last character must be a lowercase letter or digit. - */ - name?: string; - /** - * Fully-qualified URL of the network that this route applies to. - */ - network?: string; - /** - * The URL to a gateway that should handle matching packets. You can only specify the internet gateway using a full or partial valid URL: projects/project/global/gateways/default-internet-gateway - */ - nextHopGateway?: string; - /** - * The URL to a forwarding rule of type loadBalancingScheme=INTERNAL that should handle matching packets. You can only specify the forwarding rule as a partial or full URL. For example, the following are all valid URLs: - https://www.googleapis.com/compute/v1/projects/project/regions/region/forwardingRules/forwardingRule - regions/region/forwardingRules/forwardingRule Note that this can only be used when the destination_range is a public (non-RFC 1918) IP CIDR range. - */ - nextHopIlb?: string; - /** - * The URL to an instance that should handle matching packets. You can specify this as a full or partial URL. For example: https://www.googleapis.com/compute/v1/projects/project/zones/zone/instances/ - */ - nextHopInstance?: string; - /** - * [Output Only] The URL to an InterconnectAttachment which is the next hop for the route. This field will only be populated for the dynamic routes generated by Cloud Router with a linked interconnectAttachment. - */ - nextHopInterconnectAttachment?: string; - /** - * The network IP address of an instance that should handle matching packets. Only IPv4 is supported. - */ - nextHopIp?: string; - /** - * The URL of the local network if it should handle matching packets. - */ - nextHopNetwork?: string; - /** - * [Output Only] The network peering name that should handle matching packets, which should conform to RFC1035. - */ - nextHopPeering?: string; - /** - * The URL to a VpnTunnel that should handle matching packets. - */ - nextHopVpnTunnel?: string; - /** - * The priority of this route. Priority is used to break ties in cases where there is more than one matching route of equal prefix length. In cases where multiple routes have equal prefix length, the one with the lowest-numbered priority value wins. The default value is `1000`. The priority value must be from `0` to `65535`, inclusive. - */ - priority?: number; - /** - * [Output Only] Server-defined fully-qualified URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * A list of instance tags to which this route applies. - */ - tags?: string[]; - /** - * [Output Only] If potential misconfigurations are detected for this route, this field will be populated with warning messages. - */ - warnings?: Array<{ - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }>; - } - /** - * Contains a list of Route resources. - */ - export interface Schema$RouteList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Route resources. - */ - items?: Schema$Route[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents a Cloud Router resource. For more information about Cloud Router, read the the Cloud Router overview. - */ - export interface Schema$Router { - /** - * BGP information specific to this router. - */ - bgp?: Schema$RouterBgp; - /** - * BGP information that must be configured into the routing stack to establish BGP peering. This information must specify the peer ASN and either the interface name, IP address, or peer IP address. Please refer to RFC4273. - */ - bgpPeers?: Schema$RouterBgpPeer[]; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * Router interfaces. Each interface requires either one linked resource, (for example, linkedVpnTunnel), or IP address and IP address range (for example, ipRange), or both. - */ - interfaces?: Schema$RouterInterface[]; - /** - * [Output Only] Type of resource. Always compute#router for routers. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * A list of NAT services created in this router. - */ - nats?: Schema$RouterNat[]; - /** - * URI of the network to which this router belongs. - */ - network?: string; - /** - * [Output Only] URI of the region where the router resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - } - /** - * Description-tagged IP ranges for the router to advertise. - */ - export interface Schema$RouterAdvertisedIpRange { - /** - * User-specified description for the IP range. - */ - description?: string; - /** - * The IP range to advertise. The value must be a CIDR-formatted string. - */ - range?: string; - } - /** - * Contains a list of routers. - */ - export interface Schema$RouterAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Router resources. - */ - items?: {[key: string]: Schema$RoutersScopedList}; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$RouterBgp { - /** - * User-specified list of prefix groups to advertise in custom mode. This field can only be populated if advertise_mode is CUSTOM and is advertised to all peers of the router. These groups will be advertised in addition to any specified prefixes. Leave this field blank to advertise no custom groups. - */ - advertisedGroups?: string[]; - /** - * User-specified list of individual IP ranges to advertise in custom mode. This field can only be populated if advertise_mode is CUSTOM and is advertised to all peers of the router. These IP ranges will be advertised in addition to any specified groups. Leave this field blank to advertise no custom IP ranges. - */ - advertisedIpRanges?: Schema$RouterAdvertisedIpRange[]; - /** - * User-specified flag to indicate which mode to use for advertisement. The options are DEFAULT or CUSTOM. - */ - advertiseMode?: string; - /** - * Local BGP Autonomous System Number (ASN). Must be an RFC6996 private ASN, either 16-bit or 32-bit. The value will be fixed for this router resource. All VPN tunnels that link to this router will have the same local ASN. - */ - asn?: number; - /** - * The interval in seconds between BGP keepalive messages that are sent to the peer. Hold time is three times the interval at which keepalive messages are sent, and the hold time is the maximum number of seconds allowed to elapse between successive keepalive messages that BGP receives from a peer. BGP will use the smaller of either the local hold time value or the peer?s hold time value as the hold time for the BGP connection between the two peers. If set, this value must be between 1 and 120. The default is 20. - */ - keepaliveInterval?: number; - } - export interface Schema$RouterBgpPeer { - /** - * User-specified list of prefix groups to advertise in custom mode, which can take one of the following options: - ALL_SUBNETS: Advertises all available subnets, including peer VPC subnets. - ALL_VPC_SUBNETS: Advertises the router's own VPC subnets. - ALL_PEER_VPC_SUBNETS: Advertises peer subnets of the router's VPC network. Note that this field can only be populated if advertise_mode is CUSTOM and overrides the list defined for the router (in the "bgp" message). These groups are advertised in addition to any specified prefixes. Leave this field blank to advertise no custom groups. - */ - advertisedGroups?: string[]; - /** - * User-specified list of individual IP ranges to advertise in custom mode. This field can only be populated if advertise_mode is CUSTOM and overrides the list defined for the router (in the "bgp" message). These IP ranges are advertised in addition to any specified groups. Leave this field blank to advertise no custom IP ranges. - */ - advertisedIpRanges?: Schema$RouterAdvertisedIpRange[]; - /** - * The priority of routes advertised to this BGP peer. Where there is more than one matching route of maximum length, the routes with the lowest priority value win. - */ - advertisedRoutePriority?: number; - /** - * User-specified flag to indicate which mode to use for advertisement. - */ - advertiseMode?: string; - /** - * BFD configuration for the BGP peering. - */ - bfd?: Schema$RouterBgpPeerBfd; - /** - * The status of the BGP peer connection. If set to FALSE, any active session with the peer is terminated and all associated routing information is removed. If set to TRUE, the peer connection can be established with routing information. The default is TRUE. - */ - enable?: string; - /** - * Name of the interface the BGP peer is associated with. - */ - interfaceName?: string; - /** - * IP address of the interface inside Google Cloud Platform. Only IPv4 is supported. - */ - ipAddress?: string; - /** - * [Output Only] The resource that configures and manages this BGP peer. - MANAGED_BY_USER is the default value and can be managed by you or other users - MANAGED_BY_ATTACHMENT is a BGP peer that is configured and managed by Cloud Interconnect, specifically by an InterconnectAttachment of type PARTNER. Google automatically creates, updates, and deletes this type of BGP peer when the PARTNER InterconnectAttachment is created, updated, or deleted. - */ - managementType?: string; - /** - * Name of this BGP peer. The name must be 1-63 characters long and comply with RFC1035. - */ - name?: string; - /** - * Peer BGP Autonomous System Number (ASN). Each BGP interface may use a different value. - */ - peerAsn?: number; - /** - * IP address of the BGP interface outside Google Cloud Platform. Only IPv4 is supported. - */ - peerIpAddress?: string; - } - export interface Schema$RouterBgpPeerBfd { - /** - * The minimum interval, in milliseconds, between BFD packets received from the peer router. The actual value is negotiated between the two routers and is equal to the greater of this value and the transmit interval of the other router. If BFD echo mode is enabled on this router and the peer router, this value is used to negotiate the interval between BFD echo packets transmitted by the peer router. Otherwise, it will be used to determine the interval between BFD control packets. If set, this value must be between 100 and 30000. The default is 300. - */ - minReceiveInterval?: number; - /** - * The minimum interval, in milliseconds, between BFD packets transmitted to the peer router. The actual value is negotiated between the two routers and is equal to the greater of this value and the corresponding receive interval of the other router. If BFD echo mode is enabled on this router and the peer router, this value is used to negotiate the interval between BFD echo packets transmitted by this router. Otherwise, it will be used to determine the interval between BFD control packets. If set, this value must be between 100 and 30000. The default is 300. - */ - minTransmitInterval?: number; - /** - * The BFD session initialization mode for this BGP peer. If set to ACTIVE, the Cloud Router will initiate the BFD session for this BGP peer. If set to PASSIVE, the Cloud Router will wait for the peer router to initiate the BFD session for this BGP peer. If set to DISABLED, BFD is disabled for this BGP peer. The default is PASSIVE. - */ - mode?: string; - /** - * The number of consecutive BFD packets that must be missed before BFD declares that a peer is unavailable. If set, the value must be a value between 2 and 16. The default is 3. - */ - multiplier?: number; - /** - * The BFD packet mode for this BGP peer. If set to CONTROL_AND_ECHO, BFD echo mode is enabled for this BGP peer. In this mode, if the peer router also has BFD echo mode enabled, BFD echo packets will be sent to the other router. If the peer router does not have BFD echo mode enabled, only control packets will be sent. If set to CONTROL_ONLY, BFD echo mode is disabled for this BGP peer. If this router and the peer router have a multihop connection, this should be set to CONTROL_ONLY as BFD echo mode is only supported on singlehop connections. The default is CONTROL_AND_ECHO. - */ - packetMode?: string; - /** - * The BFD session initialization mode for this BGP peer. If set to ACTIVE, the Cloud Router will initiate the BFD session for this BGP peer. If set to PASSIVE, the Cloud Router will wait for the peer router to initiate the BFD session for this BGP peer. If set to DISABLED, BFD is disabled for this BGP peer. The default is PASSIVE. - */ - sessionInitializationMode?: string; - /** - * The minimum interval, in milliseconds, between BFD control packets transmitted to and received from the peer router when BFD echo mode is enabled on both routers. The actual transmit and receive intervals are negotiated between the two routers and are equal to the greater of this value and the corresponding interval on the other router. If set, this value must be between 1000 and 30000. The default is 5000. - */ - slowTimerInterval?: number; - } - export interface Schema$RouterInterface { - /** - * IP address and range of the interface. The IP range must be in the RFC3927 link-local IP address space. The value must be a CIDR-formatted string, for example: 169.254.0.1/30. NOTE: Do not truncate the address as it represents the IP address of the interface. - */ - ipRange?: string; - /** - * URI of the linked Interconnect attachment. It must be in the same region as the router. Each interface can have one linked resource, which can be either be a VPN tunnel or an Interconnect attachment. - */ - linkedInterconnectAttachment?: string; - /** - * URI of the linked VPN tunnel, which must be in the same region as the router. Each interface can have one linked resource, which can be either a VPN tunnel or an Interconnect attachment. - */ - linkedVpnTunnel?: string; - /** - * [Output Only] The resource that configures and manages this interface. - MANAGED_BY_USER is the default value and can be managed directly by users. - MANAGED_BY_ATTACHMENT is an interface that is configured and managed by Cloud Interconnect, specifically, by an InterconnectAttachment of type PARTNER. Google automatically creates, updates, and deletes this type of interface when the PARTNER InterconnectAttachment is created, updated, or deleted. - */ - managementType?: string; - /** - * Name of this interface entry. The name must be 1-63 characters long and comply with RFC1035. - */ - name?: string; - } - /** - * Contains a list of Router resources. - */ - export interface Schema$RouterList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Router resources. - */ - items?: Schema$Router[]; - /** - * [Output Only] Type of resource. Always compute#router for routers. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents a Nat resource. It enables the VMs within the specified subnetworks to access Internet without external IP addresses. It specifies a list of subnetworks (and the ranges within) that want to use NAT. Customers can also provide the external IPs that would be used for NAT. GCP would auto-allocate ephemeral IPs if no external IPs are provided. - */ - export interface Schema$RouterNat { - /** - * A list of URLs of the IP resources to be drained. These IPs must be valid static external IPs that have been assigned to the NAT. These IPs should be used for updating/patching a NAT only. - */ - drainNatIps?: string[]; - /** - * Timeout (in seconds) for ICMP connections. Defaults to 30s if not set. - */ - icmpIdleTimeoutSec?: number; - /** - * Configure logging on this NAT. - */ - logConfig?: Schema$RouterNatLogConfig; - /** - * Minimum number of ports allocated to a VM from this NAT config. If not set, a default number of ports is allocated to a VM. This is rounded up to the nearest power of 2. For example, if the value of this field is 50, at least 64 ports are allocated to a VM. - */ - minPortsPerVm?: number; - /** - * Unique name of this Nat service. The name must be 1-63 characters long and comply with RFC1035. - */ - name?: string; - /** - * Specify the NatIpAllocateOption, which can take one of the following values: - MANUAL_ONLY: Uses only Nat IP addresses provided by customers. When there are not enough specified Nat IPs, the Nat service fails for new VMs. - AUTO_ONLY: Nat IPs are allocated by Google Cloud Platform; customers can't specify any Nat IPs. When choosing AUTO_ONLY, then nat_ip should be empty. - */ - natIpAllocateOption?: string; - /** - * A list of URLs of the IP resources used for this Nat service. These IP addresses must be valid static external IP addresses assigned to the project. - */ - natIps?: string[]; - /** - * Specify the Nat option, which can take one of the following values: - ALL_SUBNETWORKS_ALL_IP_RANGES: All of the IP ranges in every Subnetwork are allowed to Nat. - ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES: All of the primary IP ranges in every Subnetwork are allowed to Nat. - LIST_OF_SUBNETWORKS: A list of Subnetworks are allowed to Nat (specified in the field subnetwork below) The default is SUBNETWORK_IP_RANGE_TO_NAT_OPTION_UNSPECIFIED. Note that if this field contains ALL_SUBNETWORKS_ALL_IP_RANGES or ALL_SUBNETWORKS_ALL_PRIMARY_IP_RANGES, then there should not be any other Router.Nat section in any Router for this network in this region. - */ - sourceSubnetworkIpRangesToNat?: string; - /** - * A list of Subnetwork resources whose traffic should be translated by NAT Gateway. It is used only when LIST_OF_SUBNETWORKS is selected for the SubnetworkIpRangeToNatOption above. - */ - subnetworks?: Schema$RouterNatSubnetworkToNat[]; - /** - * Timeout (in seconds) for TCP established connections. Defaults to 1200s if not set. - */ - tcpEstablishedIdleTimeoutSec?: number; - /** - * Timeout (in seconds) for TCP transitory connections. Defaults to 30s if not set. - */ - tcpTransitoryIdleTimeoutSec?: number; - /** - * Timeout (in seconds) for UDP connections. Defaults to 30s if not set. - */ - udpIdleTimeoutSec?: number; - } - /** - * Configuration of logging on a NAT. - */ - export interface Schema$RouterNatLogConfig { - /** - * Indicates whether or not to export logs. This is false by default. - */ - enable?: boolean; - /** - * Specifies the desired filtering of logs on this NAT. If unspecified, logs are exported for all connections handled by this NAT. - */ - filter?: string; - } - /** - * Defines the IP ranges that want to use NAT for a subnetwork. - */ - export interface Schema$RouterNatSubnetworkToNat { - /** - * URL for the subnetwork resource that will use NAT. - */ - name?: string; - /** - * A list of the secondary ranges of the Subnetwork that are allowed to use NAT. This can be populated only if "LIST_OF_SECONDARY_IP_RANGES" is one of the values in source_ip_ranges_to_nat. - */ - secondaryIpRangeNames?: string[]; - /** - * Specify the options for NAT ranges in the Subnetwork. All options of a single value are valid except NAT_IP_RANGE_OPTION_UNSPECIFIED. The only valid option with multiple values is: ["PRIMARY_IP_RANGE", "LIST_OF_SECONDARY_IP_RANGES"] Default: [ALL_IP_RANGES] - */ - sourceIpRangesToNat?: string[]; - } - export interface Schema$RoutersPreviewResponse { - /** - * Preview of given router. - */ - resource?: Schema$Router; - } - export interface Schema$RoutersScopedList { - /** - * A list of routers contained in this scope. - */ - routers?: Schema$Router[]; - /** - * Informational warning which replaces the list of routers when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$RouterStatus { - /** - * Best routes for this router's network. - */ - bestRoutes?: Schema$Route[]; - /** - * Best routes learned by this router. - */ - bestRoutesForRouter?: Schema$Route[]; - bgpPeerStatus?: Schema$RouterStatusBgpPeerStatus[]; - natStatus?: Schema$RouterStatusNatStatus[]; - /** - * URI of the network to which this router belongs. - */ - network?: string; - } - export interface Schema$RouterStatusBgpPeerStatus { - /** - * Routes that were advertised to the remote BGP peer - */ - advertisedRoutes?: Schema$Route[]; - bfdStatus?: Schema$BfdStatus; - /** - * IP address of the local BGP interface. - */ - ipAddress?: string; - /** - * URL of the VPN tunnel that this BGP peer controls. - */ - linkedVpnTunnel?: string; - /** - * Name of this BGP peer. Unique within the Routers resource. - */ - name?: string; - /** - * Number of routes learned from the remote BGP Peer. - */ - numLearnedRoutes?: number; - /** - * IP address of the remote BGP interface. - */ - peerIpAddress?: string; - /** - * BGP state as specified in RFC1771. - */ - state?: string; - /** - * Status of the BGP peer: {UP, DOWN} - */ - status?: string; - /** - * Time this session has been up. Format: 14 years, 51 weeks, 6 days, 23 hours, 59 minutes, 59 seconds - */ - uptime?: string; - /** - * Time this session has been up, in seconds. Format: 145 - */ - uptimeSeconds?: string; - } - /** - * Status of a NAT contained in this router. Next tag: 9 - */ - export interface Schema$RouterStatusNatStatus { - /** - * A list of IPs auto-allocated for NAT. Example: ["1.1.1.1", "129.2.16.89"] - */ - autoAllocatedNatIps?: string[]; - /** - * A list of IPs auto-allocated for NAT that are in drain mode. Example: ["1.1.1.1", ?179.12.26.133?]. - */ - drainAutoAllocatedNatIps?: string[]; - /** - * A list of IPs user-allocated for NAT that are in drain mode. Example: ["1.1.1.1", ?179.12.26.133?]. - */ - drainUserAllocatedNatIps?: string[]; - /** - * The number of extra IPs to allocate. This will be greater than 0 only if user-specified IPs are NOT enough to allow all configured VMs to use NAT. This value is meaningful only when auto-allocation of NAT IPs is *not* used. - */ - minExtraNatIpsNeeded?: number; - /** - * Unique name of this NAT. - */ - name?: string; - /** - * Number of VM endpoints (i.e., Nics) that can use NAT. - */ - numVmEndpointsWithNatMappings?: number; - /** - * A list of fully qualified URLs of reserved IP address resources. - */ - userAllocatedNatIpResources?: string[]; - /** - * A list of IPs user-allocated for NAT. They will be raw IP strings like "179.12.26.133". - */ - userAllocatedNatIps?: string[]; - } - export interface Schema$RouterStatusResponse { - /** - * Type of resource. - */ - kind?: string; - result?: Schema$RouterStatus; - } - /** - * A rule to be applied in a Policy. - */ - export interface Schema$Rule { - /** - * Required - */ - action?: string; - /** - * Additional restrictions that must be met. All conditions must pass for the rule to match. - */ - conditions?: Schema$Condition[]; - /** - * Human-readable description of the rule. - */ - description?: string; - /** - * If one or more 'in' clauses are specified, the rule matches if the PRINCIPAL/AUTHORITY_SELECTOR is in at least one of these entries. - */ - ins?: string[]; - /** - * The config returned to callers of tech.iam.IAM.CheckPolicy for any entries that match the LOG action. - */ - logConfigs?: Schema$LogConfig[]; - /** - * If one or more 'not_in' clauses are specified, the rule matches if the PRINCIPAL/AUTHORITY_SELECTOR is in none of the entries. - */ - notIns?: string[]; - /** - * A permission is a string of form '..' (e.g., 'storage.buckets.list'). A value of '*' matches all permissions, and a verb part of '*' (e.g., 'storage.buckets.*') matches all verbs. - */ - permissions?: string[]; - } - /** - * An instance-attached disk resource. - */ - export interface Schema$SavedAttachedDisk { - /** - * Specifies whether the disk will be auto-deleted when the instance is deleted (but not when the disk is detached from the instance). - */ - autoDelete?: boolean; - /** - * Indicates that this is a boot disk. The virtual machine will use the first partition of the disk for its root filesystem. - */ - boot?: boolean; - /** - * Specifies the name of the disk attached to the source instance. - */ - deviceName?: string; - /** - * The encryption key for the disk. - */ - diskEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * The size of the disk in base-2 GB. - */ - diskSizeGb?: string; - /** - * A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options. - */ - guestOsFeatures?: Schema$GuestOsFeature[]; - /** - * Specifies zero-based index of the disk that is attached to the source instance. - */ - index?: number; - /** - * Specifies the disk interface to use for attaching this disk, which is either SCSI or NVME. - */ - interface?: string; - /** - * [Output Only] Type of the resource. Always compute#attachedDisk for attached disks. - */ - kind?: string; - /** - * [Output Only] Any valid publicly visible licenses. - */ - licenses?: string[]; - /** - * The mode in which this disk is attached to the source instance, either READ_WRITE or READ_ONLY. - */ - mode?: string; - /** - * Specifies a URL of the disk attached to the source instance. - */ - source?: string; - /** - * [Output Only] A size of the storage used by the disk's snapshot by this machine image. - */ - storageBytes?: string; - /** - * [Output Only] An indicator whether storageBytes is in a stable state or it is being adjusted as a result of shared storage reallocation. This status can either be UPDATING, meaning the size of the snapshot is being updated, or UP_TO_DATE, meaning the size of the snapshot is up-to-date. - */ - storageBytesStatus?: string; - /** - * Specifies the type of the attached disk, either SCRATCH or PERSISTENT. - */ - type?: string; - } - /** - * Sets the scheduling options for an Instance. NextID: 9 - */ - export interface Schema$Scheduling { - /** - * Specifies whether the instance should be automatically restarted if it is terminated by Compute Engine (not terminated by a user). You can only set the automatic restart option for standard instances. Preemptible instances cannot be automatically restarted. By default, this is set to true so an instance is automatically restarted if it is terminated by Compute Engine. - */ - automaticRestart?: boolean; - /** - * Defines whether the instance is tolerant of higher cpu latency. This can only be set during instance creation, or when the instance is not currently running. It must not be set if the preemptible option is also set. - */ - latencyTolerant?: boolean; - /** - * The minimum number of virtual CPUs this instance will consume when running on a sole-tenant node. - */ - minNodeCpus?: number; - /** - * A set of node affinity and anti-affinity configurations. Refer to Configuring node affinity for more information. - */ - nodeAffinities?: Schema$SchedulingNodeAffinity[]; - /** - * Defines the maintenance behavior for this instance. For standard instances, the default behavior is MIGRATE. For preemptible instances, the default and only possible behavior is TERMINATE. For more information, see Setting Instance Scheduling Options. - */ - onHostMaintenance?: string; - /** - * Defines whether the instance is preemptible. This can only be set during instance creation, it cannot be set or changed after the instance has been created. - */ - preemptible?: boolean; - } - /** - * Node Affinity: the configuration of desired nodes onto which this Instance could be scheduled. - */ - export interface Schema$SchedulingNodeAffinity { - /** - * Corresponds to the label key of Node resource. - */ - key?: string; - /** - * Defines the operation of node selection. Valid operators are IN for affinity and NOT_IN for anti-affinity. - */ - operator?: string; - /** - * Corresponds to the label values of Node resource. - */ - values?: string[]; - } - /** - * The configuration to access the SDS server. - */ - export interface Schema$SdsConfig { - /** - * The configuration to access the SDS server over GRPC. - */ - grpcServiceConfig?: Schema$GrpcServiceConfig; - } - export interface Schema$SecurityPoliciesListPreconfiguredExpressionSetsResponse { - preconfiguredExpressionSets?: Schema$SecurityPoliciesWafConfig; - } - export interface Schema$SecurityPoliciesWafConfig { - wafRules?: Schema$PreconfiguredWafSet; - } - /** - * Represents a Cloud Armor Security Policy resource. Only external backend services that use load balancers can reference a Security Policy. For more information, read Cloud Armor Security Policy Concepts. (== resource_for v1.securityPolicies ==) (== resource_for beta.securityPolicies ==) - */ - export interface Schema$SecurityPolicy { - /** - * A list of assocations that belong to this policy. - */ - associations?: Schema$SecurityPolicyAssociation[]; - cloudArmorConfig?: Schema$SecurityPolicyCloudArmorConfig; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * Specifies a fingerprint for this resource, which is essentially a hash of the metadata's contents and used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update metadata. You must always provide an up-to-date fingerprint hash in order to update or change metadata, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make get() request to the security policy. - */ - fingerprint?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output only] Type of the resource. Always compute#securityPolicyfor security policies - */ - kind?: string; - /** - * A fingerprint for the labels being applied to this security policy, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels. To see the latest fingerprint, make get() request to the security policy. - */ - labelFingerprint?: string; - /** - * Labels to apply to this security policy resource. These can be later modified by the setLabels method. Each label key/value must comply with RFC1035. Label values may be empty. - */ - labels?: {[key: string]: string}; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * A list of rules that belong to this policy. There must always be a default rule (rule with priority 2147483647 and match "*"). If no rules are provided when creating a security policy, a default rule with action "allow" will be added. - */ - rules?: Schema$SecurityPolicyRule[]; - /** - * [Output Only] Total count of all security policy rule tuples. A security policy can not exceed a set number of tuples. - */ - ruleTupleCount?: number; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * The type indicates the intended use of the security policy. CLOUD_ARMOR policies apply to backend services. FIREWALL policies apply to organizations. - */ - type?: string; - } - export interface Schema$SecurityPolicyAssociation { - /** - * The resource that the security policy is attached to. - */ - attachmentId?: string; - /** - * The name for an association. - */ - name?: string; - /** - * [Output Only] The security policy ID of the association. - */ - securityPolicyId?: string; - } - /** - * Configuration options for Cloud Armor. - */ - export interface Schema$SecurityPolicyCloudArmorConfig { - /** - * If set to true, enables Cloud Armor Machine Learning. - */ - enableMl?: boolean; - } - export interface Schema$SecurityPolicyList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of SecurityPolicy resources. - */ - items?: Schema$SecurityPolicy[]; - /** - * [Output Only] Type of resource. Always compute#securityPolicyList for listsof securityPolicies - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$SecurityPolicyReference { - securityPolicy?: string; - } - /** - * Represents a rule that describes one or more match conditions along with the action to be taken when traffic matches this condition (allow or deny). - */ - export interface Schema$SecurityPolicyRule { - /** - * The Action to preform when the client connection triggers the rule. Can currently be either "allow" or "deny()" where valid values for status are 403, 404, and 502. - */ - action?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * The direction in which this rule applies. This field may only be specified when versioned_expr is set to FIREWALL. - */ - direction?: string; - /** - * Denotes whether to enable logging for a particular rule. If logging is enabled, logs will be exported to the configured export destination in Stackdriver. Logs may be exported to BigQuery or Pub/Sub. Note: you cannot enable logging on "goto_next" rules. This field may only be specified when the versioned_expr is set to FIREWALL. - */ - enableLogging?: boolean; - /** - * [Output only] Type of the resource. Always compute#securityPolicyRule for security policy rules - */ - kind?: string; - /** - * A match condition that incoming traffic is evaluated against. If it evaluates to true, the corresponding ?action? is enforced. - */ - match?: Schema$SecurityPolicyRuleMatcher; - /** - * If set to true, the specified action is not enforced. - */ - preview?: boolean; - /** - * An integer indicating the priority of a rule in the list. The priority must be a positive value between 0 and 2147483647. Rules are evaluated from highest to lowest priority where 0 is the highest priority and 2147483647 is the lowest prority. - */ - priority?: number; - /** - * Must be specified if the action is "rate_based_blacklist" or "throttle". Cannot be specified for any other actions. - */ - rateLimitOptions?: Schema$SecurityPolicyRuleRateLimitOptions; - /** - * [Output Only] Calculation of the complexity of a single firewall security policy rule. - */ - ruleTupleCount?: number; - /** - * A list of network resource URLs to which this rule applies. This field allows you to control which network?s VMs get this rule. If this field is left blank, all VMs within the organization will receive the rule. This field may only be specified when versioned_expr is set to FIREWALL. - */ - targetResources?: string[]; - } - /** - * Represents a match condition that incoming traffic is evaluated against. Exactly one field must be specified. - */ - export interface Schema$SecurityPolicyRuleMatcher { - /** - * The configuration options available when specifying versioned_expr. This field must be specified if versioned_expr is specified and cannot be specified if versioned_expr is not specified. - */ - config?: Schema$SecurityPolicyRuleMatcherConfig; - /** - * User defined CEVAL expression. A CEVAL expression is used to specify match criteria such as origin.ip, source.region_code and contents in the request header. - */ - expr?: Schema$Expr; - /** - * Preconfigured versioned expression. If this field is specified, config must also be specified. Available preconfigured expressions along with their requirements are: SRC_IPS_V1 - must specify the corresponding src_ip_range field in config. - */ - versionedExpr?: string; - } - export interface Schema$SecurityPolicyRuleMatcherConfig { - /** - * CIDR IP address range. This field may only be specified when versioned_expr is set to FIREWALL. - */ - destIpRanges?: string[]; - /** - * Pairs of IP protocols and ports that the rule should match. This field may only be specified when versioned_expr is set to FIREWALL. - */ - destPorts?: Schema$SecurityPolicyRuleMatcherConfigDestinationPort[]; - /** - * CIDR IP address range. - */ - srcIpRanges?: string[]; - } - export interface Schema$SecurityPolicyRuleMatcherConfigDestinationPort { - /** - * The IP protocol to which this rule applies. The protocol type is required when creating a firewall rule. This value can either be one of the following well known protocol strings (tcp, udp, icmp, esp, ah, ipip, sctp), or the IP protocol number. - */ - ipProtocol?: string; - /** - * An optional list of ports to which this rule applies. This field is only applicable for UDP or TCP protocol. Each entry must be either an integer or a range. If not specified, this rule applies to connections through any port. Example inputs include: ["22"], ["80","443"], and ["12345-12349"]. This field may only be specified when versioned_expr is set to FIREWALL. - */ - ports?: string[]; - } - export interface Schema$SecurityPolicyRuleRateLimitOptions { - /** - * Can only be specifed if the action for the rule is "rate_based_blacklist" If specified, determines the time (in seconds) the traffic will continue to be blocked by the rate limit after the rate falls below the threshold. The default value is 0 seconds. - */ - blockDuration?: number; - /** - * Action to take when requests are under the given threshold. When requests are throttled, this is also the action for all requests which are not dropped. Valid options are "allow", "fairshare", and "drop_overload". - */ - conformAction?: string; - /** - * Determines the key to enforce the threshold_rps limit on. If key is "IP", each IP has this limit enforced separately, whereas "ALL_IPs" means a single limit is applied to all requests matching this rule. - */ - enforceOnKey?: string; - /** - * When a request is denied, returns the HTTP response code specified. Valid options are "deny()" where valid values for status are 403, 404, 429, and 502. - */ - exceedAction?: string; - /** - * Rate in requests per second at which to begin ratelimiting. - */ - thresholdRps?: number; - } - /** - * The authentication and authorization settings for a BackendService. - */ - export interface Schema$SecuritySettings { - /** - * Authentication policy defines what authentication methods can be accepted on backends, and if authenticated, which method/certificate will set the request principal. - */ - authenticationPolicy?: Schema$AuthenticationPolicy; - /** - * Authorization config defines the Role Based Access Control (RBAC) config. - */ - authorizationConfig?: Schema$AuthorizationConfig; - /** - * TLS Settings for the backend service. - */ - clientTlsSettings?: Schema$ClientTlsSettings; - } - /** - * An instance's serial console output. - */ - export interface Schema$SerialPortOutput { - /** - * [Output Only] The contents of the console output. - */ - contents?: string; - /** - * [Output Only] Type of the resource. Always compute#serialPortOutput for serial port output. - */ - kind?: string; - /** - * [Output Only] The position of the next byte of content from the serial console output. Use this value in the next request as the start parameter. - */ - next?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * The starting byte position of the output that was returned. This should match the start parameter sent with the request. If the serial console output exceeds the size of the buffer, older output will be overwritten by newer content and the start values will be mismatched. - */ - start?: string; - } - export interface Schema$ServerBinding { - type?: string; - } - /** - * The TLS settings for the server. - */ - export interface Schema$ServerTlsSettings { - /** - * Configures the mechanism to obtain security certificates and identity information. - */ - proxyTlsContext?: Schema$TlsContext; - /** - * A list of alternate names to verify the subject identity in the certificate presented by the client. - */ - subjectAltNames?: string[]; - /** - * Indicates whether connections should be secured using TLS. The value of this field determines how TLS is enforced. This field can be set to one of the following: - SIMPLE Secure connections with standard TLS semantics. - MUTUAL Secure connections to the backends using mutual TLS by presenting client certificates for authentication. - */ - tlsMode?: string; - } - /** - * A service account. - */ - export interface Schema$ServiceAccount { - /** - * Email address of the service account. - */ - email?: string; - /** - * The list of scopes to be made available for this service account. - */ - scopes?: string[]; - } - /** - * A set of Shielded Instance options. - */ - export interface Schema$ShieldedInstanceConfig { - /** - * Defines whether the instance has integrity monitoring enabled. - */ - enableIntegrityMonitoring?: boolean; - /** - * Defines whether the instance has Secure Boot enabled. - */ - enableSecureBoot?: boolean; - /** - * Defines whether the instance has the vTPM enabled. - */ - enableVtpm?: boolean; - } - /** - * A shielded Instance identity entry. - */ - export interface Schema$ShieldedInstanceIdentity { - /** - * An Endorsement Key (EK) issued to the Shielded Instance's vTPM. - */ - encryptionKey?: Schema$ShieldedInstanceIdentityEntry; - /** - * [Output Only] Type of the resource. Always compute#shieldedInstanceIdentity for shielded Instance identity entry. - */ - kind?: string; - /** - * An Attestation Key (AK) issued to the Shielded Instance's vTPM. - */ - signingKey?: Schema$ShieldedInstanceIdentityEntry; - } - /** - * A Shielded Instance Identity Entry. - */ - export interface Schema$ShieldedInstanceIdentityEntry { - /** - * A PEM-encoded X.509 certificate. This field can be empty. - */ - ekCert?: string; - /** - * A PEM-encoded public key. - */ - ekPub?: string; - } - /** - * The policy describes the baseline against which Instance boot integrity is measured. - */ - export interface Schema$ShieldedInstanceIntegrityPolicy { - /** - * Updates the integrity policy baseline using the measurements from the VM instance's most recent boot. - */ - updateAutoLearnPolicy?: boolean; - } - /** - * A set of Shielded VM options. - */ - export interface Schema$ShieldedVmConfig { - /** - * Defines whether the instance has integrity monitoring enabled. - */ - enableIntegrityMonitoring?: boolean; - /** - * Defines whether the instance has Secure Boot enabled. - */ - enableSecureBoot?: boolean; - /** - * Defines whether the instance has the vTPM enabled. - */ - enableVtpm?: boolean; - } - /** - * A shielded VM identity entry. - */ - export interface Schema$ShieldedVmIdentity { - /** - * An Endorsement Key (EK) issued to the Shielded VM's vTPM. - */ - encryptionKey?: Schema$ShieldedVmIdentityEntry; - /** - * [Output Only] Type of the resource. Always compute#shieldedVmIdentity for shielded VM identity entry. - */ - kind?: string; - /** - * An Attestation Key (AK) issued to the Shielded VM's vTPM. - */ - signingKey?: Schema$ShieldedVmIdentityEntry; - } - /** - * A Shielded Instance Identity Entry. - */ - export interface Schema$ShieldedVmIdentityEntry { - /** - * A PEM-encoded X.509 certificate. This field can be empty. - */ - ekCert?: string; - /** - * A PEM-encoded public key. - */ - ekPub?: string; - } - /** - * The policy describes the baseline against which VM instance boot integrity is measured. - */ - export interface Schema$ShieldedVmIntegrityPolicy { - /** - * Updates the integrity policy baseline using the measurements from the VM instance's most recent boot. - */ - updateAutoLearnPolicy?: boolean; - } - /** - * Represents a customer-supplied Signing Key used by Cloud CDN Signed URLs - */ - export interface Schema$SignedUrlKey { - /** - * Name of the key. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - keyName?: string; - /** - * 128-bit key value used for signing the URL. The key value must be a valid RFC 4648 Section 5 base64url encoded string. - */ - keyValue?: string; - } - /** - * Represents a Persistent Disk Snapshot resource. You can use snapshots to back up data on a regular interval. For more information, read Creating persistent disk snapshots. (== resource_for beta.snapshots ==) (== resource_for v1.snapshots ==) - */ - export interface Schema$Snapshot { - /** - * [Output Only] Set to true if snapshots are automatically by applying resource policy on the target disk. - */ - autoCreated?: boolean; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] Size of the snapshot, specified in GB. - */ - diskSizeGb?: string; - /** - * [Output Only] A list of features to enable on the guest operating system. Applicable only for bootable images. Read Enabling guest operating system features to see a list of available options. - */ - guestOsFeatures?: Schema$GuestOsFeature[]; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#snapshot for Snapshot resources. - */ - kind?: string; - /** - * A fingerprint for the labels being applied to this snapshot, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a snapshot. - */ - labelFingerprint?: string; - /** - * Labels to apply to this snapshot. These can be later modified by the setLabels method. Label values may be empty. - */ - labels?: {[key: string]: string}; - /** - * [Output Only] Integer license codes indicating which licenses are attached to this snapshot. - */ - licenseCodes?: string[]; - /** - * [Output Only] A list of public visible licenses that apply to this snapshot. This can be because the original image had licenses attached (such as a Windows image). - */ - licenses?: string[]; - /** - * Name of the resource; provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource's resource id. - */ - selfLinkWithId?: string; - /** - * Encrypts the snapshot using a customer-supplied encryption key. After you encrypt a snapshot using a customer-supplied key, you must provide the same key if you use the snapshot later. For example, you must provide the encryption key when you create a disk from the encrypted snapshot in a future request. Customer-supplied encryption keys do not protect access to metadata of the snapshot. If you do not provide an encryption key when creating the snapshot, then the snapshot will be encrypted using an automatically generated key and you do not need to provide a key to use the snapshot later. - */ - snapshotEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * [Output Only] The source disk used to create this snapshot. - */ - sourceDisk?: string; - /** - * The customer-supplied encryption key of the source disk. Required if the source disk is protected by a customer-supplied encryption key. - */ - sourceDiskEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * [Output Only] The ID value of the disk used to create this snapshot. This value may be used to determine whether the snapshot was taken from the current or a previous instance of a given disk name. - */ - sourceDiskId?: string; - /** - * [Output Only] The status of the snapshot. This can be CREATING, DELETING, FAILED, READY, or UPLOADING. - */ - status?: string; - /** - * [Output Only] A size of the storage used by the snapshot. As snapshots share storage, this number is expected to change with snapshot creation/deletion. - */ - storageBytes?: string; - /** - * [Output Only] An indicator whether storageBytes is in a stable state or it is being adjusted as a result of shared storage reallocation. This status can either be UPDATING, meaning the size of the snapshot is being updated, or UP_TO_DATE, meaning the size of the snapshot is up-to-date. - */ - storageBytesStatus?: string; - /** - * GCS bucket storage location of the snapshot (regional or multi-regional). - */ - storageLocations?: string[]; - } - /** - * Contains a list of Snapshot resources. - */ - export interface Schema$SnapshotList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Snapshot resources. - */ - items?: Schema$Snapshot[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$SourceDiskEncryptionKey { - /** - * The customer-supplied encryption key of the source disk. Required if the source disk is protected by a customer-supplied encryption key. - */ - diskEncryptionKey?: Schema$CustomerEncryptionKey; - /** - * URL of the disk attached to the source instance. This can be a full or valid partial URL. For example, the following are valid values: - https://www.googleapis.com/compute/v1/projects/project/zones/zone/disks/disk - projects/project/zones/zone/disks/disk - zones/zone/disks/disk - */ - sourceDisk?: string; - } - /** - * A specification of the parameters to use when creating the instance template from a source instance. - */ - export interface Schema$SourceInstanceParams { - /** - * Attached disks configuration. If not provided, defaults are applied: For boot disk and any other R/W disks, new custom images will be created from each disk. For read-only disks, they will be attached in read-only mode. Local SSD disks will be created as blank volumes. - */ - diskConfigs?: Schema$DiskInstantiationConfig[]; - } - export interface Schema$SourceInstanceProperties { - /** - * Enables instances created based on this machine image to send packets with source IP addresses other than their own and receive packets with destination IP addresses other than their own. If these instances will be used as an IP gateway or it will be set as the next-hop in a Route resource, specify true. If unsure, leave this set to false. See the Enable IP forwarding documentation for more information. - */ - canIpForward?: boolean; - /** - * Whether the instance created from this machine image should be protected against deletion. - */ - deletionProtection?: boolean; - /** - * An optional text description for the instances that are created from this machine image. - */ - description?: string; - /** - * An array of disks that are associated with the instances that are created from this machine image. - */ - disks?: Schema$SavedAttachedDisk[]; - /** - * A list of guest accelerator cards' type and count to use for instances created from this machine image. - */ - guestAccelerators?: Schema$AcceleratorConfig[]; - /** - * Labels to apply to instances that are created from this machine image. - */ - labels?: {[key: string]: string}; - /** - * The machine type to use for instances that are created from this machine image. - */ - machineType?: string; - /** - * The metadata key/value pairs to assign to instances that are created from this machine image. These pairs can consist of custom metadata or predefined keys. See Project and instance metadata for more information. - */ - metadata?: Schema$Metadata; - /** - * Minimum cpu/platform to be used by instances created from this machine image. The instance may be scheduled on the specified or newer cpu/platform. Applicable values are the friendly names of CPU platforms, such as minCpuPlatform: "Intel Haswell" or minCpuPlatform: "Intel Sandy Bridge". For more information, read Specifying a Minimum CPU Platform. - */ - minCpuPlatform?: string; - /** - * An array of network access configurations for this interface. - */ - networkInterfaces?: Schema$NetworkInterface[]; - /** - * Specifies the scheduling options for the instances that are created from this machine image. - */ - scheduling?: Schema$Scheduling; - /** - * A list of service accounts with specified scopes. Access tokens for these service accounts are available to the instances that are created from this machine image. Use metadata queries to obtain the access tokens for these instances. - */ - serviceAccounts?: Schema$ServiceAccount[]; - /** - * A list of tags to apply to the instances that are created from this machine image. The tags identify valid sources or targets for network firewalls. The setTags method can modify this list of tags. Each tag within the list must comply with RFC1035. - */ - tags?: Schema$Tags; - } - /** - * Represents an SSL Certificate resource. This SSL certificate resource also contains a private key. You can use SSL keys and certificates to secure connections to a load balancer. For more information, read Creating and Using SSL Certificates. (== resource_for beta.sslCertificates ==) (== resource_for v1.sslCertificates ==) - */ - export interface Schema$SslCertificate { - /** - * A local certificate file. The certificate must be in PEM format. The certificate chain must be no greater than 5 certs long. The chain must include at least one intermediate cert. - */ - certificate?: string; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] Expire time of the certificate. RFC3339 - */ - expireTime?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#sslCertificate for SSL certificates. - */ - kind?: string; - /** - * Configuration and status of a managed SSL certificate. - */ - managed?: Schema$SslCertificateManagedSslCertificate; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * A write-only private key in PEM format. Only insert requests will include this field. - */ - privateKey?: string; - /** - * [Output Only] URL of the region where the regional SSL Certificate resides. This field is not applicable to global SSL Certificate. - */ - region?: string; - /** - * [Output only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * Configuration and status of a self-managed SSL certificate. - */ - selfManaged?: Schema$SslCertificateSelfManagedSslCertificate; - /** - * [Output Only] Domains associated with the certificate via Subject Alternative Name. - */ - subjectAlternativeNames?: string[]; - /** - * (Optional) Specifies the type of SSL certificate, either "SELF_MANAGED" or "MANAGED". If not specified, the certificate is self-managed and the fields certificate and private_key are used. - */ - type?: string; - } - export interface Schema$SslCertificateAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of SslCertificatesScopedList resources. - */ - items?: {[key: string]: Schema$SslCertificatesScopedList}; - /** - * [Output Only] Type of resource. Always compute#sslCertificateAggregatedList for lists of SSL Certificates. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of SslCertificate resources. - */ - export interface Schema$SslCertificateList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of SslCertificate resources. - */ - items?: Schema$SslCertificate[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Configuration and status of a managed SSL certificate. - */ - export interface Schema$SslCertificateManagedSslCertificate { - /** - * The domains for which a managed SSL certificate will be generated. Currently only single-domain certs are supported. - */ - domains?: string[]; - /** - * [Output only] Detailed statuses of the domains specified for managed certificate resource. - */ - domainStatus?: {[key: string]: string}; - /** - * [Output only] Status of the managed certificate resource. - */ - status?: string; - } - /** - * Configuration and status of a self-managed SSL certificate. - */ - export interface Schema$SslCertificateSelfManagedSslCertificate { - /** - * A local certificate file. The certificate must be in PEM format. The certificate chain must be no greater than 5 certs long. The chain must include at least one intermediate cert. - */ - certificate?: string; - /** - * A write-only private key in PEM format. Only insert requests will include this field. - */ - privateKey?: string; - } - export interface Schema$SslCertificatesScopedList { - /** - * List of SslCertificates contained in this scope. - */ - sslCertificates?: Schema$SslCertificate[]; - /** - * Informational warning which replaces the list of backend services when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$SSLHealthCheck { - /** - * The TCP port number for the health check request. The default value is 443. Valid values are 1 through 65535. - */ - port?: number; - /** - * Port name as defined in InstanceGroup#NamedPort#name. If both port and port_name are defined, port takes precedence. - */ - portName?: string; - /** - * Specifies how port is selected for health checking, can be one of following values: USE_FIXED_PORT: The port number in port is used for health checking. USE_NAMED_PORT: The portName is used for health checking. USE_SERVING_PORT: For NetworkEndpointGroup, the port specified for each network endpoint is used for health checking. For other backends, the port or named port specified in the Backend Service is used for health checking. If not specified, SSL health check follows behavior specified in port and portName fields. - */ - portSpecification?: string; - /** - * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. - */ - proxyHeader?: string; - /** - * The application data to send once the SSL connection has been established (default value is empty). If both request and response are empty, the connection establishment alone will indicate health. The request data can only be ASCII. - */ - request?: string; - /** - * The bytes to match against the beginning of the response data. If left empty (the default value), any response will indicate health. The response data can only be ASCII. - */ - response?: string; - } - export interface Schema$SslPoliciesList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of SslPolicy resources. - */ - items?: Schema$SslPolicy[]; - /** - * [Output Only] Type of the resource. Always compute#sslPoliciesList for lists of sslPolicies. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$SslPoliciesListAvailableFeaturesResponse { - features?: string[]; - } - /** - * Represents a Cloud Armor Security Policy resource. Only external backend services used by HTTP or HTTPS load balancers can reference a Security Policy. For more information, read read Cloud Armor Security Policy Concepts. (== resource_for beta.sslPolicies ==) (== resource_for v1.sslPolicies ==) - */ - export interface Schema$SslPolicy { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * A list of features enabled when the selected profile is CUSTOM. The - method returns the set of features that can be specified in this list. This field must be empty if the profile is not CUSTOM. - */ - customFeatures?: string[]; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The list of features enabled in the SSL policy. - */ - enabledFeatures?: string[]; - /** - * Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a SslPolicy. An up-to-date fingerprint must be provided in order to update the SslPolicy, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an SslPolicy. - */ - fingerprint?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output only] Type of the resource. Always compute#sslPolicyfor SSL policies. - */ - kind?: string; - /** - * The minimum version of SSL protocol that can be used by the clients to establish a connection with the load balancer. This can be one of TLS_1_0, TLS_1_1, TLS_1_2. - */ - minTlsVersion?: string; - /** - * Name of the resource. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * Profile specifies the set of SSL features that can be used by the load balancer when negotiating SSL with clients. This can be one of COMPATIBLE, MODERN, RESTRICTED, or CUSTOM. If using CUSTOM, the set of SSL features to enable must be specified in the customFeatures field. - */ - profile?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * Security settings for the proxy. This field is only applicable to a global backend service with the loadBalancingScheme set to INTERNAL_SELF_MANAGED. - */ - tlsSettings?: Schema$ServerTlsSettings; - /** - * [Output Only] If potential misconfigurations are detected for this SSL policy, this field will be populated with warning messages. - */ - warnings?: Array<{ - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }>; - } - export interface Schema$SslPolicyReference { - /** - * URL of the SSL policy resource. Set this to empty string to clear any existing SSL policy associated with the target proxy resource. - */ - sslPolicy?: string; - } - export interface Schema$StatefulPolicy { - preservedState?: Schema$StatefulPolicyPreservedState; - } - /** - * Configuration of preserved resources. - */ - export interface Schema$StatefulPolicyPreservedState { - /** - * Disks created on the instances that will be preserved on instance delete, update, etc. This map is keyed with the device names of the disks. - */ - disks?: {[key: string]: Schema$StatefulPolicyPreservedStateDiskDevice}; - } - export interface Schema$StatefulPolicyPreservedStateDiskDevice { - /** - * These stateful disks will never be deleted during autohealing, update or VM instance recreate operations. This flag is used to configure if the disk should be deleted after it is no longer used by the group, e.g. when the given instance or the whole group is deleted. Note: disks attached in READ_ONLY mode cannot be auto-deleted. - */ - autoDelete?: string; - } - /** - * Represents a Subnetwork resource. A subnetwork (also known as a subnet) is a logical partition of a Virtual Private Cloud network with one primary IP range and zero or more secondary IP ranges. For more information, read Virtual Private Cloud (VPC) Network. (== resource_for beta.subnetworks ==) (== resource_for v1.subnetworks ==) - */ - export interface Schema$Subnetwork { - /** - * Can only be specified if VPC flow logging for this subnetwork is enabled. Sets the aggregation interval for collecting flow logs. Increasing the interval time reduces the amount of generated flow logs for long-lasting connections. Default is an interval of 5 seconds per connection. Valid values: INTERVAL_5_SEC, INTERVAL_30_SEC, INTERVAL_1_MIN, INTERVAL_5_MIN, INTERVAL_10_MIN, INTERVAL_15_MIN. - */ - aggregationInterval?: string; - /** - * Whether this subnetwork can conflict with static routes. Setting this to true allows this subnetwork's primary and secondary ranges to conflict with routes that have already been configured on the corresponding network. Static routes will take precedence over the subnetwork route if the route prefix length is at least as large as the subnetwork prefix length. Also, packets destined to IPs within subnetwork may contain private/sensitive data and are prevented from leaving the virtual network. Setting this field to true will disable this feature. The default value is false and applies to all existing subnetworks and automatically created subnetworks. This field cannot be set to true at resource creation time. - */ - allowSubnetCidrRoutesOverlap?: boolean; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. This field can be set only at resource creation time. - */ - description?: string; - /** - * Whether to enable flow logging for this subnetwork. If this field is not explicitly set, it will not appear in get listings. If not set the default behavior is to disable flow logging. - */ - enableFlowLogs?: boolean; - /** - * Deprecated in favor of enable in PrivateIpv6GoogleAccess. Whether the VMs in this subnet can directly access Google services via internal IPv6 addresses. This field can be both set at resource creation time and updated using patch. - */ - enablePrivateV6Access?: boolean; - /** - * Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a Subnetwork. An up-to-date fingerprint must be provided in order to update the Subnetwork, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a Subnetwork. - */ - fingerprint?: string; - /** - * Can only be specified if VPC flow logging for this subnetwork is enabled. The value of the field must be in [0, 1]. Set the sampling rate of VPC flow logs within the subnetwork where 1.0 means all collected logs are reported and 0.0 means no logs are reported. Default is 0.5, which means half of all collected logs are reported. - */ - flowSampling?: number; - /** - * [Output Only] The gateway address for default routes to reach destination addresses outside this subnetwork. - */ - gatewayAddress?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * The range of internal addresses that are owned by this subnetwork. Provide this property when you create the subnetwork. For example, 10.0.0.0/8 or 192.168.0.0/16. Ranges must be unique and non-overlapping within a network. Only IPv4 is supported. This field can be set only at resource creation time. - */ - ipCidrRange?: string; - /** - * [Output Only] The range of internal IPv6 addresses that are owned by this subnetwork. - */ - ipv6CidrRange?: string; - /** - * [Output Only] Type of the resource. Always compute#subnetwork for Subnetwork resources. - */ - kind?: string; - /** - * This field denotes the VPC flow logging options for this subnetwork. If logging is enabled, logs are exported to Stackdriver. - */ - logConfig?: Schema$SubnetworkLogConfig; - /** - * Can only be specified if VPC flow logging for this subnetwork is enabled. Configures whether metadata fields should be added to the reported VPC flow logs. Default is INCLUDE_ALL_METADATA. - */ - metadata?: string; - /** - * The name of the resource, provided by the client when initially creating the resource. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * The URL of the network to which this subnetwork belongs, provided by the client when initially creating the subnetwork. Only networks that are in the distributed mode can have subnetworks. This field can be set only at resource creation time. - */ - network?: string; - /** - * Whether the VMs in this subnet can access Google services without assigned external IP addresses. This field can be both set at resource creation time and updated using setPrivateIpGoogleAccess. - */ - privateIpGoogleAccess?: boolean; - /** - * The private IPv6 google access type for the VMs in this subnet. This is an expanded field of enablePrivateV6Access. If both fields are set, privateIpv6GoogleAccess will take priority. This field can be both set at resource creation time and updated using patch. - */ - privateIpv6GoogleAccess?: string; - /** - * The service accounts can be used to selectively turn on Private IPv6 Google Access only on the VMs primary service account matching the value. This value only takes effect when PrivateIpv6GoogleAccess is ENABLE_OUTBOUND_VM_ACCESS_TO_GOOGLE_FOR_SERVICE_ACCOUNTS or ENABLE_BIDIRECTIONAL_ACCESS_TO_GOOGLE_FOR_SERVICE_ACCOUNTS. - */ - privateIpv6GoogleAccessServiceAccounts?: string[]; - /** - * The purpose of the resource. This field can be either PRIVATE_RFC_1918 or INTERNAL_HTTPS_LOAD_BALANCER. A subnetwork with purpose set to INTERNAL_HTTPS_LOAD_BALANCER is a user-created subnetwork that is reserved for Internal HTTP(S) Load Balancing. If unspecified, the purpose defaults to PRIVATE_RFC_1918. - */ - purpose?: string; - /** - * The type of IP CIDR range to associate with this subnetwork. The default is RFC_1918. When creating a subnetwork in non-RFC 1918 range, this field must be set to NON_RFC_1918. - */ - rangeType?: string; - /** - * URL of the region where the Subnetwork resides. This field can be set only at resource creation time. - */ - region?: string; - /** - * The role of subnetwork. Currenly, this field is only used when purpose = INTERNAL_HTTPS_LOAD_BALANCER. The value can be set to ACTIVE or BACKUP. An ACTIVE subnetwork is one that is currently being used for Internal HTTP(S) Load Balancing. A BACKUP subnetwork is one that is ready to be promoted to ACTIVE or is currently draining. This field can be updated with a patch request. - */ - role?: string; - /** - * An array of configurations for secondary IP ranges for VM instances contained in this subnetwork. The primary IP of such VM must belong to the primary ipCidrRange of the subnetwork. The alias IPs may belong to either primary or secondary ranges. This field can be updated with a patch request. - */ - secondaryIpRanges?: Schema$SubnetworkSecondaryRange[]; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] The state of the subnetwork, which can be one of READY or DRAINING. A subnetwork that is READY is ready to be used. The state of DRAINING is only applicable to subnetworks that have the purpose set to INTERNAL_HTTPS_LOAD_BALANCER and indicates that connections to the load balancer are being drained. A subnetwork that is draining cannot be used or modified until it reaches a status of READY. - */ - state?: string; - } - export interface Schema$SubnetworkAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of SubnetworksScopedList resources. - */ - items?: {[key: string]: Schema$SubnetworksScopedList}; - /** - * [Output Only] Type of resource. Always compute#subnetworkAggregatedList for aggregated lists of subnetworks. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of Subnetwork resources. - */ - export interface Schema$SubnetworkList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Subnetwork resources. - */ - items?: Schema$Subnetwork[]; - /** - * [Output Only] Type of resource. Always compute#subnetworkList for lists of subnetworks. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * The available logging options for this subnetwork. - */ - export interface Schema$SubnetworkLogConfig { - /** - * Can only be specified if VPC flow logging for this subnetwork is enabled. Toggles the aggregation interval for collecting flow logs. Increasing the interval time will reduce the amount of generated flow logs for long lasting connections. Default is an interval of 5 seconds per connection. - */ - aggregationInterval?: string; - /** - * Whether to enable flow logging for this subnetwork. If this field is not explicitly set, it will not appear in get listings. If not set the default behavior is to disable flow logging. - */ - enable?: boolean; - /** - * Can only be specified if VPC flow logging for this subnetwork is enabled. The value of the field must be in [0, 1]. Set the sampling rate of VPC flow logs within the subnetwork where 1.0 means all collected logs are reported and 0.0 means no logs are reported. Default is 0.5, which means half of all collected logs are reported. - */ - flowSampling?: number; - /** - * Can only be specified if VPC flow logs for this subnetwork is enabled. Configures whether all, none or a subset of metadata fields should be added to the reported VPC flow logs. Default is INCLUDE_ALL_METADATA. - */ - metadata?: string; - } - /** - * Represents a secondary IP range of a subnetwork. - */ - export interface Schema$SubnetworkSecondaryRange { - /** - * The range of IP addresses belonging to this subnetwork secondary range. Provide this property when you create the subnetwork. Ranges must be unique and non-overlapping with all primary and secondary IP ranges within a network. Only IPv4 is supported. - */ - ipCidrRange?: string; - /** - * The name associated with this subnetwork secondary range, used when adding an alias IP range to a VM instance. The name must be 1-63 characters long, and comply with RFC1035. The name must be unique within the subnetwork. - */ - rangeName?: string; - /** - * The type of IP CIDR range to associate with this subnetwork secondary range. The default is RFC_1918. When creating a subnetwork in non-RFC 1918 range, this field must be set to NON_RFC_1918. - */ - rangeType?: string; - } - export interface Schema$SubnetworksExpandIpCidrRangeRequest { - /** - * The IP (in CIDR format or netmask) of internal addresses that are legal on this Subnetwork. This range should be disjoint from other subnetworks within this network. This range can only be larger than (i.e. a superset of) the range previously defined before the update. - */ - ipCidrRange?: string; - /** - * The type of IP CIDR range to associate with this subnetwork. The default is RFC_1918. When expanding to a non-RFC 1918 range, this field must be be set to NON_RFC_1918. - */ - rangeType?: string; - } - export interface Schema$SubnetworksScopedList { - /** - * A list of subnetworks contained in this scope. - */ - subnetworks?: Schema$Subnetwork[]; - /** - * An informational warning that appears when the list of addresses is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$SubnetworksSetPrivateIpGoogleAccessRequest { - privateIpGoogleAccess?: boolean; - } - /** - * A set of instance tags. - */ - export interface Schema$Tags { - /** - * Specifies a fingerprint for this request, which is essentially a hash of the tags' contents and used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update tags. You must always provide an up-to-date fingerprint hash in order to update or change tags. To see the latest fingerprint, make get() request to the instance. - */ - fingerprint?: string; - /** - * An array of tags. Each tag must be 1-63 characters long, and comply with RFC1035. - */ - items?: string[]; - } - export interface Schema$TargetHttpProxiesScopedList { - /** - * A list of TargetHttpProxies contained in this scope. - */ - targetHttpProxies?: Schema$TargetHttpProxy[]; - /** - * Informational warning which replaces the list of backend services when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents a Target HTTP Proxy resource. A target HTTP proxy is a component of certain types of load balancers. Global forwarding rules reference a target HTTP proxy, and the target proxy then references a URL map. For more information, read Using Target Proxies. (== resource_for beta.targetHttpProxies ==) (== resource_for v1.targetHttpProxies ==) - */ - export interface Schema$TargetHttpProxy { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of resource. Always compute#targetHttpProxy for target HTTP proxies. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * This field only applies when the loadBalancingScheme is INTERNAL_SELF_MANAGED. When set to true the Envoy binds on the IP address specified by the forwarding rule. Default is false. - */ - proxyBind?: boolean; - /** - * [Output Only] URL of the region where the regional Target HTTP Proxy resides. This field is not applicable to global Target HTTP Proxies. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * URL to the UrlMap resource that defines the mapping from URL to the BackendService. - */ - urlMap?: string; - } - export interface Schema$TargetHttpProxyAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of TargetHttpProxiesScopedList resources. - */ - items?: {[key: string]: Schema$TargetHttpProxiesScopedList}; - /** - * [Output Only] Type of resource. Always compute#targetHttpProxyAggregatedList for lists of Target HTTP Proxies. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * A list of TargetHttpProxy resources. - */ - export interface Schema$TargetHttpProxyList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of TargetHttpProxy resources. - */ - items?: Schema$TargetHttpProxy[]; - /** - * Type of resource. Always compute#targetHttpProxyList for lists of target HTTP proxies. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$TargetHttpsProxiesScopedList { - /** - * A list of TargetHttpsProxies contained in this scope. - */ - targetHttpsProxies?: Schema$TargetHttpsProxy[]; - /** - * Informational warning which replaces the list of backend services when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$TargetHttpsProxiesSetQuicOverrideRequest { - /** - * QUIC policy for the TargetHttpsProxy resource. - */ - quicOverride?: string; - } - export interface Schema$TargetHttpsProxiesSetSslCertificatesRequest { - /** - * New set of SslCertificate resources to associate with this TargetHttpsProxy resource. Currently exactly one SslCertificate resource must be specified. - */ - sslCertificates?: string[]; - } - /** - * Represents a Target HTTPS Proxy resource. A target HTTPS proxy is a component of certain types of load balancers. Global forwarding rules reference a target HTTPS proxy, and the target proxy then references a URL map. For more information, read Using Target Proxies. (== resource_for beta.targetHttpsProxies ==) (== resource_for v1.targetHttpsProxies ==) - */ - export interface Schema$TargetHttpsProxy { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of resource. Always compute#targetHttpsProxy for target HTTPS proxies. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * This field only applies when the loadBalancingScheme is INTERNAL_SELF_MANAGED. When set to true the Envoy binds on the IP address specified by the forwarding rule. Default is false. - */ - proxyBind?: boolean; - /** - * Specifies the QUIC override policy for this TargetHttpsProxy resource. This determines whether the load balancer will attempt to negotiate QUIC with clients or not. Can specify one of NONE, ENABLE, or DISABLE. Specify ENABLE to always enable QUIC, Enables QUIC when set to ENABLE, and disables QUIC when set to DISABLE. If NONE is specified, uses the QUIC policy with no user overrides, which is equivalent to DISABLE. Not specifying this field is equivalent to specifying NONE. - */ - quicOverride?: string; - /** - * [Output Only] URL of the region where the regional TargetHttpsProxy resides. This field is not applicable to global TargetHttpsProxies. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * URLs to SslCertificate resources that are used to authenticate connections between users and the load balancer. At least one SSL certificate must be specified. Currently, you may specify up to 15 SSL certificates. - */ - sslCertificates?: string[]; - /** - * URL of SslPolicy resource that will be associated with the TargetHttpsProxy resource. If not set, the TargetHttpsProxy resource will not have any SSL policy configured. - */ - sslPolicy?: string; - /** - * A fully-qualified or valid partial URL to the UrlMap resource that defines the mapping from URL to the BackendService. For example, the following are all valid URLs for specifying a URL map: - https://www.googleapis.compute/v1/projects/project/global/urlMaps/url-map - projects/project/global/urlMaps/url-map - global/urlMaps/url-map - */ - urlMap?: string; - } - export interface Schema$TargetHttpsProxyAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of TargetHttpsProxiesScopedList resources. - */ - items?: {[key: string]: Schema$TargetHttpsProxiesScopedList}; - /** - * [Output Only] Type of resource. Always compute#targetHttpsProxyAggregatedList for lists of Target HTTP Proxies. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of TargetHttpsProxy resources. - */ - export interface Schema$TargetHttpsProxyList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of TargetHttpsProxy resources. - */ - items?: Schema$TargetHttpsProxy[]; - /** - * Type of resource. Always compute#targetHttpsProxyList for lists of target HTTPS proxies. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents a Target Instance resource. You can use a target instance to handle traffic for one or more forwarding rules, which is ideal for forwarding protocol traffic that is managed by a single source. For example, ESP, AH, TCP, or UDP. For more information, read Target instances. (== resource_for beta.targetInstances ==) (== resource_for v1.targetInstances ==) - */ - export interface Schema$TargetInstance { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * A URL to the virtual machine instance that handles traffic for this target instance. When creating a target instance, you can provide the fully-qualified URL or a valid partial URL to the desired virtual machine. For example, the following are all valid URLs: - https://www.googleapis.com/compute/v1/projects/project/zones/zone/instances/instance - projects/project/zones/zone/instances/instance - zones/zone/instances/instance - */ - instance?: string; - /** - * [Output Only] The type of the resource. Always compute#targetInstance for target instances. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * NAT option controlling how IPs are NAT'ed to the instance. Currently only NO_NAT (default value) is supported. - */ - natPolicy?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * [Output Only] URL of the zone where the target instance resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - zone?: string; - } - export interface Schema$TargetInstanceAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of TargetInstance resources. - */ - items?: {[key: string]: Schema$TargetInstancesScopedList}; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of TargetInstance resources. - */ - export interface Schema$TargetInstanceList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of TargetInstance resources. - */ - items?: Schema$TargetInstance[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$TargetInstancesScopedList { - /** - * A list of target instances contained in this scope. - */ - targetInstances?: Schema$TargetInstance[]; - /** - * Informational warning which replaces the list of addresses when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents a Target Pool resource. Target pools are used for network TCP/UDP load balancing. A target pool references member instances, an associated legacy HttpHealthCheck resource, and, optionally, a backup target pool. For more information, read Using target pools. (== resource_for beta.targetPools ==) (== resource_for v1.targetPools ==) - */ - export interface Schema$TargetPool { - /** - * This field is applicable only when the containing target pool is serving a forwarding rule as the primary pool, and its failoverRatio field is properly set to a value between [0, 1]. backupPool and failoverRatio together define the fallback behavior of the primary target pool: if the ratio of the healthy instances in the primary pool is at or below failoverRatio, traffic arriving at the load-balanced IP will be directed to the backup pool. In case where failoverRatio and backupPool are not set, or all the instances in the backup pool are unhealthy, the traffic will be directed back to the primary pool in the "force" mode, where traffic will be spread to the healthy instances with the best effort, or to all instances when no instance is healthy. - */ - backupPool?: string; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * This field is applicable only when the containing target pool is serving a forwarding rule as the primary pool (i.e., not as a backup pool to some other target pool). The value of the field must be in [0, 1]. If set, backupPool must also be set. They together define the fallback behavior of the primary target pool: if the ratio of the healthy instances in the primary pool is at or below this number, traffic arriving at the load-balanced IP will be directed to the backup pool. In case where failoverRatio is not set or all the instances in the backup pool are unhealthy, the traffic will be directed back to the primary pool in the "force" mode, where traffic will be spread to the healthy instances with the best effort, or to all instances when no instance is healthy. - */ - failoverRatio?: number; - /** - * The URL of the HttpHealthCheck resource. A member instance in this pool is considered healthy if and only if the health checks pass. An empty list means all member instances will be considered healthy at all times. Only HttpHealthChecks are supported. Only one health check may be specified. - */ - healthChecks?: string[]; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * A list of resource URLs to the virtual machine instances serving this pool. They must live in zones contained in the same region as this pool. - */ - instances?: string[]; - /** - * [Output Only] Type of the resource. Always compute#targetPool for target pools. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * [Output Only] URL of the region where the target pool resides. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Server-defined URL for this resource with the resource id. - */ - selfLinkWithId?: string; - /** - * Session affinity option, must be one of the following values: NONE: Connections from the same client IP may go to any instance in the pool. CLIENT_IP: Connections from the same client IP will go to the same instance in the pool while that instance remains healthy. CLIENT_IP_PROTO: Connections from the same client IP with the same IP protocol will go to the same instance in the pool while that instance remains healthy. - */ - sessionAffinity?: string; - } - export interface Schema$TargetPoolAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of TargetPool resources. - */ - items?: {[key: string]: Schema$TargetPoolsScopedList}; - /** - * [Output Only] Type of resource. Always compute#targetPoolAggregatedList for aggregated lists of target pools. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$TargetPoolInstanceHealth { - healthStatus?: Schema$HealthStatus[]; - /** - * [Output Only] Type of resource. Always compute#targetPoolInstanceHealth when checking the health of an instance. - */ - kind?: string; - } - /** - * Contains a list of TargetPool resources. - */ - export interface Schema$TargetPoolList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of TargetPool resources. - */ - items?: Schema$TargetPool[]; - /** - * [Output Only] Type of resource. Always compute#targetPoolList for lists of target pools. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$TargetPoolsAddHealthCheckRequest { - /** - * The HttpHealthCheck to add to the target pool. - */ - healthChecks?: Schema$HealthCheckReference[]; - } - export interface Schema$TargetPoolsAddInstanceRequest { - /** - * A full or partial URL to an instance to add to this target pool. This can be a full or partial URL. For example, the following are valid URLs: - https://www.googleapis.com/compute/v1/projects/project-id/zones/zone/instances/instance-name - projects/project-id/zones/zone/instances/instance-name - zones/zone/instances/instance-name - */ - instances?: Schema$InstanceReference[]; - } - export interface Schema$TargetPoolsRemoveHealthCheckRequest { - /** - * Health check URL to be removed. This can be a full or valid partial URL. For example, the following are valid URLs: - https://www.googleapis.com/compute/beta/projects/project/global/httpHealthChecks/health-check - projects/project/global/httpHealthChecks/health-check - global/httpHealthChecks/health-check - */ - healthChecks?: Schema$HealthCheckReference[]; - } - export interface Schema$TargetPoolsRemoveInstanceRequest { - /** - * URLs of the instances to be removed from target pool. - */ - instances?: Schema$InstanceReference[]; - } - export interface Schema$TargetPoolsScopedList { - /** - * A list of target pools contained in this scope. - */ - targetPools?: Schema$TargetPool[]; - /** - * Informational warning which replaces the list of addresses when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$TargetReference { - target?: string; - } - export interface Schema$TargetSslProxiesSetBackendServiceRequest { - /** - * The URL of the new BackendService resource for the targetSslProxy. - */ - service?: string; - } - export interface Schema$TargetSslProxiesSetProxyHeaderRequest { - /** - * The new type of proxy header to append before sending data to the backend. NONE or PROXY_V1 are allowed. - */ - proxyHeader?: string; - } - export interface Schema$TargetSslProxiesSetSslCertificatesRequest { - /** - * New set of URLs to SslCertificate resources to associate with this TargetSslProxy. Currently exactly one ssl certificate must be specified. - */ - sslCertificates?: string[]; - } - /** - * Represents a Target SSL Proxy resource. A target SSL proxy is a component of a SSL Proxy load balancer. Global forwarding rules reference a target SSL proxy, and the target proxy then references an external backend service. For more information, read Using Target Proxies. (== resource_for beta.targetSslProxies ==) (== resource_for v1.targetSslProxies ==) - */ - export interface Schema$TargetSslProxy { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#targetSslProxy for target SSL proxies. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. - */ - proxyHeader?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * URL to the BackendService resource. - */ - service?: string; - /** - * URLs to SslCertificate resources that are used to authenticate connections to Backends. At least one SSL certificate must be specified. Currently, you may specify up to 15 SSL certificates. - */ - sslCertificates?: string[]; - /** - * URL of SslPolicy resource that will be associated with the TargetSslProxy resource. If not set, the TargetSslProxy resource will not have any SSL policy configured. - */ - sslPolicy?: string; - } - /** - * Contains a list of TargetSslProxy resources. - */ - export interface Schema$TargetSslProxyList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of TargetSslProxy resources. - */ - items?: Schema$TargetSslProxy[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$TargetTcpProxiesSetBackendServiceRequest { - /** - * The URL of the new BackendService resource for the targetTcpProxy. - */ - service?: string; - } - export interface Schema$TargetTcpProxiesSetProxyHeaderRequest { - /** - * The new type of proxy header to append before sending data to the backend. NONE or PROXY_V1 are allowed. - */ - proxyHeader?: string; - } - /** - * Represents a Target TCP Proxy resource. A target TCP proxy is a component of a TCP Proxy load balancer. Global forwarding rules reference ta target TCP proxy, and the target proxy then references an external backend service. For more information, read TCP Proxy Load Balancing Concepts. (== resource_for beta.targetTcpProxies ==) (== resource_for v1.targetTcpProxies ==) - */ - export interface Schema$TargetTcpProxy { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#targetTcpProxy for target TCP proxies. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. - */ - proxyHeader?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * URL to the BackendService resource. - */ - service?: string; - } - /** - * Contains a list of TargetTcpProxy resources. - */ - export interface Schema$TargetTcpProxyList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of TargetTcpProxy resources. - */ - items?: Schema$TargetTcpProxy[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents a Target VPN Gateway resource. The target VPN gateway resource represents a Classic Cloud VPN gateway. For more information, read the the Cloud VPN Overview. (== resource_for beta.targetVpnGateways ==) (== resource_for v1.targetVpnGateways ==) - */ - export interface Schema$TargetVpnGateway { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] A list of URLs to the ForwardingRule resources. ForwardingRules are created using compute.forwardingRules.insert and associated with a VPN gateway. - */ - forwardingRules?: string[]; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of resource. Always compute#targetVpnGateway for target VPN gateways. - */ - kind?: string; - /** - * A fingerprint for the labels being applied to this TargetVpnGateway, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a TargetVpnGateway. - */ - labelFingerprint?: string; - /** - * Labels to apply to this TargetVpnGateway resource. These can be later modified by the setLabels method. Each label key/value must comply with RFC1035. Label values may be empty. - */ - labels?: {[key: string]: string}; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * URL of the network to which this VPN gateway is attached. Provided by the client when the VPN gateway is created. - */ - network?: string; - /** - * [Output Only] URL of the region where the target VPN gateway resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] The status of the VPN gateway, which can be one of the following: CREATING, READY, FAILED, or DELETING. - */ - status?: string; - /** - * [Output Only] A list of URLs to VpnTunnel resources. VpnTunnels are created using the compute.vpntunnels.insert method and associated with a VPN gateway. - */ - tunnels?: string[]; - } - export interface Schema$TargetVpnGatewayAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of TargetVpnGateway resources. - */ - items?: {[key: string]: Schema$TargetVpnGatewaysScopedList}; - /** - * [Output Only] Type of resource. Always compute#targetVpnGateway for target VPN gateways. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of TargetVpnGateway resources. - */ - export interface Schema$TargetVpnGatewayList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of TargetVpnGateway resources. - */ - items?: Schema$TargetVpnGateway[]; - /** - * [Output Only] Type of resource. Always compute#targetVpnGateway for target VPN gateways. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$TargetVpnGatewaysScopedList { - /** - * [Output Only] A list of target VPN gateways contained in this scope. - */ - targetVpnGateways?: Schema$TargetVpnGateway[]; - /** - * [Output Only] Informational warning which replaces the list of addresses when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$TCPHealthCheck { - /** - * The TCP port number for the health check request. The default value is 80. Valid values are 1 through 65535. - */ - port?: number; - /** - * Port name as defined in InstanceGroup#NamedPort#name. If both port and port_name are defined, port takes precedence. - */ - portName?: string; - /** - * Specifies how port is selected for health checking, can be one of following values: USE_FIXED_PORT: The port number in port is used for health checking. USE_NAMED_PORT: The portName is used for health checking. USE_SERVING_PORT: For NetworkEndpointGroup, the port specified for each network endpoint is used for health checking. For other backends, the port or named port specified in the Backend Service is used for health checking. If not specified, TCP health check follows behavior specified in port and portName fields. - */ - portSpecification?: string; - /** - * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. - */ - proxyHeader?: string; - /** - * The application data to send once the TCP connection has been established (default value is empty). If both request and response are empty, the connection establishment alone will indicate health. The request data can only be ASCII. - */ - request?: string; - /** - * The bytes to match against the beginning of the response data. If left empty (the default value), any response will indicate health. The response data can only be ASCII. - */ - response?: string; - } - export interface Schema$TestFailure { - actualService?: string; - expectedService?: string; - host?: string; - path?: string; - } - export interface Schema$TestPermissionsRequest { - /** - * The set of permissions to check for the 'resource'. Permissions with wildcards (such as '*' or 'storage.*') are not allowed. - */ - permissions?: string[]; - } - export interface Schema$TestPermissionsResponse { - /** - * A subset of `TestPermissionsRequest.permissions` that the caller is allowed. - */ - permissions?: string[]; - } - /** - * Defines the mechanism to obtain the client or server certificate. - */ - export interface Schema$TlsCertificateContext { - /** - * Specifies the certificate and private key paths. This field is applicable only if tlsCertificateSource is set to USE_PATH. - */ - certificatePaths?: Schema$TlsCertificatePaths; - /** - * Defines how TLS certificates are obtained. - */ - certificateSource?: string; - /** - * Specifies the config to retrieve certificates through SDS. This field is applicable only if tlsCertificateSource is set to USE_SDS. - */ - sdsConfig?: Schema$SdsConfig; - } - /** - * The paths to the mounted TLS Certificates and private key. - */ - export interface Schema$TlsCertificatePaths { - /** - * The path to the file holding the client or server TLS certificate to use. - */ - certificatePath?: string; - /** - * The path to the file holding the client or server private key. - */ - privateKeyPath?: string; - } - /** - * The TLS settings for the client or server. - */ - export interface Schema$TlsContext { - /** - * Defines the mechanism to obtain the client or server certificate. - */ - certificateContext?: Schema$TlsCertificateContext; - /** - * Defines the mechanism to obtain the Certificate Authority certificate to validate the client/server certificate. If omitted, the proxy will not validate the server or client certificate. - */ - validationContext?: Schema$TlsValidationContext; - } - /** - * Defines the mechanism to obtain the Certificate Authority certificate to validate the client/server certificate. - */ - export interface Schema$TlsValidationContext { - /** - * The path to the file holding the CA certificate to validate the client or server certificate. - */ - certificatePath?: string; - /** - * Specifies the config to retrieve certificates through SDS. This field is applicable only if tlsCertificateSource is set to USE_SDS. - */ - sdsConfig?: Schema$SdsConfig; - /** - * Defines how TLS certificates are obtained. - */ - validationSource?: string; - } - export interface Schema$UDPHealthCheck { - /** - * The UDP port number for the health check request. Valid values are 1 through 65535. - */ - port?: number; - /** - * Port name as defined in InstanceGroup#NamedPort#name. If both port and port_name are defined, port takes precedence. - */ - portName?: string; - /** - * Raw data of request to send in payload of UDP packet. It is an error if this is empty. The request data can only be ASCII. - */ - request?: string; - /** - * The bytes to match against the beginning of the response data. It is an error if this is empty. The response data can only be ASCII. - */ - response?: string; - } - /** - * Represents a URL Map resource. A URL map resource is a component of certain types of load balancers. This resource defines mappings from host names and URL paths to either a backend service or a backend bucket. To use this resource, the backend service must have a loadBalancingScheme of either EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED For more information, read URL Map Concepts. - */ - export interface Schema$UrlMap { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * defaultRouteAction takes effect when none of the hostRules match. The load balancer performs advanced routing actions like URL rewrites, header transformations, etc. prior to forwarding the request to the selected backend. If defaultRouteAction specifies any weightedBackendServices, defaultService must not be set. Conversely if defaultService is set, defaultRouteAction cannot contain any weightedBackendServices. Only one of defaultRouteAction or defaultUrlRedirect must be set. - */ - defaultRouteAction?: Schema$HttpRouteAction; - /** - * The full or partial URL of the defaultService resource to which traffic is directed if none of the hostRules match. If defaultRouteAction is additionally specified, advanced routing actions like URL Rewrites, etc. take effect prior to sending the request to the backend. However, if defaultService is specified, defaultRouteAction cannot contain any weightedBackendServices. Conversely, if routeAction specifies any weightedBackendServices, service must not be specified. Only one of defaultService, defaultUrlRedirect or defaultRouteAction.weightedBackendService must be set. - */ - defaultService?: string; - /** - * When none of the specified hostRules match, the request is redirected to a URL specified by defaultUrlRedirect. If defaultUrlRedirect is specified, defaultService or defaultRouteAction must not be set. - */ - defaultUrlRedirect?: Schema$HttpRedirectAction; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a UrlMap. An up-to-date fingerprint must be provided in order to update the UrlMap, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a UrlMap. - */ - fingerprint?: string; - /** - * Specifies changes to request and response headers that need to take effect for the selected backendService. The headerAction specified here take effect after headerAction specified under pathMatcher. - */ - headerAction?: Schema$HttpHeaderAction; - /** - * The list of HostRules to use against the URL. - */ - hostRules?: Schema$HostRule[]; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#urlMaps for url maps. - */ - kind?: string; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * The list of named PathMatchers to use against the URL. - */ - pathMatchers?: Schema$PathMatcher[]; - /** - * [Output Only] URL of the region where the regional URL map resides. This field is not applicable to global URL maps. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * The list of expected URL mapping tests. Request to update this UrlMap will succeed only if all of the test cases pass. You can specify a maximum of 100 tests per UrlMap. - */ - tests?: Schema$UrlMapTest[]; - } - /** - * Contains a list of UrlMap resources. - */ - export interface Schema$UrlMapList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of UrlMap resources. - */ - items?: Schema$UrlMap[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$UrlMapReference { - urlMap?: string; - } - export interface Schema$UrlMapsAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of UrlMapsScopedList resources. - */ - items?: {[key: string]: Schema$UrlMapsScopedList}; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$UrlMapsScopedList { - /** - * A list of UrlMaps contained in this scope. - */ - urlMaps?: Schema$UrlMap[]; - /** - * Informational warning which replaces the list of backend services when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$UrlMapsValidateRequest { - /** - * Content of the UrlMap to be validated. - */ - resource?: Schema$UrlMap; - } - export interface Schema$UrlMapsValidateResponse { - result?: Schema$UrlMapValidationResult; - } - /** - * Message for the expected URL mappings. - */ - export interface Schema$UrlMapTest { - /** - * The weight to use for the supplied host and path when using advanced routing rules that involve traffic splitting. - */ - backendServiceWeight?: number; - /** - * Description of this test case. - */ - description?: string; - /** - * The expected URL that should be redirected to for the host and path being tested. - */ - expectedUrlRedirect?: string; - /** - * Host portion of the URL. - */ - host?: string; - /** - * Path portion of the URL. - */ - path?: string; - /** - * Expected BackendService resource the given URL should be mapped to. - */ - service?: string; - } - /** - * Message representing the validation result for a UrlMap. - */ - export interface Schema$UrlMapValidationResult { - loadErrors?: string[]; - /** - * Whether the given UrlMap can be successfully loaded. If false, 'loadErrors' indicates the reasons. - */ - loadSucceeded?: boolean; - testFailures?: Schema$TestFailure[]; - /** - * If successfully loaded, this field indicates whether the test passed. If false, 'testFailures's indicate the reason of failure. - */ - testPassed?: boolean; - } - /** - * The spec for modifying the path before sending the request to the matched backend service. - */ - export interface Schema$UrlRewrite { - /** - * Prior to forwarding the request to the selected service, the request's host header is replaced with contents of hostRewrite. The value must be between 1 and 255 characters. - */ - hostRewrite?: string; - /** - * Prior to forwarding the request to the selected backend service, the matching portion of the request's path is replaced by pathPrefixRewrite. The value must be between 1 and 1024 characters. - */ - pathPrefixRewrite?: string; - } - /** - * Subnetwork which the current user has compute.subnetworks.use permission on. - */ - export interface Schema$UsableSubnetwork { - /** - * The range of internal addresses that are owned by this subnetwork. - */ - ipCidrRange?: string; - /** - * Network URL. - */ - network?: string; - /** - * Secondary IP ranges. - */ - secondaryIpRanges?: Schema$UsableSubnetworkSecondaryRange[]; - /** - * Subnetwork URL. - */ - subnetwork?: string; - } - export interface Schema$UsableSubnetworksAggregatedList { - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output] A list of usable subnetwork URLs. - */ - items?: Schema$UsableSubnetwork[]; - /** - * [Output Only] Type of resource. Always compute#usableSubnetworksAggregatedList for aggregated lists of usable subnetworks. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Secondary IP range of a usable subnetwork. - */ - export interface Schema$UsableSubnetworkSecondaryRange { - /** - * The range of IP addresses belonging to this subnetwork secondary range. - */ - ipCidrRange?: string; - /** - * The name associated with this subnetwork secondary range, used when adding an alias IP range to a VM instance. The name must be 1-63 characters long, and comply with RFC1035. The name must be unique within the subnetwork. - */ - rangeName?: string; - } - /** - * The location in Cloud Storage and naming method of the daily usage report. Contains bucket_name and report_name prefix. - */ - export interface Schema$UsageExportLocation { - /** - * The name of an existing bucket in Cloud Storage where the usage report object is stored. The Google Service Account is granted write access to this bucket. This can either be the bucket name by itself, such as example-bucket, or the bucket name with gs:// or https://storage.googleapis.com/ in front of it, such as gs://example-bucket. - */ - bucketName?: string; - /** - * An optional prefix for the name of the usage report object stored in bucketName. If not supplied, defaults to usage. The report is stored as a CSV file named report_name_prefix_gce_YYYYMMDD.csv where YYYYMMDD is the day of the usage according to Pacific Time. If you supply a prefix, it should conform to Cloud Storage object naming conventions. - */ - reportNamePrefix?: string; - } - /** - * Contain information of Nat mapping for a VM endpoint (i.e., NIC). - */ - export interface Schema$VmEndpointNatMappings { - /** - * Name of the VM instance which the endpoint belongs to - */ - instanceName?: string; - interfaceNatMappings?: Schema$VmEndpointNatMappingsInterfaceNatMappings[]; - } - /** - * Contain information of Nat mapping for an interface of this endpoint. - */ - export interface Schema$VmEndpointNatMappingsInterfaceNatMappings { - /** - * List of all drain IP:port-range mappings assigned to this interface. These ranges are inclusive, that is, both the first and the last ports can be used for NAT. Example: ["2.2.2.2:12345-12355", "1.1.1.1:2234-2234"]. - */ - drainNatIpPortRanges?: string[]; - /** - * A list of all IP:port-range mappings assigned to this interface. These ranges are inclusive, that is, both the first and the last ports can be used for NAT. Example: ["2.2.2.2:12345-12355", "1.1.1.1:2234-2234"]. - */ - natIpPortRanges?: string[]; - /** - * Total number of drain ports across all NAT IPs allocated to this interface. It equals to the aggregated port number in the field drain_nat_ip_port_ranges. - */ - numTotalDrainNatPorts?: number; - /** - * Total number of ports across all NAT IPs allocated to this interface. It equals to the aggregated port number in the field nat_ip_port_ranges. - */ - numTotalNatPorts?: number; - /** - * Alias IP range for this interface endpoint. It will be a private (RFC 1918) IP range. Examples: "10.33.4.55/32", or "192.168.5.0/24". - */ - sourceAliasIpRange?: string; - /** - * Primary IP of the VM for this NIC. - */ - sourceVirtualIp?: string; - } - /** - * Contains a list of VmEndpointNatMappings. - */ - export interface Schema$VmEndpointNatMappingsList { - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of resource. Always compute#vmEndpointNatMappingsList for lists of Nat mappings of VM endpoints. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] A list of Nat mapping information of VM endpoints. - */ - result?: Schema$VmEndpointNatMappings[]; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Represents a VPN gateway resource. - */ - export interface Schema$VpnGateway { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of resource. Always compute#vpnGateway for VPN gateways. - */ - kind?: string; - /** - * A fingerprint for the labels being applied to this VpnGateway, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an VpnGateway. - */ - labelFingerprint?: string; - /** - * Labels to apply to this VpnGateway resource. These can be later modified by the setLabels method. Each label key/value must comply with RFC1035. Label values may be empty. - */ - labels?: {[key: string]: string}; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * URL of the network to which this VPN gateway is attached. Provided by the client when the VPN gateway is created. - */ - network?: string; - /** - * [Output Only] URL of the region where the VPN gateway resides. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] A list of interfaces on this VPN gateway. - */ - vpnInterfaces?: Schema$VpnGatewayVpnGatewayInterface[]; - } - export interface Schema$VpnGatewayAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of VpnGateway resources. - */ - items?: {[key: string]: Schema$VpnGatewaysScopedList}; - /** - * [Output Only] Type of resource. Always compute#vpnGateway for VPN gateways. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of VpnGateway resources. - */ - export interface Schema$VpnGatewayList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of VpnGateway resources. - */ - items?: Schema$VpnGateway[]; - /** - * [Output Only] Type of resource. Always compute#vpnGateway for VPN gateways. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$VpnGatewaysGetStatusResponse { - result?: Schema$VpnGatewayStatus; - } - export interface Schema$VpnGatewaysScopedList { - /** - * [Output Only] A list of VPN gateways contained in this scope. - */ - vpnGateways?: Schema$VpnGateway[]; - /** - * [Output Only] Informational warning which replaces the list of addresses when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$VpnGatewayStatus { - /** - * List of VPN connection for this VpnGateway. - */ - vpnConnections?: Schema$VpnGatewayStatusVpnConnection[]; - } - /** - * Describes the high availability requirement state for the VPN connection between this Cloud VPN gateway and a peer gateway. - */ - export interface Schema$VpnGatewayStatusHighAvailabilityRequirementState { - /** - * Indicates the high availability requirement state for the VPN connection. Valid values are CONNECTION_REDUNDANCY_MET, CONNECTION_REDUNDANCY_NOT_MET. - */ - state?: string; - /** - * Indicates the reason why the VPN connection does not meet the high availability redundancy criteria/requirement. Valid values is INCOMPLETE_TUNNELS_COVERAGE. - */ - unsatisfiedReason?: string; - } - /** - * Contains some information about a VPN tunnel. - */ - export interface Schema$VpnGatewayStatusTunnel { - /** - * The VPN gateway interface this VPN tunnel is associated with. - */ - localGatewayInterface?: number; - /** - * The peer gateway interface this VPN tunnel is connected to, the peer gateway could either be an external VPN gateway or GCP VPN gateway. - */ - peerGatewayInterface?: number; - /** - * URL reference to the VPN tunnel. - */ - tunnelUrl?: string; - } - /** - * A VPN connection contains all VPN tunnels connected from this VpnGateway to the same peer gateway. The peer gateway could either be a external VPN gateway or GCP VPN gateway. - */ - export interface Schema$VpnGatewayStatusVpnConnection { - /** - * URL reference to the peer external VPN gateways to which the VPN tunnels in this VPN connection are connected. This field is mutually exclusive with peer_gcp_gateway. - */ - peerExternalGateway?: string; - /** - * URL reference to the peer side VPN gateways to which the VPN tunnels in this VPN connection are connected. This field is mutually exclusive with peer_gcp_gateway. - */ - peerGcpGateway?: string; - /** - * HighAvailabilityRequirementState for the VPN connection. - */ - state?: Schema$VpnGatewayStatusHighAvailabilityRequirementState; - /** - * List of VPN tunnels that are in this VPN connection. - */ - tunnels?: Schema$VpnGatewayStatusTunnel[]; - } - /** - * A VPN gateway interface. - */ - export interface Schema$VpnGatewayVpnGatewayInterface { - /** - * The numeric ID of this VPN gateway interface. - */ - id?: number; - /** - * The external IP address for this VPN gateway interface. - */ - ipAddress?: string; - } - /** - * Represents a Cloud VPN Tunnel resource. For more information about VPN, read the the Cloud VPN Overview. (== resource_for beta.vpnTunnels ==) (== resource_for v1.vpnTunnels ==) - */ - export interface Schema$VpnTunnel { - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * An optional description of this resource. Provide this property when you create the resource. - */ - description?: string; - /** - * [Output Only] Detailed status message for the VPN tunnel. - */ - detailedStatus?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * IKE protocol version to use when establishing the VPN tunnel with the peer VPN gateway. Acceptable IKE versions are 1 or 2. The default version is 2. - */ - ikeVersion?: number; - /** - * [Output Only] Type of resource. Always compute#vpnTunnel for VPN tunnels. - */ - kind?: string; - /** - * A fingerprint for the labels being applied to this VpnTunnel, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve a VpnTunnel. - */ - labelFingerprint?: string; - /** - * Labels to apply to this VpnTunnel. These can be later modified by the setLabels method. Each label key/value pair must comply with RFC1035. Label values may be empty. - */ - labels?: {[key: string]: string}; - /** - * Local traffic selector to use when establishing the VPN tunnel with the peer VPN gateway. The value should be a CIDR formatted string, for example: 192.168.0.0/16. The ranges must be disjoint. Only IPv4 is supported. - */ - localTrafficSelector?: string[]; - /** - * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. - */ - name?: string; - /** - * URL of the peer side external VPN gateway to which this VPN tunnel is connected. Provided by the client when the VPN tunnel is created. This field is exclusive with the field peerGcpGateway. - */ - peerExternalGateway?: string; - /** - * The interface ID of the external VPN gateway to which this VPN tunnel is connected. Provided by the client when the VPN tunnel is created. - */ - peerExternalGatewayInterface?: number; - /** - * URL of the peer side HA GCP VPN gateway to which this VPN tunnel is connected. Provided by the client when the VPN tunnel is created. This field can be used when creating highly available VPN from VPC network to VPC network, the field is exclusive with the field peerExternalGateway. If provided, the VPN tunnel will automatically use the same vpnGatewayInterface ID in the peer GCP VPN gateway. - */ - peerGcpGateway?: string; - /** - * IP address of the peer VPN gateway. Only IPv4 is supported. - */ - peerIp?: string; - /** - * [Output Only] URL of the region where the VPN tunnel resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. - */ - region?: string; - /** - * Remote traffic selectors to use when establishing the VPN tunnel with the peer VPN gateway. The value should be a CIDR formatted string, for example: 192.168.0.0/16. The ranges should be disjoint. Only IPv4 is supported. - */ - remoteTrafficSelector?: string[]; - /** - * URL of the router resource to be used for dynamic routing. - */ - router?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * Shared secret used to set the secure session between the Cloud VPN gateway and the peer VPN gateway. - */ - sharedSecret?: string; - /** - * Hash of the shared secret. - */ - sharedSecretHash?: string; - /** - * [Output Only] The status of the VPN tunnel, which can be one of the following: - PROVISIONING: Resource is being allocated for the VPN tunnel. - WAITING_FOR_FULL_CONFIG: Waiting to receive all VPN-related configs from the user. Network, TargetVpnGateway, VpnTunnel, ForwardingRule, and Route resources are needed to setup the VPN tunnel. - FIRST_HANDSHAKE: Successful first handshake with the peer VPN. - ESTABLISHED: Secure session is successfully established with the peer VPN. - NETWORK_ERROR: Deprecated, replaced by NO_INCOMING_PACKETS - AUTHORIZATION_ERROR: Auth error (for example, bad shared secret). - NEGOTIATION_FAILURE: Handshake failed. - DEPROVISIONING: Resources are being deallocated for the VPN tunnel. - FAILED: Tunnel creation has failed and the tunnel is not ready to be used. - */ - status?: string; - /** - * URL of the Target VPN gateway with which this VPN tunnel is associated. Provided by the client when the VPN tunnel is created. - */ - targetVpnGateway?: string; - /** - * URL of the VPN gateway with which this VPN tunnel is associated. Provided by the client when the VPN tunnel is created. This must be used (instead of target_vpn_gateway) if a High Availability VPN gateway resource is created. - */ - vpnGateway?: string; - /** - * The interface ID of the VPN gateway with which this VPN tunnel is associated. - */ - vpnGatewayInterface?: number; - } - export interface Schema$VpnTunnelAggregatedList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of VpnTunnelsScopedList resources. - */ - items?: {[key: string]: Schema$VpnTunnelsScopedList}; - /** - * [Output Only] Type of resource. Always compute#vpnTunnel for VPN tunnels. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Contains a list of VpnTunnel resources. - */ - export interface Schema$VpnTunnelList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of VpnTunnel resources. - */ - items?: Schema$VpnTunnel[]; - /** - * [Output Only] Type of resource. Always compute#vpnTunnel for VPN tunnels. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$VpnTunnelsScopedList { - /** - * A list of VPN tunnels contained in this scope. - */ - vpnTunnels?: Schema$VpnTunnel[]; - /** - * Informational warning which replaces the list of addresses when the list is empty. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$WafExpressionSet { - /** - * A list of alternate IDs. The format should be: - E.g. XSS-stable Generic suffix like "stable" is particularly useful if a policy likes to avail newer set of expressions without having to change the policy. A given alias name can't be used for more than one entity set. - */ - aliases?: string[]; - /** - * List of available expressions. - */ - expressions?: Schema$WafExpressionSetExpression[]; - /** - * Google specified expression set ID. The format should be: - E.g. XSS-20170329 - */ - id?: string; - } - export interface Schema$WafExpressionSetExpression { - /** - * Expression ID should uniquely identify the origin of the expression. E.g. owasp-crs-v020901-id973337 identifies Owasp core rule set version 2.9.1 rule id 973337. The ID could be used to determine the individual attack definition that has been detected. It could also be used to exclude it from the policy in case of false positive. - */ - id?: string; - } - /** - * In contrast to a single BackendService in HttpRouteAction to which all matching traffic is directed to, WeightedBackendService allows traffic to be split across multiple BackendServices. The volume of traffic for each BackendService is proportional to the weight specified in each WeightedBackendService - */ - export interface Schema$WeightedBackendService { - /** - * The full or partial URL to the default BackendService resource. Before forwarding the request to backendService, the loadbalancer applies any relevant headerActions specified as part of this backendServiceWeight. - */ - backendService?: string; - /** - * Specifies changes to request and response headers that need to take effect for the selected backendService. headerAction specified here take effect before headerAction in the enclosing HttpRouteRule, PathMatcher and UrlMap. - */ - headerAction?: Schema$HttpHeaderAction; - /** - * Specifies the fraction of traffic sent to backendService, computed as weight / (sum of all weightedBackendService weights in routeAction) . The selection of a backend service is determined only for new traffic. Once a user's request has been directed to a backendService, subsequent requests will be sent to the same backendService as determined by the BackendService's session affinity policy. The value must be between 0 and 1000 - */ - weight?: number; - } - export interface Schema$XpnHostList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * [Output Only] A list of shared VPC host project URLs. - */ - items?: Schema$Project[]; - /** - * [Output Only] Type of resource. Always compute#xpnHostList for lists of shared VPC hosts. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - /** - * Service resource (a.k.a service project) ID. - */ - export interface Schema$XpnResourceId { - /** - * The ID of the service resource. In the case of projects, this field supports project id (e.g., my-project-123) and project number (e.g. 12345678). - */ - id?: string; - /** - * The type of the service resource. - */ - type?: string; - } - /** - * Represents a Zone resource. A zone is a deployment area. These deployment areas are subsets of a region. For example the zone us-east1-a is located in the us-east1 region. For more information, read Regions and Zones. (== resource_for beta.zones ==) (== resource_for v1.zones ==) - */ - export interface Schema$Zone { - /** - * [Output Only] Available cpu/platform selections for the zone. - */ - availableCpuPlatforms?: string[]; - /** - * [Output Only] Creation timestamp in RFC3339 text format. - */ - creationTimestamp?: string; - /** - * [Output Only] The deprecation status associated with this zone. - */ - deprecated?: Schema$DeprecationStatus; - /** - * [Output Only] Textual description of the resource. - */ - description?: string; - /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. - */ - id?: string; - /** - * [Output Only] Type of the resource. Always compute#zone for zones. - */ - kind?: string; - /** - * [Output Only] Name of the resource. - */ - name?: string; - /** - * [Output Only] Full URL reference to the region which hosts the zone. - */ - region?: string; - /** - * [Output Only] Server-defined URL for the resource. - */ - selfLink?: string; - /** - * [Output Only] Status of the zone, either UP or DOWN. - */ - status?: string; - } - /** - * Contains a list of zone resources. - */ - export interface Schema$ZoneList { - /** - * [Output Only] Unique identifier for the resource; defined by the server. - */ - id?: string; - /** - * A list of Zone resources. - */ - items?: Schema$Zone[]; - /** - * Type of resource. - */ - kind?: string; - /** - * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. - */ - nextPageToken?: string; - /** - * [Output Only] Server-defined URL for this resource. - */ - selfLink?: string; - /** - * [Output Only] Informational warning message. - */ - warning?: { - code?: string; - data?: Array<{key?: string; value?: string}>; - message?: string; - }; - } - export interface Schema$ZoneSetLabelsRequest { - /** - * The fingerprint of the previous set of labels for this resource, used to detect conflicts. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels. Make a get() request to the resource to get the latest fingerprint. - */ - labelFingerprint?: string; - /** - * The labels to set for this resource. - */ - labels?: {[key: string]: string}; - } - export interface Schema$ZoneSetPolicyRequest { - /** - * Flatten Policy to create a backwacd compatible wire-format. Deprecated. Use 'policy' to specify bindings. - */ - bindings?: Schema$Binding[]; - /** - * Flatten Policy to create a backward compatible wire-format. Deprecated. Use 'policy' to specify the etag. - */ - etag?: string; - /** - * REQUIRED: The complete policy to be applied to the 'resource'. The size of the policy is limited to a few 10s of KB. An empty policy is in general a valid policy but certain services (like Projects) might reject them. - */ - policy?: Schema$Policy; - } - - export class Resource$Acceleratortypes { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.acceleratorTypes.aggregatedList - * @desc Retrieves an aggregated list of accelerator types. - * @alias compute.acceleratorTypes.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Acceleratortypes$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Acceleratortypes$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Acceleratortypes$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Acceleratortypes$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Acceleratortypes$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Acceleratortypes$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/acceleratorTypes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.acceleratorTypes.get - * @desc Returns the specified accelerator type. - * @alias compute.acceleratorTypes.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.acceleratorType Name of the accelerator type to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Acceleratortypes$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Acceleratortypes$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Acceleratortypes$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Acceleratortypes$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Acceleratortypes$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Acceleratortypes$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/acceleratorTypes/{acceleratorType}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'acceleratorType'], - pathParams: ['acceleratorType', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.acceleratorTypes.list - * @desc Retrieves a list of accelerator types available to the specified project. - * @alias compute.acceleratorTypes.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Acceleratortypes$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Acceleratortypes$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Acceleratortypes$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Acceleratortypes$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Acceleratortypes$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Acceleratortypes$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/acceleratorTypes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Acceleratortypes$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Acceleratortypes$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the accelerator type to return. - */ - acceleratorType?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Acceleratortypes$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - - export class Resource$Addresses { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.addresses.aggregatedList - * @desc Retrieves an aggregated list of addresses. - * @alias compute.addresses.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Addresses$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Addresses$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Addresses$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Addresses$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Addresses$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Addresses$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/aggregated/addresses' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.addresses.delete - * @desc Deletes the specified address resource. - * @alias compute.addresses.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.address Name of the address resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Addresses$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Addresses$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Addresses$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Addresses$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Addresses$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Addresses$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/addresses/{address}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'address'], - pathParams: ['address', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.addresses.get - * @desc Returns the specified address resource. - * @alias compute.addresses.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.address Name of the address resource to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Addresses$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Addresses$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Addresses$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Addresses$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Addresses$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Addresses$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/addresses/{address}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'address'], - pathParams: ['address', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.addresses.insert - * @desc Creates an address resource in the specified project by using the data included in the request. - * @alias compute.addresses.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Address} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Addresses$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Addresses$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Addresses$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Addresses$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Addresses$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Addresses$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/addresses' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.addresses.list - * @desc Retrieves a list of addresses contained within the specified region. - * @alias compute.addresses.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Addresses$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Addresses$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Addresses$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Addresses$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Addresses$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Addresses$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/addresses' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.addresses.setLabels - * @desc Sets the labels on an Address. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.addresses.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().RegionSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Addresses$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Addresses$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Addresses$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Addresses$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Addresses$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Addresses$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/addresses/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.addresses.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.addresses.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Addresses$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Addresses$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Addresses$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Addresses$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Addresses$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Addresses$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/addresses/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Addresses$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Addresses$Delete extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the address resource to delete. - */ - address?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Addresses$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the address resource to return. - */ - address?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Addresses$Insert extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Address; - } - export interface Params$Resource$Addresses$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Addresses$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionSetLabelsRequest; - } - export interface Params$Resource$Addresses$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Autoscalers { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.autoscalers.aggregatedList - * @desc Retrieves an aggregated list of autoscalers. - * @alias compute.autoscalers.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Autoscalers$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Autoscalers$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Autoscalers$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Autoscalers$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Autoscalers$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Autoscalers$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/autoscalers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.autoscalers.delete - * @desc Deletes the specified autoscaler. - * @alias compute.autoscalers.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.autoscaler Name of the autoscaler to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone Name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Autoscalers$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Autoscalers$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Autoscalers$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Autoscalers$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Autoscalers$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Autoscalers$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/autoscalers/{autoscaler}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'autoscaler'], - pathParams: ['autoscaler', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.autoscalers.get - * @desc Returns the specified autoscaler resource. Gets a list of available autoscalers by making a list() request. - * @alias compute.autoscalers.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.autoscaler Name of the autoscaler to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone Name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Autoscalers$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Autoscalers$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Autoscalers$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Autoscalers$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Autoscalers$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Autoscalers$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/autoscalers/{autoscaler}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'autoscaler'], - pathParams: ['autoscaler', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.autoscalers.insert - * @desc Creates an autoscaler in the specified project using the data included in the request. - * @alias compute.autoscalers.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone Name of the zone for this request. - * @param {().Autoscaler} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Autoscalers$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Autoscalers$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Autoscalers$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Autoscalers$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Autoscalers$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Autoscalers$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/autoscalers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.autoscalers.list - * @desc Retrieves a list of autoscalers contained within the specified zone. - * @alias compute.autoscalers.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone Name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Autoscalers$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Autoscalers$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Autoscalers$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Autoscalers$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Autoscalers$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Autoscalers$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/autoscalers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.autoscalers.patch - * @desc Updates an autoscaler in the specified project using the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.autoscalers.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.autoscaler Name of the autoscaler to patch. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone Name of the zone for this request. - * @param {().Autoscaler} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Autoscalers$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Autoscalers$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Autoscalers$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Autoscalers$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Autoscalers$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Autoscalers$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/autoscalers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.autoscalers.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.autoscalers.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Autoscalers$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Autoscalers$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Autoscalers$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Autoscalers$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Autoscalers$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Autoscalers$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/autoscalers/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.autoscalers.update - * @desc Updates an autoscaler in the specified project using the data included in the request. - * @alias compute.autoscalers.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.autoscaler Name of the autoscaler to update. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone Name of the zone for this request. - * @param {().Autoscaler} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Autoscalers$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Autoscalers$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Autoscalers$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Autoscalers$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Autoscalers$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Autoscalers$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/autoscalers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Autoscalers$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Autoscalers$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the autoscaler to delete. - */ - autoscaler?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Autoscalers$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the autoscaler to return. - */ - autoscaler?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Autoscalers$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Autoscaler; - } - export interface Params$Resource$Autoscalers$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Autoscalers$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the autoscaler to patch. - */ - autoscaler?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Autoscaler; - } - export interface Params$Resource$Autoscalers$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Autoscalers$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the autoscaler to update. - */ - autoscaler?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Autoscaler; - } - - export class Resource$Backendbuckets { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.backendBuckets.addSignedUrlKey - * @desc Adds a key for validating requests with signed URLs for this backend bucket. - * @alias compute.backendBuckets.addSignedUrlKey - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendBucket Name of the BackendBucket resource to which the Signed URL Key should be added. The name should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().SignedUrlKey} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addSignedUrlKey( - params?: Params$Resource$Backendbuckets$Addsignedurlkey, - options?: MethodOptions - ): GaxiosPromise; - addSignedUrlKey( - params: Params$Resource$Backendbuckets$Addsignedurlkey, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addSignedUrlKey( - params: Params$Resource$Backendbuckets$Addsignedurlkey, - callback: BodyResponseCallback - ): void; - addSignedUrlKey(callback: BodyResponseCallback): void; - addSignedUrlKey( - paramsOrCallback?: - | Params$Resource$Backendbuckets$Addsignedurlkey - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendbuckets$Addsignedurlkey; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendbuckets$Addsignedurlkey; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendBuckets/{backendBucket}/addSignedUrlKey' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'backendBucket'], - pathParams: ['backendBucket', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendBuckets.delete - * @desc Deletes the specified BackendBucket resource. - * @alias compute.backendBuckets.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendBucket Name of the BackendBucket resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Backendbuckets$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Backendbuckets$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Backendbuckets$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Backendbuckets$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendbuckets$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendbuckets$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendBuckets/{backendBucket}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'backendBucket'], - pathParams: ['backendBucket', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendBuckets.deleteSignedUrlKey - * @desc Deletes a key for validating requests with signed URLs for this backend bucket. - * @alias compute.backendBuckets.deleteSignedUrlKey - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendBucket Name of the BackendBucket resource to which the Signed URL Key should be added. The name should conform to RFC1035. - * @param {string} params.keyName The name of the Signed URL Key to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - deleteSignedUrlKey( - params?: Params$Resource$Backendbuckets$Deletesignedurlkey, - options?: MethodOptions - ): GaxiosPromise; - deleteSignedUrlKey( - params: Params$Resource$Backendbuckets$Deletesignedurlkey, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - deleteSignedUrlKey( - params: Params$Resource$Backendbuckets$Deletesignedurlkey, - callback: BodyResponseCallback - ): void; - deleteSignedUrlKey(callback: BodyResponseCallback): void; - deleteSignedUrlKey( - paramsOrCallback?: - | Params$Resource$Backendbuckets$Deletesignedurlkey - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendbuckets$Deletesignedurlkey; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendbuckets$Deletesignedurlkey; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendBuckets/{backendBucket}/deleteSignedUrlKey' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'backendBucket', 'keyName'], - pathParams: ['backendBucket', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendBuckets.get - * @desc Returns the specified BackendBucket resource. Gets a list of available backend buckets by making a list() request. - * @alias compute.backendBuckets.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendBucket Name of the BackendBucket resource to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Backendbuckets$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Backendbuckets$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Backendbuckets$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Backendbuckets$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendbuckets$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendbuckets$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendBuckets/{backendBucket}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'backendBucket'], - pathParams: ['backendBucket', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendBuckets.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.backendBuckets.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Backendbuckets$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Backendbuckets$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Backendbuckets$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Backendbuckets$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendbuckets$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendbuckets$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendBuckets/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendBuckets.insert - * @desc Creates a BackendBucket resource in the specified project using the data included in the request. - * @alias compute.backendBuckets.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().BackendBucket} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Backendbuckets$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Backendbuckets$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Backendbuckets$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Backendbuckets$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendbuckets$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendbuckets$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendBuckets' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendBuckets.list - * @desc Retrieves the list of BackendBucket resources available to the specified project. - * @alias compute.backendBuckets.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Backendbuckets$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Backendbuckets$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Backendbuckets$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Backendbuckets$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendbuckets$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendbuckets$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendBuckets' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendBuckets.patch - * @desc Updates the specified BackendBucket resource with the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.backendBuckets.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendBucket Name of the BackendBucket resource to patch. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().BackendBucket} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Backendbuckets$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Backendbuckets$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Backendbuckets$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Backendbuckets$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendbuckets$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendbuckets$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendBuckets/{backendBucket}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'backendBucket'], - pathParams: ['backendBucket', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendBuckets.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.backendBuckets.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Backendbuckets$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Backendbuckets$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Backendbuckets$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Backendbuckets$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendbuckets$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendbuckets$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendBuckets/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendBuckets.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.backendBuckets.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Backendbuckets$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Backendbuckets$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Backendbuckets$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Backendbuckets$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendbuckets$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendbuckets$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendBuckets/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendBuckets.update - * @desc Updates the specified BackendBucket resource with the data included in the request. - * @alias compute.backendBuckets.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendBucket Name of the BackendBucket resource to update. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().BackendBucket} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Backendbuckets$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Backendbuckets$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Backendbuckets$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Backendbuckets$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendbuckets$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendbuckets$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendBuckets/{backendBucket}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'backendBucket'], - pathParams: ['backendBucket', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Backendbuckets$Addsignedurlkey - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendBucket resource to which the Signed URL Key should be added. The name should conform to RFC1035. - */ - backendBucket?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SignedUrlKey; - } - export interface Params$Resource$Backendbuckets$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendBucket resource to delete. - */ - backendBucket?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Backendbuckets$Deletesignedurlkey - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendBucket resource to which the Signed URL Key should be added. The name should conform to RFC1035. - */ - backendBucket?: string; - /** - * The name of the Signed URL Key to delete. - */ - keyName?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Backendbuckets$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendBucket resource to return. - */ - backendBucket?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Backendbuckets$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Backendbuckets$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$BackendBucket; - } - export interface Params$Resource$Backendbuckets$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Backendbuckets$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendBucket resource to patch. - */ - backendBucket?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$BackendBucket; - } - export interface Params$Resource$Backendbuckets$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetPolicyRequest; - } - export interface Params$Resource$Backendbuckets$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Backendbuckets$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendBucket resource to update. - */ - backendBucket?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$BackendBucket; - } - - export class Resource$Backendservices { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.backendServices.addSignedUrlKey - * @desc Adds a key for validating requests with signed URLs for this backend service. - * @alias compute.backendServices.addSignedUrlKey - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource to which the Signed URL Key should be added. The name should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().SignedUrlKey} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addSignedUrlKey( - params?: Params$Resource$Backendservices$Addsignedurlkey, - options?: MethodOptions - ): GaxiosPromise; - addSignedUrlKey( - params: Params$Resource$Backendservices$Addsignedurlkey, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addSignedUrlKey( - params: Params$Resource$Backendservices$Addsignedurlkey, - callback: BodyResponseCallback - ): void; - addSignedUrlKey(callback: BodyResponseCallback): void; - addSignedUrlKey( - paramsOrCallback?: - | Params$Resource$Backendservices$Addsignedurlkey - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendservices$Addsignedurlkey; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendservices$Addsignedurlkey; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendServices/{backendService}/addSignedUrlKey' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'backendService'], - pathParams: ['backendService', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendServices.aggregatedList - * @desc Retrieves the list of all BackendService resources, regional and global, available to the specified project. - * @alias compute.backendServices.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Name of the project scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Backendservices$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Backendservices$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Backendservices$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Backendservices$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendservices$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendservices$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/backendServices' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.backendServices.delete - * @desc Deletes the specified BackendService resource. - * @alias compute.backendServices.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Backendservices$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Backendservices$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Backendservices$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Backendservices$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendservices$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendservices$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendServices/{backendService}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'backendService'], - pathParams: ['backendService', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendServices.deleteSignedUrlKey - * @desc Deletes a key for validating requests with signed URLs for this backend service. - * @alias compute.backendServices.deleteSignedUrlKey - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource to which the Signed URL Key should be added. The name should conform to RFC1035. - * @param {string} params.keyName The name of the Signed URL Key to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - deleteSignedUrlKey( - params?: Params$Resource$Backendservices$Deletesignedurlkey, - options?: MethodOptions - ): GaxiosPromise; - deleteSignedUrlKey( - params: Params$Resource$Backendservices$Deletesignedurlkey, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - deleteSignedUrlKey( - params: Params$Resource$Backendservices$Deletesignedurlkey, - callback: BodyResponseCallback - ): void; - deleteSignedUrlKey(callback: BodyResponseCallback): void; - deleteSignedUrlKey( - paramsOrCallback?: - | Params$Resource$Backendservices$Deletesignedurlkey - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendservices$Deletesignedurlkey; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendservices$Deletesignedurlkey; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendServices/{backendService}/deleteSignedUrlKey' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'backendService', 'keyName'], - pathParams: ['backendService', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendServices.get - * @desc Returns the specified BackendService resource. Gets a list of available backend services. - * @alias compute.backendServices.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Backendservices$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Backendservices$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Backendservices$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Backendservices$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendservices$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendservices$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendServices/{backendService}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'backendService'], - pathParams: ['backendService', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendServices.getHealth - * @desc Gets the most recent health check results for this BackendService. - * @alias compute.backendServices.getHealth - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource to which the queried instance belongs. - * @param {string} params.project - * @param {().ResourceGroupReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getHealth( - params?: Params$Resource$Backendservices$Gethealth, - options?: MethodOptions - ): GaxiosPromise; - getHealth( - params: Params$Resource$Backendservices$Gethealth, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getHealth( - params: Params$Resource$Backendservices$Gethealth, - callback: BodyResponseCallback - ): void; - getHealth( - callback: BodyResponseCallback - ): void; - getHealth( - paramsOrCallback?: - | Params$Resource$Backendservices$Gethealth - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendservices$Gethealth; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendservices$Gethealth; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendServices/{backendService}/getHealth' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'backendService'], - pathParams: ['backendService', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendServices.insert - * @desc Creates a BackendService resource in the specified project using the data included in the request. There are several restrictions and guidelines to keep in mind when creating a backend service. Read Restrictions and Guidelines for more information. - * @alias compute.backendServices.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().BackendService} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Backendservices$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Backendservices$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Backendservices$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Backendservices$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendservices$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendservices$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendServices' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendServices.list - * @desc Retrieves the list of BackendService resources available to the specified project. - * @alias compute.backendServices.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Backendservices$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Backendservices$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Backendservices$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Backendservices$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendservices$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendservices$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendServices' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendServices.patch - * @desc Patches the specified BackendService resource with the data included in the request. There are several restrictions and guidelines to keep in mind when updating a backend service. Read Restrictions and Guidelines for more information. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.backendServices.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource to patch. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().BackendService} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Backendservices$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Backendservices$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Backendservices$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Backendservices$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendservices$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendservices$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendServices/{backendService}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'backendService'], - pathParams: ['backendService', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendServices.setSecurityPolicy - * @desc Sets the security policy for the specified backend service. - * @alias compute.backendServices.setSecurityPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource to which the security policy should be set. The name should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().SecurityPolicyReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setSecurityPolicy( - params?: Params$Resource$Backendservices$Setsecuritypolicy, - options?: MethodOptions - ): GaxiosPromise; - setSecurityPolicy( - params: Params$Resource$Backendservices$Setsecuritypolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setSecurityPolicy( - params: Params$Resource$Backendservices$Setsecuritypolicy, - callback: BodyResponseCallback - ): void; - setSecurityPolicy(callback: BodyResponseCallback): void; - setSecurityPolicy( - paramsOrCallback?: - | Params$Resource$Backendservices$Setsecuritypolicy - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendservices$Setsecuritypolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendservices$Setsecuritypolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendServices/{backendService}/setSecurityPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'backendService'], - pathParams: ['backendService', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendServices.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.backendServices.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Backendservices$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Backendservices$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Backendservices$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Backendservices$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendservices$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendservices$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendServices/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.backendServices.update - * @desc Updates the specified BackendService resource with the data included in the request. There are several restrictions and guidelines to keep in mind when updating a backend service. Read Restrictions and Guidelines for more information. - * @alias compute.backendServices.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource to update. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().BackendService} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Backendservices$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Backendservices$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Backendservices$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Backendservices$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Backendservices$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Backendservices$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/backendServices/{backendService}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'backendService'], - pathParams: ['backendService', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Backendservices$Addsignedurlkey - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource to which the Signed URL Key should be added. The name should conform to RFC1035. - */ - backendService?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SignedUrlKey; - } - export interface Params$Resource$Backendservices$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Name of the project scoping this request. - */ - project?: string; - } - export interface Params$Resource$Backendservices$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource to delete. - */ - backendService?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Backendservices$Deletesignedurlkey - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource to which the Signed URL Key should be added. The name should conform to RFC1035. - */ - backendService?: string; - /** - * The name of the Signed URL Key to delete. - */ - keyName?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Backendservices$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource to return. - */ - backendService?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Backendservices$Gethealth - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource to which the queried instance belongs. - */ - backendService?: string; - /** - * - */ - project?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ResourceGroupReference; - } - export interface Params$Resource$Backendservices$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$BackendService; - } - export interface Params$Resource$Backendservices$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Backendservices$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource to patch. - */ - backendService?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$BackendService; - } - export interface Params$Resource$Backendservices$Setsecuritypolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource to which the security policy should be set. The name should conform to RFC1035. - */ - backendService?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SecurityPolicyReference; - } - export interface Params$Resource$Backendservices$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Backendservices$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource to update. - */ - backendService?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$BackendService; - } - - export class Resource$Disks { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.disks.addResourcePolicies - * @desc Adds existing resource policies to a disk. You can only add one policy which will be applied to this disk for scheduling snapshot creation. - * @alias compute.disks.addResourcePolicies - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.disk The disk name for this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().DisksAddResourcePoliciesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addResourcePolicies( - params?: Params$Resource$Disks$Addresourcepolicies, - options?: MethodOptions - ): GaxiosPromise; - addResourcePolicies( - params: Params$Resource$Disks$Addresourcepolicies, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addResourcePolicies( - params: Params$Resource$Disks$Addresourcepolicies, - callback: BodyResponseCallback - ): void; - addResourcePolicies(callback: BodyResponseCallback): void; - addResourcePolicies( - paramsOrCallback?: - | Params$Resource$Disks$Addresourcepolicies - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Disks$Addresourcepolicies; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$Addresourcepolicies; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/disks/{disk}/addResourcePolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'disk'], - pathParams: ['disk', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.disks.aggregatedList - * @desc Retrieves an aggregated list of persistent disks. - * @alias compute.disks.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Disks$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Disks$Aggregatedlist, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Disks$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Disks$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Disks$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/aggregated/disks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.disks.createSnapshot - * @desc Creates a snapshot of a specified persistent disk. - * @alias compute.disks.createSnapshot - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.disk Name of the persistent disk to snapshot. - * @param {boolean=} params.guestFlush [Input Only] Specifies to create an application consistent snapshot by informing the OS to prepare for the snapshot process. Currently only supported on Windows instances using the Volume Shadow Copy Service (VSS). - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().Snapshot} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - createSnapshot( - params?: Params$Resource$Disks$Createsnapshot, - options?: MethodOptions - ): GaxiosPromise; - createSnapshot( - params: Params$Resource$Disks$Createsnapshot, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - createSnapshot( - params: Params$Resource$Disks$Createsnapshot, - callback: BodyResponseCallback - ): void; - createSnapshot(callback: BodyResponseCallback): void; - createSnapshot( - paramsOrCallback?: - | Params$Resource$Disks$Createsnapshot - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Disks$Createsnapshot; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$Createsnapshot; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/disks/{disk}/createSnapshot' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'disk'], - pathParams: ['disk', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.disks.delete - * @desc Deletes the specified persistent disk. Deleting a disk removes its data permanently and is irreversible. However, deleting a disk does not delete any snapshots previously made from the disk. You must separately delete snapshots. - * @alias compute.disks.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.disk Name of the persistent disk to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Disks$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Disks$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Disks$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Disks$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Disks$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/disks/{disk}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'disk'], - pathParams: ['disk', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.disks.get - * @desc Returns a specified persistent disk. Gets a list of available persistent disks by making a list() request. - * @alias compute.disks.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.disk Name of the persistent disk to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Disks$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Disks$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Disks$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Disks$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Disks$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/disks/{disk}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'disk'], - pathParams: ['disk', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.disks.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.disks.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Disks$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Disks$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Disks$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Disks$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Disks$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/disks/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.disks.insert - * @desc Creates a persistent disk in the specified project using the data in the request. You can create a disk with a sourceImage, a sourceSnapshot, or create an empty 500 GB data disk by omitting all properties. You can also create a disk that is larger than the default size by specifying the sizeGb property. - * @alias compute.disks.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string=} params.sourceImage Optional. Source image to restore onto a disk. - * @param {string} params.zone The name of the zone for this request. - * @param {().Disk} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Disks$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Disks$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Disks$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Disks$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Disks$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/zones/{zone}/disks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.disks.list - * @desc Retrieves a list of persistent disks contained within the specified zone. - * @alias compute.disks.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Disks$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Disks$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Disks$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Disks$List - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Disks$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/zones/{zone}/disks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.disks.removeResourcePolicies - * @desc Removes resource policies from a disk. - * @alias compute.disks.removeResourcePolicies - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.disk The disk name for this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().DisksRemoveResourcePoliciesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - removeResourcePolicies( - params?: Params$Resource$Disks$Removeresourcepolicies, - options?: MethodOptions - ): GaxiosPromise; - removeResourcePolicies( - params: Params$Resource$Disks$Removeresourcepolicies, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - removeResourcePolicies( - params: Params$Resource$Disks$Removeresourcepolicies, - callback: BodyResponseCallback - ): void; - removeResourcePolicies( - callback: BodyResponseCallback - ): void; - removeResourcePolicies( - paramsOrCallback?: - | Params$Resource$Disks$Removeresourcepolicies - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Disks$Removeresourcepolicies; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$Removeresourcepolicies; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/disks/{disk}/removeResourcePolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'disk'], - pathParams: ['disk', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.disks.resize - * @desc Resizes the specified persistent disk. You can only increase the size of the disk. - * @alias compute.disks.resize - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.disk The name of the persistent disk. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().DisksResizeRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - resize( - params?: Params$Resource$Disks$Resize, - options?: MethodOptions - ): GaxiosPromise; - resize( - params: Params$Resource$Disks$Resize, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - resize( - params: Params$Resource$Disks$Resize, - callback: BodyResponseCallback - ): void; - resize(callback: BodyResponseCallback): void; - resize( - paramsOrCallback?: - | Params$Resource$Disks$Resize - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Disks$Resize; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$Resize; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/disks/{disk}/resize' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'disk'], - pathParams: ['disk', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.disks.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.disks.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().ZoneSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Disks$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Disks$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Disks$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Disks$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Disks$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/disks/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.disks.setLabels - * @desc Sets the labels on a disk. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.disks.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().ZoneSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Disks$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Disks$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Disks$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Disks$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Disks$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/disks/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.disks.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.disks.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Disks$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Disks$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Disks$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Disks$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Disks$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disks$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/disks/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Disks$Addresourcepolicies - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The disk name for this request. - */ - disk?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$DisksAddResourcePoliciesRequest; - } - export interface Params$Resource$Disks$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Disks$Createsnapshot - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the persistent disk to snapshot. - */ - disk?: string; - /** - * [Input Only] Specifies to create an application consistent snapshot by informing the OS to prepare for the snapshot process. Currently only supported on Windows instances using the Volume Shadow Copy Service (VSS). - */ - guestFlush?: boolean; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Snapshot; - } - export interface Params$Resource$Disks$Delete extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the persistent disk to delete. - */ - disk?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Disks$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the persistent disk to return. - */ - disk?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Disks$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Disks$Insert extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Optional. Source image to restore onto a disk. - */ - sourceImage?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Disk; - } - export interface Params$Resource$Disks$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Disks$Removeresourcepolicies - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The disk name for this request. - */ - disk?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$DisksRemoveResourcePoliciesRequest; - } - export interface Params$Resource$Disks$Resize extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the persistent disk. - */ - disk?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$DisksResizeRequest; - } - export interface Params$Resource$Disks$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ZoneSetPolicyRequest; - } - export interface Params$Resource$Disks$Setlabels extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ZoneSetLabelsRequest; - } - export interface Params$Resource$Disks$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Disktypes { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.diskTypes.aggregatedList - * @desc Retrieves an aggregated list of disk types. - * @alias compute.diskTypes.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Disktypes$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Disktypes$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Disktypes$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Disktypes$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Disktypes$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disktypes$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/aggregated/diskTypes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.diskTypes.get - * @desc Returns the specified disk type. Gets a list of available disk types by making a list() request. - * @alias compute.diskTypes.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.diskType Name of the disk type to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Disktypes$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Disktypes$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Disktypes$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Disktypes$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Disktypes$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disktypes$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/diskTypes/{diskType}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'diskType'], - pathParams: ['diskType', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.diskTypes.list - * @desc Retrieves a list of disk types available to the specified project. - * @alias compute.diskTypes.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Disktypes$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Disktypes$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Disktypes$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Disktypes$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Disktypes$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Disktypes$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/diskTypes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Disktypes$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Disktypes$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the disk type to return. - */ - diskType?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Disktypes$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - - export class Resource$Externalvpngateways { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.externalVpnGateways.delete - * @desc Deletes the specified externalVpnGateway. - * @alias compute.externalVpnGateways.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.externalVpnGateway Name of the externalVpnGateways to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Externalvpngateways$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Externalvpngateways$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Externalvpngateways$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Externalvpngateways$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Externalvpngateways$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Externalvpngateways$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/externalVpnGateways/{externalVpnGateway}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'externalVpnGateway'], - pathParams: ['externalVpnGateway', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.externalVpnGateways.get - * @desc Returns the specified externalVpnGateway. Get a list of available externalVpnGateways by making a list() request. - * @alias compute.externalVpnGateways.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.externalVpnGateway Name of the externalVpnGateway to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Externalvpngateways$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Externalvpngateways$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Externalvpngateways$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Externalvpngateways$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Externalvpngateways$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Externalvpngateways$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/externalVpnGateways/{externalVpnGateway}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'externalVpnGateway'], - pathParams: ['externalVpnGateway', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.externalVpnGateways.insert - * @desc Creates a ExternalVpnGateway in the specified project using the data included in the request. - * @alias compute.externalVpnGateways.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().ExternalVpnGateway} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Externalvpngateways$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Externalvpngateways$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Externalvpngateways$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Externalvpngateways$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Externalvpngateways$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Externalvpngateways$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/externalVpnGateways' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.externalVpnGateways.list - * @desc Retrieves the list of ExternalVpnGateway available to the specified project. - * @alias compute.externalVpnGateways.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Externalvpngateways$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Externalvpngateways$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Externalvpngateways$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Externalvpngateways$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Externalvpngateways$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Externalvpngateways$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/externalVpnGateways' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.externalVpnGateways.setLabels - * @desc Sets the labels on an ExternalVpnGateway. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.externalVpnGateways.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Externalvpngateways$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Externalvpngateways$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Externalvpngateways$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Externalvpngateways$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Externalvpngateways$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Externalvpngateways$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/externalVpnGateways/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.externalVpnGateways.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.externalVpnGateways.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Externalvpngateways$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Externalvpngateways$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Externalvpngateways$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Externalvpngateways$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Externalvpngateways$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Externalvpngateways$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/externalVpnGateways/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Externalvpngateways$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the externalVpnGateways to delete. - */ - externalVpnGateway?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Externalvpngateways$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the externalVpnGateway to return. - */ - externalVpnGateway?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Externalvpngateways$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ExternalVpnGateway; - } - export interface Params$Resource$Externalvpngateways$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Externalvpngateways$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetLabelsRequest; - } - export interface Params$Resource$Externalvpngateways$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Firewalls { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.firewalls.delete - * @desc Deletes the specified firewall. - * @alias compute.firewalls.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.firewall Name of the firewall rule to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Firewalls$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Firewalls$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Firewalls$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Firewalls$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Firewalls$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Firewalls$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/firewalls/{firewall}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'firewall'], - pathParams: ['firewall', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.firewalls.get - * @desc Returns the specified firewall. - * @alias compute.firewalls.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.firewall Name of the firewall rule to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Firewalls$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Firewalls$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Firewalls$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Firewalls$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Firewalls$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Firewalls$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/firewalls/{firewall}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'firewall'], - pathParams: ['firewall', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.firewalls.insert - * @desc Creates a firewall rule in the specified project using the data included in the request. - * @alias compute.firewalls.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Firewall} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Firewalls$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Firewalls$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Firewalls$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Firewalls$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Firewalls$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Firewalls$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/firewalls' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.firewalls.list - * @desc Retrieves the list of firewall rules available to the specified project. - * @alias compute.firewalls.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Firewalls$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Firewalls$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Firewalls$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Firewalls$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Firewalls$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Firewalls$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/firewalls' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.firewalls.patch - * @desc Updates the specified firewall rule with the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.firewalls.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.firewall Name of the firewall rule to patch. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Firewall} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Firewalls$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Firewalls$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Firewalls$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Firewalls$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Firewalls$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Firewalls$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/firewalls/{firewall}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'firewall'], - pathParams: ['firewall', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.firewalls.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.firewalls.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Firewalls$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Firewalls$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Firewalls$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Firewalls$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Firewalls$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Firewalls$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/firewalls/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.firewalls.update - * @desc Updates the specified firewall rule with the data included in the request. The PUT method can only update the following fields of firewall rule: allowed, description, sourceRanges, sourceTags, targetTags. - * @alias compute.firewalls.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.firewall Name of the firewall rule to update. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Firewall} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Firewalls$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Firewalls$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Firewalls$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Firewalls$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Firewalls$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Firewalls$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/firewalls/{firewall}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'firewall'], - pathParams: ['firewall', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Firewalls$Delete extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the firewall rule to delete. - */ - firewall?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Firewalls$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the firewall rule to return. - */ - firewall?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Firewalls$Insert extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Firewall; - } - export interface Params$Resource$Firewalls$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Firewalls$Patch extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the firewall rule to patch. - */ - firewall?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Firewall; - } - export interface Params$Resource$Firewalls$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Firewalls$Update extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the firewall rule to update. - */ - firewall?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Firewall; - } - - export class Resource$Forwardingrules { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.forwardingRules.aggregatedList - * @desc Retrieves an aggregated list of forwarding rules. - * @alias compute.forwardingRules.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Forwardingrules$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Forwardingrules$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Forwardingrules$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Forwardingrules$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Forwardingrules$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Forwardingrules$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/forwardingRules' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.forwardingRules.delete - * @desc Deletes the specified ForwardingRule resource. - * @alias compute.forwardingRules.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.forwardingRule Name of the ForwardingRule resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Forwardingrules$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Forwardingrules$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Forwardingrules$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Forwardingrules$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Forwardingrules$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Forwardingrules$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/forwardingRules/{forwardingRule}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'forwardingRule'], - pathParams: ['forwardingRule', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.forwardingRules.get - * @desc Returns the specified ForwardingRule resource. - * @alias compute.forwardingRules.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.forwardingRule Name of the ForwardingRule resource to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Forwardingrules$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Forwardingrules$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Forwardingrules$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Forwardingrules$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Forwardingrules$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Forwardingrules$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/forwardingRules/{forwardingRule}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'forwardingRule'], - pathParams: ['forwardingRule', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.forwardingRules.insert - * @desc Creates a ForwardingRule resource in the specified project and region using the data included in the request. - * @alias compute.forwardingRules.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().ForwardingRule} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Forwardingrules$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Forwardingrules$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Forwardingrules$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Forwardingrules$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Forwardingrules$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Forwardingrules$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/forwardingRules' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.forwardingRules.list - * @desc Retrieves a list of ForwardingRule resources available to the specified project and region. - * @alias compute.forwardingRules.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Forwardingrules$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Forwardingrules$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Forwardingrules$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Forwardingrules$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Forwardingrules$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Forwardingrules$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/forwardingRules' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.forwardingRules.patch - * @desc Updates the specified forwarding rule with the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. Currently, you can only patch the network_tier field. - * @alias compute.forwardingRules.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.forwardingRule Name of the ForwardingRule resource to patch. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().ForwardingRule} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Forwardingrules$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Forwardingrules$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Forwardingrules$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Forwardingrules$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Forwardingrules$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Forwardingrules$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/forwardingRules/{forwardingRule}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'region', 'forwardingRule'], - pathParams: ['forwardingRule', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.forwardingRules.setLabels - * @desc Sets the labels on the specified resource. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.forwardingRules.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().RegionSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Forwardingrules$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Forwardingrules$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Forwardingrules$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Forwardingrules$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Forwardingrules$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Forwardingrules$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/forwardingRules/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.forwardingRules.setTarget - * @desc Changes target URL for forwarding rule. The new target should be of the same type as the old target. - * @alias compute.forwardingRules.setTarget - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.forwardingRule Name of the ForwardingRule resource in which target is to be set. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().TargetReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setTarget( - params?: Params$Resource$Forwardingrules$Settarget, - options?: MethodOptions - ): GaxiosPromise; - setTarget( - params: Params$Resource$Forwardingrules$Settarget, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setTarget( - params: Params$Resource$Forwardingrules$Settarget, - callback: BodyResponseCallback - ): void; - setTarget(callback: BodyResponseCallback): void; - setTarget( - paramsOrCallback?: - | Params$Resource$Forwardingrules$Settarget - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Forwardingrules$Settarget; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Forwardingrules$Settarget; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/forwardingRules/{forwardingRule}/setTarget' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'forwardingRule'], - pathParams: ['forwardingRule', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.forwardingRules.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.forwardingRules.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Forwardingrules$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Forwardingrules$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Forwardingrules$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Forwardingrules$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Forwardingrules$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Forwardingrules$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/forwardingRules/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Forwardingrules$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Forwardingrules$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the ForwardingRule resource to delete. - */ - forwardingRule?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Forwardingrules$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the ForwardingRule resource to return. - */ - forwardingRule?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Forwardingrules$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ForwardingRule; - } - export interface Params$Resource$Forwardingrules$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Forwardingrules$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the ForwardingRule resource to patch. - */ - forwardingRule?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ForwardingRule; - } - export interface Params$Resource$Forwardingrules$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionSetLabelsRequest; - } - export interface Params$Resource$Forwardingrules$Settarget - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the ForwardingRule resource in which target is to be set. - */ - forwardingRule?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetReference; - } - export interface Params$Resource$Forwardingrules$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Globaladdresses { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.globalAddresses.delete - * @desc Deletes the specified address resource. - * @alias compute.globalAddresses.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.address Name of the address resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Globaladdresses$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Globaladdresses$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Globaladdresses$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Globaladdresses$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globaladdresses$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globaladdresses$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/addresses/{address}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'address'], - pathParams: ['address', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalAddresses.get - * @desc Returns the specified address resource. Gets a list of available addresses by making a list() request. - * @alias compute.globalAddresses.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.address Name of the address resource to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Globaladdresses$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Globaladdresses$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Globaladdresses$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Globaladdresses$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globaladdresses$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globaladdresses$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/addresses/{address}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'address'], - pathParams: ['address', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalAddresses.insert - * @desc Creates an address resource in the specified project by using the data included in the request. - * @alias compute.globalAddresses.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Address} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Globaladdresses$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Globaladdresses$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Globaladdresses$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Globaladdresses$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globaladdresses$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globaladdresses$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/addresses' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalAddresses.list - * @desc Retrieves a list of global addresses. - * @alias compute.globalAddresses.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Globaladdresses$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Globaladdresses$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Globaladdresses$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Globaladdresses$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globaladdresses$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globaladdresses$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/addresses' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalAddresses.setLabels - * @desc Sets the labels on a GlobalAddress. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.globalAddresses.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Globaladdresses$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Globaladdresses$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Globaladdresses$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Globaladdresses$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globaladdresses$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globaladdresses$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/addresses/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalAddresses.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.globalAddresses.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Globaladdresses$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Globaladdresses$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Globaladdresses$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Globaladdresses$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globaladdresses$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globaladdresses$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/addresses/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Globaladdresses$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the address resource to delete. - */ - address?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Globaladdresses$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the address resource to return. - */ - address?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Globaladdresses$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Address; - } - export interface Params$Resource$Globaladdresses$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Globaladdresses$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetLabelsRequest; - } - export interface Params$Resource$Globaladdresses$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Globalforwardingrules { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.globalForwardingRules.delete - * @desc Deletes the specified GlobalForwardingRule resource. - * @alias compute.globalForwardingRules.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.forwardingRule Name of the ForwardingRule resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Globalforwardingrules$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Globalforwardingrules$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Globalforwardingrules$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Globalforwardingrules$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalforwardingrules$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalforwardingrules$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/forwardingRules/{forwardingRule}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'forwardingRule'], - pathParams: ['forwardingRule', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalForwardingRules.get - * @desc Returns the specified GlobalForwardingRule resource. Gets a list of available forwarding rules by making a list() request. - * @alias compute.globalForwardingRules.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.forwardingRule Name of the ForwardingRule resource to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Globalforwardingrules$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Globalforwardingrules$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Globalforwardingrules$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Globalforwardingrules$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalforwardingrules$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalforwardingrules$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/forwardingRules/{forwardingRule}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'forwardingRule'], - pathParams: ['forwardingRule', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalForwardingRules.insert - * @desc Creates a GlobalForwardingRule resource in the specified project using the data included in the request. - * @alias compute.globalForwardingRules.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().ForwardingRule} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Globalforwardingrules$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Globalforwardingrules$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Globalforwardingrules$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Globalforwardingrules$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalforwardingrules$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalforwardingrules$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/forwardingRules' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalForwardingRules.list - * @desc Retrieves a list of GlobalForwardingRule resources available to the specified project. - * @alias compute.globalForwardingRules.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Globalforwardingrules$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Globalforwardingrules$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Globalforwardingrules$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Globalforwardingrules$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalforwardingrules$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalforwardingrules$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/forwardingRules' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalForwardingRules.patch - * @desc Updates the specified forwarding rule with the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. Currently, you can only patch the network_tier field. - * @alias compute.globalForwardingRules.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.forwardingRule Name of the ForwardingRule resource to patch. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().ForwardingRule} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Globalforwardingrules$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Globalforwardingrules$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Globalforwardingrules$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Globalforwardingrules$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalforwardingrules$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalforwardingrules$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/forwardingRules/{forwardingRule}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'forwardingRule'], - pathParams: ['forwardingRule', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalForwardingRules.setLabels - * @desc Sets the labels on the specified resource. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.globalForwardingRules.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Globalforwardingrules$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Globalforwardingrules$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Globalforwardingrules$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Globalforwardingrules$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalforwardingrules$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalforwardingrules$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/forwardingRules/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalForwardingRules.setTarget - * @desc Changes target URL for the GlobalForwardingRule resource. The new target should be of the same type as the old target. - * @alias compute.globalForwardingRules.setTarget - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.forwardingRule Name of the ForwardingRule resource in which target is to be set. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().TargetReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setTarget( - params?: Params$Resource$Globalforwardingrules$Settarget, - options?: MethodOptions - ): GaxiosPromise; - setTarget( - params: Params$Resource$Globalforwardingrules$Settarget, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setTarget( - params: Params$Resource$Globalforwardingrules$Settarget, - callback: BodyResponseCallback - ): void; - setTarget(callback: BodyResponseCallback): void; - setTarget( - paramsOrCallback?: - | Params$Resource$Globalforwardingrules$Settarget - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalforwardingrules$Settarget; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalforwardingrules$Settarget; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/forwardingRules/{forwardingRule}/setTarget' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'forwardingRule'], - pathParams: ['forwardingRule', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalForwardingRules.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.globalForwardingRules.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Globalforwardingrules$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Globalforwardingrules$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Globalforwardingrules$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Globalforwardingrules$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalforwardingrules$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalforwardingrules$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/forwardingRules/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Globalforwardingrules$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the ForwardingRule resource to delete. - */ - forwardingRule?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Globalforwardingrules$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the ForwardingRule resource to return. - */ - forwardingRule?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Globalforwardingrules$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ForwardingRule; - } - export interface Params$Resource$Globalforwardingrules$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Globalforwardingrules$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the ForwardingRule resource to patch. - */ - forwardingRule?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ForwardingRule; - } - export interface Params$Resource$Globalforwardingrules$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetLabelsRequest; - } - export interface Params$Resource$Globalforwardingrules$Settarget - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the ForwardingRule resource in which target is to be set. - */ - forwardingRule?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetReference; - } - export interface Params$Resource$Globalforwardingrules$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Globalnetworkendpointgroups { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.globalNetworkEndpointGroups.attachNetworkEndpoints - * @desc Attach a network endpoint to the specified network endpoint group. - * @alias compute.globalNetworkEndpointGroups.attachNetworkEndpoints - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.networkEndpointGroup The name of the network endpoint group where you are attaching network endpoints to. It should comply with RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().GlobalNetworkEndpointGroupsAttachEndpointsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - attachNetworkEndpoints( - params?: Params$Resource$Globalnetworkendpointgroups$Attachnetworkendpoints, - options?: MethodOptions - ): GaxiosPromise; - attachNetworkEndpoints( - params: Params$Resource$Globalnetworkendpointgroups$Attachnetworkendpoints, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - attachNetworkEndpoints( - params: Params$Resource$Globalnetworkendpointgroups$Attachnetworkendpoints, - callback: BodyResponseCallback - ): void; - attachNetworkEndpoints( - callback: BodyResponseCallback - ): void; - attachNetworkEndpoints( - paramsOrCallback?: - | Params$Resource$Globalnetworkendpointgroups$Attachnetworkendpoints - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalnetworkendpointgroups$Attachnetworkendpoints; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalnetworkendpointgroups$Attachnetworkendpoints; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networkEndpointGroups/{networkEndpointGroup}/attachNetworkEndpoints' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'networkEndpointGroup'], - pathParams: ['networkEndpointGroup', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalNetworkEndpointGroups.delete - * @desc Deletes the specified network endpoint group.Note that the NEG cannot be deleted if there are backend services referencing it. - * @alias compute.globalNetworkEndpointGroups.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.networkEndpointGroup The name of the network endpoint group to delete. It should comply with RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Globalnetworkendpointgroups$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Globalnetworkendpointgroups$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Globalnetworkendpointgroups$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Globalnetworkendpointgroups$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalnetworkendpointgroups$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalnetworkendpointgroups$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networkEndpointGroups/{networkEndpointGroup}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'networkEndpointGroup'], - pathParams: ['networkEndpointGroup', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalNetworkEndpointGroups.detachNetworkEndpoints - * @desc Detach the network endpoint from the specified network endpoint group. - * @alias compute.globalNetworkEndpointGroups.detachNetworkEndpoints - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.networkEndpointGroup The name of the network endpoint group where you are removing network endpoints. It should comply with RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().GlobalNetworkEndpointGroupsDetachEndpointsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - detachNetworkEndpoints( - params?: Params$Resource$Globalnetworkendpointgroups$Detachnetworkendpoints, - options?: MethodOptions - ): GaxiosPromise; - detachNetworkEndpoints( - params: Params$Resource$Globalnetworkendpointgroups$Detachnetworkendpoints, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - detachNetworkEndpoints( - params: Params$Resource$Globalnetworkendpointgroups$Detachnetworkendpoints, - callback: BodyResponseCallback - ): void; - detachNetworkEndpoints( - callback: BodyResponseCallback - ): void; - detachNetworkEndpoints( - paramsOrCallback?: - | Params$Resource$Globalnetworkendpointgroups$Detachnetworkendpoints - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalnetworkendpointgroups$Detachnetworkendpoints; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalnetworkendpointgroups$Detachnetworkendpoints; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networkEndpointGroups/{networkEndpointGroup}/detachNetworkEndpoints' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'networkEndpointGroup'], - pathParams: ['networkEndpointGroup', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalNetworkEndpointGroups.get - * @desc Returns the specified network endpoint group. Gets a list of available network endpoint groups by making a list() request. - * @alias compute.globalNetworkEndpointGroups.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.networkEndpointGroup The name of the network endpoint group. It should comply with RFC1035. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Globalnetworkendpointgroups$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Globalnetworkendpointgroups$Get, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Globalnetworkendpointgroups$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Globalnetworkendpointgroups$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalnetworkendpointgroups$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalnetworkendpointgroups$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networkEndpointGroups/{networkEndpointGroup}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'networkEndpointGroup'], - pathParams: ['networkEndpointGroup', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalNetworkEndpointGroups.insert - * @desc Creates a network endpoint group in the specified project using the parameters that are included in the request. - * @alias compute.globalNetworkEndpointGroups.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().NetworkEndpointGroup} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Globalnetworkendpointgroups$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Globalnetworkendpointgroups$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Globalnetworkendpointgroups$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Globalnetworkendpointgroups$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalnetworkendpointgroups$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalnetworkendpointgroups$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networkEndpointGroups' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalNetworkEndpointGroups.list - * @desc Retrieves the list of network endpoint groups that are located in the specified project. - * @alias compute.globalNetworkEndpointGroups.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Globalnetworkendpointgroups$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Globalnetworkendpointgroups$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Globalnetworkendpointgroups$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Globalnetworkendpointgroups$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalnetworkendpointgroups$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalnetworkendpointgroups$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networkEndpointGroups' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalNetworkEndpointGroups.listNetworkEndpoints - * @desc Lists the network endpoints in the specified network endpoint group. - * @alias compute.globalNetworkEndpointGroups.listNetworkEndpoints - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string} params.networkEndpointGroup The name of the network endpoint group from which you want to generate a list of included network endpoints. It should comply with RFC1035. - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listNetworkEndpoints( - params?: Params$Resource$Globalnetworkendpointgroups$Listnetworkendpoints, - options?: MethodOptions - ): GaxiosPromise; - listNetworkEndpoints( - params: Params$Resource$Globalnetworkendpointgroups$Listnetworkendpoints, - options: - | MethodOptions - | BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - >, - callback: BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - > - ): void; - listNetworkEndpoints( - params: Params$Resource$Globalnetworkendpointgroups$Listnetworkendpoints, - callback: BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - > - ): void; - listNetworkEndpoints( - callback: BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - > - ): void; - listNetworkEndpoints( - paramsOrCallback?: - | Params$Resource$Globalnetworkendpointgroups$Listnetworkendpoints - | BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - >, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - >, - callback?: BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - > - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalnetworkendpointgroups$Listnetworkendpoints; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalnetworkendpointgroups$Listnetworkendpoints; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networkEndpointGroups/{networkEndpointGroup}/listNetworkEndpoints' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'networkEndpointGroup'], - pathParams: ['networkEndpointGroup', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest< - Schema$NetworkEndpointGroupsListNetworkEndpoints - >(parameters); - } - } - } - - export interface Params$Resource$Globalnetworkendpointgroups$Attachnetworkendpoints - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the network endpoint group where you are attaching network endpoints to. It should comply with RFC1035. - */ - networkEndpointGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalNetworkEndpointGroupsAttachEndpointsRequest; - } - export interface Params$Resource$Globalnetworkendpointgroups$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the network endpoint group to delete. It should comply with RFC1035. - */ - networkEndpointGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Globalnetworkendpointgroups$Detachnetworkendpoints - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the network endpoint group where you are removing network endpoints. It should comply with RFC1035. - */ - networkEndpointGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalNetworkEndpointGroupsDetachEndpointsRequest; - } - export interface Params$Resource$Globalnetworkendpointgroups$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the network endpoint group. It should comply with RFC1035. - */ - networkEndpointGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Globalnetworkendpointgroups$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NetworkEndpointGroup; - } - export interface Params$Resource$Globalnetworkendpointgroups$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Globalnetworkendpointgroups$Listnetworkendpoints - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * The name of the network endpoint group from which you want to generate a list of included network endpoints. It should comply with RFC1035. - */ - networkEndpointGroup?: string; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - - export class Resource$Globaloperations { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.globalOperations.aggregatedList - * @desc Retrieves an aggregated list of all operations. - * @alias compute.globalOperations.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Globaloperations$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Globaloperations$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Globaloperations$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Globaloperations$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globaloperations$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globaloperations$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/operations' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalOperations.delete - * @desc Deletes the specified Operations resource. - * @alias compute.globalOperations.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.operation Name of the Operations resource to delete. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Globaloperations$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Globaloperations$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Globaloperations$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Globaloperations$Delete - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globaloperations$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globaloperations$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/operations/{operation}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'operation'], - pathParams: ['operation', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalOperations.get - * @desc Retrieves the specified Operations resource. Gets a list of operations by making a list() request. - * @alias compute.globalOperations.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.operation Name of the Operations resource to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Globaloperations$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Globaloperations$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Globaloperations$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Globaloperations$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globaloperations$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globaloperations$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/operations/{operation}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'operation'], - pathParams: ['operation', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalOperations.list - * @desc Retrieves a list of Operation resources contained within the specified project. - * @alias compute.globalOperations.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Globaloperations$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Globaloperations$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Globaloperations$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Globaloperations$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globaloperations$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globaloperations$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/operations' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalOperations.wait - * @desc Waits for the specified Operations resource until it is done or timeout, and retrieves the specified Operations resource. 1. Immediately returns when the operation is already done. 2. Waits for no more than the default deadline (2 minutes, subject to change) and then returns the current state of the operation, which may be DONE or still in progress. 3. Is best-effort: a. The server can wait less than the default deadline or zero seconds, in overload situations. b. There is no guarantee that the operation is actually done when returns. 4. User should be prepared to retry if the operation is not DONE. - * @alias compute.globalOperations.wait - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.operation Name of the Operations resource to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - wait( - params?: Params$Resource$Globaloperations$Wait, - options?: MethodOptions - ): GaxiosPromise; - wait( - params: Params$Resource$Globaloperations$Wait, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - wait( - params: Params$Resource$Globaloperations$Wait, - callback: BodyResponseCallback - ): void; - wait(callback: BodyResponseCallback): void; - wait( - paramsOrCallback?: - | Params$Resource$Globaloperations$Wait - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globaloperations$Wait; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globaloperations$Wait; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/operations/{operation}/wait' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'operation'], - pathParams: ['operation', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Globaloperations$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Globaloperations$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the Operations resource to delete. - */ - operation?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Globaloperations$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the Operations resource to return. - */ - operation?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Globaloperations$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Globaloperations$Wait - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the Operations resource to return. - */ - operation?: string; - /** - * Project ID for this request. - */ - project?: string; - } - - export class Resource$Globalorganizationoperations { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.globalOrganizationOperations.delete - * @desc Deletes the specified Operations resource. - * @alias compute.globalOrganizationOperations.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.operation Name of the Operations resource to delete. - * @param {string=} params.parentId Parent ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Globalorganizationoperations$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Globalorganizationoperations$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Globalorganizationoperations$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Globalorganizationoperations$Delete - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalorganizationoperations$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalorganizationoperations$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/operations/{operation}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['operation'], - pathParams: ['operation'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalOrganizationOperations.get - * @desc Retrieves the specified Operations resource. Gets a list of operations by making a list() request. - * @alias compute.globalOrganizationOperations.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.operation Name of the Operations resource to return. - * @param {string=} params.parentId Parent ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Globalorganizationoperations$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Globalorganizationoperations$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Globalorganizationoperations$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Globalorganizationoperations$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalorganizationoperations$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalorganizationoperations$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/operations/{operation}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['operation'], - pathParams: ['operation'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalOrganizationOperations.list - * @desc Retrieves a list of Operation resources contained within the specified organization. - * @alias compute.globalOrganizationOperations.list - * @memberOf! () - * - * @param {object=} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string=} params.parentId Parent ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Globalorganizationoperations$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Globalorganizationoperations$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Globalorganizationoperations$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Globalorganizationoperations$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalorganizationoperations$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalorganizationoperations$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/locations/global/operations' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: [], - pathParams: [], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.globalOrganizationOperations.wait - * @desc Waits for the specified Operations resource until it is done or timeout, and retrieves the specified Operations resource. 1. Immediately returns when the operation is already done. 2. Waits for no more than the default deadline (2 minutes, subject to change) and then returns the current state of the operation, which may be DONE or still in progress. 3. Is best-effort: a. The server can wait less than the default deadline or zero seconds, in overload situations. b. There is no guarantee that the operation is actually done when returns. 4. User should be prepared to retry if the operation is not DONE. - * @alias compute.globalOrganizationOperations.wait - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.operation Name of the Operations resource to return. - * @param {string=} params.parentId Parent ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - wait( - params?: Params$Resource$Globalorganizationoperations$Wait, - options?: MethodOptions - ): GaxiosPromise; - wait( - params: Params$Resource$Globalorganizationoperations$Wait, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - wait( - params: Params$Resource$Globalorganizationoperations$Wait, - callback: BodyResponseCallback - ): void; - wait(callback: BodyResponseCallback): void; - wait( - paramsOrCallback?: - | Params$Resource$Globalorganizationoperations$Wait - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Globalorganizationoperations$Wait; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Globalorganizationoperations$Wait; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/operations/{operation}/wait' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['operation'], - pathParams: ['operation'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Globalorganizationoperations$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the Operations resource to delete. - */ - operation?: string; - /** - * Parent ID for this request. - */ - parentId?: string; - } - export interface Params$Resource$Globalorganizationoperations$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the Operations resource to return. - */ - operation?: string; - /** - * Parent ID for this request. - */ - parentId?: string; - } - export interface Params$Resource$Globalorganizationoperations$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Parent ID for this request. - */ - parentId?: string; - } - export interface Params$Resource$Globalorganizationoperations$Wait - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the Operations resource to return. - */ - operation?: string; - /** - * Parent ID for this request. - */ - parentId?: string; - } - - export class Resource$Healthchecks { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.healthChecks.aggregatedList - * @desc Retrieves the list of all HealthCheck resources, regional and global, available to the specified project. - * @alias compute.healthChecks.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Name of the project scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Healthchecks$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Healthchecks$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Healthchecks$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Healthchecks$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Healthchecks$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Healthchecks$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/healthChecks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.healthChecks.delete - * @desc Deletes the specified HealthCheck resource. - * @alias compute.healthChecks.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.healthCheck Name of the HealthCheck resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Healthchecks$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Healthchecks$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Healthchecks$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Healthchecks$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Healthchecks$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Healthchecks$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/healthChecks/{healthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'healthCheck'], - pathParams: ['healthCheck', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.healthChecks.get - * @desc Returns the specified HealthCheck resource. Gets a list of available health checks by making a list() request. - * @alias compute.healthChecks.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.healthCheck Name of the HealthCheck resource to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Healthchecks$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Healthchecks$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Healthchecks$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Healthchecks$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Healthchecks$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Healthchecks$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/healthChecks/{healthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'healthCheck'], - pathParams: ['healthCheck', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.healthChecks.insert - * @desc Creates a HealthCheck resource in the specified project using the data included in the request. - * @alias compute.healthChecks.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HealthCheck} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Healthchecks$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Healthchecks$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Healthchecks$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Healthchecks$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Healthchecks$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Healthchecks$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/healthChecks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.healthChecks.list - * @desc Retrieves the list of HealthCheck resources available to the specified project. - * @alias compute.healthChecks.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Healthchecks$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Healthchecks$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Healthchecks$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Healthchecks$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Healthchecks$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Healthchecks$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/healthChecks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.healthChecks.patch - * @desc Updates a HealthCheck resource in the specified project using the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.healthChecks.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.healthCheck Name of the HealthCheck resource to patch. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HealthCheck} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Healthchecks$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Healthchecks$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Healthchecks$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Healthchecks$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Healthchecks$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Healthchecks$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/healthChecks/{healthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'healthCheck'], - pathParams: ['healthCheck', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.healthChecks.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.healthChecks.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Healthchecks$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Healthchecks$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Healthchecks$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Healthchecks$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Healthchecks$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Healthchecks$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/healthChecks/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.healthChecks.update - * @desc Updates a HealthCheck resource in the specified project using the data included in the request. - * @alias compute.healthChecks.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.healthCheck Name of the HealthCheck resource to update. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HealthCheck} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Healthchecks$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Healthchecks$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Healthchecks$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Healthchecks$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Healthchecks$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Healthchecks$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/healthChecks/{healthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'healthCheck'], - pathParams: ['healthCheck', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Healthchecks$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Name of the project scoping this request. - */ - project?: string; - } - export interface Params$Resource$Healthchecks$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HealthCheck resource to delete. - */ - healthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Healthchecks$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HealthCheck resource to return. - */ - healthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Healthchecks$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HealthCheck; - } - export interface Params$Resource$Healthchecks$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Healthchecks$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HealthCheck resource to patch. - */ - healthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HealthCheck; - } - export interface Params$Resource$Healthchecks$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Healthchecks$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HealthCheck resource to update. - */ - healthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HealthCheck; - } - - export class Resource$Httphealthchecks { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.httpHealthChecks.delete - * @desc Deletes the specified HttpHealthCheck resource. - * @alias compute.httpHealthChecks.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.httpHealthCheck Name of the HttpHealthCheck resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Httphealthchecks$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Httphealthchecks$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Httphealthchecks$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Httphealthchecks$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httphealthchecks$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httphealthchecks$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpHealthChecks/{httpHealthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'httpHealthCheck'], - pathParams: ['httpHealthCheck', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.httpHealthChecks.get - * @desc Returns the specified HttpHealthCheck resource. Gets a list of available HTTP health checks by making a list() request. - * @alias compute.httpHealthChecks.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.httpHealthCheck Name of the HttpHealthCheck resource to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Httphealthchecks$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Httphealthchecks$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Httphealthchecks$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Httphealthchecks$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httphealthchecks$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httphealthchecks$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpHealthChecks/{httpHealthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'httpHealthCheck'], - pathParams: ['httpHealthCheck', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.httpHealthChecks.insert - * @desc Creates a HttpHealthCheck resource in the specified project using the data included in the request. - * @alias compute.httpHealthChecks.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HttpHealthCheck} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Httphealthchecks$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Httphealthchecks$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Httphealthchecks$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Httphealthchecks$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httphealthchecks$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httphealthchecks$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpHealthChecks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.httpHealthChecks.list - * @desc Retrieves the list of HttpHealthCheck resources available to the specified project. - * @alias compute.httpHealthChecks.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Httphealthchecks$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Httphealthchecks$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Httphealthchecks$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Httphealthchecks$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httphealthchecks$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httphealthchecks$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpHealthChecks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.httpHealthChecks.patch - * @desc Updates a HttpHealthCheck resource in the specified project using the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.httpHealthChecks.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.httpHealthCheck Name of the HttpHealthCheck resource to patch. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HttpHealthCheck} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Httphealthchecks$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Httphealthchecks$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Httphealthchecks$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Httphealthchecks$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httphealthchecks$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httphealthchecks$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpHealthChecks/{httpHealthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'httpHealthCheck'], - pathParams: ['httpHealthCheck', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.httpHealthChecks.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.httpHealthChecks.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Httphealthchecks$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Httphealthchecks$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Httphealthchecks$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Httphealthchecks$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httphealthchecks$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httphealthchecks$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpHealthChecks/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.httpHealthChecks.update - * @desc Updates a HttpHealthCheck resource in the specified project using the data included in the request. - * @alias compute.httpHealthChecks.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.httpHealthCheck Name of the HttpHealthCheck resource to update. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HttpHealthCheck} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Httphealthchecks$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Httphealthchecks$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Httphealthchecks$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Httphealthchecks$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httphealthchecks$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httphealthchecks$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpHealthChecks/{httpHealthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'httpHealthCheck'], - pathParams: ['httpHealthCheck', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Httphealthchecks$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HttpHealthCheck resource to delete. - */ - httpHealthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Httphealthchecks$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HttpHealthCheck resource to return. - */ - httpHealthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Httphealthchecks$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HttpHealthCheck; - } - export interface Params$Resource$Httphealthchecks$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Httphealthchecks$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HttpHealthCheck resource to patch. - */ - httpHealthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HttpHealthCheck; - } - export interface Params$Resource$Httphealthchecks$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Httphealthchecks$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HttpHealthCheck resource to update. - */ - httpHealthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HttpHealthCheck; - } - - export class Resource$Httpshealthchecks { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.httpsHealthChecks.delete - * @desc Deletes the specified HttpsHealthCheck resource. - * @alias compute.httpsHealthChecks.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.httpsHealthCheck Name of the HttpsHealthCheck resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Httpshealthchecks$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Httpshealthchecks$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Httpshealthchecks$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Httpshealthchecks$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httpshealthchecks$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httpshealthchecks$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpsHealthChecks/{httpsHealthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'httpsHealthCheck'], - pathParams: ['httpsHealthCheck', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.httpsHealthChecks.get - * @desc Returns the specified HttpsHealthCheck resource. Gets a list of available HTTPS health checks by making a list() request. - * @alias compute.httpsHealthChecks.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.httpsHealthCheck Name of the HttpsHealthCheck resource to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Httpshealthchecks$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Httpshealthchecks$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Httpshealthchecks$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Httpshealthchecks$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httpshealthchecks$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httpshealthchecks$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpsHealthChecks/{httpsHealthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'httpsHealthCheck'], - pathParams: ['httpsHealthCheck', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.httpsHealthChecks.insert - * @desc Creates a HttpsHealthCheck resource in the specified project using the data included in the request. - * @alias compute.httpsHealthChecks.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HttpsHealthCheck} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Httpshealthchecks$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Httpshealthchecks$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Httpshealthchecks$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Httpshealthchecks$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httpshealthchecks$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httpshealthchecks$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpsHealthChecks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.httpsHealthChecks.list - * @desc Retrieves the list of HttpsHealthCheck resources available to the specified project. - * @alias compute.httpsHealthChecks.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Httpshealthchecks$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Httpshealthchecks$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Httpshealthchecks$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Httpshealthchecks$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httpshealthchecks$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httpshealthchecks$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpsHealthChecks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.httpsHealthChecks.patch - * @desc Updates a HttpsHealthCheck resource in the specified project using the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.httpsHealthChecks.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.httpsHealthCheck Name of the HttpsHealthCheck resource to patch. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HttpsHealthCheck} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Httpshealthchecks$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Httpshealthchecks$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Httpshealthchecks$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Httpshealthchecks$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httpshealthchecks$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httpshealthchecks$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpsHealthChecks/{httpsHealthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'httpsHealthCheck'], - pathParams: ['httpsHealthCheck', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.httpsHealthChecks.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.httpsHealthChecks.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Httpshealthchecks$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Httpshealthchecks$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Httpshealthchecks$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Httpshealthchecks$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httpshealthchecks$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httpshealthchecks$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpsHealthChecks/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.httpsHealthChecks.update - * @desc Updates a HttpsHealthCheck resource in the specified project using the data included in the request. - * @alias compute.httpsHealthChecks.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.httpsHealthCheck Name of the HttpsHealthCheck resource to update. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HttpsHealthCheck} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Httpshealthchecks$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Httpshealthchecks$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Httpshealthchecks$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Httpshealthchecks$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Httpshealthchecks$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Httpshealthchecks$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/httpsHealthChecks/{httpsHealthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'httpsHealthCheck'], - pathParams: ['httpsHealthCheck', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Httpshealthchecks$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HttpsHealthCheck resource to delete. - */ - httpsHealthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Httpshealthchecks$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HttpsHealthCheck resource to return. - */ - httpsHealthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Httpshealthchecks$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HttpsHealthCheck; - } - export interface Params$Resource$Httpshealthchecks$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Httpshealthchecks$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HttpsHealthCheck resource to patch. - */ - httpsHealthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HttpsHealthCheck; - } - export interface Params$Resource$Httpshealthchecks$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Httpshealthchecks$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HttpsHealthCheck resource to update. - */ - httpsHealthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HttpsHealthCheck; - } - - export class Resource$Images { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.images.delete - * @desc Deletes the specified image. - * @alias compute.images.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.image Name of the image resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Images$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Images$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Images$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Images$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Images$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Images$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/images/{image}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'image'], - pathParams: ['image', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.images.deprecate - * @desc Sets the deprecation status of an image. If an empty request body is given, clears the deprecation status instead. - * @alias compute.images.deprecate - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.image Image name. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().DeprecationStatus} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - deprecate( - params?: Params$Resource$Images$Deprecate, - options?: MethodOptions - ): GaxiosPromise; - deprecate( - params: Params$Resource$Images$Deprecate, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - deprecate( - params: Params$Resource$Images$Deprecate, - callback: BodyResponseCallback - ): void; - deprecate(callback: BodyResponseCallback): void; - deprecate( - paramsOrCallback?: - | Params$Resource$Images$Deprecate - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Images$Deprecate; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Images$Deprecate; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/images/{image}/deprecate' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'image'], - pathParams: ['image', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.images.get - * @desc Returns the specified image. Gets a list of available images by making a list() request. - * @alias compute.images.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.image Name of the image resource to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Images$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Images$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Images$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Images$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Images$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Images$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/images/{image}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'image'], - pathParams: ['image', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.images.getFromFamily - * @desc Returns the latest image that is part of an image family and is not deprecated. - * @alias compute.images.getFromFamily - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.family Name of the image family to search for. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getFromFamily( - params?: Params$Resource$Images$Getfromfamily, - options?: MethodOptions - ): GaxiosPromise; - getFromFamily( - params: Params$Resource$Images$Getfromfamily, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getFromFamily( - params: Params$Resource$Images$Getfromfamily, - callback: BodyResponseCallback - ): void; - getFromFamily(callback: BodyResponseCallback): void; - getFromFamily( - paramsOrCallback?: - | Params$Resource$Images$Getfromfamily - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Images$Getfromfamily; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Images$Getfromfamily; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/images/family/{family}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'family'], - pathParams: ['family', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.images.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.images.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Images$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Images$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Images$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Images$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Images$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Images$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/images/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.images.insert - * @desc Creates an image in the specified project using the data included in the request. - * @alias compute.images.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {boolean=} params.forceCreate Force image creation if true. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Image} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Images$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Images$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Images$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Images$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Images$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Images$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/images' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.images.list - * @desc Retrieves the list of custom images available to the specified project. Custom images are images you create that belong to your project. This method does not get any images that belong to other projects, including publicly-available images, like Debian 8. If you want to get a list of publicly-available images, use this method to make a request to the respective image project, such as debian-cloud or windows-cloud. - * @alias compute.images.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Images$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Images$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Images$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Images$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Images$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Images$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/images' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.images.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.images.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Images$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Images$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Images$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Images$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Images$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Images$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/images/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.images.setLabels - * @desc Sets the labels on an image. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.images.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Images$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Images$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Images$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Images$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Images$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Images$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/images/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.images.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.images.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Images$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Images$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Images$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Images$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Images$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Images$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/images/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Images$Delete extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the image resource to delete. - */ - image?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Images$Deprecate extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Image name. - */ - image?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$DeprecationStatus; - } - export interface Params$Resource$Images$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the image resource to return. - */ - image?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Images$Getfromfamily - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the image family to search for. - */ - family?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Images$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Images$Insert extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Force image creation if true. - */ - forceCreate?: boolean; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Image; - } - export interface Params$Resource$Images$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Images$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetPolicyRequest; - } - export interface Params$Resource$Images$Setlabels extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetLabelsRequest; - } - export interface Params$Resource$Images$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Instancegroupmanagers { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.instanceGroupManagers.abandonInstances - * @desc Flags the specified instances to be removed from the managed instance group. Abandoning an instance does not delete the instance, but it does remove the instance from any target pools that are applied by the managed instance group. This method reduces the targetSize of the managed instance group by the number of instances that you abandon. This operation is marked as DONE when the action is scheduled even if the instances have not yet been removed from the group. You must separately verify the status of the abandoning action with the listmanagedinstances method. If the group is part of a backend service that has enabled connection draining, it can take up to 60 seconds after the connection draining duration has elapsed before the VM instance is removed or deleted. You can specify a maximum of 1000 instances with this method per request. - * @alias compute.instanceGroupManagers.abandonInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the managed instance group is located. - * @param {().InstanceGroupManagersAbandonInstancesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - abandonInstances( - params?: Params$Resource$Instancegroupmanagers$Abandoninstances, - options?: MethodOptions - ): GaxiosPromise; - abandonInstances( - params: Params$Resource$Instancegroupmanagers$Abandoninstances, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - abandonInstances( - params: Params$Resource$Instancegroupmanagers$Abandoninstances, - callback: BodyResponseCallback - ): void; - abandonInstances(callback: BodyResponseCallback): void; - abandonInstances( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Abandoninstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Abandoninstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Abandoninstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/abandonInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.aggregatedList - * @desc Retrieves the list of managed instance groups and groups them by zone. - * @alias compute.instanceGroupManagers.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Instancegroupmanagers$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Instancegroupmanagers$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Instancegroupmanagers$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/instanceGroupManagers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.instanceGroupManagers.applyUpdatesToInstances - * @desc Apply changes to selected instances on the managed instance group. This method can be used to apply new overrides and/or new versions. - * @alias compute.instanceGroupManagers.applyUpdatesToInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group, should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the managed instance group is located. Should conform to RFC1035. - * @param {().InstanceGroupManagersApplyUpdatesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - applyUpdatesToInstances( - params?: Params$Resource$Instancegroupmanagers$Applyupdatestoinstances, - options?: MethodOptions - ): GaxiosPromise; - applyUpdatesToInstances( - params: Params$Resource$Instancegroupmanagers$Applyupdatestoinstances, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - applyUpdatesToInstances( - params: Params$Resource$Instancegroupmanagers$Applyupdatestoinstances, - callback: BodyResponseCallback - ): void; - applyUpdatesToInstances( - callback: BodyResponseCallback - ): void; - applyUpdatesToInstances( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Applyupdatestoinstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Applyupdatestoinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Applyupdatestoinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/applyUpdatesToInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.createInstances - * @desc Creates instances with per-instance configs in this managed instance group. Instances are created using the current instance template. The create instances operation is marked DONE if the createInstances request is successful. The underlying actions take additional time. You must separately verify the status of the creating or actions with the listmanagedinstances method. - * @alias compute.instanceGroupManagers.createInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. It should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the managed instance group is located. It should conform to RFC1035. - * @param {().InstanceGroupManagersCreateInstancesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - createInstances( - params?: Params$Resource$Instancegroupmanagers$Createinstances, - options?: MethodOptions - ): GaxiosPromise; - createInstances( - params: Params$Resource$Instancegroupmanagers$Createinstances, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - createInstances( - params: Params$Resource$Instancegroupmanagers$Createinstances, - callback: BodyResponseCallback - ): void; - createInstances(callback: BodyResponseCallback): void; - createInstances( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Createinstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Createinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Createinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/createInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.delete - * @desc Deletes the specified managed instance group and all of the instances in that group. Note that the instance group must not belong to a backend service. Read Deleting an instance group for more information. - * @alias compute.instanceGroupManagers.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the managed instance group is located. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Instancegroupmanagers$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Instancegroupmanagers$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Instancegroupmanagers$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.deleteInstances - * @desc Flags the specified instances in the managed instance group for immediate deletion. The instances are also removed from any target pools of which they were a member. This method reduces the targetSize of the managed instance group by the number of instances that you delete. This operation is marked as DONE when the action is scheduled even if the instances are still being deleted. You must separately verify the status of the deleting action with the listmanagedinstances method. If the group is part of a backend service that has enabled connection draining, it can take up to 60 seconds after the connection draining duration has elapsed before the VM instance is removed or deleted. You can specify a maximum of 1000 instances with this method per request. - * @alias compute.instanceGroupManagers.deleteInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the managed instance group is located. - * @param {().InstanceGroupManagersDeleteInstancesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - deleteInstances( - params?: Params$Resource$Instancegroupmanagers$Deleteinstances, - options?: MethodOptions - ): GaxiosPromise; - deleteInstances( - params: Params$Resource$Instancegroupmanagers$Deleteinstances, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - deleteInstances( - params: Params$Resource$Instancegroupmanagers$Deleteinstances, - callback: BodyResponseCallback - ): void; - deleteInstances(callback: BodyResponseCallback): void; - deleteInstances( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Deleteinstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Deleteinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Deleteinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/deleteInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.deletePerInstanceConfigs - * @desc Deletes selected per-instance configs for the managed instance group. - * @alias compute.instanceGroupManagers.deletePerInstanceConfigs - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. It should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the managed instance group is located. It should conform to RFC1035. - * @param {().InstanceGroupManagersDeletePerInstanceConfigsReq} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - deletePerInstanceConfigs( - params?: Params$Resource$Instancegroupmanagers$Deleteperinstanceconfigs, - options?: MethodOptions - ): GaxiosPromise; - deletePerInstanceConfigs( - params: Params$Resource$Instancegroupmanagers$Deleteperinstanceconfigs, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - deletePerInstanceConfigs( - params: Params$Resource$Instancegroupmanagers$Deleteperinstanceconfigs, - callback: BodyResponseCallback - ): void; - deletePerInstanceConfigs( - callback: BodyResponseCallback - ): void; - deletePerInstanceConfigs( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Deleteperinstanceconfigs - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Deleteperinstanceconfigs; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Deleteperinstanceconfigs; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/deletePerInstanceConfigs' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.get - * @desc Returns all of the details about the specified managed instance group. Gets a list of available managed instance groups by making a list() request. - * @alias compute.instanceGroupManagers.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the managed instance group is located. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Instancegroupmanagers$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Instancegroupmanagers$Get, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Instancegroupmanagers$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.insert - * @desc Creates a managed instance group using the information that you specify in the request. After the group is created, instances in the group are created using the specified instance template. This operation is marked as DONE when the group is created even if the instances in the group have not yet been created. You must separately verify the status of the individual instances with the listmanagedinstances method. A managed instance group can have up to 1000 VM instances per group. Please contact Cloud Support if you need an increase in this limit. - * @alias compute.instanceGroupManagers.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where you want to create the managed instance group. - * @param {().InstanceGroupManager} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Instancegroupmanagers$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Instancegroupmanagers$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Instancegroupmanagers$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.list - * @desc Retrieves a list of managed instance groups that are contained within the specified project and zone. - * @alias compute.instanceGroupManagers.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the managed instance group is located. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Instancegroupmanagers$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Instancegroupmanagers$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Instancegroupmanagers$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.listErrors - * @desc Lists all errors thrown by actions on instances for a given managed instance group. - * @alias compute.instanceGroupManagers.listErrors - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {string} params.instanceGroupManager The name of the managed instance group. It must be a string that meets the requirements in RFC1035, or an unsigned long integer: must match regexp pattern: (?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?)|[1-9][0-9]{0,19}. - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the managed instance group is located. It should conform to RFC1035. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listErrors( - params?: Params$Resource$Instancegroupmanagers$Listerrors, - options?: MethodOptions - ): GaxiosPromise; - listErrors( - params: Params$Resource$Instancegroupmanagers$Listerrors, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback< - Schema$InstanceGroupManagersListErrorsResponse - > - ): void; - listErrors( - params: Params$Resource$Instancegroupmanagers$Listerrors, - callback: BodyResponseCallback< - Schema$InstanceGroupManagersListErrorsResponse - > - ): void; - listErrors( - callback: BodyResponseCallback< - Schema$InstanceGroupManagersListErrorsResponse - > - ): void; - listErrors( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Listerrors - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback< - Schema$InstanceGroupManagersListErrorsResponse - > - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Listerrors; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Listerrors; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/listErrors' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.instanceGroupManagers.listManagedInstances - * @desc Lists all of the instances in the managed instance group. Each instance in the list has a currentAction, which indicates the action that the managed instance group is performing on the instance. For example, if the group is still creating an instance, the currentAction is CREATING. If a previous action failed, the list displays the errors for that failed action. - * @alias compute.instanceGroupManagers.listManagedInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {string} params.instanceGroupManager The name of the managed instance group. - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.order_by Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the managed instance group is located. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listManagedInstances( - params?: Params$Resource$Instancegroupmanagers$Listmanagedinstances, - options?: MethodOptions - ): GaxiosPromise; - listManagedInstances( - params: Params$Resource$Instancegroupmanagers$Listmanagedinstances, - options: - | MethodOptions - | BodyResponseCallback< - Schema$InstanceGroupManagersListManagedInstancesResponse - >, - callback: BodyResponseCallback< - Schema$InstanceGroupManagersListManagedInstancesResponse - > - ): void; - listManagedInstances( - params: Params$Resource$Instancegroupmanagers$Listmanagedinstances, - callback: BodyResponseCallback< - Schema$InstanceGroupManagersListManagedInstancesResponse - > - ): void; - listManagedInstances( - callback: BodyResponseCallback< - Schema$InstanceGroupManagersListManagedInstancesResponse - > - ): void; - listManagedInstances( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Listmanagedinstances - | BodyResponseCallback< - Schema$InstanceGroupManagersListManagedInstancesResponse - >, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback< - Schema$InstanceGroupManagersListManagedInstancesResponse - >, - callback?: BodyResponseCallback< - Schema$InstanceGroupManagersListManagedInstancesResponse - > - ): void | GaxiosPromise< - Schema$InstanceGroupManagersListManagedInstancesResponse - > { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Listmanagedinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Listmanagedinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/listManagedInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest< - Schema$InstanceGroupManagersListManagedInstancesResponse - >(parameters, callback); - } else { - return createAPIRequest< - Schema$InstanceGroupManagersListManagedInstancesResponse - >(parameters); - } - } - - /** - * compute.instanceGroupManagers.listPerInstanceConfigs - * @desc Lists all of the per-instance configs defined for the managed instance group. - * @alias compute.instanceGroupManagers.listPerInstanceConfigs - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {string} params.instanceGroupManager The name of the managed instance group. It should conform to RFC1035. - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the managed instance group is located. It should conform to RFC1035. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listPerInstanceConfigs( - params?: Params$Resource$Instancegroupmanagers$Listperinstanceconfigs, - options?: MethodOptions - ): GaxiosPromise; - listPerInstanceConfigs( - params: Params$Resource$Instancegroupmanagers$Listperinstanceconfigs, - options: - | MethodOptions - | BodyResponseCallback< - Schema$InstanceGroupManagersListPerInstanceConfigsResp - >, - callback: BodyResponseCallback< - Schema$InstanceGroupManagersListPerInstanceConfigsResp - > - ): void; - listPerInstanceConfigs( - params: Params$Resource$Instancegroupmanagers$Listperinstanceconfigs, - callback: BodyResponseCallback< - Schema$InstanceGroupManagersListPerInstanceConfigsResp - > - ): void; - listPerInstanceConfigs( - callback: BodyResponseCallback< - Schema$InstanceGroupManagersListPerInstanceConfigsResp - > - ): void; - listPerInstanceConfigs( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Listperinstanceconfigs - | BodyResponseCallback< - Schema$InstanceGroupManagersListPerInstanceConfigsResp - >, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback< - Schema$InstanceGroupManagersListPerInstanceConfigsResp - >, - callback?: BodyResponseCallback< - Schema$InstanceGroupManagersListPerInstanceConfigsResp - > - ): void | GaxiosPromise< - Schema$InstanceGroupManagersListPerInstanceConfigsResp - > { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Listperinstanceconfigs; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Listperinstanceconfigs; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/listPerInstanceConfigs' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest< - Schema$InstanceGroupManagersListPerInstanceConfigsResp - >(parameters, callback); - } else { - return createAPIRequest< - Schema$InstanceGroupManagersListPerInstanceConfigsResp - >(parameters); - } - } - - /** - * compute.instanceGroupManagers.patch - * @desc Updates a managed instance group using the information that you specify in the request. This operation is marked as DONE when the group is patched even if the instances in the group are still in the process of being patched. You must separately verify the status of the individual instances with the listManagedInstances method. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.instanceGroupManagers.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the instance group manager. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where you want to create the managed instance group. - * @param {().InstanceGroupManager} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Instancegroupmanagers$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Instancegroupmanagers$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Instancegroupmanagers$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.patchPerInstanceConfigs - * @desc Insert or patch (for the ones that already exist) per-instance configs for the managed instance group. perInstanceConfig.instance serves as a key used to distinguish whether to perform insert or patch. - * @alias compute.instanceGroupManagers.patchPerInstanceConfigs - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. It should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the managed instance group is located. It should conform to RFC1035. - * @param {().InstanceGroupManagersPatchPerInstanceConfigsReq} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patchPerInstanceConfigs( - params?: Params$Resource$Instancegroupmanagers$Patchperinstanceconfigs, - options?: MethodOptions - ): GaxiosPromise; - patchPerInstanceConfigs( - params: Params$Resource$Instancegroupmanagers$Patchperinstanceconfigs, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patchPerInstanceConfigs( - params: Params$Resource$Instancegroupmanagers$Patchperinstanceconfigs, - callback: BodyResponseCallback - ): void; - patchPerInstanceConfigs( - callback: BodyResponseCallback - ): void; - patchPerInstanceConfigs( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Patchperinstanceconfigs - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Patchperinstanceconfigs; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Patchperinstanceconfigs; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/patchPerInstanceConfigs' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.recreateInstances - * @desc Flags the specified instances in the managed instance group to be immediately recreated. The instances are deleted and recreated using the current instance template for the managed instance group. This operation is marked as DONE when the flag is set even if the instances have not yet been recreated. You must separately verify the status of the recreating action with the listmanagedinstances method. If the group is part of a backend service that has enabled connection draining, it can take up to 60 seconds after the connection draining duration has elapsed before the VM instance is removed or deleted. You can specify a maximum of 1000 instances with this method per request. - * @alias compute.instanceGroupManagers.recreateInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the managed instance group is located. - * @param {().InstanceGroupManagersRecreateInstancesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - recreateInstances( - params?: Params$Resource$Instancegroupmanagers$Recreateinstances, - options?: MethodOptions - ): GaxiosPromise; - recreateInstances( - params: Params$Resource$Instancegroupmanagers$Recreateinstances, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - recreateInstances( - params: Params$Resource$Instancegroupmanagers$Recreateinstances, - callback: BodyResponseCallback - ): void; - recreateInstances(callback: BodyResponseCallback): void; - recreateInstances( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Recreateinstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Recreateinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Recreateinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/recreateInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.resize - * @desc Resizes the managed instance group. If you increase the size, the group creates new instances using the current instance template. If you decrease the size, the group deletes instances. The resize operation is marked DONE when the resize actions are scheduled even if the group has not yet added or deleted any instances. You must separately verify the status of the creating or deleting actions with the listmanagedinstances method. When resizing down, the instance group arbitrarily chooses the order in which VMs are deleted. The group takes into account some VM attributes when making the selection including: + The status of the VM instance. + The health of the VM instance. + The instance template version the VM is based on. + For regional managed instance groups, the location of the VM instance. This list is subject to change. If the group is part of a backend service that has enabled connection draining, it can take up to 60 seconds after the connection draining duration has elapsed before the VM instance is removed or deleted. - * @alias compute.instanceGroupManagers.resize - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {integer} params.size The number of running instances that the managed instance group should maintain at any given time. The group automatically adds or removes instances to maintain the number of instances specified by this parameter. - * @param {string} params.zone The name of the zone where the managed instance group is located. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - resize( - params?: Params$Resource$Instancegroupmanagers$Resize, - options?: MethodOptions - ): GaxiosPromise; - resize( - params: Params$Resource$Instancegroupmanagers$Resize, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - resize( - params: Params$Resource$Instancegroupmanagers$Resize, - callback: BodyResponseCallback - ): void; - resize(callback: BodyResponseCallback): void; - resize( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Resize - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Resize; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Resize; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/resize' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager', 'size'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.resizeAdvanced - * @desc Resizes the managed instance group with advanced configuration options like disabling creation retries. This is an extended version of the resize method. If you increase the size of the instance group, the group creates new instances using the current instance template. If you decrease the size, the group deletes instances. The resize operation is marked DONE when the resize actions are scheduled even if the group has not yet added or deleted any instances. You must separately verify the status of the creating, creatingWithoutRetries, or deleting actions with the get or listmanagedinstances method. If the group is part of a backend service that has enabled connection draining, it can take up to 60 seconds after the connection draining duration has elapsed before the VM instance is removed or deleted. - * @alias compute.instanceGroupManagers.resizeAdvanced - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the managed instance group is located. - * @param {().InstanceGroupManagersResizeAdvancedRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - resizeAdvanced( - params?: Params$Resource$Instancegroupmanagers$Resizeadvanced, - options?: MethodOptions - ): GaxiosPromise; - resizeAdvanced( - params: Params$Resource$Instancegroupmanagers$Resizeadvanced, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - resizeAdvanced( - params: Params$Resource$Instancegroupmanagers$Resizeadvanced, - callback: BodyResponseCallback - ): void; - resizeAdvanced(callback: BodyResponseCallback): void; - resizeAdvanced( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Resizeadvanced - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Resizeadvanced; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Resizeadvanced; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/resizeAdvanced' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.setAutoHealingPolicies - * @desc Modifies the autohealing policies. [Deprecated] This method is deprecated. Please use Patch instead. - * @alias compute.instanceGroupManagers.setAutoHealingPolicies - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the instance group manager. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the managed instance group is located. - * @param {().InstanceGroupManagersSetAutoHealingRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setAutoHealingPolicies( - params?: Params$Resource$Instancegroupmanagers$Setautohealingpolicies, - options?: MethodOptions - ): GaxiosPromise; - setAutoHealingPolicies( - params: Params$Resource$Instancegroupmanagers$Setautohealingpolicies, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setAutoHealingPolicies( - params: Params$Resource$Instancegroupmanagers$Setautohealingpolicies, - callback: BodyResponseCallback - ): void; - setAutoHealingPolicies( - callback: BodyResponseCallback - ): void; - setAutoHealingPolicies( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Setautohealingpolicies - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Setautohealingpolicies; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Setautohealingpolicies; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/setAutoHealingPolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.setInstanceTemplate - * @desc Specifies the instance template to use when creating new instances in this group. The templates for existing instances in the group do not change unless you recreate them. - * @alias compute.instanceGroupManagers.setInstanceTemplate - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the managed instance group is located. - * @param {().InstanceGroupManagersSetInstanceTemplateRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setInstanceTemplate( - params?: Params$Resource$Instancegroupmanagers$Setinstancetemplate, - options?: MethodOptions - ): GaxiosPromise; - setInstanceTemplate( - params: Params$Resource$Instancegroupmanagers$Setinstancetemplate, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setInstanceTemplate( - params: Params$Resource$Instancegroupmanagers$Setinstancetemplate, - callback: BodyResponseCallback - ): void; - setInstanceTemplate(callback: BodyResponseCallback): void; - setInstanceTemplate( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Setinstancetemplate - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Setinstancetemplate; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Setinstancetemplate; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/setInstanceTemplate' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.setTargetPools - * @desc Modifies the target pools to which all instances in this managed instance group are assigned. The target pools automatically apply to all of the instances in the managed instance group. This operation is marked DONE when you make the request even if the instances have not yet been added to their target pools. The change might take some time to apply to all of the instances in the group depending on the size of the group. - * @alias compute.instanceGroupManagers.setTargetPools - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the managed instance group is located. - * @param {().InstanceGroupManagersSetTargetPoolsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setTargetPools( - params?: Params$Resource$Instancegroupmanagers$Settargetpools, - options?: MethodOptions - ): GaxiosPromise; - setTargetPools( - params: Params$Resource$Instancegroupmanagers$Settargetpools, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setTargetPools( - params: Params$Resource$Instancegroupmanagers$Settargetpools, - callback: BodyResponseCallback - ): void; - setTargetPools(callback: BodyResponseCallback): void; - setTargetPools( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Settargetpools - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Settargetpools; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Settargetpools; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/setTargetPools' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.instanceGroupManagers.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Instancegroupmanagers$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Instancegroupmanagers$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Instancegroupmanagers$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.update - * @desc Updates a managed instance group using the information that you specify in the request. This operation is marked as DONE when the group is updated even if the instances in the group have not yet been updated. You must separately verify the status of the individual instances with the listManagedInstances method. - * @alias compute.instanceGroupManagers.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the instance group manager. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where you want to create the managed instance group. - * @param {().InstanceGroupManager} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Instancegroupmanagers$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Instancegroupmanagers$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Instancegroupmanagers$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroupManagers.updatePerInstanceConfigs - * @desc Insert or update (for the ones that already exist) per-instance configs for the managed instance group. perInstanceConfig.instance serves as a key used to distinguish whether to perform insert or patch. - * @alias compute.instanceGroupManagers.updatePerInstanceConfigs - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. It should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the managed instance group is located. It should conform to RFC1035. - * @param {().InstanceGroupManagersUpdatePerInstanceConfigsReq} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - updatePerInstanceConfigs( - params?: Params$Resource$Instancegroupmanagers$Updateperinstanceconfigs, - options?: MethodOptions - ): GaxiosPromise; - updatePerInstanceConfigs( - params: Params$Resource$Instancegroupmanagers$Updateperinstanceconfigs, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - updatePerInstanceConfigs( - params: Params$Resource$Instancegroupmanagers$Updateperinstanceconfigs, - callback: BodyResponseCallback - ): void; - updatePerInstanceConfigs( - callback: BodyResponseCallback - ): void; - updatePerInstanceConfigs( - paramsOrCallback?: - | Params$Resource$Instancegroupmanagers$Updateperinstanceconfigs - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroupmanagers$Updateperinstanceconfigs; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroupmanagers$Updateperinstanceconfigs; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroupManagers/{instanceGroupManager}/updatePerInstanceConfigs' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Instancegroupmanagers$Abandoninstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the managed instance group is located. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManagersAbandonInstancesRequest; - } - export interface Params$Resource$Instancegroupmanagers$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Instancegroupmanagers$Applyupdatestoinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group, should conform to RFC1035. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the managed instance group is located. Should conform to RFC1035. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManagersApplyUpdatesRequest; - } - export interface Params$Resource$Instancegroupmanagers$Createinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. It should conform to RFC1035. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the managed instance group is located. It should conform to RFC1035. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManagersCreateInstancesRequest; - } - export interface Params$Resource$Instancegroupmanagers$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group to delete. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the managed instance group is located. - */ - zone?: string; - } - export interface Params$Resource$Instancegroupmanagers$Deleteinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the managed instance group is located. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManagersDeleteInstancesRequest; - } - export interface Params$Resource$Instancegroupmanagers$Deleteperinstanceconfigs - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. It should conform to RFC1035. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the managed instance group is located. It should conform to RFC1035. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManagersDeletePerInstanceConfigsReq; - } - export interface Params$Resource$Instancegroupmanagers$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the managed instance group is located. - */ - zone?: string; - } - export interface Params$Resource$Instancegroupmanagers$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where you want to create the managed instance group. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManager; - } - export interface Params$Resource$Instancegroupmanagers$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the managed instance group is located. - */ - zone?: string; - } - export interface Params$Resource$Instancegroupmanagers$Listerrors - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The name of the managed instance group. It must be a string that meets the requirements in RFC1035, or an unsigned long integer: must match regexp pattern: (?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?)|[1-9][0-9]{0,19}. - */ - instanceGroupManager?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the managed instance group is located. It should conform to RFC1035. - */ - zone?: string; - } - export interface Params$Resource$Instancegroupmanagers$Listmanagedinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - order_by?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the managed instance group is located. - */ - zone?: string; - } - export interface Params$Resource$Instancegroupmanagers$Listperinstanceconfigs - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The name of the managed instance group. It should conform to RFC1035. - */ - instanceGroupManager?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the managed instance group is located. It should conform to RFC1035. - */ - zone?: string; - } - export interface Params$Resource$Instancegroupmanagers$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the instance group manager. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where you want to create the managed instance group. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManager; - } - export interface Params$Resource$Instancegroupmanagers$Patchperinstanceconfigs - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. It should conform to RFC1035. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the managed instance group is located. It should conform to RFC1035. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManagersPatchPerInstanceConfigsReq; - } - export interface Params$Resource$Instancegroupmanagers$Recreateinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the managed instance group is located. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManagersRecreateInstancesRequest; - } - export interface Params$Resource$Instancegroupmanagers$Resize - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The number of running instances that the managed instance group should maintain at any given time. The group automatically adds or removes instances to maintain the number of instances specified by this parameter. - */ - size?: number; - /** - * The name of the zone where the managed instance group is located. - */ - zone?: string; - } - export interface Params$Resource$Instancegroupmanagers$Resizeadvanced - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the managed instance group is located. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManagersResizeAdvancedRequest; - } - export interface Params$Resource$Instancegroupmanagers$Setautohealingpolicies - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the instance group manager. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the managed instance group is located. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManagersSetAutoHealingRequest; - } - export interface Params$Resource$Instancegroupmanagers$Setinstancetemplate - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the managed instance group is located. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManagersSetInstanceTemplateRequest; - } - export interface Params$Resource$Instancegroupmanagers$Settargetpools - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the managed instance group is located. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManagersSetTargetPoolsRequest; - } - export interface Params$Resource$Instancegroupmanagers$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Instancegroupmanagers$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the instance group manager. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where you want to create the managed instance group. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManager; - } - export interface Params$Resource$Instancegroupmanagers$Updateperinstanceconfigs - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. It should conform to RFC1035. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the managed instance group is located. It should conform to RFC1035. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManagersUpdatePerInstanceConfigsReq; - } - - export class Resource$Instancegroups { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.instanceGroups.addInstances - * @desc Adds a list of instances to the specified instance group. All of the instances in the instance group must be in the same network/subnetwork. Read Adding instances for more information. - * @alias compute.instanceGroups.addInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroup The name of the instance group where you are adding instances. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the instance group is located. - * @param {().InstanceGroupsAddInstancesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addInstances( - params?: Params$Resource$Instancegroups$Addinstances, - options?: MethodOptions - ): GaxiosPromise; - addInstances( - params: Params$Resource$Instancegroups$Addinstances, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addInstances( - params: Params$Resource$Instancegroups$Addinstances, - callback: BodyResponseCallback - ): void; - addInstances(callback: BodyResponseCallback): void; - addInstances( - paramsOrCallback?: - | Params$Resource$Instancegroups$Addinstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroups$Addinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroups$Addinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroups/{instanceGroup}/addInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroup'], - pathParams: ['instanceGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroups.aggregatedList - * @desc Retrieves the list of instance groups and sorts them by zone. - * @alias compute.instanceGroups.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Instancegroups$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Instancegroups$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Instancegroups$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Instancegroups$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroups$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroups$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/instanceGroups' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroups.delete - * @desc Deletes the specified instance group. The instances in the group are not deleted. Note that instance group must not belong to a backend service. Read Deleting an instance group for more information. - * @alias compute.instanceGroups.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroup The name of the instance group to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the instance group is located. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Instancegroups$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Instancegroups$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Instancegroups$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Instancegroups$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroups$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroups$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroups/{instanceGroup}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroup'], - pathParams: ['instanceGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroups.get - * @desc Returns the specified instance group. Gets a list of available instance groups by making a list() request. - * @alias compute.instanceGroups.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroup The name of the instance group. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the instance group is located. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Instancegroups$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Instancegroups$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Instancegroups$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Instancegroups$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroups$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroups$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroups/{instanceGroup}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroup'], - pathParams: ['instanceGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroups.insert - * @desc Creates an instance group in the specified project using the parameters that are included in the request. - * @alias compute.instanceGroups.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where you want to create the instance group. - * @param {().InstanceGroup} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Instancegroups$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Instancegroups$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Instancegroups$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Instancegroups$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroups$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroups$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroups' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroups.list - * @desc Retrieves the list of instance groups that are located in the specified project and zone. - * @alias compute.instanceGroups.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the instance group is located. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Instancegroups$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Instancegroups$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Instancegroups$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Instancegroups$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroups$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroups$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroups' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroups.listInstances - * @desc Lists the instances in the specified instance group. - * @alias compute.instanceGroups.listInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {string} params.instanceGroup The name of the instance group from which you want to generate a list of included instances. - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the instance group is located. - * @param {().InstanceGroupsListInstancesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listInstances( - params?: Params$Resource$Instancegroups$Listinstances, - options?: MethodOptions - ): GaxiosPromise; - listInstances( - params: Params$Resource$Instancegroups$Listinstances, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - listInstances( - params: Params$Resource$Instancegroups$Listinstances, - callback: BodyResponseCallback - ): void; - listInstances( - callback: BodyResponseCallback - ): void; - listInstances( - paramsOrCallback?: - | Params$Resource$Instancegroups$Listinstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroups$Listinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroups$Listinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroups/{instanceGroup}/listInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroup'], - pathParams: ['instanceGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroups.removeInstances - * @desc Removes one or more instances from the specified instance group, but does not delete those instances. If the group is part of a backend service that has enabled connection draining, it can take up to 60 seconds after the connection draining duration before the VM instance is removed or deleted. - * @alias compute.instanceGroups.removeInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroup The name of the instance group where the specified instances will be removed. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the instance group is located. - * @param {().InstanceGroupsRemoveInstancesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - removeInstances( - params?: Params$Resource$Instancegroups$Removeinstances, - options?: MethodOptions - ): GaxiosPromise; - removeInstances( - params: Params$Resource$Instancegroups$Removeinstances, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - removeInstances( - params: Params$Resource$Instancegroups$Removeinstances, - callback: BodyResponseCallback - ): void; - removeInstances(callback: BodyResponseCallback): void; - removeInstances( - paramsOrCallback?: - | Params$Resource$Instancegroups$Removeinstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroups$Removeinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroups$Removeinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroups/{instanceGroup}/removeInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroup'], - pathParams: ['instanceGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroups.setNamedPorts - * @desc Sets the named ports for the specified instance group. - * @alias compute.instanceGroups.setNamedPorts - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroup The name of the instance group where the named ports are updated. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the instance group is located. - * @param {().InstanceGroupsSetNamedPortsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setNamedPorts( - params?: Params$Resource$Instancegroups$Setnamedports, - options?: MethodOptions - ): GaxiosPromise; - setNamedPorts( - params: Params$Resource$Instancegroups$Setnamedports, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setNamedPorts( - params: Params$Resource$Instancegroups$Setnamedports, - callback: BodyResponseCallback - ): void; - setNamedPorts(callback: BodyResponseCallback): void; - setNamedPorts( - paramsOrCallback?: - | Params$Resource$Instancegroups$Setnamedports - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroups$Setnamedports; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroups$Setnamedports; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroups/{instanceGroup}/setNamedPorts' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instanceGroup'], - pathParams: ['instanceGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceGroups.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.instanceGroups.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Instancegroups$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Instancegroups$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Instancegroups$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Instancegroups$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancegroups$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancegroups$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instanceGroups/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Instancegroups$Addinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the instance group where you are adding instances. - */ - instanceGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the instance group is located. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupsAddInstancesRequest; - } - export interface Params$Resource$Instancegroups$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Instancegroups$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the instance group to delete. - */ - instanceGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the instance group is located. - */ - zone?: string; - } - export interface Params$Resource$Instancegroups$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the instance group. - */ - instanceGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the instance group is located. - */ - zone?: string; - } - export interface Params$Resource$Instancegroups$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where you want to create the instance group. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroup; - } - export interface Params$Resource$Instancegroups$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the instance group is located. - */ - zone?: string; - } - export interface Params$Resource$Instancegroups$Listinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The name of the instance group from which you want to generate a list of included instances. - */ - instanceGroup?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the instance group is located. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupsListInstancesRequest; - } - export interface Params$Resource$Instancegroups$Removeinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the instance group where the specified instances will be removed. - */ - instanceGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the instance group is located. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupsRemoveInstancesRequest; - } - export interface Params$Resource$Instancegroups$Setnamedports - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the instance group where the named ports are updated. - */ - instanceGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the instance group is located. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupsSetNamedPortsRequest; - } - export interface Params$Resource$Instancegroups$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Instances { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.instances.addAccessConfig - * @desc Adds an access config to an instance's network interface. - * @alias compute.instances.addAccessConfig - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance The instance name for this request. - * @param {string} params.networkInterface The name of the network interface to add to this instance. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().AccessConfig} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addAccessConfig( - params?: Params$Resource$Instances$Addaccessconfig, - options?: MethodOptions - ): GaxiosPromise; - addAccessConfig( - params: Params$Resource$Instances$Addaccessconfig, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addAccessConfig( - params: Params$Resource$Instances$Addaccessconfig, - callback: BodyResponseCallback - ): void; - addAccessConfig(callback: BodyResponseCallback): void; - addAccessConfig( - paramsOrCallback?: - | Params$Resource$Instances$Addaccessconfig - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Addaccessconfig; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Addaccessconfig; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/addAccessConfig' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance', 'networkInterface'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.addResourcePolicies - * @desc Adds existing resource policies to an instance. You can only add one policy right now which will be applied to this instance for scheduling live migrations. - * @alias compute.instances.addResourcePolicies - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance The instance name for this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().InstancesAddResourcePoliciesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addResourcePolicies( - params?: Params$Resource$Instances$Addresourcepolicies, - options?: MethodOptions - ): GaxiosPromise; - addResourcePolicies( - params: Params$Resource$Instances$Addresourcepolicies, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addResourcePolicies( - params: Params$Resource$Instances$Addresourcepolicies, - callback: BodyResponseCallback - ): void; - addResourcePolicies(callback: BodyResponseCallback): void; - addResourcePolicies( - paramsOrCallback?: - | Params$Resource$Instances$Addresourcepolicies - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Addresourcepolicies; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Addresourcepolicies; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/addResourcePolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.aggregatedList - * @desc Retrieves aggregated list of all of the instances in your project across all regions and zones. - * @alias compute.instances.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Instances$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Instances$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Instances$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Instances$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/aggregated/instances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.attachDisk - * @desc Attaches an existing Disk resource to an instance. You must first create the disk before you can attach it. It is not possible to create and attach a disk at the same time. For more information, read Adding a persistent disk to your instance. - * @alias compute.instances.attachDisk - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {boolean=} params.forceAttach Whether to force attach the disk even if it's currently attached to another instance. - * @param {string} params.instance The instance name for this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().AttachedDisk} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - attachDisk( - params?: Params$Resource$Instances$Attachdisk, - options?: MethodOptions - ): GaxiosPromise; - attachDisk( - params: Params$Resource$Instances$Attachdisk, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - attachDisk( - params: Params$Resource$Instances$Attachdisk, - callback: BodyResponseCallback - ): void; - attachDisk(callback: BodyResponseCallback): void; - attachDisk( - paramsOrCallback?: - | Params$Resource$Instances$Attachdisk - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Attachdisk; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Attachdisk; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/attachDisk' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.delete - * @desc Deletes the specified Instance resource. For more information, see Stopping or Deleting an Instance. - * @alias compute.instances.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Instances$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Instances$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Instances$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Instances$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Instances$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.deleteAccessConfig - * @desc Deletes an access config from an instance's network interface. - * @alias compute.instances.deleteAccessConfig - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.accessConfig The name of the access config to delete. - * @param {string} params.instance The instance name for this request. - * @param {string} params.networkInterface The name of the network interface. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - deleteAccessConfig( - params?: Params$Resource$Instances$Deleteaccessconfig, - options?: MethodOptions - ): GaxiosPromise; - deleteAccessConfig( - params: Params$Resource$Instances$Deleteaccessconfig, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - deleteAccessConfig( - params: Params$Resource$Instances$Deleteaccessconfig, - callback: BodyResponseCallback - ): void; - deleteAccessConfig(callback: BodyResponseCallback): void; - deleteAccessConfig( - paramsOrCallback?: - | Params$Resource$Instances$Deleteaccessconfig - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Deleteaccessconfig; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Deleteaccessconfig; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/deleteAccessConfig' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: [ - 'project', - 'zone', - 'instance', - 'accessConfig', - 'networkInterface', - ], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.detachDisk - * @desc Detaches a disk from an instance. - * @alias compute.instances.detachDisk - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.deviceName The device name of the disk to detach. Make a get() request on the instance to view currently attached disks and device names. - * @param {string} params.instance Instance name for this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - detachDisk( - params?: Params$Resource$Instances$Detachdisk, - options?: MethodOptions - ): GaxiosPromise; - detachDisk( - params: Params$Resource$Instances$Detachdisk, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - detachDisk( - params: Params$Resource$Instances$Detachdisk, - callback: BodyResponseCallback - ): void; - detachDisk(callback: BodyResponseCallback): void; - detachDisk( - paramsOrCallback?: - | Params$Resource$Instances$Detachdisk - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Detachdisk; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Detachdisk; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/detachDisk' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance', 'deviceName'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.get - * @desc Returns the specified Instance resource. Gets a list of available instances by making a list() request. - * @alias compute.instances.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance resource to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Instances$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Instances$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Instances$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Instances$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Instances$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.getEffectiveFirewalls - * @desc Returns effective firewalls applied to an interface of the instance. - * @alias compute.instances.getEffectiveFirewalls - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.networkInterface The name of the network interface to get the effective firewalls. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getEffectiveFirewalls( - params?: Params$Resource$Instances$Geteffectivefirewalls, - options?: MethodOptions - ): GaxiosPromise; - getEffectiveFirewalls( - params: Params$Resource$Instances$Geteffectivefirewalls, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback< - Schema$InstancesGetEffectiveFirewallsResponse - > - ): void; - getEffectiveFirewalls( - params: Params$Resource$Instances$Geteffectivefirewalls, - callback: BodyResponseCallback< - Schema$InstancesGetEffectiveFirewallsResponse - > - ): void; - getEffectiveFirewalls( - callback: BodyResponseCallback< - Schema$InstancesGetEffectiveFirewallsResponse - > - ): void; - getEffectiveFirewalls( - paramsOrCallback?: - | Params$Resource$Instances$Geteffectivefirewalls - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback< - Schema$InstancesGetEffectiveFirewallsResponse - > - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Geteffectivefirewalls; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Geteffectivefirewalls; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/getEffectiveFirewalls' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance', 'networkInterface'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.instances.getGuestAttributes - * @desc Returns the specified guest attributes entry. - * @alias compute.instances.getGuestAttributes - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.queryPath Specifies the guest attributes path to be queried. - * @param {string=} params.variableKey Specifies the key for the guest attributes entry. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getGuestAttributes( - params?: Params$Resource$Instances$Getguestattributes, - options?: MethodOptions - ): GaxiosPromise; - getGuestAttributes( - params: Params$Resource$Instances$Getguestattributes, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getGuestAttributes( - params: Params$Resource$Instances$Getguestattributes, - callback: BodyResponseCallback - ): void; - getGuestAttributes( - callback: BodyResponseCallback - ): void; - getGuestAttributes( - paramsOrCallback?: - | Params$Resource$Instances$Getguestattributes - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Getguestattributes; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Getguestattributes; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/getGuestAttributes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.instances.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Instances$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Instances$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Instances$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Instances$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.getSerialPortOutput - * @desc Returns the last 1 MB of serial port output from the specified instance. - * @alias compute.instances.getSerialPortOutput - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {integer=} params.port Specifies which COM or serial port to retrieve data from. - * @param {string} params.project Project ID for this request. - * @param {string=} params.start Returns output starting from a specific byte position. Use this to page through output when the output is too large to return in a single request. For the initial request, leave this field unspecified. For subsequent calls, this field should be set to the next value returned in the previous call. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getSerialPortOutput( - params?: Params$Resource$Instances$Getserialportoutput, - options?: MethodOptions - ): GaxiosPromise; - getSerialPortOutput( - params: Params$Resource$Instances$Getserialportoutput, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getSerialPortOutput( - params: Params$Resource$Instances$Getserialportoutput, - callback: BodyResponseCallback - ): void; - getSerialPortOutput( - callback: BodyResponseCallback - ): void; - getSerialPortOutput( - paramsOrCallback?: - | Params$Resource$Instances$Getserialportoutput - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Getserialportoutput; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Getserialportoutput; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/serialPort' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.getShieldedInstanceIdentity - * @desc Returns the Shielded Instance Identity of an instance - * @alias compute.instances.getShieldedInstanceIdentity - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name or id of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getShieldedInstanceIdentity( - params?: Params$Resource$Instances$Getshieldedinstanceidentity, - options?: MethodOptions - ): GaxiosPromise; - getShieldedInstanceIdentity( - params: Params$Resource$Instances$Getshieldedinstanceidentity, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getShieldedInstanceIdentity( - params: Params$Resource$Instances$Getshieldedinstanceidentity, - callback: BodyResponseCallback - ): void; - getShieldedInstanceIdentity( - callback: BodyResponseCallback - ): void; - getShieldedInstanceIdentity( - paramsOrCallback?: - | Params$Resource$Instances$Getshieldedinstanceidentity - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Getshieldedinstanceidentity; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Getshieldedinstanceidentity; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/getShieldedInstanceIdentity' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.getShieldedVmIdentity - * @desc Returns the Shielded VM Identity of an instance - * @alias compute.instances.getShieldedVmIdentity - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getShieldedVmIdentity( - params?: Params$Resource$Instances$Getshieldedvmidentity, - options?: MethodOptions - ): GaxiosPromise; - getShieldedVmIdentity( - params: Params$Resource$Instances$Getshieldedvmidentity, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getShieldedVmIdentity( - params: Params$Resource$Instances$Getshieldedvmidentity, - callback: BodyResponseCallback - ): void; - getShieldedVmIdentity( - callback: BodyResponseCallback - ): void; - getShieldedVmIdentity( - paramsOrCallback?: - | Params$Resource$Instances$Getshieldedvmidentity - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Getshieldedvmidentity; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Getshieldedvmidentity; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/getShieldedVmIdentity' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.insert - * @desc Creates an instance resource in the specified project using the data included in the request. - * @alias compute.instances.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string=} params.sourceInstanceTemplate Specifies instance template to create the instance. This field is optional. It can be a full or partial URL. For example, the following are all valid URLs to an instance template: - https://www.googleapis.com/compute/v1/projects/project/global/instanceTemplates/instanceTemplate - projects/project/global/instanceTemplates/instanceTemplate - global/instanceTemplates/instanceTemplate - * @param {string=} params.sourceMachineImage Specifies instance machine to create the instance. This field is optional. It can be a full or partial URL. For example, the following are all valid URLs to an instance template: - https://www.googleapis.com/compute/v1/projects/project/global/global/machineImages/machineImage - projects/project/global/global/machineImages/machineImage - global/machineImages/machineImage - * @param {string} params.zone The name of the zone for this request. - * @param {().Instance} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Instances$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Instances$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Instances$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Instances$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Instances$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.list - * @desc Retrieves the list of instances contained within the specified zone. - * @alias compute.instances.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Instances$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Instances$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Instances$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Instances$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Instances$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.listReferrers - * @desc Retrieves the list of referrers to instances contained within the specified zone. For more information, read Viewing Referrers to VM Instances. - * @alias compute.instances.listReferrers - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {string} params.instance Name of the target instance scoping this request, or '-' if the request should span over all instances in the container. - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listReferrers( - params?: Params$Resource$Instances$Listreferrers, - options?: MethodOptions - ): GaxiosPromise; - listReferrers( - params: Params$Resource$Instances$Listreferrers, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - listReferrers( - params: Params$Resource$Instances$Listreferrers, - callback: BodyResponseCallback - ): void; - listReferrers( - callback: BodyResponseCallback - ): void; - listReferrers( - paramsOrCallback?: - | Params$Resource$Instances$Listreferrers - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Listreferrers; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Listreferrers; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/referrers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.removeResourcePolicies - * @desc Removes resource policies from an instance. - * @alias compute.instances.removeResourcePolicies - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance The instance name for this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().InstancesRemoveResourcePoliciesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - removeResourcePolicies( - params?: Params$Resource$Instances$Removeresourcepolicies, - options?: MethodOptions - ): GaxiosPromise; - removeResourcePolicies( - params: Params$Resource$Instances$Removeresourcepolicies, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - removeResourcePolicies( - params: Params$Resource$Instances$Removeresourcepolicies, - callback: BodyResponseCallback - ): void; - removeResourcePolicies( - callback: BodyResponseCallback - ): void; - removeResourcePolicies( - paramsOrCallback?: - | Params$Resource$Instances$Removeresourcepolicies - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Removeresourcepolicies; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Removeresourcepolicies; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/removeResourcePolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.reset - * @desc Performs a reset on the instance. This is a hard reset the VM does not do a graceful shutdown. For more information, see Resetting an instance. - * @alias compute.instances.reset - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - reset( - params?: Params$Resource$Instances$Reset, - options?: MethodOptions - ): GaxiosPromise; - reset( - params: Params$Resource$Instances$Reset, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - reset( - params: Params$Resource$Instances$Reset, - callback: BodyResponseCallback - ): void; - reset(callback: BodyResponseCallback): void; - reset( - paramsOrCallback?: - | Params$Resource$Instances$Reset - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Instances$Reset; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Reset; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/reset' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.resume - * @desc Resumes an instance that was suspended using the instances().suspend method. - * @alias compute.instances.resume - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance resource to resume. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().InstancesResumeRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - resume( - params?: Params$Resource$Instances$Resume, - options?: MethodOptions - ): GaxiosPromise; - resume( - params: Params$Resource$Instances$Resume, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - resume( - params: Params$Resource$Instances$Resume, - callback: BodyResponseCallback - ): void; - resume(callback: BodyResponseCallback): void; - resume( - paramsOrCallback?: - | Params$Resource$Instances$Resume - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Instances$Resume; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Resume; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/resume' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setDeletionProtection - * @desc Sets deletion protection on the instance. - * @alias compute.instances.setDeletionProtection - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {boolean=} params.deletionProtection Whether the resource should be protected against deletion. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setDeletionProtection( - params?: Params$Resource$Instances$Setdeletionprotection, - options?: MethodOptions - ): GaxiosPromise; - setDeletionProtection( - params: Params$Resource$Instances$Setdeletionprotection, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setDeletionProtection( - params: Params$Resource$Instances$Setdeletionprotection, - callback: BodyResponseCallback - ): void; - setDeletionProtection( - callback: BodyResponseCallback - ): void; - setDeletionProtection( - paramsOrCallback?: - | Params$Resource$Instances$Setdeletionprotection - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setdeletionprotection; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setdeletionprotection; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{resource}/setDeletionProtection' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setDiskAutoDelete - * @desc Sets the auto-delete flag for a disk attached to an instance. - * @alias compute.instances.setDiskAutoDelete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {boolean} params.autoDelete Whether to auto-delete the disk when the instance is deleted. - * @param {string} params.deviceName The device name of the disk to modify. Make a get() request on the instance to view currently attached disks and device names. - * @param {string} params.instance The instance name for this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setDiskAutoDelete( - params?: Params$Resource$Instances$Setdiskautodelete, - options?: MethodOptions - ): GaxiosPromise; - setDiskAutoDelete( - params: Params$Resource$Instances$Setdiskautodelete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setDiskAutoDelete( - params: Params$Resource$Instances$Setdiskautodelete, - callback: BodyResponseCallback - ): void; - setDiskAutoDelete(callback: BodyResponseCallback): void; - setDiskAutoDelete( - paramsOrCallback?: - | Params$Resource$Instances$Setdiskautodelete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setdiskautodelete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setdiskautodelete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/setDiskAutoDelete' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: [ - 'project', - 'zone', - 'instance', - 'autoDelete', - 'deviceName', - ], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.instances.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().ZoneSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Instances$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Instances$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Instances$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Instances$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setLabels - * @desc Sets labels on an instance. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.instances.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().InstancesSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Instances$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Instances$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Instances$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Instances$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setMachineResources - * @desc Changes the number and/or type of accelerator for a stopped instance to the values specified in the request. - * @alias compute.instances.setMachineResources - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().InstancesSetMachineResourcesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setMachineResources( - params?: Params$Resource$Instances$Setmachineresources, - options?: MethodOptions - ): GaxiosPromise; - setMachineResources( - params: Params$Resource$Instances$Setmachineresources, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setMachineResources( - params: Params$Resource$Instances$Setmachineresources, - callback: BodyResponseCallback - ): void; - setMachineResources(callback: BodyResponseCallback): void; - setMachineResources( - paramsOrCallback?: - | Params$Resource$Instances$Setmachineresources - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setmachineresources; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setmachineresources; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/setMachineResources' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setMachineType - * @desc Changes the machine type for a stopped instance to the machine type specified in the request. - * @alias compute.instances.setMachineType - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().InstancesSetMachineTypeRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setMachineType( - params?: Params$Resource$Instances$Setmachinetype, - options?: MethodOptions - ): GaxiosPromise; - setMachineType( - params: Params$Resource$Instances$Setmachinetype, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setMachineType( - params: Params$Resource$Instances$Setmachinetype, - callback: BodyResponseCallback - ): void; - setMachineType(callback: BodyResponseCallback): void; - setMachineType( - paramsOrCallback?: - | Params$Resource$Instances$Setmachinetype - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setmachinetype; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setmachinetype; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/setMachineType' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setMetadata - * @desc Sets metadata for the specified instance to the data included in the request. - * @alias compute.instances.setMetadata - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().Metadata} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setMetadata( - params?: Params$Resource$Instances$Setmetadata, - options?: MethodOptions - ): GaxiosPromise; - setMetadata( - params: Params$Resource$Instances$Setmetadata, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setMetadata( - params: Params$Resource$Instances$Setmetadata, - callback: BodyResponseCallback - ): void; - setMetadata(callback: BodyResponseCallback): void; - setMetadata( - paramsOrCallback?: - | Params$Resource$Instances$Setmetadata - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setmetadata; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setmetadata; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/setMetadata' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setMinCpuPlatform - * @desc Changes the minimum CPU platform that this instance should use. This method can only be called on a stopped instance. For more information, read Specifying a Minimum CPU Platform. - * @alias compute.instances.setMinCpuPlatform - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().InstancesSetMinCpuPlatformRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setMinCpuPlatform( - params?: Params$Resource$Instances$Setmincpuplatform, - options?: MethodOptions - ): GaxiosPromise; - setMinCpuPlatform( - params: Params$Resource$Instances$Setmincpuplatform, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setMinCpuPlatform( - params: Params$Resource$Instances$Setmincpuplatform, - callback: BodyResponseCallback - ): void; - setMinCpuPlatform(callback: BodyResponseCallback): void; - setMinCpuPlatform( - paramsOrCallback?: - | Params$Resource$Instances$Setmincpuplatform - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setmincpuplatform; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setmincpuplatform; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/setMinCpuPlatform' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setName - * @desc Sets name of an instance. - * @alias compute.instances.setName - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance The instance name for this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().InstancesSetNameRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setName( - params?: Params$Resource$Instances$Setname, - options?: MethodOptions - ): GaxiosPromise; - setName( - params: Params$Resource$Instances$Setname, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setName( - params: Params$Resource$Instances$Setname, - callback: BodyResponseCallback - ): void; - setName(callback: BodyResponseCallback): void; - setName( - paramsOrCallback?: - | Params$Resource$Instances$Setname - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setname; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setname; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/setName' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setScheduling - * @desc Sets an instance's scheduling options. - * @alias compute.instances.setScheduling - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Instance name for this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().Scheduling} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setScheduling( - params?: Params$Resource$Instances$Setscheduling, - options?: MethodOptions - ): GaxiosPromise; - setScheduling( - params: Params$Resource$Instances$Setscheduling, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setScheduling( - params: Params$Resource$Instances$Setscheduling, - callback: BodyResponseCallback - ): void; - setScheduling(callback: BodyResponseCallback): void; - setScheduling( - paramsOrCallback?: - | Params$Resource$Instances$Setscheduling - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setscheduling; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setscheduling; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/setScheduling' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setServiceAccount - * @desc Sets the service account on the instance. For more information, read Changing the service account and access scopes for an instance. - * @alias compute.instances.setServiceAccount - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance resource to start. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().InstancesSetServiceAccountRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setServiceAccount( - params?: Params$Resource$Instances$Setserviceaccount, - options?: MethodOptions - ): GaxiosPromise; - setServiceAccount( - params: Params$Resource$Instances$Setserviceaccount, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setServiceAccount( - params: Params$Resource$Instances$Setserviceaccount, - callback: BodyResponseCallback - ): void; - setServiceAccount(callback: BodyResponseCallback): void; - setServiceAccount( - paramsOrCallback?: - | Params$Resource$Instances$Setserviceaccount - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setserviceaccount; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setserviceaccount; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/setServiceAccount' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setShieldedInstanceIntegrityPolicy - * @desc Sets the Shielded Instance integrity policy for an instance. You can only use this method on a running instance. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.instances.setShieldedInstanceIntegrityPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name or id of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().ShieldedInstanceIntegrityPolicy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setShieldedInstanceIntegrityPolicy( - params?: Params$Resource$Instances$Setshieldedinstanceintegritypolicy, - options?: MethodOptions - ): GaxiosPromise; - setShieldedInstanceIntegrityPolicy( - params: Params$Resource$Instances$Setshieldedinstanceintegritypolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setShieldedInstanceIntegrityPolicy( - params: Params$Resource$Instances$Setshieldedinstanceintegritypolicy, - callback: BodyResponseCallback - ): void; - setShieldedInstanceIntegrityPolicy( - callback: BodyResponseCallback - ): void; - setShieldedInstanceIntegrityPolicy( - paramsOrCallback?: - | Params$Resource$Instances$Setshieldedinstanceintegritypolicy - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setshieldedinstanceintegritypolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setshieldedinstanceintegritypolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/setShieldedInstanceIntegrityPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setShieldedVmIntegrityPolicy - * @desc Sets the Shielded VM integrity policy for a VM instance. You can only use this method on a running VM instance. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.instances.setShieldedVmIntegrityPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().ShieldedVmIntegrityPolicy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setShieldedVmIntegrityPolicy( - params?: Params$Resource$Instances$Setshieldedvmintegritypolicy, - options?: MethodOptions - ): GaxiosPromise; - setShieldedVmIntegrityPolicy( - params: Params$Resource$Instances$Setshieldedvmintegritypolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setShieldedVmIntegrityPolicy( - params: Params$Resource$Instances$Setshieldedvmintegritypolicy, - callback: BodyResponseCallback - ): void; - setShieldedVmIntegrityPolicy( - callback: BodyResponseCallback - ): void; - setShieldedVmIntegrityPolicy( - paramsOrCallback?: - | Params$Resource$Instances$Setshieldedvmintegritypolicy - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Setshieldedvmintegritypolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Setshieldedvmintegritypolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/setShieldedVmIntegrityPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.setTags - * @desc Sets network tags for the specified instance to the data included in the request. - * @alias compute.instances.setTags - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().Tags} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setTags( - params?: Params$Resource$Instances$Settags, - options?: MethodOptions - ): GaxiosPromise; - setTags( - params: Params$Resource$Instances$Settags, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setTags( - params: Params$Resource$Instances$Settags, - callback: BodyResponseCallback - ): void; - setTags(callback: BodyResponseCallback): void; - setTags( - paramsOrCallback?: - | Params$Resource$Instances$Settags - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Settags; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Settags; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/setTags' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.simulateMaintenanceEvent - * @desc Simulates a maintenance event on the instance. - * @alias compute.instances.simulateMaintenanceEvent - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - simulateMaintenanceEvent( - params?: Params$Resource$Instances$Simulatemaintenanceevent, - options?: MethodOptions - ): GaxiosPromise; - simulateMaintenanceEvent( - params: Params$Resource$Instances$Simulatemaintenanceevent, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - simulateMaintenanceEvent( - params: Params$Resource$Instances$Simulatemaintenanceevent, - callback: BodyResponseCallback - ): void; - simulateMaintenanceEvent( - callback: BodyResponseCallback - ): void; - simulateMaintenanceEvent( - paramsOrCallback?: - | Params$Resource$Instances$Simulatemaintenanceevent - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Simulatemaintenanceevent; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Simulatemaintenanceevent; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/simulateMaintenanceEvent' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.start - * @desc Starts an instance that was stopped using the instances().stop method. For more information, see Restart an instance. - * @alias compute.instances.start - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance resource to start. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - start( - params?: Params$Resource$Instances$Start, - options?: MethodOptions - ): GaxiosPromise; - start( - params: Params$Resource$Instances$Start, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - start( - params: Params$Resource$Instances$Start, - callback: BodyResponseCallback - ): void; - start(callback: BodyResponseCallback): void; - start( - paramsOrCallback?: - | Params$Resource$Instances$Start - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Instances$Start; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Start; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/start' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.startWithEncryptionKey - * @desc Starts an instance that was stopped using the instances().stop method. For more information, see Restart an instance. - * @alias compute.instances.startWithEncryptionKey - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance resource to start. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().InstancesStartWithEncryptionKeyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - startWithEncryptionKey( - params?: Params$Resource$Instances$Startwithencryptionkey, - options?: MethodOptions - ): GaxiosPromise; - startWithEncryptionKey( - params: Params$Resource$Instances$Startwithencryptionkey, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - startWithEncryptionKey( - params: Params$Resource$Instances$Startwithencryptionkey, - callback: BodyResponseCallback - ): void; - startWithEncryptionKey( - callback: BodyResponseCallback - ): void; - startWithEncryptionKey( - paramsOrCallback?: - | Params$Resource$Instances$Startwithencryptionkey - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Startwithencryptionkey; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Startwithencryptionkey; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/startWithEncryptionKey' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.stop - * @desc Stops a running instance, shutting it down cleanly, and allows you to restart the instance at a later time. Stopped instances do not incur VM usage charges while they are stopped. However, resources that the VM is using, such as persistent disks and static IP addresses, will continue to be charged until they are deleted. For more information, see Stopping an instance. - * @alias compute.instances.stop - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {boolean=} params.discardLocalSsd If true, discard the contents of any attached localSSD partitions. Default value is false (== preserve localSSD data). - * @param {string} params.instance Name of the instance resource to stop. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - stop( - params?: Params$Resource$Instances$Stop, - options?: MethodOptions - ): GaxiosPromise; - stop( - params: Params$Resource$Instances$Stop, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - stop( - params: Params$Resource$Instances$Stop, - callback: BodyResponseCallback - ): void; - stop(callback: BodyResponseCallback): void; - stop( - paramsOrCallback?: - | Params$Resource$Instances$Stop - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Instances$Stop; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Stop; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/stop' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.suspend - * @desc This method suspends a running instance, saving its state to persistent storage, and allows you to resume the instance at a later time. Suspended instances incur reduced per-minute, virtual machine usage charges while they are suspended. Any resources the virtual machine is using, such as persistent disks and static IP addresses, will continue to be charged until they are deleted. - * @alias compute.instances.suspend - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {boolean=} params.discardLocalSsd If true, discard the contents of any attached localSSD partitions. Default value is false (== preserve localSSD data). - * @param {string} params.instance Name of the instance resource to suspend. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - suspend( - params?: Params$Resource$Instances$Suspend, - options?: MethodOptions - ): GaxiosPromise; - suspend( - params: Params$Resource$Instances$Suspend, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - suspend( - params: Params$Resource$Instances$Suspend, - callback: BodyResponseCallback - ): void; - suspend(callback: BodyResponseCallback): void; - suspend( - paramsOrCallback?: - | Params$Resource$Instances$Suspend - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Suspend; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Suspend; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/suspend' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.instances.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Instances$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Instances$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Instances$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Instances$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.updateAccessConfig - * @desc Updates the specified access config from an instance's network interface with the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.instances.updateAccessConfig - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance The instance name for this request. - * @param {string} params.networkInterface The name of the network interface where the access config is attached. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().AccessConfig} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - updateAccessConfig( - params?: Params$Resource$Instances$Updateaccessconfig, - options?: MethodOptions - ): GaxiosPromise; - updateAccessConfig( - params: Params$Resource$Instances$Updateaccessconfig, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - updateAccessConfig( - params: Params$Resource$Instances$Updateaccessconfig, - callback: BodyResponseCallback - ): void; - updateAccessConfig(callback: BodyResponseCallback): void; - updateAccessConfig( - paramsOrCallback?: - | Params$Resource$Instances$Updateaccessconfig - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Updateaccessconfig; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Updateaccessconfig; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/updateAccessConfig' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance', 'networkInterface'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.updateDisplayDevice - * @desc Updates the Display config for a VM instance. You can only use this method on a stopped VM instance. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.instances.updateDisplayDevice - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().DisplayDevice} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - updateDisplayDevice( - params?: Params$Resource$Instances$Updatedisplaydevice, - options?: MethodOptions - ): GaxiosPromise; - updateDisplayDevice( - params: Params$Resource$Instances$Updatedisplaydevice, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - updateDisplayDevice( - params: Params$Resource$Instances$Updatedisplaydevice, - callback: BodyResponseCallback - ): void; - updateDisplayDevice(callback: BodyResponseCallback): void; - updateDisplayDevice( - paramsOrCallback?: - | Params$Resource$Instances$Updatedisplaydevice - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Updatedisplaydevice; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Updatedisplaydevice; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/updateDisplayDevice' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.updateNetworkInterface - * @desc Updates an instance's network interface. This method follows PATCH semantics. - * @alias compute.instances.updateNetworkInterface - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance The instance name for this request. - * @param {string} params.networkInterface The name of the network interface to update. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().NetworkInterface} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - updateNetworkInterface( - params?: Params$Resource$Instances$Updatenetworkinterface, - options?: MethodOptions - ): GaxiosPromise; - updateNetworkInterface( - params: Params$Resource$Instances$Updatenetworkinterface, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - updateNetworkInterface( - params: Params$Resource$Instances$Updatenetworkinterface, - callback: BodyResponseCallback - ): void; - updateNetworkInterface( - callback: BodyResponseCallback - ): void; - updateNetworkInterface( - paramsOrCallback?: - | Params$Resource$Instances$Updatenetworkinterface - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Updatenetworkinterface; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Updatenetworkinterface; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/updateNetworkInterface' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance', 'networkInterface'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.updateShieldedInstanceConfig - * @desc Updates the Shielded Instance config for an instance. You can only use this method on a stopped instance. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.instances.updateShieldedInstanceConfig - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name or id of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().ShieldedInstanceConfig} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - updateShieldedInstanceConfig( - params?: Params$Resource$Instances$Updateshieldedinstanceconfig, - options?: MethodOptions - ): GaxiosPromise; - updateShieldedInstanceConfig( - params: Params$Resource$Instances$Updateshieldedinstanceconfig, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - updateShieldedInstanceConfig( - params: Params$Resource$Instances$Updateshieldedinstanceconfig, - callback: BodyResponseCallback - ): void; - updateShieldedInstanceConfig( - callback: BodyResponseCallback - ): void; - updateShieldedInstanceConfig( - paramsOrCallback?: - | Params$Resource$Instances$Updateshieldedinstanceconfig - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Updateshieldedinstanceconfig; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Updateshieldedinstanceconfig; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/updateShieldedInstanceConfig' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instances.updateShieldedVmConfig - * @desc Updates the Shielded VM config for a VM instance. You can only use this method on a stopped VM instance. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.instances.updateShieldedVmConfig - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instance Name of the instance scoping this request. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().ShieldedVmConfig} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - updateShieldedVmConfig( - params?: Params$Resource$Instances$Updateshieldedvmconfig, - options?: MethodOptions - ): GaxiosPromise; - updateShieldedVmConfig( - params: Params$Resource$Instances$Updateshieldedvmconfig, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - updateShieldedVmConfig( - params: Params$Resource$Instances$Updateshieldedvmconfig, - callback: BodyResponseCallback - ): void; - updateShieldedVmConfig( - callback: BodyResponseCallback - ): void; - updateShieldedVmConfig( - paramsOrCallback?: - | Params$Resource$Instances$Updateshieldedvmconfig - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instances$Updateshieldedvmconfig; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instances$Updateshieldedvmconfig; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/instances/{instance}/updateShieldedVmConfig' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'instance'], - pathParams: ['instance', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Instances$Addaccessconfig - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The instance name for this request. - */ - instance?: string; - /** - * The name of the network interface to add to this instance. - */ - networkInterface?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$AccessConfig; - } - export interface Params$Resource$Instances$Addresourcepolicies - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The instance name for this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstancesAddResourcePoliciesRequest; - } - export interface Params$Resource$Instances$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Instances$Attachdisk - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Whether to force attach the disk even if it's currently attached to another instance. - */ - forceAttach?: boolean; - /** - * The instance name for this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$AttachedDisk; - } - export interface Params$Resource$Instances$Delete extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance resource to delete. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Deleteaccessconfig - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the access config to delete. - */ - accessConfig?: string; - /** - * The instance name for this request. - */ - instance?: string; - /** - * The name of the network interface. - */ - networkInterface?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Detachdisk - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The device name of the disk to detach. Make a get() request on the instance to view currently attached disks and device names. - */ - deviceName?: string; - /** - * Instance name for this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance resource to return. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Geteffectivefirewalls - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * The name of the network interface to get the effective firewalls. - */ - networkInterface?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Getguestattributes - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Specifies the guest attributes path to be queried. - */ - queryPath?: string; - /** - * Specifies the key for the guest attributes entry. - */ - variableKey?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Getserialportoutput - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Specifies which COM or serial port to retrieve data from. - */ - port?: number; - /** - * Project ID for this request. - */ - project?: string; - /** - * Returns output starting from a specific byte position. Use this to page through output when the output is too large to return in a single request. For the initial request, leave this field unspecified. For subsequent calls, this field should be set to the next value returned in the previous call. - */ - start?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Getshieldedinstanceidentity - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name or id of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Getshieldedvmidentity - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Insert extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Specifies instance template to create the instance. This field is optional. It can be a full or partial URL. For example, the following are all valid URLs to an instance template: - https://www.googleapis.com/compute/v1/projects/project/global/instanceTemplates/instanceTemplate - projects/project/global/instanceTemplates/instanceTemplate - global/instanceTemplates/instanceTemplate - */ - sourceInstanceTemplate?: string; - /** - * Specifies instance machine to create the instance. This field is optional. It can be a full or partial URL. For example, the following are all valid URLs to an instance template: - https://www.googleapis.com/compute/v1/projects/project/global/global/machineImages/machineImage - projects/project/global/global/machineImages/machineImage - global/machineImages/machineImage - */ - sourceMachineImage?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Instance; - } - export interface Params$Resource$Instances$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Listreferrers - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * Name of the target instance scoping this request, or '-' if the request should span over all instances in the container. - */ - instance?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Removeresourcepolicies - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The instance name for this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstancesRemoveResourcePoliciesRequest; - } - export interface Params$Resource$Instances$Reset extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Resume extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance resource to resume. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstancesResumeRequest; - } - export interface Params$Resource$Instances$Setdeletionprotection - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Whether the resource should be protected against deletion. - */ - deletionProtection?: boolean; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Setdiskautodelete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Whether to auto-delete the disk when the instance is deleted. - */ - autoDelete?: boolean; - /** - * The device name of the disk to modify. Make a get() request on the instance to view currently attached disks and device names. - */ - deviceName?: string; - /** - * The instance name for this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ZoneSetPolicyRequest; - } - export interface Params$Resource$Instances$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstancesSetLabelsRequest; - } - export interface Params$Resource$Instances$Setmachineresources - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstancesSetMachineResourcesRequest; - } - export interface Params$Resource$Instances$Setmachinetype - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstancesSetMachineTypeRequest; - } - export interface Params$Resource$Instances$Setmetadata - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Metadata; - } - export interface Params$Resource$Instances$Setmincpuplatform - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstancesSetMinCpuPlatformRequest; - } - export interface Params$Resource$Instances$Setname - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The instance name for this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstancesSetNameRequest; - } - export interface Params$Resource$Instances$Setscheduling - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Instance name for this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Scheduling; - } - export interface Params$Resource$Instances$Setserviceaccount - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance resource to start. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstancesSetServiceAccountRequest; - } - export interface Params$Resource$Instances$Setshieldedinstanceintegritypolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name or id of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ShieldedInstanceIntegrityPolicy; - } - export interface Params$Resource$Instances$Setshieldedvmintegritypolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ShieldedVmIntegrityPolicy; - } - export interface Params$Resource$Instances$Settags - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Tags; - } - export interface Params$Resource$Instances$Simulatemaintenanceevent - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Start extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance resource to start. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Startwithencryptionkey - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance resource to start. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstancesStartWithEncryptionKeyRequest; - } - export interface Params$Resource$Instances$Stop extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * If true, discard the contents of any attached localSSD partitions. Default value is false (== preserve localSSD data). - */ - discardLocalSsd?: boolean; - /** - * Name of the instance resource to stop. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Suspend - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * If true, discard the contents of any attached localSSD partitions. Default value is false (== preserve localSSD data). - */ - discardLocalSsd?: boolean; - /** - * Name of the instance resource to suspend. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Instances$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Instances$Updateaccessconfig - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The instance name for this request. - */ - instance?: string; - /** - * The name of the network interface where the access config is attached. - */ - networkInterface?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$AccessConfig; - } - export interface Params$Resource$Instances$Updatedisplaydevice - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$DisplayDevice; - } - export interface Params$Resource$Instances$Updatenetworkinterface - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The instance name for this request. - */ - instance?: string; - /** - * The name of the network interface to update. - */ - networkInterface?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NetworkInterface; - } - export interface Params$Resource$Instances$Updateshieldedinstanceconfig - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name or id of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ShieldedInstanceConfig; - } - export interface Params$Resource$Instances$Updateshieldedvmconfig - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance scoping this request. - */ - instance?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ShieldedVmConfig; - } - - export class Resource$Instancetemplates { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.instanceTemplates.delete - * @desc Deletes the specified instance template. Deleting an instance template is permanent and cannot be undone. It is not possible to delete templates that are already in use by a managed instance group. - * @alias compute.instanceTemplates.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceTemplate The name of the instance template to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Instancetemplates$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Instancetemplates$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Instancetemplates$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Instancetemplates$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancetemplates$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancetemplates$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/instanceTemplates/{instanceTemplate}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'instanceTemplate'], - pathParams: ['instanceTemplate', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceTemplates.get - * @desc Returns the specified instance template. Gets a list of available instance templates by making a list() request. - * @alias compute.instanceTemplates.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceTemplate The name of the instance template. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Instancetemplates$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Instancetemplates$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Instancetemplates$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Instancetemplates$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancetemplates$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancetemplates$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/instanceTemplates/{instanceTemplate}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'instanceTemplate'], - pathParams: ['instanceTemplate', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceTemplates.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.instanceTemplates.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Instancetemplates$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Instancetemplates$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Instancetemplates$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Instancetemplates$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancetemplates$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancetemplates$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/instanceTemplates/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceTemplates.insert - * @desc Creates an instance template in the specified project using the data that is included in the request. If you are creating a new template to update an existing instance group, your new instance template must use the same network or, if applicable, the same subnetwork as the original template. - * @alias compute.instanceTemplates.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().InstanceTemplate} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Instancetemplates$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Instancetemplates$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Instancetemplates$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Instancetemplates$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancetemplates$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancetemplates$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/instanceTemplates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceTemplates.list - * @desc Retrieves a list of instance templates that are contained within the specified project. - * @alias compute.instanceTemplates.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Instancetemplates$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Instancetemplates$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Instancetemplates$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Instancetemplates$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancetemplates$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancetemplates$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/instanceTemplates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceTemplates.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.instanceTemplates.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Instancetemplates$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Instancetemplates$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Instancetemplates$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Instancetemplates$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancetemplates$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancetemplates$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/instanceTemplates/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.instanceTemplates.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.instanceTemplates.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Instancetemplates$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Instancetemplates$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Instancetemplates$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Instancetemplates$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Instancetemplates$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Instancetemplates$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/instanceTemplates/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Instancetemplates$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the instance template to delete. - */ - instanceTemplate?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Instancetemplates$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the instance template. - */ - instanceTemplate?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Instancetemplates$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Instancetemplates$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceTemplate; - } - export interface Params$Resource$Instancetemplates$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Instancetemplates$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetPolicyRequest; - } - export interface Params$Resource$Instancetemplates$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Interconnectattachments { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.interconnectAttachments.aggregatedList - * @desc Retrieves an aggregated list of interconnect attachments. - * @alias compute.interconnectAttachments.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Interconnectattachments$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Interconnectattachments$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback< - Schema$InterconnectAttachmentAggregatedList - > - ): void; - aggregatedList( - params: Params$Resource$Interconnectattachments$Aggregatedlist, - callback: BodyResponseCallback< - Schema$InterconnectAttachmentAggregatedList - > - ): void; - aggregatedList( - callback: BodyResponseCallback< - Schema$InterconnectAttachmentAggregatedList - > - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Interconnectattachments$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback< - Schema$InterconnectAttachmentAggregatedList - > - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectattachments$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectattachments$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/interconnectAttachments' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.interconnectAttachments.delete - * @desc Deletes the specified interconnect attachment. - * @alias compute.interconnectAttachments.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.interconnectAttachment Name of the interconnect attachment to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Interconnectattachments$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Interconnectattachments$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Interconnectattachments$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Interconnectattachments$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectattachments$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectattachments$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/interconnectAttachments/{interconnectAttachment}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'interconnectAttachment'], - pathParams: ['interconnectAttachment', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnectAttachments.get - * @desc Returns the specified interconnect attachment. - * @alias compute.interconnectAttachments.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.interconnectAttachment Name of the interconnect attachment to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Interconnectattachments$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Interconnectattachments$Get, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Interconnectattachments$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Interconnectattachments$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectattachments$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectattachments$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/interconnectAttachments/{interconnectAttachment}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'interconnectAttachment'], - pathParams: ['interconnectAttachment', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnectAttachments.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.interconnectAttachments.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Interconnectattachments$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Interconnectattachments$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Interconnectattachments$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Interconnectattachments$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectattachments$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectattachments$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/interconnectAttachments/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnectAttachments.insert - * @desc Creates an InterconnectAttachment in the specified project using the data included in the request. - * @alias compute.interconnectAttachments.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {boolean=} params.validateOnly If true, the request will not be committed. - * @param {().InterconnectAttachment} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Interconnectattachments$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Interconnectattachments$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Interconnectattachments$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Interconnectattachments$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectattachments$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectattachments$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/interconnectAttachments' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnectAttachments.list - * @desc Retrieves the list of interconnect attachments contained within the specified region. - * @alias compute.interconnectAttachments.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Interconnectattachments$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Interconnectattachments$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Interconnectattachments$List, - callback: BodyResponseCallback - ): void; - list( - callback: BodyResponseCallback - ): void; - list( - paramsOrCallback?: - | Params$Resource$Interconnectattachments$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectattachments$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectattachments$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/interconnectAttachments' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnectAttachments.patch - * @desc Updates the specified interconnect attachment with the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.interconnectAttachments.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.interconnectAttachment Name of the interconnect attachment to patch. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().InterconnectAttachment} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Interconnectattachments$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Interconnectattachments$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Interconnectattachments$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Interconnectattachments$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectattachments$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectattachments$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/interconnectAttachments/{interconnectAttachment}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'region', 'interconnectAttachment'], - pathParams: ['interconnectAttachment', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnectAttachments.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.interconnectAttachments.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().RegionSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Interconnectattachments$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Interconnectattachments$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Interconnectattachments$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Interconnectattachments$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectattachments$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectattachments$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/interconnectAttachments/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnectAttachments.setLabels - * @desc Sets the labels on an InterconnectAttachment. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.interconnectAttachments.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().RegionSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Interconnectattachments$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Interconnectattachments$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Interconnectattachments$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Interconnectattachments$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectattachments$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectattachments$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/interconnectAttachments/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnectAttachments.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.interconnectAttachments.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Interconnectattachments$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Interconnectattachments$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Interconnectattachments$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Interconnectattachments$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectattachments$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectattachments$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/interconnectAttachments/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Interconnectattachments$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Interconnectattachments$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the interconnect attachment to delete. - */ - interconnectAttachment?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Interconnectattachments$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the interconnect attachment to return. - */ - interconnectAttachment?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Interconnectattachments$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Interconnectattachments$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * If true, the request will not be committed. - */ - validateOnly?: boolean; - - /** - * Request body metadata - */ - requestBody?: Schema$InterconnectAttachment; - } - export interface Params$Resource$Interconnectattachments$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Interconnectattachments$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the interconnect attachment to patch. - */ - interconnectAttachment?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InterconnectAttachment; - } - export interface Params$Resource$Interconnectattachments$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionSetPolicyRequest; - } - export interface Params$Resource$Interconnectattachments$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionSetLabelsRequest; - } - export interface Params$Resource$Interconnectattachments$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Interconnectlocations { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.interconnectLocations.get - * @desc Returns the details for the specified interconnect location. Gets a list of available interconnect locations by making a list() request. - * @alias compute.interconnectLocations.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.interconnectLocation Name of the interconnect location to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Interconnectlocations$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Interconnectlocations$Get, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Interconnectlocations$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Interconnectlocations$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectlocations$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectlocations$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/interconnectLocations/{interconnectLocation}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'interconnectLocation'], - pathParams: ['interconnectLocation', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnectLocations.list - * @desc Retrieves the list of interconnect locations available to the specified project. - * @alias compute.interconnectLocations.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Interconnectlocations$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Interconnectlocations$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Interconnectlocations$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Interconnectlocations$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectlocations$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectlocations$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/interconnectLocations' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnectLocations.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.interconnectLocations.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Interconnectlocations$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Interconnectlocations$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Interconnectlocations$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Interconnectlocations$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnectlocations$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnectlocations$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/interconnectLocations/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Interconnectlocations$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the interconnect location to return. - */ - interconnectLocation?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Interconnectlocations$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Interconnectlocations$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Interconnects { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.interconnects.delete - * @desc Deletes the specified interconnect. - * @alias compute.interconnects.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.interconnect Name of the interconnect to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Interconnects$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Interconnects$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Interconnects$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Interconnects$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnects$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnects$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/interconnects/{interconnect}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'interconnect'], - pathParams: ['interconnect', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnects.get - * @desc Returns the specified interconnect. Get a list of available interconnects by making a list() request. - * @alias compute.interconnects.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.interconnect Name of the interconnect to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Interconnects$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Interconnects$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Interconnects$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Interconnects$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnects$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnects$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/interconnects/{interconnect}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'interconnect'], - pathParams: ['interconnect', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnects.getDiagnostics - * @desc Returns the interconnectDiagnostics for the specified interconnect. - * @alias compute.interconnects.getDiagnostics - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.interconnect Name of the interconnect resource to query. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getDiagnostics( - params?: Params$Resource$Interconnects$Getdiagnostics, - options?: MethodOptions - ): GaxiosPromise; - getDiagnostics( - params: Params$Resource$Interconnects$Getdiagnostics, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getDiagnostics( - params: Params$Resource$Interconnects$Getdiagnostics, - callback: BodyResponseCallback - ): void; - getDiagnostics( - callback: BodyResponseCallback - ): void; - getDiagnostics( - paramsOrCallback?: - | Params$Resource$Interconnects$Getdiagnostics - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback< - Schema$InterconnectsGetDiagnosticsResponse - > - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnects$Getdiagnostics; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnects$Getdiagnostics; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/interconnects/{interconnect}/getDiagnostics' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'interconnect'], - pathParams: ['interconnect', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.interconnects.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.interconnects.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Interconnects$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Interconnects$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Interconnects$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Interconnects$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnects$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnects$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/interconnects/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnects.insert - * @desc Creates a Interconnect in the specified project using the data included in the request. - * @alias compute.interconnects.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Interconnect} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Interconnects$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Interconnects$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Interconnects$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Interconnects$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnects$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnects$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/interconnects' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnects.list - * @desc Retrieves the list of interconnect available to the specified project. - * @alias compute.interconnects.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Interconnects$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Interconnects$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Interconnects$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Interconnects$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnects$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnects$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/interconnects' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnects.patch - * @desc Updates the specified interconnect with the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.interconnects.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.interconnect Name of the interconnect to update. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Interconnect} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Interconnects$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Interconnects$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Interconnects$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Interconnects$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnects$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnects$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/interconnects/{interconnect}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'interconnect'], - pathParams: ['interconnect', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnects.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.interconnects.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Interconnects$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Interconnects$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Interconnects$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Interconnects$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnects$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnects$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/interconnects/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnects.setLabels - * @desc Sets the labels on an Interconnect. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.interconnects.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Interconnects$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Interconnects$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Interconnects$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Interconnects$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnects$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnects$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/interconnects/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.interconnects.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.interconnects.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Interconnects$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Interconnects$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Interconnects$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Interconnects$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Interconnects$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Interconnects$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/interconnects/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Interconnects$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the interconnect to delete. - */ - interconnect?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Interconnects$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the interconnect to return. - */ - interconnect?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Interconnects$Getdiagnostics - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the interconnect resource to query. - */ - interconnect?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Interconnects$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Interconnects$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Interconnect; - } - export interface Params$Resource$Interconnects$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Interconnects$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the interconnect to update. - */ - interconnect?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Interconnect; - } - export interface Params$Resource$Interconnects$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetPolicyRequest; - } - export interface Params$Resource$Interconnects$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetLabelsRequest; - } - export interface Params$Resource$Interconnects$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Licensecodes { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.licenseCodes.get - * @desc Return a specified license code. License codes are mirrored across all projects that have permissions to read the License Code. - * @alias compute.licenseCodes.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.licenseCode Number corresponding to the License code resource to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Licensecodes$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Licensecodes$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Licensecodes$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Licensecodes$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Licensecodes$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Licensecodes$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/licenseCodes/{licenseCode}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'licenseCode'], - pathParams: ['licenseCode', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.licenseCodes.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.licenseCodes.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Licensecodes$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Licensecodes$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Licensecodes$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Licensecodes$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Licensecodes$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Licensecodes$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/licenseCodes/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.licenseCodes.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.licenseCodes.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Licensecodes$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Licensecodes$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Licensecodes$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Licensecodes$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Licensecodes$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Licensecodes$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/licenseCodes/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.licenseCodes.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.licenseCodes.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Licensecodes$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Licensecodes$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Licensecodes$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Licensecodes$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Licensecodes$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Licensecodes$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/licenseCodes/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Licensecodes$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Number corresponding to the License code resource to return. - */ - licenseCode?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Licensecodes$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Licensecodes$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetPolicyRequest; - } - export interface Params$Resource$Licensecodes$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Licenses { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.licenses.delete - * @desc Deletes the specified license. - * @alias compute.licenses.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.license Name of the license resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Licenses$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Licenses$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Licenses$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Licenses$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Licenses$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Licenses$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/licenses/{license}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'license'], - pathParams: ['license', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.licenses.get - * @desc Returns the specified License resource. - * @alias compute.licenses.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.license Name of the License resource to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Licenses$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Licenses$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Licenses$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Licenses$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Licenses$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Licenses$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/licenses/{license}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'license'], - pathParams: ['license', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.licenses.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.licenses.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Licenses$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Licenses$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Licenses$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Licenses$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Licenses$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Licenses$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/licenses/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.licenses.insert - * @desc Create a License resource in the specified project. - * @alias compute.licenses.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().License} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Licenses$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Licenses$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Licenses$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Licenses$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Licenses$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Licenses$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/licenses' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.licenses.list - * @desc Retrieves the list of licenses available in the specified project. This method does not get any licenses that belong to other projects, including licenses attached to publicly-available images, like Debian 9. If you want to get a list of publicly-available licenses, use this method to make a request to the respective image project, such as debian-cloud or windows-cloud. - * @alias compute.licenses.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Licenses$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Licenses$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Licenses$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Licenses$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Licenses$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Licenses$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/licenses' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.licenses.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.licenses.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Licenses$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Licenses$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Licenses$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Licenses$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Licenses$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Licenses$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/licenses/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.licenses.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.licenses.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Licenses$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Licenses$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Licenses$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Licenses$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Licenses$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Licenses$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/licenses/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Licenses$Delete extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the license resource to delete. - */ - license?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Licenses$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the License resource to return. - */ - license?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Licenses$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Licenses$Insert extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$License; - } - export interface Params$Resource$Licenses$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Licenses$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetPolicyRequest; - } - export interface Params$Resource$Licenses$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Machineimages { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.machineImages.delete - * @desc Deletes the specified machine image. Deleting a machine image is permanent and cannot be undone. - * @alias compute.machineImages.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.machineImage The name of the machine image to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Machineimages$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Machineimages$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Machineimages$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Machineimages$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Machineimages$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Machineimages$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/machineImages/{machineImage}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'machineImage'], - pathParams: ['machineImage', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.machineImages.get - * @desc Returns the specified machine image. Gets a list of available machine images by making a list() request. - * @alias compute.machineImages.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.machineImage The name of the machine image. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Machineimages$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Machineimages$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Machineimages$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Machineimages$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Machineimages$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Machineimages$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/machineImages/{machineImage}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'machineImage'], - pathParams: ['machineImage', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.machineImages.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.machineImages.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Machineimages$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Machineimages$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Machineimages$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Machineimages$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Machineimages$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Machineimages$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/machineImages/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.machineImages.insert - * @desc Creates a machine image in the specified project using the data that is included in the request. If you are creating a new machine image to update an existing instance, your new machine image should use the same network or, if applicable, the same subnetwork as the original instance. - * @alias compute.machineImages.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string=} params.sourceInstance Required. Source instance that is used to create the machine image from. - * @param {().MachineImage} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Machineimages$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Machineimages$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Machineimages$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Machineimages$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Machineimages$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Machineimages$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/machineImages' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.machineImages.list - * @desc Retrieves a list of machine images that are contained within the specified project. - * @alias compute.machineImages.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Machineimages$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Machineimages$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Machineimages$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Machineimages$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Machineimages$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Machineimages$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/machineImages' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.machineImages.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.machineImages.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Machineimages$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Machineimages$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Machineimages$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Machineimages$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Machineimages$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Machineimages$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/machineImages/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.machineImages.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.machineImages.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Machineimages$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Machineimages$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Machineimages$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Machineimages$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Machineimages$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Machineimages$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/machineImages/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Machineimages$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the machine image to delete. - */ - machineImage?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Machineimages$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the machine image. - */ - machineImage?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Machineimages$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Machineimages$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Required. Source instance that is used to create the machine image from. - */ - sourceInstance?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$MachineImage; - } - export interface Params$Resource$Machineimages$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Machineimages$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetPolicyRequest; - } - export interface Params$Resource$Machineimages$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Machinetypes { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.machineTypes.aggregatedList - * @desc Retrieves an aggregated list of machine types. - * @alias compute.machineTypes.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Machinetypes$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Machinetypes$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Machinetypes$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Machinetypes$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Machinetypes$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Machinetypes$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/machineTypes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.machineTypes.get - * @desc Returns the specified machine type. Gets a list of available machine types by making a list() request. - * @alias compute.machineTypes.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.machineType Name of the machine type to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Machinetypes$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Machinetypes$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Machinetypes$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Machinetypes$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Machinetypes$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Machinetypes$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/machineTypes/{machineType}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'machineType'], - pathParams: ['machineType', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.machineTypes.list - * @desc Retrieves a list of machine types available to the specified project. - * @alias compute.machineTypes.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Machinetypes$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Machinetypes$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Machinetypes$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Machinetypes$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Machinetypes$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Machinetypes$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/machineTypes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Machinetypes$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Machinetypes$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the machine type to return. - */ - machineType?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Machinetypes$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - - export class Resource$Networkendpointgroups { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.networkEndpointGroups.aggregatedList - * @desc Retrieves the list of network endpoint groups and sorts them by zone. - * @alias compute.networkEndpointGroups.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Networkendpointgroups$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Networkendpointgroups$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Networkendpointgroups$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Networkendpointgroups$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networkendpointgroups$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networkendpointgroups$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/networkEndpointGroups' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.networkEndpointGroups.attachNetworkEndpoints - * @desc Attach a list of network endpoints to the specified network endpoint group. - * @alias compute.networkEndpointGroups.attachNetworkEndpoints - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.networkEndpointGroup The name of the network endpoint group where you are attaching network endpoints to. It should comply with RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the network endpoint group is located. It should comply with RFC1035. - * @param {().NetworkEndpointGroupsAttachEndpointsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - attachNetworkEndpoints( - params?: Params$Resource$Networkendpointgroups$Attachnetworkendpoints, - options?: MethodOptions - ): GaxiosPromise; - attachNetworkEndpoints( - params: Params$Resource$Networkendpointgroups$Attachnetworkendpoints, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - attachNetworkEndpoints( - params: Params$Resource$Networkendpointgroups$Attachnetworkendpoints, - callback: BodyResponseCallback - ): void; - attachNetworkEndpoints( - callback: BodyResponseCallback - ): void; - attachNetworkEndpoints( - paramsOrCallback?: - | Params$Resource$Networkendpointgroups$Attachnetworkendpoints - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networkendpointgroups$Attachnetworkendpoints; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networkendpointgroups$Attachnetworkendpoints; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/networkEndpointGroups/{networkEndpointGroup}/attachNetworkEndpoints' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'networkEndpointGroup'], - pathParams: ['networkEndpointGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networkEndpointGroups.delete - * @desc Deletes the specified network endpoint group. The network endpoints in the NEG and the VM instances they belong to are not terminated when the NEG is deleted. Note that the NEG cannot be deleted if there are backend services referencing it. - * @alias compute.networkEndpointGroups.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.networkEndpointGroup The name of the network endpoint group to delete. It should comply with RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the network endpoint group is located. It should comply with RFC1035. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Networkendpointgroups$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Networkendpointgroups$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Networkendpointgroups$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Networkendpointgroups$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networkendpointgroups$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networkendpointgroups$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/networkEndpointGroups/{networkEndpointGroup}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'networkEndpointGroup'], - pathParams: ['networkEndpointGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networkEndpointGroups.detachNetworkEndpoints - * @desc Detach a list of network endpoints from the specified network endpoint group. - * @alias compute.networkEndpointGroups.detachNetworkEndpoints - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.networkEndpointGroup The name of the network endpoint group where you are removing network endpoints. It should comply with RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where the network endpoint group is located. It should comply with RFC1035. - * @param {().NetworkEndpointGroupsDetachEndpointsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - detachNetworkEndpoints( - params?: Params$Resource$Networkendpointgroups$Detachnetworkendpoints, - options?: MethodOptions - ): GaxiosPromise; - detachNetworkEndpoints( - params: Params$Resource$Networkendpointgroups$Detachnetworkendpoints, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - detachNetworkEndpoints( - params: Params$Resource$Networkendpointgroups$Detachnetworkendpoints, - callback: BodyResponseCallback - ): void; - detachNetworkEndpoints( - callback: BodyResponseCallback - ): void; - detachNetworkEndpoints( - paramsOrCallback?: - | Params$Resource$Networkendpointgroups$Detachnetworkendpoints - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networkendpointgroups$Detachnetworkendpoints; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networkendpointgroups$Detachnetworkendpoints; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/networkEndpointGroups/{networkEndpointGroup}/detachNetworkEndpoints' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'networkEndpointGroup'], - pathParams: ['networkEndpointGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networkEndpointGroups.get - * @desc Returns the specified network endpoint group. Gets a list of available network endpoint groups by making a list() request. - * @alias compute.networkEndpointGroups.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.networkEndpointGroup The name of the network endpoint group. It should comply with RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the network endpoint group is located. It should comply with RFC1035. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Networkendpointgroups$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Networkendpointgroups$Get, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Networkendpointgroups$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Networkendpointgroups$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networkendpointgroups$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networkendpointgroups$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/networkEndpointGroups/{networkEndpointGroup}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'networkEndpointGroup'], - pathParams: ['networkEndpointGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networkEndpointGroups.insert - * @desc Creates a network endpoint group in the specified project using the parameters that are included in the request. - * @alias compute.networkEndpointGroups.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone where you want to create the network endpoint group. It should comply with RFC1035. - * @param {().NetworkEndpointGroup} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Networkendpointgroups$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Networkendpointgroups$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Networkendpointgroups$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Networkendpointgroups$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networkendpointgroups$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networkendpointgroups$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/networkEndpointGroups' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networkEndpointGroups.list - * @desc Retrieves the list of network endpoint groups that are located in the specified project and zone. - * @alias compute.networkEndpointGroups.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the network endpoint group is located. It should comply with RFC1035. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Networkendpointgroups$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Networkendpointgroups$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Networkendpointgroups$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Networkendpointgroups$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networkendpointgroups$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networkendpointgroups$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/networkEndpointGroups' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networkEndpointGroups.listNetworkEndpoints - * @desc Lists the network endpoints in the specified network endpoint group. - * @alias compute.networkEndpointGroups.listNetworkEndpoints - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string} params.networkEndpointGroup The name of the network endpoint group from which you want to generate a list of included network endpoints. It should comply with RFC1035. - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone where the network endpoint group is located. It should comply with RFC1035. - * @param {().NetworkEndpointGroupsListEndpointsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listNetworkEndpoints( - params?: Params$Resource$Networkendpointgroups$Listnetworkendpoints, - options?: MethodOptions - ): GaxiosPromise; - listNetworkEndpoints( - params: Params$Resource$Networkendpointgroups$Listnetworkendpoints, - options: - | MethodOptions - | BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - >, - callback: BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - > - ): void; - listNetworkEndpoints( - params: Params$Resource$Networkendpointgroups$Listnetworkendpoints, - callback: BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - > - ): void; - listNetworkEndpoints( - callback: BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - > - ): void; - listNetworkEndpoints( - paramsOrCallback?: - | Params$Resource$Networkendpointgroups$Listnetworkendpoints - | BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - >, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - >, - callback?: BodyResponseCallback< - Schema$NetworkEndpointGroupsListNetworkEndpoints - > - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networkendpointgroups$Listnetworkendpoints; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networkendpointgroups$Listnetworkendpoints; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/networkEndpointGroups/{networkEndpointGroup}/listNetworkEndpoints' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'networkEndpointGroup'], - pathParams: ['networkEndpointGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest< - Schema$NetworkEndpointGroupsListNetworkEndpoints - >(parameters); - } - } - - /** - * compute.networkEndpointGroups.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.networkEndpointGroups.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Networkendpointgroups$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Networkendpointgroups$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Networkendpointgroups$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Networkendpointgroups$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networkendpointgroups$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networkendpointgroups$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/networkEndpointGroups/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Networkendpointgroups$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Networkendpointgroups$Attachnetworkendpoints - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the network endpoint group where you are attaching network endpoints to. It should comply with RFC1035. - */ - networkEndpointGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the network endpoint group is located. It should comply with RFC1035. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NetworkEndpointGroupsAttachEndpointsRequest; - } - export interface Params$Resource$Networkendpointgroups$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the network endpoint group to delete. It should comply with RFC1035. - */ - networkEndpointGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the network endpoint group is located. It should comply with RFC1035. - */ - zone?: string; - } - export interface Params$Resource$Networkendpointgroups$Detachnetworkendpoints - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the network endpoint group where you are removing network endpoints. It should comply with RFC1035. - */ - networkEndpointGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where the network endpoint group is located. It should comply with RFC1035. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NetworkEndpointGroupsDetachEndpointsRequest; - } - export interface Params$Resource$Networkendpointgroups$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the network endpoint group. It should comply with RFC1035. - */ - networkEndpointGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the network endpoint group is located. It should comply with RFC1035. - */ - zone?: string; - } - export interface Params$Resource$Networkendpointgroups$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone where you want to create the network endpoint group. It should comply with RFC1035. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NetworkEndpointGroup; - } - export interface Params$Resource$Networkendpointgroups$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the network endpoint group is located. It should comply with RFC1035. - */ - zone?: string; - } - export interface Params$Resource$Networkendpointgroups$Listnetworkendpoints - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * The name of the network endpoint group from which you want to generate a list of included network endpoints. It should comply with RFC1035. - */ - networkEndpointGroup?: string; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone where the network endpoint group is located. It should comply with RFC1035. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NetworkEndpointGroupsListEndpointsRequest; - } - export interface Params$Resource$Networkendpointgroups$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Networks { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.networks.addPeering - * @desc Adds a peering to the specified network. - * @alias compute.networks.addPeering - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.network Name of the network resource to add peering to. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().NetworksAddPeeringRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addPeering( - params?: Params$Resource$Networks$Addpeering, - options?: MethodOptions - ): GaxiosPromise; - addPeering( - params: Params$Resource$Networks$Addpeering, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addPeering( - params: Params$Resource$Networks$Addpeering, - callback: BodyResponseCallback - ): void; - addPeering(callback: BodyResponseCallback): void; - addPeering( - paramsOrCallback?: - | Params$Resource$Networks$Addpeering - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networks$Addpeering; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Addpeering; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networks/{network}/addPeering' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'network'], - pathParams: ['network', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networks.delete - * @desc Deletes the specified network. - * @alias compute.networks.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.network Name of the network to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Networks$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Networks$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Networks$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Networks$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Networks$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networks/{network}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'network'], - pathParams: ['network', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networks.get - * @desc Returns the specified network. Gets a list of available networks by making a list() request. - * @alias compute.networks.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.network Name of the network to return. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Networks$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Networks$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Networks$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Networks$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Networks$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networks/{network}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'network'], - pathParams: ['network', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networks.getEffectiveFirewalls - * @desc Returns the effective firewalls on a given network. - * @alias compute.networks.getEffectiveFirewalls - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.network Name of the network for this request. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getEffectiveFirewalls( - params?: Params$Resource$Networks$Geteffectivefirewalls, - options?: MethodOptions - ): GaxiosPromise; - getEffectiveFirewalls( - params: Params$Resource$Networks$Geteffectivefirewalls, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback< - Schema$NetworksGetEffectiveFirewallsResponse - > - ): void; - getEffectiveFirewalls( - params: Params$Resource$Networks$Geteffectivefirewalls, - callback: BodyResponseCallback< - Schema$NetworksGetEffectiveFirewallsResponse - > - ): void; - getEffectiveFirewalls( - callback: BodyResponseCallback< - Schema$NetworksGetEffectiveFirewallsResponse - > - ): void; - getEffectiveFirewalls( - paramsOrCallback?: - | Params$Resource$Networks$Geteffectivefirewalls - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback< - Schema$NetworksGetEffectiveFirewallsResponse - > - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networks$Geteffectivefirewalls; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Geteffectivefirewalls; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networks/{network}/getEffectiveFirewalls' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'network'], - pathParams: ['network', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.networks.insert - * @desc Creates a network in the specified project using the data included in the request. - * @alias compute.networks.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Network} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Networks$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Networks$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Networks$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Networks$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Networks$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/networks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networks.list - * @desc Retrieves the list of networks available to the specified project. - * @alias compute.networks.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Networks$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Networks$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Networks$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Networks$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Networks$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/networks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networks.listIpAddresses - * @desc Lists the internal IP addresses in the specified network. - * @alias compute.networks.listIpAddresses - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string} params.network Name of the network for this request. - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string=} params.types (Optional) types filter separate by comma, valid values are: SUBNETWORK, RESERVED, PEER_USED, PEER_RESERVED, REMOTE_USED, REMOTE_RESERVED. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listIpAddresses( - params?: Params$Resource$Networks$Listipaddresses, - options?: MethodOptions - ): GaxiosPromise; - listIpAddresses( - params: Params$Resource$Networks$Listipaddresses, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - listIpAddresses( - params: Params$Resource$Networks$Listipaddresses, - callback: BodyResponseCallback - ): void; - listIpAddresses( - callback: BodyResponseCallback - ): void; - listIpAddresses( - paramsOrCallback?: - | Params$Resource$Networks$Listipaddresses - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networks$Listipaddresses; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Listipaddresses; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networks/{network}/listIpAddresses' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'network'], - pathParams: ['network', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networks.listIpOwners - * @desc Lists the internal IP owners in the specified network. - * @alias compute.networks.listIpOwners - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {string=} params.ipCidrRange (Optional) IP CIDR range filter, example: "10.128.10.0/30". - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string} params.network Name of the network to return. - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.ownerProjects (Optional) Project IDs filter, example: "project-1,project-2". - * @param {string=} params.ownerTypes (Optional) Owner types filter, example: "instance,forwardingRule". - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string=} params.subnetName (Optional) Subnetwork name filter. - * @param {string=} params.subnetRegion (Optional) Subnetwork region filter. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listIpOwners( - params?: Params$Resource$Networks$Listipowners, - options?: MethodOptions - ): GaxiosPromise; - listIpOwners( - params: Params$Resource$Networks$Listipowners, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - listIpOwners( - params: Params$Resource$Networks$Listipowners, - callback: BodyResponseCallback - ): void; - listIpOwners(callback: BodyResponseCallback): void; - listIpOwners( - paramsOrCallback?: - | Params$Resource$Networks$Listipowners - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networks$Listipowners; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Listipowners; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networks/{network}/listIpOwners' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'network'], - pathParams: ['network', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networks.listPeeringRoutes - * @desc Lists the peering routes exchanged over peering connection. - * @alias compute.networks.listPeeringRoutes - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.direction The direction of the exchanged routes. - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string} params.network Name of the network for this request. - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string=} params.peeringName The response will show routes exchanged over the given peering connection. - * @param {string} params.project Project ID for this request. - * @param {string=} params.region The region of the request. The response will include all subnet routes, static routes and dynamic routes in the region. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listPeeringRoutes( - params?: Params$Resource$Networks$Listpeeringroutes, - options?: MethodOptions - ): GaxiosPromise; - listPeeringRoutes( - params: Params$Resource$Networks$Listpeeringroutes, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - listPeeringRoutes( - params: Params$Resource$Networks$Listpeeringroutes, - callback: BodyResponseCallback - ): void; - listPeeringRoutes( - callback: BodyResponseCallback - ): void; - listPeeringRoutes( - paramsOrCallback?: - | Params$Resource$Networks$Listpeeringroutes - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networks$Listpeeringroutes; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Listpeeringroutes; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networks/{network}/listPeeringRoutes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'network'], - pathParams: ['network', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networks.patch - * @desc Patches the specified network with the data included in the request. Only the following fields can be modified: routingConfig.routingMode. - * @alias compute.networks.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.network Name of the network to update. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Network} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Networks$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Networks$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Networks$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Networks$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Networks$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networks/{network}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'network'], - pathParams: ['network', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networks.removePeering - * @desc Removes a peering from the specified network. - * @alias compute.networks.removePeering - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.network Name of the network resource to remove peering from. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().NetworksRemovePeeringRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - removePeering( - params?: Params$Resource$Networks$Removepeering, - options?: MethodOptions - ): GaxiosPromise; - removePeering( - params: Params$Resource$Networks$Removepeering, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - removePeering( - params: Params$Resource$Networks$Removepeering, - callback: BodyResponseCallback - ): void; - removePeering(callback: BodyResponseCallback): void; - removePeering( - paramsOrCallback?: - | Params$Resource$Networks$Removepeering - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networks$Removepeering; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Removepeering; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networks/{network}/removePeering' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'network'], - pathParams: ['network', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networks.switchToCustomMode - * @desc Switches the network mode from auto subnet mode to custom subnet mode. - * @alias compute.networks.switchToCustomMode - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.network Name of the network to be updated. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - switchToCustomMode( - params?: Params$Resource$Networks$Switchtocustommode, - options?: MethodOptions - ): GaxiosPromise; - switchToCustomMode( - params: Params$Resource$Networks$Switchtocustommode, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - switchToCustomMode( - params: Params$Resource$Networks$Switchtocustommode, - callback: BodyResponseCallback - ): void; - switchToCustomMode(callback: BodyResponseCallback): void; - switchToCustomMode( - paramsOrCallback?: - | Params$Resource$Networks$Switchtocustommode - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networks$Switchtocustommode; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Switchtocustommode; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networks/{network}/switchToCustomMode' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'network'], - pathParams: ['network', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networks.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.networks.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Networks$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Networks$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Networks$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Networks$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networks$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networks/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.networks.updatePeering - * @desc Updates the specified network peering with the data included in the request Only the following fields can be modified: NetworkPeering.export_custom_routes, and NetworkPeering.import_custom_routes - * @alias compute.networks.updatePeering - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.network Name of the network resource which the updated peering is belonging to. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().NetworksUpdatePeeringRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - updatePeering( - params?: Params$Resource$Networks$Updatepeering, - options?: MethodOptions - ): GaxiosPromise; - updatePeering( - params: Params$Resource$Networks$Updatepeering, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - updatePeering( - params: Params$Resource$Networks$Updatepeering, - callback: BodyResponseCallback - ): void; - updatePeering(callback: BodyResponseCallback): void; - updatePeering( - paramsOrCallback?: - | Params$Resource$Networks$Updatepeering - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Networks$Updatepeering; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Networks$Updatepeering; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/networks/{network}/updatePeering' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'network'], - pathParams: ['network', 'project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Networks$Addpeering - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the network resource to add peering to. - */ - network?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NetworksAddPeeringRequest; - } - export interface Params$Resource$Networks$Delete extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the network to delete. - */ - network?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Networks$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the network to return. - */ - network?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Networks$Geteffectivefirewalls - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the network for this request. - */ - network?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Networks$Insert extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Network; - } - export interface Params$Resource$Networks$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Networks$Listipaddresses - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Name of the network for this request. - */ - network?: string; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * (Optional) types filter separate by comma, valid values are: SUBNETWORK, RESERVED, PEER_USED, PEER_RESERVED, REMOTE_USED, REMOTE_RESERVED. - */ - types?: string; - } - export interface Params$Resource$Networks$Listipowners - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * (Optional) IP CIDR range filter, example: "10.128.10.0/30". - */ - ipCidrRange?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Name of the network to return. - */ - network?: string; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * (Optional) Project IDs filter, example: "project-1,project-2". - */ - ownerProjects?: string; - /** - * (Optional) Owner types filter, example: "instance,forwardingRule". - */ - ownerTypes?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * (Optional) Subnetwork name filter. - */ - subnetName?: string; - /** - * (Optional) Subnetwork region filter. - */ - subnetRegion?: string; - } - export interface Params$Resource$Networks$Listpeeringroutes - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The direction of the exchanged routes. - */ - direction?: string; - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Name of the network for this request. - */ - network?: string; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * The response will show routes exchanged over the given peering connection. - */ - peeringName?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The region of the request. The response will include all subnet routes, static routes and dynamic routes in the region. - */ - region?: string; - } - export interface Params$Resource$Networks$Patch extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the network to update. - */ - network?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Network; - } - export interface Params$Resource$Networks$Removepeering - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the network resource to remove peering from. - */ - network?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NetworksRemovePeeringRequest; - } - export interface Params$Resource$Networks$Switchtocustommode - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the network to be updated. - */ - network?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Networks$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Networks$Updatepeering - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the network resource which the updated peering is belonging to. - */ - network?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NetworksUpdatePeeringRequest; - } - - export class Resource$Nodegroups { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.nodeGroups.addNodes - * @desc Adds specified number of nodes to the node group. - * @alias compute.nodeGroups.addNodes - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.nodeGroup Name of the NodeGroup resource. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().NodeGroupsAddNodesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addNodes( - params?: Params$Resource$Nodegroups$Addnodes, - options?: MethodOptions - ): GaxiosPromise; - addNodes( - params: Params$Resource$Nodegroups$Addnodes, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addNodes( - params: Params$Resource$Nodegroups$Addnodes, - callback: BodyResponseCallback - ): void; - addNodes(callback: BodyResponseCallback): void; - addNodes( - paramsOrCallback?: - | Params$Resource$Nodegroups$Addnodes - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodegroups$Addnodes; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$Addnodes; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeGroups/{nodeGroup}/addNodes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'nodeGroup'], - pathParams: ['nodeGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeGroups.aggregatedList - * @desc Retrieves an aggregated list of node groups. Note: use nodeGroups.listNodes for more details about each group. - * @alias compute.nodeGroups.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Nodegroups$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Nodegroups$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Nodegroups$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Nodegroups$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodegroups$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/nodeGroups' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeGroups.delete - * @desc Deletes the specified NodeGroup resource. - * @alias compute.nodeGroups.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.nodeGroup Name of the NodeGroup resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Nodegroups$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Nodegroups$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Nodegroups$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Nodegroups$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodegroups$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeGroups/{nodeGroup}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'nodeGroup'], - pathParams: ['nodeGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeGroups.deleteNodes - * @desc Deletes specified nodes from the node group. - * @alias compute.nodeGroups.deleteNodes - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.nodeGroup Name of the NodeGroup resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().NodeGroupsDeleteNodesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - deleteNodes( - params?: Params$Resource$Nodegroups$Deletenodes, - options?: MethodOptions - ): GaxiosPromise; - deleteNodes( - params: Params$Resource$Nodegroups$Deletenodes, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - deleteNodes( - params: Params$Resource$Nodegroups$Deletenodes, - callback: BodyResponseCallback - ): void; - deleteNodes(callback: BodyResponseCallback): void; - deleteNodes( - paramsOrCallback?: - | Params$Resource$Nodegroups$Deletenodes - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodegroups$Deletenodes; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$Deletenodes; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeGroups/{nodeGroup}/deleteNodes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'nodeGroup'], - pathParams: ['nodeGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeGroups.get - * @desc Returns the specified NodeGroup. Get a list of available NodeGroups by making a list() request. Note: the "nodes" field should not be used. Use nodeGroups.listNodes instead. - * @alias compute.nodeGroups.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.nodeGroup Name of the node group to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Nodegroups$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Nodegroups$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Nodegroups$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Nodegroups$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Nodegroups$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeGroups/{nodeGroup}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'nodeGroup'], - pathParams: ['nodeGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeGroups.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.nodeGroups.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Nodegroups$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Nodegroups$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Nodegroups$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Nodegroups$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodegroups$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeGroups/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeGroups.insert - * @desc Creates a NodeGroup resource in the specified project using the data included in the request. - * @alias compute.nodeGroups.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {integer} params.initialNodeCount Initial count of nodes in the node group. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().NodeGroup} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Nodegroups$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Nodegroups$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Nodegroups$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Nodegroups$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodegroups$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeGroups' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'initialNodeCount'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeGroups.list - * @desc Retrieves a list of node groups available to the specified project. Note: use nodeGroups.listNodes for more details about each group. - * @alias compute.nodeGroups.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Nodegroups$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Nodegroups$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Nodegroups$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Nodegroups$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Nodegroups$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeGroups' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeGroups.listNodes - * @desc Lists nodes in the node group. - * @alias compute.nodeGroups.listNodes - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string} params.nodeGroup Name of the NodeGroup resource whose nodes you want to list. - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listNodes( - params?: Params$Resource$Nodegroups$Listnodes, - options?: MethodOptions - ): GaxiosPromise; - listNodes( - params: Params$Resource$Nodegroups$Listnodes, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - listNodes( - params: Params$Resource$Nodegroups$Listnodes, - callback: BodyResponseCallback - ): void; - listNodes(callback: BodyResponseCallback): void; - listNodes( - paramsOrCallback?: - | Params$Resource$Nodegroups$Listnodes - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodegroups$Listnodes; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$Listnodes; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeGroups/{nodeGroup}/listNodes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'nodeGroup'], - pathParams: ['nodeGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeGroups.setAutoscalingPolicy - * @desc Sets the autoscaling policy of the node group. - * @alias compute.nodeGroups.setAutoscalingPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.nodeGroup Name of the NodeGroup resource to update. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().NodeGroupsSetAutoscalingPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setAutoscalingPolicy( - params?: Params$Resource$Nodegroups$Setautoscalingpolicy, - options?: MethodOptions - ): GaxiosPromise; - setAutoscalingPolicy( - params: Params$Resource$Nodegroups$Setautoscalingpolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setAutoscalingPolicy( - params: Params$Resource$Nodegroups$Setautoscalingpolicy, - callback: BodyResponseCallback - ): void; - setAutoscalingPolicy( - callback: BodyResponseCallback - ): void; - setAutoscalingPolicy( - paramsOrCallback?: - | Params$Resource$Nodegroups$Setautoscalingpolicy - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodegroups$Setautoscalingpolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$Setautoscalingpolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeGroups/{nodeGroup}/setAutoscalingPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'nodeGroup'], - pathParams: ['nodeGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeGroups.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.nodeGroups.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().ZoneSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Nodegroups$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Nodegroups$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Nodegroups$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Nodegroups$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodegroups$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeGroups/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeGroups.setNodeTemplate - * @desc Updates the node template of the node group. - * @alias compute.nodeGroups.setNodeTemplate - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.nodeGroup Name of the NodeGroup resource to update. - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone The name of the zone for this request. - * @param {().NodeGroupsSetNodeTemplateRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setNodeTemplate( - params?: Params$Resource$Nodegroups$Setnodetemplate, - options?: MethodOptions - ): GaxiosPromise; - setNodeTemplate( - params: Params$Resource$Nodegroups$Setnodetemplate, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setNodeTemplate( - params: Params$Resource$Nodegroups$Setnodetemplate, - callback: BodyResponseCallback - ): void; - setNodeTemplate(callback: BodyResponseCallback): void; - setNodeTemplate( - paramsOrCallback?: - | Params$Resource$Nodegroups$Setnodetemplate - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodegroups$Setnodetemplate; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$Setnodetemplate; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeGroups/{nodeGroup}/setNodeTemplate' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'nodeGroup'], - pathParams: ['nodeGroup', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeGroups.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.nodeGroups.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Nodegroups$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Nodegroups$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Nodegroups$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Nodegroups$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodegroups$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodegroups$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeGroups/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Nodegroups$Addnodes - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the NodeGroup resource. - */ - nodeGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NodeGroupsAddNodesRequest; - } - export interface Params$Resource$Nodegroups$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Nodegroups$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the NodeGroup resource to delete. - */ - nodeGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Nodegroups$Deletenodes - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the NodeGroup resource to delete. - */ - nodeGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NodeGroupsDeleteNodesRequest; - } - export interface Params$Resource$Nodegroups$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the node group to return. - */ - nodeGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Nodegroups$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Nodegroups$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Initial count of nodes in the node group. - */ - initialNodeCount?: number; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NodeGroup; - } - export interface Params$Resource$Nodegroups$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Nodegroups$Listnodes - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Name of the NodeGroup resource whose nodes you want to list. - */ - nodeGroup?: string; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Nodegroups$Setautoscalingpolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the NodeGroup resource to update. - */ - nodeGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NodeGroupsSetAutoscalingPolicyRequest; - } - export interface Params$Resource$Nodegroups$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ZoneSetPolicyRequest; - } - export interface Params$Resource$Nodegroups$Setnodetemplate - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the NodeGroup resource to update. - */ - nodeGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NodeGroupsSetNodeTemplateRequest; - } - export interface Params$Resource$Nodegroups$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Nodetemplates { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.nodeTemplates.aggregatedList - * @desc Retrieves an aggregated list of node templates. - * @alias compute.nodeTemplates.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Nodetemplates$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Nodetemplates$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Nodetemplates$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Nodetemplates$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodetemplates$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodetemplates$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/nodeTemplates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeTemplates.delete - * @desc Deletes the specified NodeTemplate resource. - * @alias compute.nodeTemplates.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.nodeTemplate Name of the NodeTemplate resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Nodetemplates$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Nodetemplates$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Nodetemplates$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Nodetemplates$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodetemplates$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodetemplates$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/nodeTemplates/{nodeTemplate}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'nodeTemplate'], - pathParams: ['nodeTemplate', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeTemplates.get - * @desc Returns the specified node template. Gets a list of available node templates by making a list() request. - * @alias compute.nodeTemplates.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.nodeTemplate Name of the node template to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Nodetemplates$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Nodetemplates$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Nodetemplates$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Nodetemplates$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodetemplates$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodetemplates$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/nodeTemplates/{nodeTemplate}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'nodeTemplate'], - pathParams: ['nodeTemplate', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeTemplates.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.nodeTemplates.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Nodetemplates$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Nodetemplates$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Nodetemplates$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Nodetemplates$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodetemplates$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodetemplates$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/nodeTemplates/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeTemplates.insert - * @desc Creates a NodeTemplate resource in the specified project using the data included in the request. - * @alias compute.nodeTemplates.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().NodeTemplate} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Nodetemplates$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Nodetemplates$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Nodetemplates$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Nodetemplates$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodetemplates$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodetemplates$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/nodeTemplates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeTemplates.list - * @desc Retrieves a list of node templates available to the specified project. - * @alias compute.nodeTemplates.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Nodetemplates$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Nodetemplates$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Nodetemplates$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Nodetemplates$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodetemplates$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodetemplates$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/nodeTemplates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeTemplates.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.nodeTemplates.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().RegionSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Nodetemplates$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Nodetemplates$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Nodetemplates$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Nodetemplates$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodetemplates$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodetemplates$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/nodeTemplates/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeTemplates.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.nodeTemplates.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Nodetemplates$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Nodetemplates$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Nodetemplates$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Nodetemplates$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodetemplates$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodetemplates$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/nodeTemplates/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Nodetemplates$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Nodetemplates$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the NodeTemplate resource to delete. - */ - nodeTemplate?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Nodetemplates$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the node template to return. - */ - nodeTemplate?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Nodetemplates$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Nodetemplates$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NodeTemplate; - } - export interface Params$Resource$Nodetemplates$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Nodetemplates$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionSetPolicyRequest; - } - export interface Params$Resource$Nodetemplates$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Nodetypes { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.nodeTypes.aggregatedList - * @desc Retrieves an aggregated list of node types. - * @alias compute.nodeTypes.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Nodetypes$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Nodetypes$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Nodetypes$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Nodetypes$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Nodetypes$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodetypes$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/aggregated/nodeTypes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeTypes.get - * @desc Returns the specified node type. Gets a list of available node types by making a list() request. - * @alias compute.nodeTypes.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.nodeType Name of the node type to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Nodetypes$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Nodetypes$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Nodetypes$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Nodetypes$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Nodetypes$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodetypes$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeTypes/{nodeType}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'nodeType'], - pathParams: ['nodeType', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.nodeTypes.list - * @desc Retrieves a list of node types available to the specified project. - * @alias compute.nodeTypes.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Nodetypes$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Nodetypes$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Nodetypes$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Nodetypes$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Nodetypes$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Nodetypes$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/nodeTypes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Nodetypes$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Nodetypes$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the node type to return. - */ - nodeType?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Nodetypes$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - - export class Resource$Organizationsecuritypolicies { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.organizationSecurityPolicies.addAssociation - * @desc Inserts an association for the specified security policy. - * @alias compute.organizationSecurityPolicies.addAssociation - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {boolean=} params.replaceExistingAssociation Indicates whether or not to replace it if an association of the attachment already exists. This is false by default, in which case an error will be returned if an assocation already exists. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.securityPolicy Name of the security policy to update. - * @param {().SecurityPolicyAssociation} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addAssociation( - params?: Params$Resource$Organizationsecuritypolicies$Addassociation, - options?: MethodOptions - ): GaxiosPromise; - addAssociation( - params: Params$Resource$Organizationsecuritypolicies$Addassociation, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addAssociation( - params: Params$Resource$Organizationsecuritypolicies$Addassociation, - callback: BodyResponseCallback - ): void; - addAssociation(callback: BodyResponseCallback): void; - addAssociation( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Addassociation - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Addassociation; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Addassociation; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/{securityPolicy}/addAssociation' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['securityPolicy'], - pathParams: ['securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.addRule - * @desc Inserts a rule into a security policy. - * @alias compute.organizationSecurityPolicies.addRule - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.securityPolicy Name of the security policy to update. - * @param {().SecurityPolicyRule} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addRule( - params?: Params$Resource$Organizationsecuritypolicies$Addrule, - options?: MethodOptions - ): GaxiosPromise; - addRule( - params: Params$Resource$Organizationsecuritypolicies$Addrule, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addRule( - params: Params$Resource$Organizationsecuritypolicies$Addrule, - callback: BodyResponseCallback - ): void; - addRule(callback: BodyResponseCallback): void; - addRule( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Addrule - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Addrule; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Addrule; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/{securityPolicy}/addRule' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['securityPolicy'], - pathParams: ['securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.copyRules - * @desc Copies rules to the specified security policy. - * @alias compute.organizationSecurityPolicies.copyRules - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.securityPolicy Name of the security policy to update. - * @param {string=} params.sourceSecurityPolicy The security policy from which to copy rules. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - copyRules( - params?: Params$Resource$Organizationsecuritypolicies$Copyrules, - options?: MethodOptions - ): GaxiosPromise; - copyRules( - params: Params$Resource$Organizationsecuritypolicies$Copyrules, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - copyRules( - params: Params$Resource$Organizationsecuritypolicies$Copyrules, - callback: BodyResponseCallback - ): void; - copyRules(callback: BodyResponseCallback): void; - copyRules( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Copyrules - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Copyrules; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Copyrules; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/{securityPolicy}/copyRules' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['securityPolicy'], - pathParams: ['securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.delete - * @desc Deletes the specified policy. - * @alias compute.organizationSecurityPolicies.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.securityPolicy Name of the security policy to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Organizationsecuritypolicies$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Organizationsecuritypolicies$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Organizationsecuritypolicies$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/{securityPolicy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['securityPolicy'], - pathParams: ['securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.get - * @desc List all of the ordered rules present in a single specified policy. - * @alias compute.organizationSecurityPolicies.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.securityPolicy Name of the security policy to get. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Organizationsecuritypolicies$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Organizationsecuritypolicies$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Organizationsecuritypolicies$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/{securityPolicy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['securityPolicy'], - pathParams: ['securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.getAssociation - * @desc Gets an association with the specified name. - * @alias compute.organizationSecurityPolicies.getAssociation - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.name The name of the association to get from the security policy. - * @param {string} params.securityPolicy Name of the security policy to which the queried rule belongs. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getAssociation( - params?: Params$Resource$Organizationsecuritypolicies$Getassociation, - options?: MethodOptions - ): GaxiosPromise; - getAssociation( - params: Params$Resource$Organizationsecuritypolicies$Getassociation, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getAssociation( - params: Params$Resource$Organizationsecuritypolicies$Getassociation, - callback: BodyResponseCallback - ): void; - getAssociation( - callback: BodyResponseCallback - ): void; - getAssociation( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Getassociation - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Getassociation; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Getassociation; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/{securityPolicy}/getAssociation' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['securityPolicy'], - pathParams: ['securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.getRule - * @desc Gets a rule at the specified priority. - * @alias compute.organizationSecurityPolicies.getRule - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {integer=} params.priority The priority of the rule to get from the security policy. - * @param {string} params.securityPolicy Name of the security policy to which the queried rule belongs. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getRule( - params?: Params$Resource$Organizationsecuritypolicies$Getrule, - options?: MethodOptions - ): GaxiosPromise; - getRule( - params: Params$Resource$Organizationsecuritypolicies$Getrule, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getRule( - params: Params$Resource$Organizationsecuritypolicies$Getrule, - callback: BodyResponseCallback - ): void; - getRule(callback: BodyResponseCallback): void; - getRule( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Getrule - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Getrule; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Getrule; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/{securityPolicy}/getRule' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['securityPolicy'], - pathParams: ['securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.insert - * @desc Creates a new policy in the specified project using the data included in the request. - * @alias compute.organizationSecurityPolicies.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.parentId Parent ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().SecurityPolicy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Organizationsecuritypolicies$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Organizationsecuritypolicies$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Organizationsecuritypolicies$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: [], - pathParams: [], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.list - * @desc List all the policies that have been configured for the specified project. - * @alias compute.organizationSecurityPolicies.list - * @memberOf! () - * - * @param {object=} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string=} params.parentId Parent ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Organizationsecuritypolicies$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Organizationsecuritypolicies$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Organizationsecuritypolicies$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: [], - pathParams: [], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.listAssociations - * @desc Lists associations of a specified target, i.e., organization or folder. - * @alias compute.organizationSecurityPolicies.listAssociations - * @memberOf! () - * - * @param {object=} params Parameters for request - * @param {string=} params.targetResource The target resource to list associations. It is an organization, or a folder. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listAssociations( - params?: Params$Resource$Organizationsecuritypolicies$Listassociations, - options?: MethodOptions - ): GaxiosPromise< - Schema$OrganizationSecurityPoliciesListAssociationsResponse - >; - listAssociations( - params: Params$Resource$Organizationsecuritypolicies$Listassociations, - options: - | MethodOptions - | BodyResponseCallback< - Schema$OrganizationSecurityPoliciesListAssociationsResponse - >, - callback: BodyResponseCallback< - Schema$OrganizationSecurityPoliciesListAssociationsResponse - > - ): void; - listAssociations( - params: Params$Resource$Organizationsecuritypolicies$Listassociations, - callback: BodyResponseCallback< - Schema$OrganizationSecurityPoliciesListAssociationsResponse - > - ): void; - listAssociations( - callback: BodyResponseCallback< - Schema$OrganizationSecurityPoliciesListAssociationsResponse - > - ): void; - listAssociations( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Listassociations - | BodyResponseCallback< - Schema$OrganizationSecurityPoliciesListAssociationsResponse - >, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback< - Schema$OrganizationSecurityPoliciesListAssociationsResponse - >, - callback?: BodyResponseCallback< - Schema$OrganizationSecurityPoliciesListAssociationsResponse - > - ): void | GaxiosPromise< - Schema$OrganizationSecurityPoliciesListAssociationsResponse - > { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Listassociations; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Listassociations; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/listAssociations' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: [], - pathParams: [], - context: this.context, - }; - if (callback) { - createAPIRequest< - Schema$OrganizationSecurityPoliciesListAssociationsResponse - >(parameters, callback); - } else { - return createAPIRequest< - Schema$OrganizationSecurityPoliciesListAssociationsResponse - >(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.move - * @desc Moves the specified security policy. - * @alias compute.organizationSecurityPolicies.move - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.parentId The new parent of the security policy. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.securityPolicy Name of the security policy to update. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - move( - params?: Params$Resource$Organizationsecuritypolicies$Move, - options?: MethodOptions - ): GaxiosPromise; - move( - params: Params$Resource$Organizationsecuritypolicies$Move, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - move( - params: Params$Resource$Organizationsecuritypolicies$Move, - callback: BodyResponseCallback - ): void; - move(callback: BodyResponseCallback): void; - move( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Move - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Move; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Move; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/{securityPolicy}/move' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['securityPolicy'], - pathParams: ['securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.patch - * @desc Patches the specified policy with the data included in the request. - * @alias compute.organizationSecurityPolicies.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.securityPolicy Name of the security policy to update. - * @param {().SecurityPolicy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Organizationsecuritypolicies$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Organizationsecuritypolicies$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Organizationsecuritypolicies$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/{securityPolicy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['securityPolicy'], - pathParams: ['securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.patchRule - * @desc Patches a rule at the specified priority. - * @alias compute.organizationSecurityPolicies.patchRule - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {integer=} params.priority The priority of the rule to patch. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.securityPolicy Name of the security policy to update. - * @param {().SecurityPolicyRule} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patchRule( - params?: Params$Resource$Organizationsecuritypolicies$Patchrule, - options?: MethodOptions - ): GaxiosPromise; - patchRule( - params: Params$Resource$Organizationsecuritypolicies$Patchrule, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patchRule( - params: Params$Resource$Organizationsecuritypolicies$Patchrule, - callback: BodyResponseCallback - ): void; - patchRule(callback: BodyResponseCallback): void; - patchRule( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Patchrule - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Patchrule; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Patchrule; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/{securityPolicy}/patchRule' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['securityPolicy'], - pathParams: ['securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.removeAssociation - * @desc Removes an association for the specified security policy. - * @alias compute.organizationSecurityPolicies.removeAssociation - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.name Name for the attachment that will be removed. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.securityPolicy Name of the security policy to update. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - removeAssociation( - params?: Params$Resource$Organizationsecuritypolicies$Removeassociation, - options?: MethodOptions - ): GaxiosPromise; - removeAssociation( - params: Params$Resource$Organizationsecuritypolicies$Removeassociation, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - removeAssociation( - params: Params$Resource$Organizationsecuritypolicies$Removeassociation, - callback: BodyResponseCallback - ): void; - removeAssociation(callback: BodyResponseCallback): void; - removeAssociation( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Removeassociation - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Removeassociation; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Removeassociation; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/{securityPolicy}/removeAssociation' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['securityPolicy'], - pathParams: ['securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.organizationSecurityPolicies.removeRule - * @desc Deletes a rule at the specified priority. - * @alias compute.organizationSecurityPolicies.removeRule - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {integer=} params.priority The priority of the rule to remove from the security policy. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.securityPolicy Name of the security policy to update. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - removeRule( - params?: Params$Resource$Organizationsecuritypolicies$Removerule, - options?: MethodOptions - ): GaxiosPromise; - removeRule( - params: Params$Resource$Organizationsecuritypolicies$Removerule, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - removeRule( - params: Params$Resource$Organizationsecuritypolicies$Removerule, - callback: BodyResponseCallback - ): void; - removeRule(callback: BodyResponseCallback): void; - removeRule( - paramsOrCallback?: - | Params$Resource$Organizationsecuritypolicies$Removerule - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Organizationsecuritypolicies$Removerule; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Organizationsecuritypolicies$Removerule; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/locations/global/securityPolicies/{securityPolicy}/removeRule' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['securityPolicy'], - pathParams: ['securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Organizationsecuritypolicies$Addassociation - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Indicates whether or not to replace it if an association of the attachment already exists. This is false by default, in which case an error will be returned if an assocation already exists. - */ - replaceExistingAssociation?: boolean; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the security policy to update. - */ - securityPolicy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SecurityPolicyAssociation; - } - export interface Params$Resource$Organizationsecuritypolicies$Addrule - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the security policy to update. - */ - securityPolicy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SecurityPolicyRule; - } - export interface Params$Resource$Organizationsecuritypolicies$Copyrules - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the security policy to update. - */ - securityPolicy?: string; - /** - * The security policy from which to copy rules. - */ - sourceSecurityPolicy?: string; - } - export interface Params$Resource$Organizationsecuritypolicies$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the security policy to delete. - */ - securityPolicy?: string; - } - export interface Params$Resource$Organizationsecuritypolicies$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the security policy to get. - */ - securityPolicy?: string; - } - export interface Params$Resource$Organizationsecuritypolicies$Getassociation - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the association to get from the security policy. - */ - name?: string; - /** - * Name of the security policy to which the queried rule belongs. - */ - securityPolicy?: string; - } - export interface Params$Resource$Organizationsecuritypolicies$Getrule - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The priority of the rule to get from the security policy. - */ - priority?: number; - /** - * Name of the security policy to which the queried rule belongs. - */ - securityPolicy?: string; - } - export interface Params$Resource$Organizationsecuritypolicies$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Parent ID for this request. - */ - parentId?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SecurityPolicy; - } - export interface Params$Resource$Organizationsecuritypolicies$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Parent ID for this request. - */ - parentId?: string; - } - export interface Params$Resource$Organizationsecuritypolicies$Listassociations - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The target resource to list associations. It is an organization, or a folder. - */ - targetResource?: string; - } - export interface Params$Resource$Organizationsecuritypolicies$Move - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The new parent of the security policy. - */ - parentId?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the security policy to update. - */ - securityPolicy?: string; - } - export interface Params$Resource$Organizationsecuritypolicies$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the security policy to update. - */ - securityPolicy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SecurityPolicy; - } - export interface Params$Resource$Organizationsecuritypolicies$Patchrule - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The priority of the rule to patch. - */ - priority?: number; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the security policy to update. - */ - securityPolicy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SecurityPolicyRule; - } - export interface Params$Resource$Organizationsecuritypolicies$Removeassociation - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name for the attachment that will be removed. - */ - name?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the security policy to update. - */ - securityPolicy?: string; - } - export interface Params$Resource$Organizationsecuritypolicies$Removerule - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The priority of the rule to remove from the security policy. - */ - priority?: number; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the security policy to update. - */ - securityPolicy?: string; - } - - export class Resource$Packetmirrorings { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.packetMirrorings.aggregatedList - * @desc Retrieves an aggregated list of packetMirrorings. - * @alias compute.packetMirrorings.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Packetmirrorings$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Packetmirrorings$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Packetmirrorings$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Packetmirrorings$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Packetmirrorings$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Packetmirrorings$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/packetMirrorings' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.packetMirrorings.delete - * @desc Deletes the specified PacketMirroring resource. - * @alias compute.packetMirrorings.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.packetMirroring Name of the PacketMirroring resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Packetmirrorings$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Packetmirrorings$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Packetmirrorings$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Packetmirrorings$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Packetmirrorings$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Packetmirrorings$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/packetMirrorings/{packetMirroring}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'packetMirroring'], - pathParams: ['packetMirroring', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.packetMirrorings.get - * @desc Returns the specified PacketMirroring resource. - * @alias compute.packetMirrorings.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.packetMirroring Name of the PacketMirroring resource to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Packetmirrorings$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Packetmirrorings$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Packetmirrorings$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Packetmirrorings$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Packetmirrorings$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Packetmirrorings$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/packetMirrorings/{packetMirroring}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'packetMirroring'], - pathParams: ['packetMirroring', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.packetMirrorings.insert - * @desc Creates a PacketMirroring resource in the specified project and region using the data included in the request. - * @alias compute.packetMirrorings.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().PacketMirroring} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Packetmirrorings$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Packetmirrorings$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Packetmirrorings$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Packetmirrorings$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Packetmirrorings$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Packetmirrorings$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/packetMirrorings' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.packetMirrorings.list - * @desc Retrieves a list of PacketMirroring resources available to the specified project and region. - * @alias compute.packetMirrorings.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Packetmirrorings$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Packetmirrorings$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Packetmirrorings$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Packetmirrorings$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Packetmirrorings$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Packetmirrorings$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/packetMirrorings' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.packetMirrorings.patch - * @desc Patches the specified PacketMirroring resource with the data included in the request. This method supports PATCH semantics and uses JSON merge patch format and processing rules. - * @alias compute.packetMirrorings.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.packetMirroring Name of the PacketMirroring resource to patch. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().PacketMirroring} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Packetmirrorings$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Packetmirrorings$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Packetmirrorings$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Packetmirrorings$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Packetmirrorings$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Packetmirrorings$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/packetMirrorings/{packetMirroring}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'region', 'packetMirroring'], - pathParams: ['packetMirroring', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.packetMirrorings.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.packetMirrorings.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Packetmirrorings$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Packetmirrorings$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Packetmirrorings$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Packetmirrorings$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Packetmirrorings$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Packetmirrorings$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/packetMirrorings/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Packetmirrorings$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Packetmirrorings$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the PacketMirroring resource to delete. - */ - packetMirroring?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Packetmirrorings$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the PacketMirroring resource to return. - */ - packetMirroring?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Packetmirrorings$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$PacketMirroring; - } - export interface Params$Resource$Packetmirrorings$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Packetmirrorings$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the PacketMirroring resource to patch. - */ - packetMirroring?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$PacketMirroring; - } - export interface Params$Resource$Packetmirrorings$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Projects { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.projects.disableXpnHost - * @desc Disable this project as a shared VPC host project. - * @alias compute.projects.disableXpnHost - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - disableXpnHost( - params?: Params$Resource$Projects$Disablexpnhost, - options?: MethodOptions - ): GaxiosPromise; - disableXpnHost( - params: Params$Resource$Projects$Disablexpnhost, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - disableXpnHost( - params: Params$Resource$Projects$Disablexpnhost, - callback: BodyResponseCallback - ): void; - disableXpnHost(callback: BodyResponseCallback): void; - disableXpnHost( - paramsOrCallback?: - | Params$Resource$Projects$Disablexpnhost - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Disablexpnhost; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Disablexpnhost; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/disableXpnHost' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.disableXpnResource - * @desc Disable a service resource (also known as service project) associated with this host project. - * @alias compute.projects.disableXpnResource - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().ProjectsDisableXpnResourceRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - disableXpnResource( - params?: Params$Resource$Projects$Disablexpnresource, - options?: MethodOptions - ): GaxiosPromise; - disableXpnResource( - params: Params$Resource$Projects$Disablexpnresource, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - disableXpnResource( - params: Params$Resource$Projects$Disablexpnresource, - callback: BodyResponseCallback - ): void; - disableXpnResource(callback: BodyResponseCallback): void; - disableXpnResource( - paramsOrCallback?: - | Params$Resource$Projects$Disablexpnresource - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Disablexpnresource; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Disablexpnresource; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/disableXpnResource' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.enableXpnHost - * @desc Enable this project as a shared VPC host project. - * @alias compute.projects.enableXpnHost - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - enableXpnHost( - params?: Params$Resource$Projects$Enablexpnhost, - options?: MethodOptions - ): GaxiosPromise; - enableXpnHost( - params: Params$Resource$Projects$Enablexpnhost, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - enableXpnHost( - params: Params$Resource$Projects$Enablexpnhost, - callback: BodyResponseCallback - ): void; - enableXpnHost(callback: BodyResponseCallback): void; - enableXpnHost( - paramsOrCallback?: - | Params$Resource$Projects$Enablexpnhost - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Enablexpnhost; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Enablexpnhost; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/enableXpnHost' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.enableXpnResource - * @desc Enable service resource (a.k.a service project) for a host project, so that subnets in the host project can be used by instances in the service project. - * @alias compute.projects.enableXpnResource - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().ProjectsEnableXpnResourceRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - enableXpnResource( - params?: Params$Resource$Projects$Enablexpnresource, - options?: MethodOptions - ): GaxiosPromise; - enableXpnResource( - params: Params$Resource$Projects$Enablexpnresource, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - enableXpnResource( - params: Params$Resource$Projects$Enablexpnresource, - callback: BodyResponseCallback - ): void; - enableXpnResource(callback: BodyResponseCallback): void; - enableXpnResource( - paramsOrCallback?: - | Params$Resource$Projects$Enablexpnresource - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Enablexpnresource; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Enablexpnresource; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/enableXpnResource' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.get - * @desc Returns the specified Project resource. - * @alias compute.projects.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Projects$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Projects$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Projects$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Projects$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Projects$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/compute/alpha/projects/{project}').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.getXpnHost - * @desc Gets the shared VPC host project that this project links to. May be empty if no link exists. - * @alias compute.projects.getXpnHost - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getXpnHost( - params?: Params$Resource$Projects$Getxpnhost, - options?: MethodOptions - ): GaxiosPromise; - getXpnHost( - params: Params$Resource$Projects$Getxpnhost, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getXpnHost( - params: Params$Resource$Projects$Getxpnhost, - callback: BodyResponseCallback - ): void; - getXpnHost(callback: BodyResponseCallback): void; - getXpnHost( - paramsOrCallback?: - | Params$Resource$Projects$Getxpnhost - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Getxpnhost; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Getxpnhost; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/getXpnHost' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.getXpnResources - * @desc Gets service resources (a.k.a service project) associated with this host project. - * @alias compute.projects.getXpnResources - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.order_by Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getXpnResources( - params?: Params$Resource$Projects$Getxpnresources, - options?: MethodOptions - ): GaxiosPromise; - getXpnResources( - params: Params$Resource$Projects$Getxpnresources, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getXpnResources( - params: Params$Resource$Projects$Getxpnresources, - callback: BodyResponseCallback - ): void; - getXpnResources( - callback: BodyResponseCallback - ): void; - getXpnResources( - paramsOrCallback?: - | Params$Resource$Projects$Getxpnresources - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Getxpnresources; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Getxpnresources; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/getXpnResources' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.listXpnHosts - * @desc Lists all shared VPC host projects visible to the user in an organization. - * @alias compute.projects.listXpnHosts - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.order_by Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {().ProjectsListXpnHostsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listXpnHosts( - params?: Params$Resource$Projects$Listxpnhosts, - options?: MethodOptions - ): GaxiosPromise; - listXpnHosts( - params: Params$Resource$Projects$Listxpnhosts, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - listXpnHosts( - params: Params$Resource$Projects$Listxpnhosts, - callback: BodyResponseCallback - ): void; - listXpnHosts(callback: BodyResponseCallback): void; - listXpnHosts( - paramsOrCallback?: - | Params$Resource$Projects$Listxpnhosts - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Listxpnhosts; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Listxpnhosts; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/listXpnHosts' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.moveDisk - * @desc Moves a persistent disk from one zone to another. - * @alias compute.projects.moveDisk - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().DiskMoveRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - moveDisk( - params?: Params$Resource$Projects$Movedisk, - options?: MethodOptions - ): GaxiosPromise; - moveDisk( - params: Params$Resource$Projects$Movedisk, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - moveDisk( - params: Params$Resource$Projects$Movedisk, - callback: BodyResponseCallback - ): void; - moveDisk(callback: BodyResponseCallback): void; - moveDisk( - paramsOrCallback?: - | Params$Resource$Projects$Movedisk - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Movedisk; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Movedisk; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/moveDisk' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.moveInstance - * @desc Moves an instance and its attached persistent disks from one zone to another. - * @alias compute.projects.moveInstance - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().InstanceMoveRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - moveInstance( - params?: Params$Resource$Projects$Moveinstance, - options?: MethodOptions - ): GaxiosPromise; - moveInstance( - params: Params$Resource$Projects$Moveinstance, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - moveInstance( - params: Params$Resource$Projects$Moveinstance, - callback: BodyResponseCallback - ): void; - moveInstance(callback: BodyResponseCallback): void; - moveInstance( - paramsOrCallback?: - | Params$Resource$Projects$Moveinstance - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Moveinstance; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Moveinstance; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/moveInstance' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.setCommonInstanceMetadata - * @desc Sets metadata common to all instances within the specified project using the data included in the request. - * @alias compute.projects.setCommonInstanceMetadata - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Metadata} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setCommonInstanceMetadata( - params?: Params$Resource$Projects$Setcommoninstancemetadata, - options?: MethodOptions - ): GaxiosPromise; - setCommonInstanceMetadata( - params: Params$Resource$Projects$Setcommoninstancemetadata, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setCommonInstanceMetadata( - params: Params$Resource$Projects$Setcommoninstancemetadata, - callback: BodyResponseCallback - ): void; - setCommonInstanceMetadata( - callback: BodyResponseCallback - ): void; - setCommonInstanceMetadata( - paramsOrCallback?: - | Params$Resource$Projects$Setcommoninstancemetadata - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Setcommoninstancemetadata; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Setcommoninstancemetadata; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/setCommonInstanceMetadata' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.setDefaultNetworkTier - * @desc Sets the default network tier of the project. The default network tier is used when an address/forwardingRule/instance is created without specifying the network tier field. - * @alias compute.projects.setDefaultNetworkTier - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().ProjectsSetDefaultNetworkTierRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setDefaultNetworkTier( - params?: Params$Resource$Projects$Setdefaultnetworktier, - options?: MethodOptions - ): GaxiosPromise; - setDefaultNetworkTier( - params: Params$Resource$Projects$Setdefaultnetworktier, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setDefaultNetworkTier( - params: Params$Resource$Projects$Setdefaultnetworktier, - callback: BodyResponseCallback - ): void; - setDefaultNetworkTier( - callback: BodyResponseCallback - ): void; - setDefaultNetworkTier( - paramsOrCallback?: - | Params$Resource$Projects$Setdefaultnetworktier - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Setdefaultnetworktier; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Setdefaultnetworktier; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/setDefaultNetworkTier' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.setDefaultServiceAccount - * @desc Sets the default service account of the project. The default service account is used when a VM instance is created with the service account email address set to "default". - * @alias compute.projects.setDefaultServiceAccount - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().ProjectsSetDefaultServiceAccountRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setDefaultServiceAccount( - params?: Params$Resource$Projects$Setdefaultserviceaccount, - options?: MethodOptions - ): GaxiosPromise; - setDefaultServiceAccount( - params: Params$Resource$Projects$Setdefaultserviceaccount, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setDefaultServiceAccount( - params: Params$Resource$Projects$Setdefaultserviceaccount, - callback: BodyResponseCallback - ): void; - setDefaultServiceAccount( - callback: BodyResponseCallback - ): void; - setDefaultServiceAccount( - paramsOrCallback?: - | Params$Resource$Projects$Setdefaultserviceaccount - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Setdefaultserviceaccount; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Setdefaultserviceaccount; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/setDefaultServiceAccount' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.projects.setUsageExportBucket - * @desc Enables the usage export feature and sets the usage export bucket where reports are stored. If you provide an empty request body using this method, the usage export feature will be disabled. - * @alias compute.projects.setUsageExportBucket - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().UsageExportLocation} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setUsageExportBucket( - params?: Params$Resource$Projects$Setusageexportbucket, - options?: MethodOptions - ): GaxiosPromise; - setUsageExportBucket( - params: Params$Resource$Projects$Setusageexportbucket, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setUsageExportBucket( - params: Params$Resource$Projects$Setusageexportbucket, - callback: BodyResponseCallback - ): void; - setUsageExportBucket( - callback: BodyResponseCallback - ): void; - setUsageExportBucket( - paramsOrCallback?: - | Params$Resource$Projects$Setusageexportbucket - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Setusageexportbucket; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Setusageexportbucket; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/setUsageExportBucket' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Projects$Disablexpnhost - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Projects$Disablexpnresource - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ProjectsDisableXpnResourceRequest; - } - export interface Params$Resource$Projects$Enablexpnhost - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Projects$Enablexpnresource - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ProjectsEnableXpnResourceRequest; - } - export interface Params$Resource$Projects$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Projects$Getxpnhost - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Projects$Getxpnresources - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - order_by?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Projects$Listxpnhosts - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - order_by?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ProjectsListXpnHostsRequest; - } - export interface Params$Resource$Projects$Movedisk - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$DiskMoveRequest; - } - export interface Params$Resource$Projects$Moveinstance - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceMoveRequest; - } - export interface Params$Resource$Projects$Setcommoninstancemetadata - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Metadata; - } - export interface Params$Resource$Projects$Setdefaultnetworktier - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ProjectsSetDefaultNetworkTierRequest; - } - export interface Params$Resource$Projects$Setdefaultserviceaccount - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ProjectsSetDefaultServiceAccountRequest; - } - export interface Params$Resource$Projects$Setusageexportbucket - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$UsageExportLocation; - } - - export class Resource$Regionautoscalers { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionAutoscalers.delete - * @desc Deletes the specified autoscaler. - * @alias compute.regionAutoscalers.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.autoscaler Name of the autoscaler to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Regionautoscalers$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Regionautoscalers$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Regionautoscalers$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Regionautoscalers$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionautoscalers$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionautoscalers$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/autoscalers/{autoscaler}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'autoscaler'], - pathParams: ['autoscaler', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionAutoscalers.get - * @desc Returns the specified autoscaler. - * @alias compute.regionAutoscalers.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.autoscaler Name of the autoscaler to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regionautoscalers$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regionautoscalers$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regionautoscalers$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regionautoscalers$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionautoscalers$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionautoscalers$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/autoscalers/{autoscaler}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'autoscaler'], - pathParams: ['autoscaler', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionAutoscalers.insert - * @desc Creates an autoscaler in the specified project using the data included in the request. - * @alias compute.regionAutoscalers.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Autoscaler} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Regionautoscalers$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Regionautoscalers$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Regionautoscalers$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Regionautoscalers$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionautoscalers$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionautoscalers$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/autoscalers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionAutoscalers.list - * @desc Retrieves a list of autoscalers contained within the specified region. - * @alias compute.regionAutoscalers.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regionautoscalers$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regionautoscalers$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regionautoscalers$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regionautoscalers$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionautoscalers$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionautoscalers$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/autoscalers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionAutoscalers.patch - * @desc Updates an autoscaler in the specified project using the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.regionAutoscalers.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.autoscaler Name of the autoscaler to patch. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Autoscaler} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Regionautoscalers$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Regionautoscalers$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Regionautoscalers$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Regionautoscalers$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionautoscalers$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionautoscalers$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/autoscalers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionAutoscalers.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.regionAutoscalers.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regionautoscalers$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regionautoscalers$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regionautoscalers$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regionautoscalers$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionautoscalers$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionautoscalers$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/autoscalers/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionAutoscalers.update - * @desc Updates an autoscaler in the specified project using the data included in the request. - * @alias compute.regionAutoscalers.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.autoscaler Name of the autoscaler to update. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Autoscaler} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Regionautoscalers$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Regionautoscalers$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Regionautoscalers$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Regionautoscalers$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionautoscalers$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionautoscalers$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/autoscalers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regionautoscalers$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the autoscaler to delete. - */ - autoscaler?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Regionautoscalers$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the autoscaler to return. - */ - autoscaler?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regionautoscalers$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Autoscaler; - } - export interface Params$Resource$Regionautoscalers$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regionautoscalers$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the autoscaler to patch. - */ - autoscaler?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Autoscaler; - } - export interface Params$Resource$Regionautoscalers$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Regionautoscalers$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the autoscaler to update. - */ - autoscaler?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Autoscaler; - } - - export class Resource$Regionbackendservices { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionBackendServices.delete - * @desc Deletes the specified regional BackendService resource. - * @alias compute.regionBackendServices.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Regionbackendservices$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Regionbackendservices$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Regionbackendservices$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Regionbackendservices$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionbackendservices$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionbackendservices$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/backendServices/{backendService}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'backendService'], - pathParams: ['backendService', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionBackendServices.get - * @desc Returns the specified regional BackendService resource. - * @alias compute.regionBackendServices.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regionbackendservices$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regionbackendservices$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regionbackendservices$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regionbackendservices$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionbackendservices$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionbackendservices$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/backendServices/{backendService}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'backendService'], - pathParams: ['backendService', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionBackendServices.getHealth - * @desc Gets the most recent health check results for this regional BackendService. - * @alias compute.regionBackendServices.getHealth - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource for which to get health. - * @param {string} params.project - * @param {string} params.region Name of the region scoping this request. - * @param {().ResourceGroupReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getHealth( - params?: Params$Resource$Regionbackendservices$Gethealth, - options?: MethodOptions - ): GaxiosPromise; - getHealth( - params: Params$Resource$Regionbackendservices$Gethealth, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getHealth( - params: Params$Resource$Regionbackendservices$Gethealth, - callback: BodyResponseCallback - ): void; - getHealth( - callback: BodyResponseCallback - ): void; - getHealth( - paramsOrCallback?: - | Params$Resource$Regionbackendservices$Gethealth - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionbackendservices$Gethealth; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionbackendservices$Gethealth; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/backendServices/{backendService}/getHealth' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'backendService'], - pathParams: ['backendService', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionBackendServices.insert - * @desc Creates a regional BackendService resource in the specified project using the data included in the request. There are several restrictions and guidelines to keep in mind when creating a regional backend service. Read Restrictions and Guidelines for more information. - * @alias compute.regionBackendServices.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().BackendService} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Regionbackendservices$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Regionbackendservices$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Regionbackendservices$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Regionbackendservices$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionbackendservices$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionbackendservices$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/backendServices' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionBackendServices.list - * @desc Retrieves the list of regional BackendService resources available to the specified project in the given region. - * @alias compute.regionBackendServices.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regionbackendservices$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regionbackendservices$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regionbackendservices$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regionbackendservices$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionbackendservices$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionbackendservices$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/backendServices' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionBackendServices.patch - * @desc Updates the specified regional BackendService resource with the data included in the request. There are several restrictions and guidelines to keep in mind when updating a backend service. Read Restrictions and Guidelines for more information. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.regionBackendServices.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource to patch. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().BackendService} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Regionbackendservices$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Regionbackendservices$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Regionbackendservices$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Regionbackendservices$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionbackendservices$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionbackendservices$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/backendServices/{backendService}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'region', 'backendService'], - pathParams: ['backendService', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionBackendServices.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.regionBackendServices.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regionbackendservices$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regionbackendservices$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regionbackendservices$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regionbackendservices$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionbackendservices$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionbackendservices$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/backendServices/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionBackendServices.update - * @desc Updates the specified regional BackendService resource with the data included in the request. There are several restrictions and guidelines to keep in mind when updating a backend service. Read Restrictions and Guidelines for more information. - * @alias compute.regionBackendServices.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.backendService Name of the BackendService resource to update. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().BackendService} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Regionbackendservices$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Regionbackendservices$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Regionbackendservices$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Regionbackendservices$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionbackendservices$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionbackendservices$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/backendServices/{backendService}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'region', 'backendService'], - pathParams: ['backendService', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regionbackendservices$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource to delete. - */ - backendService?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Regionbackendservices$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource to return. - */ - backendService?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regionbackendservices$Gethealth - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource for which to get health. - */ - backendService?: string; - /** - * - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ResourceGroupReference; - } - export interface Params$Resource$Regionbackendservices$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$BackendService; - } - export interface Params$Resource$Regionbackendservices$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regionbackendservices$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource to patch. - */ - backendService?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$BackendService; - } - export interface Params$Resource$Regionbackendservices$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Regionbackendservices$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the BackendService resource to update. - */ - backendService?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$BackendService; - } - - export class Resource$Regioncommitments { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionCommitments.aggregatedList - * @desc Retrieves an aggregated list of commitments. - * @alias compute.regionCommitments.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Regioncommitments$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Regioncommitments$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Regioncommitments$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Regioncommitments$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioncommitments$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioncommitments$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/commitments' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionCommitments.get - * @desc Returns the specified commitment resource. Gets a list of available commitments by making a list() request. - * @alias compute.regionCommitments.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.commitment Name of the commitment to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regioncommitments$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regioncommitments$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regioncommitments$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regioncommitments$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioncommitments$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioncommitments$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/commitments/{commitment}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'commitment'], - pathParams: ['commitment', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionCommitments.insert - * @desc Creates a commitment in the specified project using the data included in the request. - * @alias compute.regionCommitments.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Commitment} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Regioncommitments$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Regioncommitments$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Regioncommitments$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Regioncommitments$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioncommitments$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioncommitments$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/commitments' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionCommitments.list - * @desc Retrieves a list of commitments contained within the specified region. - * @alias compute.regionCommitments.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regioncommitments$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regioncommitments$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regioncommitments$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regioncommitments$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioncommitments$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioncommitments$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/commitments' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionCommitments.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.regionCommitments.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regioncommitments$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regioncommitments$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regioncommitments$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regioncommitments$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioncommitments$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioncommitments$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/commitments/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionCommitments.updateReservations - * @desc Update the shape of reservations for GPUS/Local SSDs of reservations within the commitments. - * @alias compute.regionCommitments.updateReservations - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.commitment Name of the commitment of which the reservation's capacities are being updated. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionCommitmentsUpdateReservationsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - updateReservations( - params?: Params$Resource$Regioncommitments$Updatereservations, - options?: MethodOptions - ): GaxiosPromise; - updateReservations( - params: Params$Resource$Regioncommitments$Updatereservations, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - updateReservations( - params: Params$Resource$Regioncommitments$Updatereservations, - callback: BodyResponseCallback - ): void; - updateReservations(callback: BodyResponseCallback): void; - updateReservations( - paramsOrCallback?: - | Params$Resource$Regioncommitments$Updatereservations - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioncommitments$Updatereservations; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioncommitments$Updatereservations; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/commitments/{commitment}/updateReservations' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'commitment'], - pathParams: ['commitment', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regioncommitments$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Regioncommitments$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the commitment to return. - */ - commitment?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Regioncommitments$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Commitment; - } - export interface Params$Resource$Regioncommitments$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Regioncommitments$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Regioncommitments$Updatereservations - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the commitment of which the reservation's capacities are being updated. - */ - commitment?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionCommitmentsUpdateReservationsRequest; - } - - export class Resource$Regiondisks { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionDisks.addResourcePolicies - * @desc Adds existing resource policies to a regional disk. You can only add one policy which will be applied to this disk for scheduling snapshot creation. - * @alias compute.regionDisks.addResourcePolicies - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.disk The disk name for this request. - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionDisksAddResourcePoliciesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addResourcePolicies( - params?: Params$Resource$Regiondisks$Addresourcepolicies, - options?: MethodOptions - ): GaxiosPromise; - addResourcePolicies( - params: Params$Resource$Regiondisks$Addresourcepolicies, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addResourcePolicies( - params: Params$Resource$Regiondisks$Addresourcepolicies, - callback: BodyResponseCallback - ): void; - addResourcePolicies(callback: BodyResponseCallback): void; - addResourcePolicies( - paramsOrCallback?: - | Params$Resource$Regiondisks$Addresourcepolicies - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiondisks$Addresourcepolicies; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisks$Addresourcepolicies; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/disks/{disk}/addResourcePolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'disk'], - pathParams: ['disk', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionDisks.createSnapshot - * @desc Creates a snapshot of this regional disk. - * @alias compute.regionDisks.createSnapshot - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.disk Name of the regional persistent disk to snapshot. - * @param {boolean=} params.guestFlush [Input Only] Specifies to create an application consistent snapshot by informing the OS to prepare for the snapshot process. Currently only supported on Windows instances using the Volume Shadow Copy Service (VSS). - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Snapshot} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - createSnapshot( - params?: Params$Resource$Regiondisks$Createsnapshot, - options?: MethodOptions - ): GaxiosPromise; - createSnapshot( - params: Params$Resource$Regiondisks$Createsnapshot, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - createSnapshot( - params: Params$Resource$Regiondisks$Createsnapshot, - callback: BodyResponseCallback - ): void; - createSnapshot(callback: BodyResponseCallback): void; - createSnapshot( - paramsOrCallback?: - | Params$Resource$Regiondisks$Createsnapshot - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiondisks$Createsnapshot; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisks$Createsnapshot; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/disks/{disk}/createSnapshot' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'disk'], - pathParams: ['disk', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionDisks.delete - * @desc Deletes the specified regional persistent disk. Deleting a regional disk removes all the replicas of its data permanently and is irreversible. However, deleting a disk does not delete any snapshots previously made from the disk. You must separately delete snapshots. - * @alias compute.regionDisks.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.disk Name of the regional persistent disk to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Regiondisks$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Regiondisks$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Regiondisks$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Regiondisks$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiondisks$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisks$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/disks/{disk}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'disk'], - pathParams: ['disk', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionDisks.get - * @desc Returns a specified regional persistent disk. - * @alias compute.regionDisks.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.disk Name of the regional persistent disk to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regiondisks$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regiondisks$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regiondisks$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regiondisks$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Regiondisks$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisks$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/disks/{disk}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'disk'], - pathParams: ['disk', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionDisks.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.regionDisks.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Regiondisks$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Regiondisks$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Regiondisks$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Regiondisks$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiondisks$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisks$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/disks/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionDisks.insert - * @desc Creates a persistent regional disk in the specified project using the data included in the request. - * @alias compute.regionDisks.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string=} params.sourceImage Optional. Source image to restore onto a disk. - * @param {().Disk} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Regiondisks$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Regiondisks$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Regiondisks$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Regiondisks$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiondisks$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisks$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/disks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionDisks.list - * @desc Retrieves the list of persistent disks contained within the specified region. - * @alias compute.regionDisks.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regiondisks$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regiondisks$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regiondisks$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regiondisks$List - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Regiondisks$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisks$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/disks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionDisks.removeResourcePolicies - * @desc Removes resource policies from a regional disk. - * @alias compute.regionDisks.removeResourcePolicies - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.disk The disk name for this request. - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionDisksRemoveResourcePoliciesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - removeResourcePolicies( - params?: Params$Resource$Regiondisks$Removeresourcepolicies, - options?: MethodOptions - ): GaxiosPromise; - removeResourcePolicies( - params: Params$Resource$Regiondisks$Removeresourcepolicies, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - removeResourcePolicies( - params: Params$Resource$Regiondisks$Removeresourcepolicies, - callback: BodyResponseCallback - ): void; - removeResourcePolicies( - callback: BodyResponseCallback - ): void; - removeResourcePolicies( - paramsOrCallback?: - | Params$Resource$Regiondisks$Removeresourcepolicies - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiondisks$Removeresourcepolicies; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisks$Removeresourcepolicies; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/disks/{disk}/removeResourcePolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'disk'], - pathParams: ['disk', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionDisks.resize - * @desc Resizes the specified regional persistent disk. - * @alias compute.regionDisks.resize - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.disk Name of the regional persistent disk. - * @param {string} params.project The project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionDisksResizeRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - resize( - params?: Params$Resource$Regiondisks$Resize, - options?: MethodOptions - ): GaxiosPromise; - resize( - params: Params$Resource$Regiondisks$Resize, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - resize( - params: Params$Resource$Regiondisks$Resize, - callback: BodyResponseCallback - ): void; - resize(callback: BodyResponseCallback): void; - resize( - paramsOrCallback?: - | Params$Resource$Regiondisks$Resize - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiondisks$Resize; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisks$Resize; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/disks/{disk}/resize' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'disk'], - pathParams: ['disk', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionDisks.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.regionDisks.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().RegionSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Regiondisks$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Regiondisks$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Regiondisks$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Regiondisks$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiondisks$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisks$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/disks/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionDisks.setLabels - * @desc Sets the labels on the target regional disk. - * @alias compute.regionDisks.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().RegionSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Regiondisks$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Regiondisks$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Regiondisks$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Regiondisks$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiondisks$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisks$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/disks/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionDisks.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.regionDisks.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regiondisks$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regiondisks$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regiondisks$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regiondisks$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiondisks$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisks$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/disks/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regiondisks$Addresourcepolicies - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The disk name for this request. - */ - disk?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionDisksAddResourcePoliciesRequest; - } - export interface Params$Resource$Regiondisks$Createsnapshot - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the regional persistent disk to snapshot. - */ - disk?: string; - /** - * [Input Only] Specifies to create an application consistent snapshot by informing the OS to prepare for the snapshot process. Currently only supported on Windows instances using the Volume Shadow Copy Service (VSS). - */ - guestFlush?: boolean; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Snapshot; - } - export interface Params$Resource$Regiondisks$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the regional persistent disk to delete. - */ - disk?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Regiondisks$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the regional persistent disk to return. - */ - disk?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Regiondisks$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Regiondisks$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Optional. Source image to restore onto a disk. - */ - sourceImage?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Disk; - } - export interface Params$Resource$Regiondisks$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Regiondisks$Removeresourcepolicies - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The disk name for this request. - */ - disk?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionDisksRemoveResourcePoliciesRequest; - } - export interface Params$Resource$Regiondisks$Resize - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the regional persistent disk. - */ - disk?: string; - /** - * The project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionDisksResizeRequest; - } - export interface Params$Resource$Regiondisks$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionSetPolicyRequest; - } - export interface Params$Resource$Regiondisks$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionSetLabelsRequest; - } - export interface Params$Resource$Regiondisks$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Regiondisktypes { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionDiskTypes.get - * @desc Returns the specified regional disk type. Gets a list of available disk types by making a list() request. - * @alias compute.regionDiskTypes.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.diskType Name of the disk type to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regiondisktypes$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regiondisktypes$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regiondisktypes$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regiondisktypes$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiondisktypes$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisktypes$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/diskTypes/{diskType}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'diskType'], - pathParams: ['diskType', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionDiskTypes.list - * @desc Retrieves a list of regional disk types available to the specified project. - * @alias compute.regionDiskTypes.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regiondisktypes$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regiondisktypes$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regiondisktypes$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regiondisktypes$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiondisktypes$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiondisktypes$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/diskTypes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regiondisktypes$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the disk type to return. - */ - diskType?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Regiondisktypes$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - } - - export class Resource$Regionhealthchecks { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionHealthChecks.delete - * @desc Deletes the specified HealthCheck resource. - * @alias compute.regionHealthChecks.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.healthCheck Name of the HealthCheck resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Regionhealthchecks$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Regionhealthchecks$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Regionhealthchecks$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Regionhealthchecks$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionhealthchecks$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionhealthchecks$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/healthChecks/{healthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'healthCheck'], - pathParams: ['healthCheck', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionHealthChecks.get - * @desc Returns the specified HealthCheck resource. Gets a list of available health checks by making a list() request. - * @alias compute.regionHealthChecks.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.healthCheck Name of the HealthCheck resource to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regionhealthchecks$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regionhealthchecks$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regionhealthchecks$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regionhealthchecks$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionhealthchecks$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionhealthchecks$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/healthChecks/{healthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'healthCheck'], - pathParams: ['healthCheck', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionHealthChecks.insert - * @desc Creates a HealthCheck resource in the specified project using the data included in the request. - * @alias compute.regionHealthChecks.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HealthCheck} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Regionhealthchecks$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Regionhealthchecks$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Regionhealthchecks$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Regionhealthchecks$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionhealthchecks$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionhealthchecks$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/healthChecks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionHealthChecks.list - * @desc Retrieves the list of HealthCheck resources available to the specified project. - * @alias compute.regionHealthChecks.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regionhealthchecks$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regionhealthchecks$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regionhealthchecks$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regionhealthchecks$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionhealthchecks$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionhealthchecks$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/healthChecks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionHealthChecks.patch - * @desc Updates a HealthCheck resource in the specified project using the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.regionHealthChecks.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.healthCheck Name of the HealthCheck resource to patch. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HealthCheck} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Regionhealthchecks$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Regionhealthchecks$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Regionhealthchecks$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Regionhealthchecks$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionhealthchecks$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionhealthchecks$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/healthChecks/{healthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'region', 'healthCheck'], - pathParams: ['healthCheck', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionHealthChecks.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.regionHealthChecks.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regionhealthchecks$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regionhealthchecks$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regionhealthchecks$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regionhealthchecks$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionhealthchecks$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionhealthchecks$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/healthChecks/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionHealthChecks.update - * @desc Updates a HealthCheck resource in the specified project using the data included in the request. - * @alias compute.regionHealthChecks.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.healthCheck Name of the HealthCheck resource to update. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HealthCheck} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Regionhealthchecks$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Regionhealthchecks$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Regionhealthchecks$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Regionhealthchecks$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionhealthchecks$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionhealthchecks$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/healthChecks/{healthCheck}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'region', 'healthCheck'], - pathParams: ['healthCheck', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regionhealthchecks$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HealthCheck resource to delete. - */ - healthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Regionhealthchecks$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HealthCheck resource to return. - */ - healthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regionhealthchecks$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HealthCheck; - } - export interface Params$Resource$Regionhealthchecks$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regionhealthchecks$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HealthCheck resource to patch. - */ - healthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HealthCheck; - } - export interface Params$Resource$Regionhealthchecks$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Regionhealthchecks$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HealthCheck resource to update. - */ - healthCheck?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HealthCheck; - } - - export class Resource$Regionhealthcheckservices { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionHealthCheckServices.delete - * @desc Deletes the specified regional HealthCheckService. - * @alias compute.regionHealthCheckServices.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.healthCheckService Name of the HealthCheckService to delete. The name must be 1-63 characters long, and comply with RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Regionhealthcheckservices$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Regionhealthcheckservices$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Regionhealthcheckservices$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Regionhealthcheckservices$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionhealthcheckservices$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionhealthcheckservices$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/healthCheckServices/{healthCheckService}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'healthCheckService'], - pathParams: ['healthCheckService', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionHealthCheckServices.get - * @desc Returns the specified regional HealthCheckService resource. - * @alias compute.regionHealthCheckServices.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.healthCheckService Name of the HealthCheckService to update. The name must be 1-63 characters long, and comply with RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regionhealthcheckservices$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regionhealthcheckservices$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regionhealthcheckservices$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regionhealthcheckservices$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionhealthcheckservices$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionhealthcheckservices$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/healthCheckServices/{healthCheckService}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'healthCheckService'], - pathParams: ['healthCheckService', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionHealthCheckServices.insert - * @desc Creates a regional HealthCheckService resource in the specified project and region using the data included in the request. - * @alias compute.regionHealthCheckServices.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().HealthCheckService} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Regionhealthcheckservices$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Regionhealthcheckservices$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Regionhealthcheckservices$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Regionhealthcheckservices$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionhealthcheckservices$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionhealthcheckservices$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/healthCheckServices' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionHealthCheckServices.list - * @desc Lists all the HealthCheckService resources that have been configured for the specified project in the given region. - * @alias compute.regionHealthCheckServices.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regionhealthcheckservices$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regionhealthcheckservices$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regionhealthcheckservices$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regionhealthcheckservices$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionhealthcheckservices$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionhealthcheckservices$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/healthCheckServices' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionHealthCheckServices.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.regionHealthCheckServices.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regionhealthcheckservices$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regionhealthcheckservices$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regionhealthcheckservices$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regionhealthcheckservices$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionhealthcheckservices$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionhealthcheckservices$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/healthCheckServices/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regionhealthcheckservices$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HealthCheckService to delete. The name must be 1-63 characters long, and comply with RFC1035. - */ - healthCheckService?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Regionhealthcheckservices$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the HealthCheckService to update. The name must be 1-63 characters long, and comply with RFC1035. - */ - healthCheckService?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regionhealthcheckservices$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$HealthCheckService; - } - export interface Params$Resource$Regionhealthcheckservices$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regionhealthcheckservices$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Regioninstancegroupmanagers { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionInstanceGroupManagers.abandonInstances - * @desc Flags the specified instances to be immediately removed from the managed instance group. Abandoning an instance does not delete the instance, but it does remove the instance from any target pools that are applied by the managed instance group. This method reduces the targetSize of the managed instance group by the number of instances that you abandon. This operation is marked as DONE when the action is scheduled even if the instances have not yet been removed from the group. You must separately verify the status of the abandoning action with the listmanagedinstances method. If the group is part of a backend service that has enabled connection draining, it can take up to 60 seconds after the connection draining duration has elapsed before the VM instance is removed or deleted. You can specify a maximum of 1000 instances with this method per request. - * @alias compute.regionInstanceGroupManagers.abandonInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager Name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionInstanceGroupManagersAbandonInstancesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - abandonInstances( - params?: Params$Resource$Regioninstancegroupmanagers$Abandoninstances, - options?: MethodOptions - ): GaxiosPromise; - abandonInstances( - params: Params$Resource$Regioninstancegroupmanagers$Abandoninstances, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - abandonInstances( - params: Params$Resource$Regioninstancegroupmanagers$Abandoninstances, - callback: BodyResponseCallback - ): void; - abandonInstances(callback: BodyResponseCallback): void; - abandonInstances( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Abandoninstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Abandoninstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Abandoninstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/abandonInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.applyUpdatesToInstances - * @desc Apply updates to selected instances the managed instance group. - * @alias compute.regionInstanceGroupManagers.applyUpdatesToInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group, should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request, should conform to RFC1035. - * @param {().RegionInstanceGroupManagersApplyUpdatesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - applyUpdatesToInstances( - params?: Params$Resource$Regioninstancegroupmanagers$Applyupdatestoinstances, - options?: MethodOptions - ): GaxiosPromise; - applyUpdatesToInstances( - params: Params$Resource$Regioninstancegroupmanagers$Applyupdatestoinstances, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - applyUpdatesToInstances( - params: Params$Resource$Regioninstancegroupmanagers$Applyupdatestoinstances, - callback: BodyResponseCallback - ): void; - applyUpdatesToInstances( - callback: BodyResponseCallback - ): void; - applyUpdatesToInstances( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Applyupdatestoinstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Applyupdatestoinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Applyupdatestoinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/applyUpdatesToInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.createInstances - * @desc Creates instances with per-instance configs in this regional managed instance group. Instances are created using the current instance template. The create instances operation is marked DONE if the createInstances request is successful. The underlying actions take additional time. You must separately verify the status of the creating or actions with the listmanagedinstances method. - * @alias compute.regionInstanceGroupManagers.createInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. It should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region where the managed instance group is located. It should conform to RFC1035. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionInstanceGroupManagersCreateInstancesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - createInstances( - params?: Params$Resource$Regioninstancegroupmanagers$Createinstances, - options?: MethodOptions - ): GaxiosPromise; - createInstances( - params: Params$Resource$Regioninstancegroupmanagers$Createinstances, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - createInstances( - params: Params$Resource$Regioninstancegroupmanagers$Createinstances, - callback: BodyResponseCallback - ): void; - createInstances(callback: BodyResponseCallback): void; - createInstances( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Createinstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Createinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Createinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/createInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.delete - * @desc Deletes the specified managed instance group and all of the instances in that group. - * @alias compute.regionInstanceGroupManagers.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager Name of the managed instance group to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Regioninstancegroupmanagers$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Regioninstancegroupmanagers$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Regioninstancegroupmanagers$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.deleteInstances - * @desc Flags the specified instances in the managed instance group to be immediately deleted. The instances are also removed from any target pools of which they were a member. This method reduces the targetSize of the managed instance group by the number of instances that you delete. The deleteInstances operation is marked DONE if the deleteInstances request is successful. The underlying actions take additional time. You must separately verify the status of the deleting action with the listmanagedinstances method. If the group is part of a backend service that has enabled connection draining, it can take up to 60 seconds after the connection draining duration has elapsed before the VM instance is removed or deleted. You can specify a maximum of 1000 instances with this method per request. - * @alias compute.regionInstanceGroupManagers.deleteInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager Name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionInstanceGroupManagersDeleteInstancesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - deleteInstances( - params?: Params$Resource$Regioninstancegroupmanagers$Deleteinstances, - options?: MethodOptions - ): GaxiosPromise; - deleteInstances( - params: Params$Resource$Regioninstancegroupmanagers$Deleteinstances, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - deleteInstances( - params: Params$Resource$Regioninstancegroupmanagers$Deleteinstances, - callback: BodyResponseCallback - ): void; - deleteInstances(callback: BodyResponseCallback): void; - deleteInstances( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Deleteinstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Deleteinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Deleteinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/deleteInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.deletePerInstanceConfigs - * @desc Deletes selected per-instance configs for the managed instance group. - * @alias compute.regionInstanceGroupManagers.deletePerInstanceConfigs - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. It should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request, should conform to RFC1035. - * @param {().RegionInstanceGroupManagerDeleteInstanceConfigReq} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - deletePerInstanceConfigs( - params?: Params$Resource$Regioninstancegroupmanagers$Deleteperinstanceconfigs, - options?: MethodOptions - ): GaxiosPromise; - deletePerInstanceConfigs( - params: Params$Resource$Regioninstancegroupmanagers$Deleteperinstanceconfigs, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - deletePerInstanceConfigs( - params: Params$Resource$Regioninstancegroupmanagers$Deleteperinstanceconfigs, - callback: BodyResponseCallback - ): void; - deletePerInstanceConfigs( - callback: BodyResponseCallback - ): void; - deletePerInstanceConfigs( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Deleteperinstanceconfigs - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Deleteperinstanceconfigs; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Deleteperinstanceconfigs; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/deletePerInstanceConfigs' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.get - * @desc Returns all of the details about the specified managed instance group. - * @alias compute.regionInstanceGroupManagers.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager Name of the managed instance group to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regioninstancegroupmanagers$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regioninstancegroupmanagers$Get, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regioninstancegroupmanagers$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.insert - * @desc Creates a managed instance group using the information that you specify in the request. After the group is created, instances in the group are created using the specified instance template. This operation is marked as DONE when the group is created even if the instances in the group have not yet been created. You must separately verify the status of the individual instances with the listmanagedinstances method. A regional managed instance group can contain up to 2000 instances. - * @alias compute.regionInstanceGroupManagers.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().InstanceGroupManager} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Regioninstancegroupmanagers$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Regioninstancegroupmanagers$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Regioninstancegroupmanagers$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.list - * @desc Retrieves the list of managed instance groups that are contained within the specified region. - * @alias compute.regionInstanceGroupManagers.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regioninstancegroupmanagers$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regioninstancegroupmanagers$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regioninstancegroupmanagers$List, - callback: BodyResponseCallback - ): void; - list( - callback: BodyResponseCallback - ): void; - list( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.regionInstanceGroupManagers.listErrors - * @desc Lists all errors thrown by actions on instances for a given regional managed instance group. - * @alias compute.regionInstanceGroupManagers.listErrors - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {string} params.instanceGroupManager The name of the managed instance group. It must be a string that meets the requirements in RFC1035, or an unsigned long integer: must match regexp pattern: (?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?)|[1-9][0-9]{0,19}. - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. This should conform to RFC1035. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listErrors( - params?: Params$Resource$Regioninstancegroupmanagers$Listerrors, - options?: MethodOptions - ): GaxiosPromise; - listErrors( - params: Params$Resource$Regioninstancegroupmanagers$Listerrors, - options: - | MethodOptions - | BodyResponseCallback< - Schema$RegionInstanceGroupManagersListErrorsResponse - >, - callback: BodyResponseCallback< - Schema$RegionInstanceGroupManagersListErrorsResponse - > - ): void; - listErrors( - params: Params$Resource$Regioninstancegroupmanagers$Listerrors, - callback: BodyResponseCallback< - Schema$RegionInstanceGroupManagersListErrorsResponse - > - ): void; - listErrors( - callback: BodyResponseCallback< - Schema$RegionInstanceGroupManagersListErrorsResponse - > - ): void; - listErrors( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Listerrors - | BodyResponseCallback< - Schema$RegionInstanceGroupManagersListErrorsResponse - >, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback< - Schema$RegionInstanceGroupManagersListErrorsResponse - >, - callback?: BodyResponseCallback< - Schema$RegionInstanceGroupManagersListErrorsResponse - > - ): void | GaxiosPromise< - Schema$RegionInstanceGroupManagersListErrorsResponse - > { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Listerrors; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Listerrors; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/listErrors' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest< - Schema$RegionInstanceGroupManagersListErrorsResponse - >(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.listManagedInstances - * @desc Lists the instances in the managed instance group and instances that are scheduled to be created. The list includes any current actions that the group has scheduled for its instances. - * @alias compute.regionInstanceGroupManagers.listManagedInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {string} params.instanceGroupManager The name of the managed instance group. - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.order_by Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listManagedInstances( - params?: Params$Resource$Regioninstancegroupmanagers$Listmanagedinstances, - options?: MethodOptions - ): GaxiosPromise; - listManagedInstances( - params: Params$Resource$Regioninstancegroupmanagers$Listmanagedinstances, - options: - | MethodOptions - | BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstancesResponse - >, - callback: BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstancesResponse - > - ): void; - listManagedInstances( - params: Params$Resource$Regioninstancegroupmanagers$Listmanagedinstances, - callback: BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstancesResponse - > - ): void; - listManagedInstances( - callback: BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstancesResponse - > - ): void; - listManagedInstances( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Listmanagedinstances - | BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstancesResponse - >, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstancesResponse - >, - callback?: BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstancesResponse - > - ): void | GaxiosPromise< - Schema$RegionInstanceGroupManagersListInstancesResponse - > { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Listmanagedinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Listmanagedinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/listManagedInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest< - Schema$RegionInstanceGroupManagersListInstancesResponse - >(parameters, callback); - } else { - return createAPIRequest< - Schema$RegionInstanceGroupManagersListInstancesResponse - >(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.listPerInstanceConfigs - * @desc Lists all of the per-instance configs defined for the managed instance group. - * @alias compute.regionInstanceGroupManagers.listPerInstanceConfigs - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {string} params.instanceGroupManager The name of the managed instance group. It should conform to RFC1035. - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request, should conform to RFC1035. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listPerInstanceConfigs( - params?: Params$Resource$Regioninstancegroupmanagers$Listperinstanceconfigs, - options?: MethodOptions - ): GaxiosPromise; - listPerInstanceConfigs( - params: Params$Resource$Regioninstancegroupmanagers$Listperinstanceconfigs, - options: - | MethodOptions - | BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstanceConfigsResp - >, - callback: BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstanceConfigsResp - > - ): void; - listPerInstanceConfigs( - params: Params$Resource$Regioninstancegroupmanagers$Listperinstanceconfigs, - callback: BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstanceConfigsResp - > - ): void; - listPerInstanceConfigs( - callback: BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstanceConfigsResp - > - ): void; - listPerInstanceConfigs( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Listperinstanceconfigs - | BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstanceConfigsResp - >, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstanceConfigsResp - >, - callback?: BodyResponseCallback< - Schema$RegionInstanceGroupManagersListInstanceConfigsResp - > - ): void | GaxiosPromise< - Schema$RegionInstanceGroupManagersListInstanceConfigsResp - > { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Listperinstanceconfigs; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Listperinstanceconfigs; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/listPerInstanceConfigs' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest< - Schema$RegionInstanceGroupManagersListInstanceConfigsResp - >(parameters, callback); - } else { - return createAPIRequest< - Schema$RegionInstanceGroupManagersListInstanceConfigsResp - >(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.patch - * @desc Updates a managed instance group using the information that you specify in the request. This operation is marked as DONE when the group is patched even if the instances in the group are still in the process of being patched. You must separately verify the status of the individual instances with the listmanagedinstances method. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.regionInstanceGroupManagers.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the instance group manager. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().InstanceGroupManager} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Regioninstancegroupmanagers$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Regioninstancegroupmanagers$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Regioninstancegroupmanagers$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.patchPerInstanceConfigs - * @desc Insert or patch (for the ones that already exist) per-instance configs for the managed instance group. perInstanceConfig.instance serves as a key used to distinguish whether to perform insert or patch. - * @alias compute.regionInstanceGroupManagers.patchPerInstanceConfigs - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. It should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request, should conform to RFC1035. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionInstanceGroupManagerPatchInstanceConfigReq} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patchPerInstanceConfigs( - params?: Params$Resource$Regioninstancegroupmanagers$Patchperinstanceconfigs, - options?: MethodOptions - ): GaxiosPromise; - patchPerInstanceConfigs( - params: Params$Resource$Regioninstancegroupmanagers$Patchperinstanceconfigs, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patchPerInstanceConfigs( - params: Params$Resource$Regioninstancegroupmanagers$Patchperinstanceconfigs, - callback: BodyResponseCallback - ): void; - patchPerInstanceConfigs( - callback: BodyResponseCallback - ): void; - patchPerInstanceConfigs( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Patchperinstanceconfigs - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Patchperinstanceconfigs; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Patchperinstanceconfigs; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/patchPerInstanceConfigs' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.recreateInstances - * @desc Flags the specified instances in the managed instance group to be immediately recreated. The instances are deleted and recreated using the current instance template for the managed instance group. This operation is marked as DONE when the flag is set even if the instances have not yet been recreated. You must separately verify the status of the recreating action with the listmanagedinstances method. If the group is part of a backend service that has enabled connection draining, it can take up to 60 seconds after the connection draining duration has elapsed before the VM instance is removed or deleted. You can specify a maximum of 1000 instances with this method per request. - * @alias compute.regionInstanceGroupManagers.recreateInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager Name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionInstanceGroupManagersRecreateRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - recreateInstances( - params?: Params$Resource$Regioninstancegroupmanagers$Recreateinstances, - options?: MethodOptions - ): GaxiosPromise; - recreateInstances( - params: Params$Resource$Regioninstancegroupmanagers$Recreateinstances, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - recreateInstances( - params: Params$Resource$Regioninstancegroupmanagers$Recreateinstances, - callback: BodyResponseCallback - ): void; - recreateInstances(callback: BodyResponseCallback): void; - recreateInstances( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Recreateinstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Recreateinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Recreateinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/recreateInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.resize - * @desc Changes the intended size of the managed instance group. If you increase the size, the group creates new instances using the current instance template. If you decrease the size, the group deletes one or more instances. The resize operation is marked DONE if the resize request is successful. The underlying actions take additional time. You must separately verify the status of the creating or deleting actions with the listmanagedinstances method. If the group is part of a backend service that has enabled connection draining, it can take up to 60 seconds after the connection draining duration has elapsed before the VM instance is removed or deleted. - * @alias compute.regionInstanceGroupManagers.resize - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager Name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {integer} params.size Number of instances that should exist in this instance group manager. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - resize( - params?: Params$Resource$Regioninstancegroupmanagers$Resize, - options?: MethodOptions - ): GaxiosPromise; - resize( - params: Params$Resource$Regioninstancegroupmanagers$Resize, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - resize( - params: Params$Resource$Regioninstancegroupmanagers$Resize, - callback: BodyResponseCallback - ): void; - resize(callback: BodyResponseCallback): void; - resize( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Resize - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Resize; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Resize; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/resize' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager', 'size'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.setAutoHealingPolicies - * @desc Modifies the autohealing policy for the instances in this managed instance group. [Deprecated] This method is deprecated. Please use Patch instead. - * @alias compute.regionInstanceGroupManagers.setAutoHealingPolicies - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager Name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionInstanceGroupManagersSetAutoHealingRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setAutoHealingPolicies( - params?: Params$Resource$Regioninstancegroupmanagers$Setautohealingpolicies, - options?: MethodOptions - ): GaxiosPromise; - setAutoHealingPolicies( - params: Params$Resource$Regioninstancegroupmanagers$Setautohealingpolicies, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setAutoHealingPolicies( - params: Params$Resource$Regioninstancegroupmanagers$Setautohealingpolicies, - callback: BodyResponseCallback - ): void; - setAutoHealingPolicies( - callback: BodyResponseCallback - ): void; - setAutoHealingPolicies( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Setautohealingpolicies - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Setautohealingpolicies; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Setautohealingpolicies; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/setAutoHealingPolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.setInstanceTemplate - * @desc Sets the instance template to use when creating new instances or recreating instances in this group. Existing instances are not affected. - * @alias compute.regionInstanceGroupManagers.setInstanceTemplate - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionInstanceGroupManagersSetTemplateRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setInstanceTemplate( - params?: Params$Resource$Regioninstancegroupmanagers$Setinstancetemplate, - options?: MethodOptions - ): GaxiosPromise; - setInstanceTemplate( - params: Params$Resource$Regioninstancegroupmanagers$Setinstancetemplate, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setInstanceTemplate( - params: Params$Resource$Regioninstancegroupmanagers$Setinstancetemplate, - callback: BodyResponseCallback - ): void; - setInstanceTemplate(callback: BodyResponseCallback): void; - setInstanceTemplate( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Setinstancetemplate - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Setinstancetemplate; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Setinstancetemplate; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/setInstanceTemplate' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.setTargetPools - * @desc Modifies the target pools to which all new instances in this group are assigned. Existing instances in the group are not affected. - * @alias compute.regionInstanceGroupManagers.setTargetPools - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager Name of the managed instance group. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionInstanceGroupManagersSetTargetPoolsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setTargetPools( - params?: Params$Resource$Regioninstancegroupmanagers$Settargetpools, - options?: MethodOptions - ): GaxiosPromise; - setTargetPools( - params: Params$Resource$Regioninstancegroupmanagers$Settargetpools, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setTargetPools( - params: Params$Resource$Regioninstancegroupmanagers$Settargetpools, - callback: BodyResponseCallback - ): void; - setTargetPools(callback: BodyResponseCallback): void; - setTargetPools( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Settargetpools - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Settargetpools; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Settargetpools; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/setTargetPools' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.regionInstanceGroupManagers.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regioninstancegroupmanagers$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regioninstancegroupmanagers$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regioninstancegroupmanagers$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.update - * @desc Updates a managed instance group using the information that you specify in the request. This operation is marked as DONE when the group is updated even if the instances in the group have not yet been updated. You must separately verify the status of the individual instances with the listmanagedinstances method. - * @alias compute.regionInstanceGroupManagers.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the instance group manager. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().InstanceGroupManager} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Regioninstancegroupmanagers$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Regioninstancegroupmanagers$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Regioninstancegroupmanagers$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroupManagers.updatePerInstanceConfigs - * @desc Insert or update (for the ones that already exist) per-instance configs for the managed instance group. perInstanceConfig.instance serves as a key used to distinguish whether to perform insert or patch. - * @alias compute.regionInstanceGroupManagers.updatePerInstanceConfigs - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroupManager The name of the managed instance group. It should conform to RFC1035. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request, should conform to RFC1035. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionInstanceGroupManagerUpdateInstanceConfigReq} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - updatePerInstanceConfigs( - params?: Params$Resource$Regioninstancegroupmanagers$Updateperinstanceconfigs, - options?: MethodOptions - ): GaxiosPromise; - updatePerInstanceConfigs( - params: Params$Resource$Regioninstancegroupmanagers$Updateperinstanceconfigs, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - updatePerInstanceConfigs( - params: Params$Resource$Regioninstancegroupmanagers$Updateperinstanceconfigs, - callback: BodyResponseCallback - ): void; - updatePerInstanceConfigs( - callback: BodyResponseCallback - ): void; - updatePerInstanceConfigs( - paramsOrCallback?: - | Params$Resource$Regioninstancegroupmanagers$Updateperinstanceconfigs - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroupmanagers$Updateperinstanceconfigs; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroupmanagers$Updateperinstanceconfigs; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroupManagers/{instanceGroupManager}/updatePerInstanceConfigs' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroupManager'], - pathParams: ['instanceGroupManager', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regioninstancegroupmanagers$Abandoninstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupManagersAbandonInstancesRequest; - } - export interface Params$Resource$Regioninstancegroupmanagers$Applyupdatestoinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group, should conform to RFC1035. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request, should conform to RFC1035. - */ - region?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupManagersApplyUpdatesRequest; - } - export interface Params$Resource$Regioninstancegroupmanagers$Createinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. It should conform to RFC1035. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region where the managed instance group is located. It should conform to RFC1035. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupManagersCreateInstancesRequest; - } - export interface Params$Resource$Regioninstancegroupmanagers$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the managed instance group to delete. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Regioninstancegroupmanagers$Deleteinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupManagersDeleteInstancesRequest; - } - export interface Params$Resource$Regioninstancegroupmanagers$Deleteperinstanceconfigs - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. It should conform to RFC1035. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request, should conform to RFC1035. - */ - region?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupManagerDeleteInstanceConfigReq; - } - export interface Params$Resource$Regioninstancegroupmanagers$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the managed instance group to return. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regioninstancegroupmanagers$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManager; - } - export interface Params$Resource$Regioninstancegroupmanagers$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regioninstancegroupmanagers$Listerrors - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The name of the managed instance group. It must be a string that meets the requirements in RFC1035, or an unsigned long integer: must match regexp pattern: (?:[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?)|[1-9][0-9]{0,19}. - */ - instanceGroupManager?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. This should conform to RFC1035. - */ - region?: string; - } - export interface Params$Resource$Regioninstancegroupmanagers$Listmanagedinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - order_by?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regioninstancegroupmanagers$Listperinstanceconfigs - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The name of the managed instance group. It should conform to RFC1035. - */ - instanceGroupManager?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request, should conform to RFC1035. - */ - region?: string; - } - export interface Params$Resource$Regioninstancegroupmanagers$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the instance group manager. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManager; - } - export interface Params$Resource$Regioninstancegroupmanagers$Patchperinstanceconfigs - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. It should conform to RFC1035. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request, should conform to RFC1035. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupManagerPatchInstanceConfigReq; - } - export interface Params$Resource$Regioninstancegroupmanagers$Recreateinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupManagersRecreateRequest; - } - export interface Params$Resource$Regioninstancegroupmanagers$Resize - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Number of instances that should exist in this instance group manager. - */ - size?: number; - } - export interface Params$Resource$Regioninstancegroupmanagers$Setautohealingpolicies - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupManagersSetAutoHealingRequest; - } - export interface Params$Resource$Regioninstancegroupmanagers$Setinstancetemplate - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupManagersSetTemplateRequest; - } - export interface Params$Resource$Regioninstancegroupmanagers$Settargetpools - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the managed instance group. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupManagersSetTargetPoolsRequest; - } - export interface Params$Resource$Regioninstancegroupmanagers$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Regioninstancegroupmanagers$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the instance group manager. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceGroupManager; - } - export interface Params$Resource$Regioninstancegroupmanagers$Updateperinstanceconfigs - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the managed instance group. It should conform to RFC1035. - */ - instanceGroupManager?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request, should conform to RFC1035. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupManagerUpdateInstanceConfigReq; - } - - export class Resource$Regioninstancegroups { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionInstanceGroups.get - * @desc Returns the specified instance group resource. - * @alias compute.regionInstanceGroups.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroup Name of the instance group resource to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regioninstancegroups$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regioninstancegroups$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regioninstancegroups$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regioninstancegroups$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroups$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroups$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroups/{instanceGroup}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroup'], - pathParams: ['instanceGroup', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroups.list - * @desc Retrieves the list of instance group resources contained within the specified region. - * @alias compute.regionInstanceGroups.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regioninstancegroups$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regioninstancegroups$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regioninstancegroups$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regioninstancegroups$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroups$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroups$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroups' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroups.listInstances - * @desc Lists the instances in the specified instance group and displays information about the named ports. Depending on the specified options, this method can list all instances or only the instances that are running. - * @alias compute.regionInstanceGroups.listInstances - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {string} params.instanceGroup Name of the regional instance group for which we want to list the instances. - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {().RegionInstanceGroupsListInstancesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listInstances( - params?: Params$Resource$Regioninstancegroups$Listinstances, - options?: MethodOptions - ): GaxiosPromise; - listInstances( - params: Params$Resource$Regioninstancegroups$Listinstances, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - listInstances( - params: Params$Resource$Regioninstancegroups$Listinstances, - callback: BodyResponseCallback - ): void; - listInstances( - callback: BodyResponseCallback - ): void; - listInstances( - paramsOrCallback?: - | Params$Resource$Regioninstancegroups$Listinstances - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroups$Listinstances; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroups$Listinstances; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroups/{instanceGroup}/listInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroup'], - pathParams: ['instanceGroup', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.regionInstanceGroups.setNamedPorts - * @desc Sets the named ports for the specified regional instance group. - * @alias compute.regionInstanceGroups.setNamedPorts - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.instanceGroup The name of the regional instance group where the named ports are updated. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().RegionInstanceGroupsSetNamedPortsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setNamedPorts( - params?: Params$Resource$Regioninstancegroups$Setnamedports, - options?: MethodOptions - ): GaxiosPromise; - setNamedPorts( - params: Params$Resource$Regioninstancegroups$Setnamedports, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setNamedPorts( - params: Params$Resource$Regioninstancegroups$Setnamedports, - callback: BodyResponseCallback - ): void; - setNamedPorts(callback: BodyResponseCallback): void; - setNamedPorts( - paramsOrCallback?: - | Params$Resource$Regioninstancegroups$Setnamedports - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroups$Setnamedports; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroups$Setnamedports; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroups/{instanceGroup}/setNamedPorts' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'instanceGroup'], - pathParams: ['instanceGroup', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionInstanceGroups.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.regionInstanceGroups.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regioninstancegroups$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regioninstancegroups$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regioninstancegroups$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regioninstancegroups$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regioninstancegroups$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regioninstancegroups$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/instanceGroups/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regioninstancegroups$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the instance group resource to return. - */ - instanceGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regioninstancegroups$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regioninstancegroups$Listinstances - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * Name of the regional instance group for which we want to list the instances. - */ - instanceGroup?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupsListInstancesRequest; - } - export interface Params$Resource$Regioninstancegroups$Setnamedports - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the regional instance group where the named ports are updated. - */ - instanceGroup?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionInstanceGroupsSetNamedPortsRequest; - } - export interface Params$Resource$Regioninstancegroups$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Regionnotificationendpoints { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionNotificationEndpoints.delete - * @desc Deletes the specified NotificationEndpoint in the given region - * @alias compute.regionNotificationEndpoints.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.notificationEndpoint Name of the NotificationEndpoint resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Regionnotificationendpoints$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Regionnotificationendpoints$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Regionnotificationendpoints$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Regionnotificationendpoints$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionnotificationendpoints$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionnotificationendpoints$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/notificationEndpoints/{notificationEndpoint}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'notificationEndpoint'], - pathParams: ['notificationEndpoint', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionNotificationEndpoints.get - * @desc Returns the specified NotificationEndpoint resource in the given region. - * @alias compute.regionNotificationEndpoints.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.notificationEndpoint Name of the NotificationEndpoint resource to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regionnotificationendpoints$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regionnotificationendpoints$Get, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regionnotificationendpoints$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regionnotificationendpoints$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionnotificationendpoints$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionnotificationendpoints$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/notificationEndpoints/{notificationEndpoint}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'notificationEndpoint'], - pathParams: ['notificationEndpoint', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionNotificationEndpoints.insert - * @desc Create a NotificationEndpoint in the specified project in the given region using the parameters that are included in the request. - * @alias compute.regionNotificationEndpoints.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().NotificationEndpoint} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Regionnotificationendpoints$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Regionnotificationendpoints$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Regionnotificationendpoints$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Regionnotificationendpoints$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionnotificationendpoints$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionnotificationendpoints$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/notificationEndpoints' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionNotificationEndpoints.list - * @desc Lists the NotificationEndpoints for a project in the given region. - * @alias compute.regionNotificationEndpoints.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regionnotificationendpoints$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regionnotificationendpoints$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regionnotificationendpoints$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regionnotificationendpoints$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionnotificationendpoints$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionnotificationendpoints$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/notificationEndpoints' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionNotificationEndpoints.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.regionNotificationEndpoints.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regionnotificationendpoints$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regionnotificationendpoints$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regionnotificationendpoints$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regionnotificationendpoints$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionnotificationendpoints$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionnotificationendpoints$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/notificationEndpoints/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regionnotificationendpoints$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the NotificationEndpoint resource to delete. - */ - notificationEndpoint?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - } - export interface Params$Resource$Regionnotificationendpoints$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the NotificationEndpoint resource to return. - */ - notificationEndpoint?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regionnotificationendpoints$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$NotificationEndpoint; - } - export interface Params$Resource$Regionnotificationendpoints$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regionnotificationendpoints$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Regionoperations { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionOperations.delete - * @desc Deletes the specified region-specific Operations resource. - * @alias compute.regionOperations.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.operation Name of the Operations resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Regionoperations$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Regionoperations$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Regionoperations$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Regionoperations$Delete - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionoperations$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionoperations$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/operations/{operation}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'operation'], - pathParams: ['operation', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionOperations.get - * @desc Retrieves the specified region-specific Operations resource. - * @alias compute.regionOperations.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.operation Name of the Operations resource to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regionoperations$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regionoperations$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regionoperations$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regionoperations$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionoperations$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionoperations$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/operations/{operation}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'operation'], - pathParams: ['operation', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionOperations.list - * @desc Retrieves a list of Operation resources contained within the specified region. - * @alias compute.regionOperations.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regionoperations$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regionoperations$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regionoperations$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regionoperations$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionoperations$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionoperations$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/operations' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionOperations.wait - * @desc Waits for the specified region-specific Operations resource until it is done or timeout, and retrieves the specified Operations resource. 1. Immediately returns when the operation is already done. 2. Waits for no more than the default deadline (2 minutes, subject to change) and then returns the current state of the operation, which may be DONE or still in progress. 3. Is best-effort: a. The server can wait less than the default deadline or zero seconds, in overload situations. b. There is no guarantee that the operation is actually done when returns. 4. User should be prepared to retry if the operation is not DONE. - * @alias compute.regionOperations.wait - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.operation Name of the Operations resource to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - wait( - params?: Params$Resource$Regionoperations$Wait, - options?: MethodOptions - ): GaxiosPromise; - wait( - params: Params$Resource$Regionoperations$Wait, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - wait( - params: Params$Resource$Regionoperations$Wait, - callback: BodyResponseCallback - ): void; - wait(callback: BodyResponseCallback): void; - wait( - paramsOrCallback?: - | Params$Resource$Regionoperations$Wait - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionoperations$Wait; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionoperations$Wait; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/operations/{operation}/wait' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'operation'], - pathParams: ['operation', 'project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regionoperations$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the Operations resource to delete. - */ - operation?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Regionoperations$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the Operations resource to return. - */ - operation?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Regionoperations$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Regionoperations$Wait - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the Operations resource to return. - */ - operation?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - - export class Resource$Regions { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regions.get - * @desc Returns the specified Region resource. Gets a list of available regions by making a list() request. - * @alias compute.regions.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regions$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regions$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regions$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regions$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Regions$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regions$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/regions/{region}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regions.list - * @desc Retrieves the list of region resources available to the specified project. - * @alias compute.regions.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regions$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regions$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regions$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regions$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Regions$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regions$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/regions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regions$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region resource to return. - */ - region?: string; - } - export interface Params$Resource$Regions$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - - export class Resource$Regionsslcertificates { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionSslCertificates.delete - * @desc Deletes the specified SslCertificate resource in the region. - * @alias compute.regionSslCertificates.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.sslCertificate Name of the SslCertificate resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Regionsslcertificates$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Regionsslcertificates$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Regionsslcertificates$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Regionsslcertificates$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionsslcertificates$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionsslcertificates$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/sslCertificates/{sslCertificate}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'sslCertificate'], - pathParams: ['project', 'region', 'sslCertificate'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionSslCertificates.get - * @desc Returns the specified SslCertificate resource in the specified region. Get a list of available SSL certificates by making a list() request. - * @alias compute.regionSslCertificates.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string} params.sslCertificate Name of the SslCertificate resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regionsslcertificates$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regionsslcertificates$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regionsslcertificates$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regionsslcertificates$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionsslcertificates$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionsslcertificates$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/sslCertificates/{sslCertificate}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'sslCertificate'], - pathParams: ['project', 'region', 'sslCertificate'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionSslCertificates.insert - * @desc Creates a SslCertificate resource in the specified project and region using the data included in the request - * @alias compute.regionSslCertificates.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().SslCertificate} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Regionsslcertificates$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Regionsslcertificates$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Regionsslcertificates$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Regionsslcertificates$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionsslcertificates$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionsslcertificates$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/sslCertificates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionSslCertificates.list - * @desc Retrieves the list of SslCertificate resources available to the specified project in the specified region. - * @alias compute.regionSslCertificates.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regionsslcertificates$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regionsslcertificates$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regionsslcertificates$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regionsslcertificates$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionsslcertificates$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionsslcertificates$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/sslCertificates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionSslCertificates.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource and region. - * @alias compute.regionSslCertificates.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regionsslcertificates$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regionsslcertificates$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regionsslcertificates$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regionsslcertificates$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionsslcertificates$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionsslcertificates$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/sslCertificates/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regionsslcertificates$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the SslCertificate resource to delete. - */ - sslCertificate?: string; - } - export interface Params$Resource$Regionsslcertificates$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * Name of the SslCertificate resource to return. - */ - sslCertificate?: string; - } - export interface Params$Resource$Regionsslcertificates$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SslCertificate; - } - export interface Params$Resource$Regionsslcertificates$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regionsslcertificates$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Regiontargethttpproxies { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionTargetHttpProxies.delete - * @desc Deletes the specified TargetHttpProxy resource. - * @alias compute.regionTargetHttpProxies.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetHttpProxy Name of the TargetHttpProxy resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Regiontargethttpproxies$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Regiontargethttpproxies$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Regiontargethttpproxies$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Regiontargethttpproxies$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpproxies$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpproxies$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpProxies/{targetHttpProxy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetHttpProxy'], - pathParams: ['project', 'region', 'targetHttpProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionTargetHttpProxies.get - * @desc Returns the specified TargetHttpProxy resource in the specified region. Gets a list of available target HTTP proxies by making a list() request. - * @alias compute.regionTargetHttpProxies.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string} params.targetHttpProxy Name of the TargetHttpProxy resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regiontargethttpproxies$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regiontargethttpproxies$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regiontargethttpproxies$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regiontargethttpproxies$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpproxies$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpproxies$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpProxies/{targetHttpProxy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetHttpProxy'], - pathParams: ['project', 'region', 'targetHttpProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionTargetHttpProxies.insert - * @desc Creates a TargetHttpProxy resource in the specified project and region using the data included in the request. - * @alias compute.regionTargetHttpProxies.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().TargetHttpProxy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Regiontargethttpproxies$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Regiontargethttpproxies$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Regiontargethttpproxies$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Regiontargethttpproxies$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpproxies$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpproxies$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionTargetHttpProxies.list - * @desc Retrieves the list of TargetHttpProxy resources available to the specified project in the specified region. - * @alias compute.regionTargetHttpProxies.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regiontargethttpproxies$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regiontargethttpproxies$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regiontargethttpproxies$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regiontargethttpproxies$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpproxies$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpproxies$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionTargetHttpProxies.setUrlMap - * @desc Changes the URL map for TargetHttpProxy. - * @alias compute.regionTargetHttpProxies.setUrlMap - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetHttpProxy Name of the TargetHttpProxy to set a URL map for. - * @param {().UrlMapReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setUrlMap( - params?: Params$Resource$Regiontargethttpproxies$Seturlmap, - options?: MethodOptions - ): GaxiosPromise; - setUrlMap( - params: Params$Resource$Regiontargethttpproxies$Seturlmap, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setUrlMap( - params: Params$Resource$Regiontargethttpproxies$Seturlmap, - callback: BodyResponseCallback - ): void; - setUrlMap(callback: BodyResponseCallback): void; - setUrlMap( - paramsOrCallback?: - | Params$Resource$Regiontargethttpproxies$Seturlmap - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpproxies$Seturlmap; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpproxies$Seturlmap; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpProxies/{targetHttpProxy}/setUrlMap' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetHttpProxy'], - pathParams: ['project', 'region', 'targetHttpProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionTargetHttpProxies.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.regionTargetHttpProxies.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regiontargethttpproxies$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regiontargethttpproxies$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regiontargethttpproxies$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regiontargethttpproxies$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpproxies$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpproxies$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpProxies/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regiontargethttpproxies$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetHttpProxy resource to delete. - */ - targetHttpProxy?: string; - } - export interface Params$Resource$Regiontargethttpproxies$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * Name of the TargetHttpProxy resource to return. - */ - targetHttpProxy?: string; - } - export interface Params$Resource$Regiontargethttpproxies$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetHttpProxy; - } - export interface Params$Resource$Regiontargethttpproxies$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regiontargethttpproxies$Seturlmap - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetHttpProxy to set a URL map for. - */ - targetHttpProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$UrlMapReference; - } - export interface Params$Resource$Regiontargethttpproxies$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Regiontargethttpsproxies { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionTargetHttpsProxies.delete - * @desc Deletes the specified TargetHttpsProxy resource. - * @alias compute.regionTargetHttpsProxies.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetHttpsProxy Name of the TargetHttpsProxy resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Regiontargethttpsproxies$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Regiontargethttpsproxies$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Regiontargethttpsproxies$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Regiontargethttpsproxies$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpsproxies$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpsproxies$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpsProxies/{targetHttpsProxy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetHttpsProxy'], - pathParams: ['project', 'region', 'targetHttpsProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionTargetHttpsProxies.get - * @desc Returns the specified TargetHttpsProxy resource in the specified region. Gets a list of available target HTTP proxies by making a list() request. - * @alias compute.regionTargetHttpsProxies.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string} params.targetHttpsProxy Name of the TargetHttpsProxy resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regiontargethttpsproxies$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regiontargethttpsproxies$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regiontargethttpsproxies$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regiontargethttpsproxies$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpsproxies$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpsproxies$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpsProxies/{targetHttpsProxy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetHttpsProxy'], - pathParams: ['project', 'region', 'targetHttpsProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionTargetHttpsProxies.insert - * @desc Creates a TargetHttpsProxy resource in the specified project and region using the data included in the request. - * @alias compute.regionTargetHttpsProxies.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().TargetHttpsProxy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Regiontargethttpsproxies$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Regiontargethttpsproxies$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Regiontargethttpsproxies$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Regiontargethttpsproxies$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpsproxies$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpsproxies$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpsProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionTargetHttpsProxies.list - * @desc Retrieves the list of TargetHttpsProxy resources available to the specified project in the specified region. - * @alias compute.regionTargetHttpsProxies.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regiontargethttpsproxies$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regiontargethttpsproxies$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regiontargethttpsproxies$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regiontargethttpsproxies$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpsproxies$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpsproxies$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpsProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionTargetHttpsProxies.setSslCertificates - * @desc Replaces SslCertificates for TargetHttpsProxy. - * @alias compute.regionTargetHttpsProxies.setSslCertificates - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetHttpsProxy Name of the TargetHttpsProxy resource to set an SslCertificates resource for. - * @param {().RegionTargetHttpsProxiesSetSslCertificatesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setSslCertificates( - params?: Params$Resource$Regiontargethttpsproxies$Setsslcertificates, - options?: MethodOptions - ): GaxiosPromise; - setSslCertificates( - params: Params$Resource$Regiontargethttpsproxies$Setsslcertificates, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setSslCertificates( - params: Params$Resource$Regiontargethttpsproxies$Setsslcertificates, - callback: BodyResponseCallback - ): void; - setSslCertificates(callback: BodyResponseCallback): void; - setSslCertificates( - paramsOrCallback?: - | Params$Resource$Regiontargethttpsproxies$Setsslcertificates - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpsproxies$Setsslcertificates; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpsproxies$Setsslcertificates; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpsProxies/{targetHttpsProxy}/setSslCertificates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetHttpsProxy'], - pathParams: ['project', 'region', 'targetHttpsProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionTargetHttpsProxies.setUrlMap - * @desc Changes the URL map for TargetHttpsProxy. - * @alias compute.regionTargetHttpsProxies.setUrlMap - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetHttpsProxy Name of the TargetHttpsProxy to set a URL map for. - * @param {().UrlMapReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setUrlMap( - params?: Params$Resource$Regiontargethttpsproxies$Seturlmap, - options?: MethodOptions - ): GaxiosPromise; - setUrlMap( - params: Params$Resource$Regiontargethttpsproxies$Seturlmap, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setUrlMap( - params: Params$Resource$Regiontargethttpsproxies$Seturlmap, - callback: BodyResponseCallback - ): void; - setUrlMap(callback: BodyResponseCallback): void; - setUrlMap( - paramsOrCallback?: - | Params$Resource$Regiontargethttpsproxies$Seturlmap - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpsproxies$Seturlmap; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpsproxies$Seturlmap; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpsProxies/{targetHttpsProxy}/setUrlMap' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetHttpsProxy'], - pathParams: ['project', 'region', 'targetHttpsProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionTargetHttpsProxies.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.regionTargetHttpsProxies.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regiontargethttpsproxies$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regiontargethttpsproxies$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regiontargethttpsproxies$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regiontargethttpsproxies$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regiontargethttpsproxies$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regiontargethttpsproxies$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetHttpsProxies/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regiontargethttpsproxies$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetHttpsProxy resource to delete. - */ - targetHttpsProxy?: string; - } - export interface Params$Resource$Regiontargethttpsproxies$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * Name of the TargetHttpsProxy resource to return. - */ - targetHttpsProxy?: string; - } - export interface Params$Resource$Regiontargethttpsproxies$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetHttpsProxy; - } - export interface Params$Resource$Regiontargethttpsproxies$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regiontargethttpsproxies$Setsslcertificates - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetHttpsProxy resource to set an SslCertificates resource for. - */ - targetHttpsProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionTargetHttpsProxiesSetSslCertificatesRequest; - } - export interface Params$Resource$Regiontargethttpsproxies$Seturlmap - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetHttpsProxy to set a URL map for. - */ - targetHttpsProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$UrlMapReference; - } - export interface Params$Resource$Regiontargethttpsproxies$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Regionurlmaps { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.regionUrlMaps.delete - * @desc Deletes the specified UrlMap resource. - * @alias compute.regionUrlMaps.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. - * @param {string} params.urlMap Name of the UrlMap resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Regionurlmaps$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Regionurlmaps$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Regionurlmaps$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Regionurlmaps$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionurlmaps$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionurlmaps$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/urlMaps/{urlMap}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'urlMap'], - pathParams: ['project', 'region', 'urlMap'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionUrlMaps.get - * @desc Returns the specified UrlMap resource. Gets a list of available URL maps by making a list() request. - * @alias compute.regionUrlMaps.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string} params.urlMap Name of the UrlMap resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Regionurlmaps$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Regionurlmaps$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Regionurlmaps$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Regionurlmaps$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionurlmaps$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionurlmaps$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/urlMaps/{urlMap}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'urlMap'], - pathParams: ['project', 'region', 'urlMap'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionUrlMaps.insert - * @desc Creates a UrlMap resource in the specified project using the data included in the request. - * @alias compute.regionUrlMaps.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. - * @param {().UrlMap} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Regionurlmaps$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Regionurlmaps$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Regionurlmaps$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Regionurlmaps$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionurlmaps$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionurlmaps$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/urlMaps' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionUrlMaps.invalidateCache - * @desc Initiates a cache invalidation operation, invalidating the specified path, scoped to the specified UrlMap. - * @alias compute.regionUrlMaps.invalidateCache - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. - * @param {string} params.urlMap Name of the UrlMap scoping this request. - * @param {().CacheInvalidationRule} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - invalidateCache( - params?: Params$Resource$Regionurlmaps$Invalidatecache, - options?: MethodOptions - ): GaxiosPromise; - invalidateCache( - params: Params$Resource$Regionurlmaps$Invalidatecache, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - invalidateCache( - params: Params$Resource$Regionurlmaps$Invalidatecache, - callback: BodyResponseCallback - ): void; - invalidateCache(callback: BodyResponseCallback): void; - invalidateCache( - paramsOrCallback?: - | Params$Resource$Regionurlmaps$Invalidatecache - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionurlmaps$Invalidatecache; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionurlmaps$Invalidatecache; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/urlMaps/{urlMap}/invalidateCache' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'urlMap'], - pathParams: ['project', 'region', 'urlMap'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionUrlMaps.list - * @desc Retrieves the list of UrlMap resources available to the specified project in the specified region. - * @alias compute.regionUrlMaps.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Regionurlmaps$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Regionurlmaps$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Regionurlmaps$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Regionurlmaps$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionurlmaps$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionurlmaps$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/urlMaps' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionUrlMaps.patch - * @desc Patches the specified UrlMap resource with the data included in the request. This method supports PATCH semantics and uses JSON merge patch format and processing rules. - * @alias compute.regionUrlMaps.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. - * @param {string} params.urlMap Name of the UrlMap resource to patch. - * @param {().UrlMap} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Regionurlmaps$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Regionurlmaps$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Regionurlmaps$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Regionurlmaps$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionurlmaps$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionurlmaps$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/urlMaps/{urlMap}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'region', 'urlMap'], - pathParams: ['project', 'region', 'urlMap'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionUrlMaps.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.regionUrlMaps.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Regionurlmaps$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Regionurlmaps$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Regionurlmaps$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Regionurlmaps$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionurlmaps$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionurlmaps$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/urlMaps/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionUrlMaps.update - * @desc Updates the specified UrlMap resource with the data included in the request. - * @alias compute.regionUrlMaps.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. - * @param {string} params.urlMap Name of the UrlMap resource to update. - * @param {().UrlMap} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Regionurlmaps$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Regionurlmaps$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Regionurlmaps$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Regionurlmaps$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionurlmaps$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionurlmaps$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/urlMaps/{urlMap}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'region', 'urlMap'], - pathParams: ['project', 'region', 'urlMap'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.regionUrlMaps.validate - * @desc Runs static validation for the UrlMap. In particular, the tests of the provided UrlMap will be run. Calling this method does NOT create the UrlMap. - * @alias compute.regionUrlMaps.validate - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string} params.urlMap Name of the UrlMap resource to be validated as. - * @param {().RegionUrlMapsValidateRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - validate( - params?: Params$Resource$Regionurlmaps$Validate, - options?: MethodOptions - ): GaxiosPromise; - validate( - params: Params$Resource$Regionurlmaps$Validate, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - validate( - params: Params$Resource$Regionurlmaps$Validate, - callback: BodyResponseCallback - ): void; - validate( - callback: BodyResponseCallback - ): void; - validate( - paramsOrCallback?: - | Params$Resource$Regionurlmaps$Validate - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Regionurlmaps$Validate; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Regionurlmaps$Validate; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/urlMaps/{urlMap}/validate' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'urlMap'], - pathParams: ['project', 'region', 'urlMap'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Regionurlmaps$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. - */ - requestId?: string; - /** - * Name of the UrlMap resource to delete. - */ - urlMap?: string; - } - export interface Params$Resource$Regionurlmaps$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * Name of the UrlMap resource to return. - */ - urlMap?: string; - } - export interface Params$Resource$Regionurlmaps$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$UrlMap; - } - export interface Params$Resource$Regionurlmaps$Invalidatecache - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. - */ - requestId?: string; - /** - * Name of the UrlMap scoping this request. - */ - urlMap?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$CacheInvalidationRule; - } - export interface Params$Resource$Regionurlmaps$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Regionurlmaps$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. - */ - requestId?: string; - /** - * Name of the UrlMap resource to patch. - */ - urlMap?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$UrlMap; - } - export interface Params$Resource$Regionurlmaps$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Regionurlmaps$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. - */ - requestId?: string; - /** - * Name of the UrlMap resource to update. - */ - urlMap?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$UrlMap; - } - export interface Params$Resource$Regionurlmaps$Validate - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * Name of the UrlMap resource to be validated as. - */ - urlMap?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionUrlMapsValidateRequest; - } - - export class Resource$Reservations { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.reservations.aggregatedList - * @desc Retrieves an aggregated list of reservations. - * @alias compute.reservations.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Reservations$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Reservations$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Reservations$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Reservations$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Reservations$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Reservations$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/reservations' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.reservations.delete - * @desc Deletes the specified reservation. - * @alias compute.reservations.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.reservation Name of the reservation to delete. - * @param {string} params.zone Name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Reservations$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Reservations$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Reservations$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Reservations$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Reservations$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Reservations$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/reservations/{reservation}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'reservation'], - pathParams: ['project', 'reservation', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.reservations.get - * @desc Retrieves all information of the specified reservation. - * @alias compute.reservations.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.reservation Name of the reservation to retrieve. - * @param {string} params.zone Name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Reservations$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Reservations$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Reservations$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Reservations$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Reservations$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Reservations$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/reservations/{reservation}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'reservation'], - pathParams: ['project', 'reservation', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.reservations.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.reservations.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Reservations$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Reservations$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Reservations$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Reservations$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Reservations$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Reservations$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/reservations/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.reservations.insert - * @desc Creates a new reservation. For more information, read Reserving zonal resources. - * @alias compute.reservations.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone Name of the zone for this request. - * @param {().Reservation} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Reservations$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Reservations$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Reservations$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Reservations$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Reservations$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Reservations$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/reservations' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.reservations.list - * @desc A list all the reservations that have been configured for the specified project in specified zone. - * @alias compute.reservations.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone Name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Reservations$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Reservations$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Reservations$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Reservations$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Reservations$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Reservations$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/reservations' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.reservations.resize - * @desc Resizes the reservation (applicable to standalone reservations only) - * @alias compute.reservations.resize - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.reservation Name of the reservation to update. - * @param {string} params.zone Name of the zone for this request. - * @param {().ReservationsResizeRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - resize( - params?: Params$Resource$Reservations$Resize, - options?: MethodOptions - ): GaxiosPromise; - resize( - params: Params$Resource$Reservations$Resize, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - resize( - params: Params$Resource$Reservations$Resize, - callback: BodyResponseCallback - ): void; - resize(callback: BodyResponseCallback): void; - resize( - paramsOrCallback?: - | Params$Resource$Reservations$Resize - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Reservations$Resize; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Reservations$Resize; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/reservations/{reservation}/resize' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'reservation'], - pathParams: ['project', 'reservation', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.reservations.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.reservations.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().ZoneSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Reservations$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Reservations$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Reservations$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Reservations$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Reservations$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Reservations$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/reservations/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.reservations.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.reservations.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Reservations$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Reservations$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Reservations$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Reservations$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Reservations$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Reservations$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/reservations/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Reservations$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Reservations$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the reservation to delete. - */ - reservation?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Reservations$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the reservation to retrieve. - */ - reservation?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Reservations$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Reservations$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Reservation; - } - export interface Params$Resource$Reservations$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Reservations$Resize - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the reservation to update. - */ - reservation?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ReservationsResizeRequest; - } - export interface Params$Resource$Reservations$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ZoneSetPolicyRequest; - } - export interface Params$Resource$Reservations$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Resourcepolicies { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.resourcePolicies.aggregatedList - * @desc Retrieves an aggregated list of resource policies. - * @alias compute.resourcePolicies.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Resourcepolicies$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Resourcepolicies$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Resourcepolicies$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Resourcepolicies$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Resourcepolicies$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Resourcepolicies$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/resourcePolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.resourcePolicies.delete - * @desc Deletes the specified resource policy. - * @alias compute.resourcePolicies.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.resourcePolicy Name of the resource policy to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Resourcepolicies$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Resourcepolicies$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Resourcepolicies$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Resourcepolicies$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Resourcepolicies$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Resourcepolicies$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/resourcePolicies/{resourcePolicy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resourcePolicy'], - pathParams: ['project', 'region', 'resourcePolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.resourcePolicies.get - * @desc Retrieves all information of the specified resource policy. - * @alias compute.resourcePolicies.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string} params.resourcePolicy Name of the resource policy to retrieve. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Resourcepolicies$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Resourcepolicies$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Resourcepolicies$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Resourcepolicies$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Resourcepolicies$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Resourcepolicies$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/resourcePolicies/{resourcePolicy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resourcePolicy'], - pathParams: ['project', 'region', 'resourcePolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.resourcePolicies.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.resourcePolicies.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Resourcepolicies$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Resourcepolicies$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Resourcepolicies$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Resourcepolicies$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Resourcepolicies$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Resourcepolicies$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/resourcePolicies/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.resourcePolicies.insert - * @desc Creates a new resource policy. - * @alias compute.resourcePolicies.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().ResourcePolicy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Resourcepolicies$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Resourcepolicies$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Resourcepolicies$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Resourcepolicies$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Resourcepolicies$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Resourcepolicies$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/resourcePolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.resourcePolicies.list - * @desc A list all the resource policies that have been configured for the specified project in specified region. - * @alias compute.resourcePolicies.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Resourcepolicies$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Resourcepolicies$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Resourcepolicies$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Resourcepolicies$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Resourcepolicies$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Resourcepolicies$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/resourcePolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.resourcePolicies.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.resourcePolicies.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().RegionSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Resourcepolicies$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Resourcepolicies$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Resourcepolicies$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Resourcepolicies$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Resourcepolicies$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Resourcepolicies$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/resourcePolicies/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.resourcePolicies.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.resourcePolicies.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Resourcepolicies$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Resourcepolicies$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Resourcepolicies$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Resourcepolicies$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Resourcepolicies$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Resourcepolicies$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/resourcePolicies/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Resourcepolicies$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Resourcepolicies$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the resource policy to delete. - */ - resourcePolicy?: string; - } - export interface Params$Resource$Resourcepolicies$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * Name of the resource policy to retrieve. - */ - resourcePolicy?: string; - } - export interface Params$Resource$Resourcepolicies$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Resourcepolicies$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$ResourcePolicy; - } - export interface Params$Resource$Resourcepolicies$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Resourcepolicies$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionSetPolicyRequest; - } - export interface Params$Resource$Resourcepolicies$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Routers { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.routers.aggregatedList - * @desc Retrieves an aggregated list of routers. - * @alias compute.routers.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Routers$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Routers$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Routers$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Routers$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Routers$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routers$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/aggregated/routers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routers.delete - * @desc Deletes the specified Router resource. - * @alias compute.routers.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.router Name of the Router resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Routers$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Routers$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Routers$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Routers$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Routers$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routers$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/routers/{router}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'router'], - pathParams: ['project', 'region', 'router'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routers.get - * @desc Returns the specified Router resource. Gets a list of available routers by making a list() request. - * @alias compute.routers.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string} params.router Name of the Router resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Routers$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Routers$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Routers$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Routers$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Routers$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routers$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/routers/{router}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'router'], - pathParams: ['project', 'region', 'router'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routers.getNatMappingInfo - * @desc Retrieves runtime Nat mapping information of VM endpoints. - * @alias compute.routers.getNatMappingInfo - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.natName Name of the nat service to filter the Nat Mapping information. If it is omitted, all nats for this router will be returned. Name should conform to RFC1035. - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string} params.router Name of the Router resource to query for Nat Mapping information of VM endpoints. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getNatMappingInfo( - params?: Params$Resource$Routers$Getnatmappinginfo, - options?: MethodOptions - ): GaxiosPromise; - getNatMappingInfo( - params: Params$Resource$Routers$Getnatmappinginfo, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getNatMappingInfo( - params: Params$Resource$Routers$Getnatmappinginfo, - callback: BodyResponseCallback - ): void; - getNatMappingInfo( - callback: BodyResponseCallback - ): void; - getNatMappingInfo( - paramsOrCallback?: - | Params$Resource$Routers$Getnatmappinginfo - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Routers$Getnatmappinginfo; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routers$Getnatmappinginfo; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/routers/{router}/getNatMappingInfo' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'router'], - pathParams: ['project', 'region', 'router'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routers.getRouterStatus - * @desc Retrieves runtime information of the specified router. - * @alias compute.routers.getRouterStatus - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string} params.router Name of the Router resource to query. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getRouterStatus( - params?: Params$Resource$Routers$Getrouterstatus, - options?: MethodOptions - ): GaxiosPromise; - getRouterStatus( - params: Params$Resource$Routers$Getrouterstatus, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getRouterStatus( - params: Params$Resource$Routers$Getrouterstatus, - callback: BodyResponseCallback - ): void; - getRouterStatus( - callback: BodyResponseCallback - ): void; - getRouterStatus( - paramsOrCallback?: - | Params$Resource$Routers$Getrouterstatus - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Routers$Getrouterstatus; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routers$Getrouterstatus; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/routers/{router}/getRouterStatus' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'router'], - pathParams: ['project', 'region', 'router'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routers.insert - * @desc Creates a Router resource in the specified project and region using the data included in the request. - * @alias compute.routers.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Router} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Routers$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Routers$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Routers$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Routers$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Routers$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routers$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/routers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routers.list - * @desc Retrieves a list of Router resources available to the specified project. - * @alias compute.routers.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Routers$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Routers$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Routers$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Routers$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Routers$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routers$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/routers' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routers.patch - * @desc Patches the specified Router resource with the data included in the request. This method supports PATCH semantics and uses JSON merge patch format and processing rules. - * @alias compute.routers.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.router Name of the Router resource to patch. - * @param {().Router} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Routers$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Routers$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Routers$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Routers$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Routers$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routers$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/routers/{router}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'region', 'router'], - pathParams: ['project', 'region', 'router'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routers.preview - * @desc Preview fields auto-generated during router create and update operations. Calling this method does NOT create or update the router. - * @alias compute.routers.preview - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string} params.router Name of the Router resource to query. - * @param {().Router} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - preview( - params?: Params$Resource$Routers$Preview, - options?: MethodOptions - ): GaxiosPromise; - preview( - params: Params$Resource$Routers$Preview, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - preview( - params: Params$Resource$Routers$Preview, - callback: BodyResponseCallback - ): void; - preview( - callback: BodyResponseCallback - ): void; - preview( - paramsOrCallback?: - | Params$Resource$Routers$Preview - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Routers$Preview; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routers$Preview; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/routers/{router}/preview' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'router'], - pathParams: ['project', 'region', 'router'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routers.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.routers.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Routers$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Routers$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Routers$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Routers$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Routers$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routers$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/routers/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routers.update - * @desc Updates the specified Router resource with the data included in the request. This method conforms to PUT semantics, which requests that the state of the target resource be created or replaced with the state defined by the representation enclosed in the request message payload. - * @alias compute.routers.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.router Name of the Router resource to update. - * @param {().Router} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Routers$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Routers$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Routers$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Routers$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Routers$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routers$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/routers/{router}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'region', 'router'], - pathParams: ['project', 'region', 'router'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Routers$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Routers$Delete extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the Router resource to delete. - */ - router?: string; - } - export interface Params$Resource$Routers$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * Name of the Router resource to return. - */ - router?: string; - } - export interface Params$Resource$Routers$Getnatmappinginfo - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Name of the nat service to filter the Nat Mapping information. If it is omitted, all nats for this router will be returned. Name should conform to RFC1035. - */ - natName?: string; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * Name of the Router resource to query for Nat Mapping information of VM endpoints. - */ - router?: string; - } - export interface Params$Resource$Routers$Getrouterstatus - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * Name of the Router resource to query. - */ - router?: string; - } - export interface Params$Resource$Routers$Insert extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Router; - } - export interface Params$Resource$Routers$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Routers$Patch extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the Router resource to patch. - */ - router?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Router; - } - export interface Params$Resource$Routers$Preview extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * Name of the Router resource to query. - */ - router?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Router; - } - export interface Params$Resource$Routers$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Routers$Update extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the Router resource to update. - */ - router?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Router; - } - - export class Resource$Routes { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.routes.delete - * @desc Deletes the specified Route resource. - * @alias compute.routes.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.route Name of the Route resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Routes$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Routes$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Routes$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Routes$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Routes$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routes$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/routes/{route}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'route'], - pathParams: ['project', 'route'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routes.get - * @desc Returns the specified Route resource. Gets a list of available routes by making a list() request. - * @alias compute.routes.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.route Name of the Route resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Routes$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Routes$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Routes$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Routes$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Routes$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routes$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/routes/{route}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'route'], - pathParams: ['project', 'route'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routes.insert - * @desc Creates a Route resource in the specified project using the data included in the request. - * @alias compute.routes.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Route} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Routes$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Routes$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Routes$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Routes$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Routes$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routes$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/routes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routes.list - * @desc Retrieves the list of Route resources available to the specified project. - * @alias compute.routes.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Routes$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Routes$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Routes$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Routes$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Routes$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routes$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/routes' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.routes.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.routes.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Routes$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Routes$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Routes$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Routes$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Routes$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Routes$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/routes/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Routes$Delete extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the Route resource to delete. - */ - route?: string; - } - export interface Params$Resource$Routes$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the Route resource to return. - */ - route?: string; - } - export interface Params$Resource$Routes$Insert extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Route; - } - export interface Params$Resource$Routes$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Routes$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Securitypolicies { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.securityPolicies.addRule - * @desc Inserts a rule into a security policy. - * @alias compute.securityPolicies.addRule - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.securityPolicy Name of the security policy to update. - * @param {boolean=} params.validateOnly If true, the request will not be committed. - * @param {().SecurityPolicyRule} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addRule( - params?: Params$Resource$Securitypolicies$Addrule, - options?: MethodOptions - ): GaxiosPromise; - addRule( - params: Params$Resource$Securitypolicies$Addrule, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addRule( - params: Params$Resource$Securitypolicies$Addrule, - callback: BodyResponseCallback - ): void; - addRule(callback: BodyResponseCallback): void; - addRule( - paramsOrCallback?: - | Params$Resource$Securitypolicies$Addrule - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Securitypolicies$Addrule; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Securitypolicies$Addrule; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/securityPolicies/{securityPolicy}/addRule' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'securityPolicy'], - pathParams: ['project', 'securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.securityPolicies.delete - * @desc Deletes the specified policy. - * @alias compute.securityPolicies.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.securityPolicy Name of the security policy to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Securitypolicies$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Securitypolicies$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Securitypolicies$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Securitypolicies$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Securitypolicies$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Securitypolicies$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/securityPolicies/{securityPolicy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'securityPolicy'], - pathParams: ['project', 'securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.securityPolicies.get - * @desc List all of the ordered rules present in a single specified policy. - * @alias compute.securityPolicies.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.securityPolicy Name of the security policy to get. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Securitypolicies$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Securitypolicies$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Securitypolicies$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Securitypolicies$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Securitypolicies$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Securitypolicies$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/securityPolicies/{securityPolicy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'securityPolicy'], - pathParams: ['project', 'securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.securityPolicies.getRule - * @desc Gets a rule at the specified priority. - * @alias compute.securityPolicies.getRule - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {integer=} params.priority The priority of the rule to get from the security policy. - * @param {string} params.project Project ID for this request. - * @param {string} params.securityPolicy Name of the security policy to which the queried rule belongs. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getRule( - params?: Params$Resource$Securitypolicies$Getrule, - options?: MethodOptions - ): GaxiosPromise; - getRule( - params: Params$Resource$Securitypolicies$Getrule, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getRule( - params: Params$Resource$Securitypolicies$Getrule, - callback: BodyResponseCallback - ): void; - getRule(callback: BodyResponseCallback): void; - getRule( - paramsOrCallback?: - | Params$Resource$Securitypolicies$Getrule - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Securitypolicies$Getrule; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Securitypolicies$Getrule; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/securityPolicies/{securityPolicy}/getRule' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'securityPolicy'], - pathParams: ['project', 'securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.securityPolicies.insert - * @desc Creates a new policy in the specified project using the data included in the request. - * @alias compute.securityPolicies.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {boolean=} params.validateOnly If true, the request will not be committed. - * @param {().SecurityPolicy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Securitypolicies$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Securitypolicies$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Securitypolicies$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Securitypolicies$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Securitypolicies$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Securitypolicies$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/securityPolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.securityPolicies.list - * @desc List all the policies that have been configured for the specified project. - * @alias compute.securityPolicies.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Securitypolicies$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Securitypolicies$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Securitypolicies$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Securitypolicies$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Securitypolicies$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Securitypolicies$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/securityPolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.securityPolicies.listPreconfiguredExpressionSets - * @desc Gets the current list of preconfigured Web Application Firewall (WAF) expressions. - * @alias compute.securityPolicies.listPreconfiguredExpressionSets - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listPreconfiguredExpressionSets( - params?: Params$Resource$Securitypolicies$Listpreconfiguredexpressionsets, - options?: MethodOptions - ): GaxiosPromise< - Schema$SecurityPoliciesListPreconfiguredExpressionSetsResponse - >; - listPreconfiguredExpressionSets( - params: Params$Resource$Securitypolicies$Listpreconfiguredexpressionsets, - options: - | MethodOptions - | BodyResponseCallback< - Schema$SecurityPoliciesListPreconfiguredExpressionSetsResponse - >, - callback: BodyResponseCallback< - Schema$SecurityPoliciesListPreconfiguredExpressionSetsResponse - > - ): void; - listPreconfiguredExpressionSets( - params: Params$Resource$Securitypolicies$Listpreconfiguredexpressionsets, - callback: BodyResponseCallback< - Schema$SecurityPoliciesListPreconfiguredExpressionSetsResponse - > - ): void; - listPreconfiguredExpressionSets( - callback: BodyResponseCallback< - Schema$SecurityPoliciesListPreconfiguredExpressionSetsResponse - > - ): void; - listPreconfiguredExpressionSets( - paramsOrCallback?: - | Params$Resource$Securitypolicies$Listpreconfiguredexpressionsets - | BodyResponseCallback< - Schema$SecurityPoliciesListPreconfiguredExpressionSetsResponse - >, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback< - Schema$SecurityPoliciesListPreconfiguredExpressionSetsResponse - >, - callback?: BodyResponseCallback< - Schema$SecurityPoliciesListPreconfiguredExpressionSetsResponse - > - ): void | GaxiosPromise< - Schema$SecurityPoliciesListPreconfiguredExpressionSetsResponse - > { - let params = (paramsOrCallback || - {}) as Params$Resource$Securitypolicies$Listpreconfiguredexpressionsets; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Securitypolicies$Listpreconfiguredexpressionsets; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/securityPolicies/listPreconfiguredExpressionSets' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest< - Schema$SecurityPoliciesListPreconfiguredExpressionSetsResponse - >(parameters, callback); - } else { - return createAPIRequest< - Schema$SecurityPoliciesListPreconfiguredExpressionSetsResponse - >(parameters); - } - } - - /** - * compute.securityPolicies.patch - * @desc Patches the specified policy with the data included in the request. - * @alias compute.securityPolicies.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.securityPolicy Name of the security policy to update. - * @param {().SecurityPolicy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Securitypolicies$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Securitypolicies$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Securitypolicies$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Securitypolicies$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Securitypolicies$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Securitypolicies$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/securityPolicies/{securityPolicy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'securityPolicy'], - pathParams: ['project', 'securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.securityPolicies.patchRule - * @desc Patches a rule at the specified priority. - * @alias compute.securityPolicies.patchRule - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {integer=} params.priority The priority of the rule to patch. - * @param {string} params.project Project ID for this request. - * @param {string} params.securityPolicy Name of the security policy to update. - * @param {boolean=} params.validateOnly If true, the request will not be committed. - * @param {().SecurityPolicyRule} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patchRule( - params?: Params$Resource$Securitypolicies$Patchrule, - options?: MethodOptions - ): GaxiosPromise; - patchRule( - params: Params$Resource$Securitypolicies$Patchrule, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patchRule( - params: Params$Resource$Securitypolicies$Patchrule, - callback: BodyResponseCallback - ): void; - patchRule(callback: BodyResponseCallback): void; - patchRule( - paramsOrCallback?: - | Params$Resource$Securitypolicies$Patchrule - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Securitypolicies$Patchrule; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Securitypolicies$Patchrule; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/securityPolicies/{securityPolicy}/patchRule' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'securityPolicy'], - pathParams: ['project', 'securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.securityPolicies.removeRule - * @desc Deletes a rule at the specified priority. - * @alias compute.securityPolicies.removeRule - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {integer=} params.priority The priority of the rule to remove from the security policy. - * @param {string} params.project Project ID for this request. - * @param {string} params.securityPolicy Name of the security policy to update. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - removeRule( - params?: Params$Resource$Securitypolicies$Removerule, - options?: MethodOptions - ): GaxiosPromise; - removeRule( - params: Params$Resource$Securitypolicies$Removerule, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - removeRule( - params: Params$Resource$Securitypolicies$Removerule, - callback: BodyResponseCallback - ): void; - removeRule(callback: BodyResponseCallback): void; - removeRule( - paramsOrCallback?: - | Params$Resource$Securitypolicies$Removerule - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Securitypolicies$Removerule; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Securitypolicies$Removerule; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/securityPolicies/{securityPolicy}/removeRule' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'securityPolicy'], - pathParams: ['project', 'securityPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.securityPolicies.setLabels - * @desc Sets the labels on a security policy. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.securityPolicies.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Securitypolicies$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Securitypolicies$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Securitypolicies$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Securitypolicies$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Securitypolicies$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Securitypolicies$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/securityPolicies/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.securityPolicies.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.securityPolicies.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Securitypolicies$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Securitypolicies$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Securitypolicies$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Securitypolicies$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Securitypolicies$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Securitypolicies$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/securityPolicies/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Securitypolicies$Addrule - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the security policy to update. - */ - securityPolicy?: string; - /** - * If true, the request will not be committed. - */ - validateOnly?: boolean; - - /** - * Request body metadata - */ - requestBody?: Schema$SecurityPolicyRule; - } - export interface Params$Resource$Securitypolicies$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the security policy to delete. - */ - securityPolicy?: string; - } - export interface Params$Resource$Securitypolicies$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the security policy to get. - */ - securityPolicy?: string; - } - export interface Params$Resource$Securitypolicies$Getrule - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The priority of the rule to get from the security policy. - */ - priority?: number; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the security policy to which the queried rule belongs. - */ - securityPolicy?: string; - } - export interface Params$Resource$Securitypolicies$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * If true, the request will not be committed. - */ - validateOnly?: boolean; - - /** - * Request body metadata - */ - requestBody?: Schema$SecurityPolicy; - } - export interface Params$Resource$Securitypolicies$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Securitypolicies$Listpreconfiguredexpressionsets - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Securitypolicies$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the security policy to update. - */ - securityPolicy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SecurityPolicy; - } - export interface Params$Resource$Securitypolicies$Patchrule - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The priority of the rule to patch. - */ - priority?: number; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the security policy to update. - */ - securityPolicy?: string; - /** - * If true, the request will not be committed. - */ - validateOnly?: boolean; - - /** - * Request body metadata - */ - requestBody?: Schema$SecurityPolicyRule; - } - export interface Params$Resource$Securitypolicies$Removerule - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The priority of the rule to remove from the security policy. - */ - priority?: number; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the security policy to update. - */ - securityPolicy?: string; - } - export interface Params$Resource$Securitypolicies$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetLabelsRequest; - } - export interface Params$Resource$Securitypolicies$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Snapshots { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.snapshots.delete - * @desc Deletes the specified Snapshot resource. Keep in mind that deleting a single snapshot might not necessarily delete all the data on that snapshot. If any data on the snapshot that is marked for deletion is needed for subsequent snapshots, the data will be moved to the next corresponding snapshot. For more information, see Deleting snapshots. - * @alias compute.snapshots.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.snapshot Name of the Snapshot resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Snapshots$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Snapshots$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Snapshots$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Snapshots$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Snapshots$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Snapshots$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/snapshots/{snapshot}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'snapshot'], - pathParams: ['project', 'snapshot'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.snapshots.get - * @desc Returns the specified Snapshot resource. Gets a list of available snapshots by making a list() request. - * @alias compute.snapshots.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.snapshot Name of the Snapshot resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Snapshots$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Snapshots$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Snapshots$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Snapshots$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Snapshots$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Snapshots$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/snapshots/{snapshot}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'snapshot'], - pathParams: ['project', 'snapshot'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.snapshots.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.snapshots.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Snapshots$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Snapshots$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Snapshots$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Snapshots$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Snapshots$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Snapshots$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/snapshots/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.snapshots.list - * @desc Retrieves the list of Snapshot resources contained within the specified project. - * @alias compute.snapshots.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Snapshots$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Snapshots$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Snapshots$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Snapshots$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Snapshots$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Snapshots$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/snapshots' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.snapshots.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.snapshots.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Snapshots$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Snapshots$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Snapshots$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Snapshots$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Snapshots$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Snapshots$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/snapshots/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.snapshots.setLabels - * @desc Sets the labels on a snapshot. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.snapshots.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().GlobalSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Snapshots$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Snapshots$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Snapshots$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Snapshots$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Snapshots$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Snapshots$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/snapshots/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.snapshots.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.snapshots.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Snapshots$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Snapshots$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Snapshots$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Snapshots$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Snapshots$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Snapshots$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/snapshots/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Snapshots$Delete extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the Snapshot resource to delete. - */ - snapshot?: string; - } - export interface Params$Resource$Snapshots$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the Snapshot resource to return. - */ - snapshot?: string; - } - export interface Params$Resource$Snapshots$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Snapshots$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Snapshots$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetPolicyRequest; - } - export interface Params$Resource$Snapshots$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GlobalSetLabelsRequest; - } - export interface Params$Resource$Snapshots$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Sslcertificates { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.sslCertificates.aggregatedList - * @desc Retrieves the list of all SslCertificate resources, regional and global, available to the specified project. - * @alias compute.sslCertificates.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Name of the project scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Sslcertificates$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Sslcertificates$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Sslcertificates$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Sslcertificates$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Sslcertificates$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslcertificates$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/sslCertificates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.sslCertificates.delete - * @desc Deletes the specified SslCertificate resource. - * @alias compute.sslCertificates.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.sslCertificate Name of the SslCertificate resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Sslcertificates$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Sslcertificates$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Sslcertificates$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Sslcertificates$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Sslcertificates$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslcertificates$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/sslCertificates/{sslCertificate}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'sslCertificate'], - pathParams: ['project', 'sslCertificate'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.sslCertificates.get - * @desc Returns the specified SslCertificate resource. Gets a list of available SSL certificates by making a list() request. - * @alias compute.sslCertificates.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.sslCertificate Name of the SslCertificate resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Sslcertificates$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Sslcertificates$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Sslcertificates$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Sslcertificates$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Sslcertificates$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslcertificates$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/sslCertificates/{sslCertificate}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'sslCertificate'], - pathParams: ['project', 'sslCertificate'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.sslCertificates.insert - * @desc Creates a SslCertificate resource in the specified project using the data included in the request. - * @alias compute.sslCertificates.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().SslCertificate} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Sslcertificates$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Sslcertificates$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Sslcertificates$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Sslcertificates$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Sslcertificates$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslcertificates$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/sslCertificates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.sslCertificates.list - * @desc Retrieves the list of SslCertificate resources available to the specified project. - * @alias compute.sslCertificates.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Sslcertificates$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Sslcertificates$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Sslcertificates$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Sslcertificates$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Sslcertificates$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslcertificates$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/sslCertificates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.sslCertificates.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.sslCertificates.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Sslcertificates$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Sslcertificates$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Sslcertificates$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Sslcertificates$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Sslcertificates$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslcertificates$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/sslCertificates/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Sslcertificates$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Name of the project scoping this request. - */ - project?: string; - } - export interface Params$Resource$Sslcertificates$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the SslCertificate resource to delete. - */ - sslCertificate?: string; - } - export interface Params$Resource$Sslcertificates$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the SslCertificate resource to return. - */ - sslCertificate?: string; - } - export interface Params$Resource$Sslcertificates$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SslCertificate; - } - export interface Params$Resource$Sslcertificates$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Sslcertificates$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Sslpolicies { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.sslPolicies.delete - * @desc Deletes the specified SSL policy. The SSL policy resource can be deleted only if it is not in use by any TargetHttpsProxy or TargetSslProxy resources. - * @alias compute.sslPolicies.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.sslPolicy Name of the SSL policy to delete. The name must be 1-63 characters long, and comply with RFC1035. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Sslpolicies$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Sslpolicies$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Sslpolicies$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Sslpolicies$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Sslpolicies$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslpolicies$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/sslPolicies/{sslPolicy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'sslPolicy'], - pathParams: ['project', 'sslPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.sslPolicies.get - * @desc Lists all of the ordered rules present in a single specified policy. - * @alias compute.sslPolicies.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.sslPolicy Name of the SSL policy to update. The name must be 1-63 characters long, and comply with RFC1035. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Sslpolicies$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Sslpolicies$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Sslpolicies$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Sslpolicies$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Sslpolicies$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslpolicies$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/sslPolicies/{sslPolicy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'sslPolicy'], - pathParams: ['project', 'sslPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.sslPolicies.insert - * @desc Returns the specified SSL policy resource. Gets a list of available SSL policies by making a list() request. - * @alias compute.sslPolicies.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().SslPolicy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Sslpolicies$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Sslpolicies$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Sslpolicies$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Sslpolicies$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Sslpolicies$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslpolicies$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/sslPolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.sslPolicies.list - * @desc Lists all the SSL policies that have been configured for the specified project. - * @alias compute.sslPolicies.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Sslpolicies$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Sslpolicies$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Sslpolicies$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Sslpolicies$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Sslpolicies$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslpolicies$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/sslPolicies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.sslPolicies.listAvailableFeatures - * @desc Lists all features that can be specified in the SSL policy when using custom profile. - * @alias compute.sslPolicies.listAvailableFeatures - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listAvailableFeatures( - params?: Params$Resource$Sslpolicies$Listavailablefeatures, - options?: MethodOptions - ): GaxiosPromise; - listAvailableFeatures( - params: Params$Resource$Sslpolicies$Listavailablefeatures, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback< - Schema$SslPoliciesListAvailableFeaturesResponse - > - ): void; - listAvailableFeatures( - params: Params$Resource$Sslpolicies$Listavailablefeatures, - callback: BodyResponseCallback< - Schema$SslPoliciesListAvailableFeaturesResponse - > - ): void; - listAvailableFeatures( - callback: BodyResponseCallback< - Schema$SslPoliciesListAvailableFeaturesResponse - > - ): void; - listAvailableFeatures( - paramsOrCallback?: - | Params$Resource$Sslpolicies$Listavailablefeatures - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback< - Schema$SslPoliciesListAvailableFeaturesResponse - > - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Sslpolicies$Listavailablefeatures; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslpolicies$Listavailablefeatures; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/sslPolicies/listAvailableFeatures' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest< - Schema$SslPoliciesListAvailableFeaturesResponse - >(parameters); - } - } - - /** - * compute.sslPolicies.patch - * @desc Patches the specified SSL policy with the data included in the request. - * @alias compute.sslPolicies.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.sslPolicy Name of the SSL policy to update. The name must be 1-63 characters long, and comply with RFC1035. - * @param {().SslPolicy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Sslpolicies$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Sslpolicies$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Sslpolicies$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Sslpolicies$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Sslpolicies$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslpolicies$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/sslPolicies/{sslPolicy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'sslPolicy'], - pathParams: ['project', 'sslPolicy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.sslPolicies.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.sslPolicies.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Sslpolicies$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Sslpolicies$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Sslpolicies$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Sslpolicies$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Sslpolicies$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Sslpolicies$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/sslPolicies/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Sslpolicies$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the SSL policy to delete. The name must be 1-63 characters long, and comply with RFC1035. - */ - sslPolicy?: string; - } - export interface Params$Resource$Sslpolicies$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the SSL policy to update. The name must be 1-63 characters long, and comply with RFC1035. - */ - sslPolicy?: string; - } - export interface Params$Resource$Sslpolicies$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SslPolicy; - } - export interface Params$Resource$Sslpolicies$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Sslpolicies$Listavailablefeatures - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Sslpolicies$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the SSL policy to update. The name must be 1-63 characters long, and comply with RFC1035. - */ - sslPolicy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SslPolicy; - } - export interface Params$Resource$Sslpolicies$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Subnetworks { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.subnetworks.aggregatedList - * @desc Retrieves an aggregated list of subnetworks. - * @alias compute.subnetworks.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Subnetworks$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Subnetworks$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Subnetworks$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Subnetworks$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Subnetworks$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Subnetworks$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/subnetworks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.subnetworks.delete - * @desc Deletes the specified subnetwork. - * @alias compute.subnetworks.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.subnetwork Name of the Subnetwork resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Subnetworks$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Subnetworks$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Subnetworks$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Subnetworks$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Subnetworks$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Subnetworks$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/subnetworks/{subnetwork}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'subnetwork'], - pathParams: ['project', 'region', 'subnetwork'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.subnetworks.expandIpCidrRange - * @desc Expands the IP CIDR range of the subnetwork to a specified value. - * @alias compute.subnetworks.expandIpCidrRange - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.subnetwork Name of the Subnetwork resource to update. - * @param {().SubnetworksExpandIpCidrRangeRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - expandIpCidrRange( - params?: Params$Resource$Subnetworks$Expandipcidrrange, - options?: MethodOptions - ): GaxiosPromise; - expandIpCidrRange( - params: Params$Resource$Subnetworks$Expandipcidrrange, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - expandIpCidrRange( - params: Params$Resource$Subnetworks$Expandipcidrrange, - callback: BodyResponseCallback - ): void; - expandIpCidrRange(callback: BodyResponseCallback): void; - expandIpCidrRange( - paramsOrCallback?: - | Params$Resource$Subnetworks$Expandipcidrrange - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Subnetworks$Expandipcidrrange; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Subnetworks$Expandipcidrrange; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/subnetworks/{subnetwork}/expandIpCidrRange' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'subnetwork'], - pathParams: ['project', 'region', 'subnetwork'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.subnetworks.get - * @desc Returns the specified subnetwork. Gets a list of available subnetworks list() request. - * @alias compute.subnetworks.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string} params.subnetwork Name of the Subnetwork resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Subnetworks$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Subnetworks$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Subnetworks$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Subnetworks$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Subnetworks$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Subnetworks$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/subnetworks/{subnetwork}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'subnetwork'], - pathParams: ['project', 'region', 'subnetwork'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.subnetworks.getIamPolicy - * @desc Gets the access control policy for a resource. May be empty if no such policy or resource exists. - * @alias compute.subnetworks.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Subnetworks$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Subnetworks$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Subnetworks$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Subnetworks$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Subnetworks$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Subnetworks$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/subnetworks/{resource}/getIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.subnetworks.insert - * @desc Creates a subnetwork in the specified project using the data included in the request. - * @alias compute.subnetworks.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().Subnetwork} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Subnetworks$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Subnetworks$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Subnetworks$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Subnetworks$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Subnetworks$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Subnetworks$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/subnetworks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.subnetworks.list - * @desc Retrieves a list of subnetworks available to the specified project. - * @alias compute.subnetworks.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Subnetworks$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Subnetworks$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Subnetworks$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Subnetworks$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Subnetworks$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Subnetworks$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/subnetworks' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.subnetworks.listUsable - * @desc Retrieves an aggregated list of usable subnetworks. - * @alias compute.subnetworks.listUsable - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - listUsable( - params?: Params$Resource$Subnetworks$Listusable, - options?: MethodOptions - ): GaxiosPromise; - listUsable( - params: Params$Resource$Subnetworks$Listusable, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - listUsable( - params: Params$Resource$Subnetworks$Listusable, - callback: BodyResponseCallback - ): void; - listUsable( - callback: BodyResponseCallback - ): void; - listUsable( - paramsOrCallback?: - | Params$Resource$Subnetworks$Listusable - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Subnetworks$Listusable; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Subnetworks$Listusable; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/subnetworks/listUsable' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.subnetworks.patch - * @desc Patches the specified subnetwork with the data included in the request. Only certain fields can up updated with a patch request as indicated in the field descriptions. You must specify the current fingeprint of the subnetwork resource being patched. - * @alias compute.subnetworks.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {integer=} params.drainTimeoutSeconds The drain timeout specifies the upper bound in seconds on the amount of time allowed to drain connections from the current ACTIVE subnetwork to the current BACKUP subnetwork. The drain timeout is only applicable when the following conditions are true: - the subnetwork being patched has purpose = INTERNAL_HTTPS_LOAD_BALANCER - the subnetwork being patched has role = BACKUP - the patch request is setting the role to ACTIVE. Note that after this patch operation the roles of the ACTIVE and BACKUP subnetworks will be swapped. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.subnetwork Name of the Subnetwork resource to patch. - * @param {().Subnetwork} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Subnetworks$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Subnetworks$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Subnetworks$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Subnetworks$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Subnetworks$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Subnetworks$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/subnetworks/{subnetwork}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'region', 'subnetwork'], - pathParams: ['project', 'region', 'subnetwork'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.subnetworks.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @alias compute.subnetworks.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().RegionSetPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Subnetworks$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Subnetworks$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Subnetworks$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Subnetworks$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Subnetworks$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Subnetworks$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/subnetworks/{resource}/setIamPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.subnetworks.setPrivateIpGoogleAccess - * @desc Set whether VMs in this subnet can access Google services without assigning external IP addresses through Private Google Access. - * @alias compute.subnetworks.setPrivateIpGoogleAccess - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.subnetwork Name of the Subnetwork resource. - * @param {().SubnetworksSetPrivateIpGoogleAccessRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setPrivateIpGoogleAccess( - params?: Params$Resource$Subnetworks$Setprivateipgoogleaccess, - options?: MethodOptions - ): GaxiosPromise; - setPrivateIpGoogleAccess( - params: Params$Resource$Subnetworks$Setprivateipgoogleaccess, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setPrivateIpGoogleAccess( - params: Params$Resource$Subnetworks$Setprivateipgoogleaccess, - callback: BodyResponseCallback - ): void; - setPrivateIpGoogleAccess( - callback: BodyResponseCallback - ): void; - setPrivateIpGoogleAccess( - paramsOrCallback?: - | Params$Resource$Subnetworks$Setprivateipgoogleaccess - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Subnetworks$Setprivateipgoogleaccess; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Subnetworks$Setprivateipgoogleaccess; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/subnetworks/{subnetwork}/setPrivateIpGoogleAccess' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'subnetwork'], - pathParams: ['project', 'region', 'subnetwork'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.subnetworks.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.subnetworks.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Subnetworks$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Subnetworks$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Subnetworks$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Subnetworks$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Subnetworks$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Subnetworks$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/subnetworks/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Subnetworks$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Subnetworks$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the Subnetwork resource to delete. - */ - subnetwork?: string; - } - export interface Params$Resource$Subnetworks$Expandipcidrrange - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the Subnetwork resource to update. - */ - subnetwork?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SubnetworksExpandIpCidrRangeRequest; - } - export interface Params$Resource$Subnetworks$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * Name of the Subnetwork resource to return. - */ - subnetwork?: string; - } - export interface Params$Resource$Subnetworks$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - } - export interface Params$Resource$Subnetworks$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Subnetwork; - } - export interface Params$Resource$Subnetworks$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Subnetworks$Listusable - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Subnetworks$Patch - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The drain timeout specifies the upper bound in seconds on the amount of time allowed to drain connections from the current ACTIVE subnetwork to the current BACKUP subnetwork. The drain timeout is only applicable when the following conditions are true: - the subnetwork being patched has purpose = INTERNAL_HTTPS_LOAD_BALANCER - the subnetwork being patched has role = BACKUP - the patch request is setting the role to ACTIVE. Note that after this patch operation the roles of the ACTIVE and BACKUP subnetworks will be swapped. - */ - drainTimeoutSeconds?: number; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the Subnetwork resource to patch. - */ - subnetwork?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$Subnetwork; - } - export interface Params$Resource$Subnetworks$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionSetPolicyRequest; - } - export interface Params$Resource$Subnetworks$Setprivateipgoogleaccess - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the Subnetwork resource. - */ - subnetwork?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SubnetworksSetPrivateIpGoogleAccessRequest; - } - export interface Params$Resource$Subnetworks$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Targethttpproxies { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.targetHttpProxies.aggregatedList - * @desc Retrieves the list of all TargetHttpProxy resources, regional and global, available to the specified project. - * @alias compute.targetHttpProxies.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Name of the project scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Targethttpproxies$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Targethttpproxies$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Targethttpproxies$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Targethttpproxies$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpproxies$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpproxies$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/targetHttpProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.targetHttpProxies.delete - * @desc Deletes the specified TargetHttpProxy resource. - * @alias compute.targetHttpProxies.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetHttpProxy Name of the TargetHttpProxy resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Targethttpproxies$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Targethttpproxies$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Targethttpproxies$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Targethttpproxies$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpproxies$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpproxies$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetHttpProxies/{targetHttpProxy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'targetHttpProxy'], - pathParams: ['project', 'targetHttpProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpProxies.get - * @desc Returns the specified TargetHttpProxy resource. Gets a list of available target HTTP proxies by making a list() request. - * @alias compute.targetHttpProxies.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.targetHttpProxy Name of the TargetHttpProxy resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Targethttpproxies$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Targethttpproxies$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Targethttpproxies$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Targethttpproxies$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpproxies$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpproxies$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetHttpProxies/{targetHttpProxy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'targetHttpProxy'], - pathParams: ['project', 'targetHttpProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpProxies.insert - * @desc Creates a TargetHttpProxy resource in the specified project using the data included in the request. - * @alias compute.targetHttpProxies.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().TargetHttpProxy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Targethttpproxies$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Targethttpproxies$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Targethttpproxies$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Targethttpproxies$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpproxies$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpproxies$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetHttpProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpProxies.list - * @desc Retrieves the list of TargetHttpProxy resources available to the specified project. - * @alias compute.targetHttpProxies.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Targethttpproxies$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Targethttpproxies$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Targethttpproxies$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Targethttpproxies$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpproxies$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpproxies$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetHttpProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpProxies.setUrlMap - * @desc Changes the URL map for TargetHttpProxy. - * @alias compute.targetHttpProxies.setUrlMap - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetHttpProxy Name of the TargetHttpProxy to set a URL map for. - * @param {().UrlMapReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setUrlMap( - params?: Params$Resource$Targethttpproxies$Seturlmap, - options?: MethodOptions - ): GaxiosPromise; - setUrlMap( - params: Params$Resource$Targethttpproxies$Seturlmap, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setUrlMap( - params: Params$Resource$Targethttpproxies$Seturlmap, - callback: BodyResponseCallback - ): void; - setUrlMap(callback: BodyResponseCallback): void; - setUrlMap( - paramsOrCallback?: - | Params$Resource$Targethttpproxies$Seturlmap - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpproxies$Seturlmap; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpproxies$Seturlmap; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/targetHttpProxies/{targetHttpProxy}/setUrlMap' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'targetHttpProxy'], - pathParams: ['project', 'targetHttpProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpProxies.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.targetHttpProxies.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Targethttpproxies$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Targethttpproxies$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Targethttpproxies$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Targethttpproxies$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpproxies$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpproxies$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetHttpProxies/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Targethttpproxies$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Name of the project scoping this request. - */ - project?: string; - } - export interface Params$Resource$Targethttpproxies$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetHttpProxy resource to delete. - */ - targetHttpProxy?: string; - } - export interface Params$Resource$Targethttpproxies$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the TargetHttpProxy resource to return. - */ - targetHttpProxy?: string; - } - export interface Params$Resource$Targethttpproxies$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetHttpProxy; - } - export interface Params$Resource$Targethttpproxies$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Targethttpproxies$Seturlmap - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetHttpProxy to set a URL map for. - */ - targetHttpProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$UrlMapReference; - } - export interface Params$Resource$Targethttpproxies$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Targethttpsproxies { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.targetHttpsProxies.aggregatedList - * @desc Retrieves the list of all TargetHttpsProxy resources, regional and global, available to the specified project. - * @alias compute.targetHttpsProxies.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Name of the project scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Targethttpsproxies$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Targethttpsproxies$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Targethttpsproxies$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Targethttpsproxies$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpsproxies$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpsproxies$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/targetHttpsProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.targetHttpsProxies.delete - * @desc Deletes the specified TargetHttpsProxy resource. - * @alias compute.targetHttpsProxies.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetHttpsProxy Name of the TargetHttpsProxy resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Targethttpsproxies$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Targethttpsproxies$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Targethttpsproxies$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Targethttpsproxies$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpsproxies$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpsproxies$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetHttpsProxies/{targetHttpsProxy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'targetHttpsProxy'], - pathParams: ['project', 'targetHttpsProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpsProxies.get - * @desc Returns the specified TargetHttpsProxy resource. Gets a list of available target HTTPS proxies by making a list() request. - * @alias compute.targetHttpsProxies.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.targetHttpsProxy Name of the TargetHttpsProxy resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Targethttpsproxies$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Targethttpsproxies$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Targethttpsproxies$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Targethttpsproxies$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpsproxies$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpsproxies$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetHttpsProxies/{targetHttpsProxy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'targetHttpsProxy'], - pathParams: ['project', 'targetHttpsProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpsProxies.insert - * @desc Creates a TargetHttpsProxy resource in the specified project using the data included in the request. - * @alias compute.targetHttpsProxies.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().TargetHttpsProxy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Targethttpsproxies$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Targethttpsproxies$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Targethttpsproxies$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Targethttpsproxies$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpsproxies$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpsproxies$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetHttpsProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpsProxies.list - * @desc Retrieves the list of TargetHttpsProxy resources available to the specified project. - * @alias compute.targetHttpsProxies.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Targethttpsproxies$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Targethttpsproxies$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Targethttpsproxies$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Targethttpsproxies$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpsproxies$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpsproxies$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetHttpsProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpsProxies.setQuicOverride - * @desc Sets the QUIC override policy for TargetHttpsProxy. - * @alias compute.targetHttpsProxies.setQuicOverride - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetHttpsProxy Name of the TargetHttpsProxy resource to set the QUIC override policy for. The name should conform to RFC1035. - * @param {().TargetHttpsProxiesSetQuicOverrideRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setQuicOverride( - params?: Params$Resource$Targethttpsproxies$Setquicoverride, - options?: MethodOptions - ): GaxiosPromise; - setQuicOverride( - params: Params$Resource$Targethttpsproxies$Setquicoverride, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setQuicOverride( - params: Params$Resource$Targethttpsproxies$Setquicoverride, - callback: BodyResponseCallback - ): void; - setQuicOverride(callback: BodyResponseCallback): void; - setQuicOverride( - paramsOrCallback?: - | Params$Resource$Targethttpsproxies$Setquicoverride - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpsproxies$Setquicoverride; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpsproxies$Setquicoverride; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetHttpsProxies/{targetHttpsProxy}/setQuicOverride' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'targetHttpsProxy'], - pathParams: ['project', 'targetHttpsProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpsProxies.setSslCertificates - * @desc Replaces SslCertificates for TargetHttpsProxy. - * @alias compute.targetHttpsProxies.setSslCertificates - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetHttpsProxy Name of the TargetHttpsProxy resource to set an SslCertificates resource for. - * @param {().TargetHttpsProxiesSetSslCertificatesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setSslCertificates( - params?: Params$Resource$Targethttpsproxies$Setsslcertificates, - options?: MethodOptions - ): GaxiosPromise; - setSslCertificates( - params: Params$Resource$Targethttpsproxies$Setsslcertificates, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setSslCertificates( - params: Params$Resource$Targethttpsproxies$Setsslcertificates, - callback: BodyResponseCallback - ): void; - setSslCertificates(callback: BodyResponseCallback): void; - setSslCertificates( - paramsOrCallback?: - | Params$Resource$Targethttpsproxies$Setsslcertificates - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpsproxies$Setsslcertificates; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpsproxies$Setsslcertificates; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/targetHttpsProxies/{targetHttpsProxy}/setSslCertificates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'targetHttpsProxy'], - pathParams: ['project', 'targetHttpsProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpsProxies.setSslPolicy - * @desc Sets the SSL policy for TargetHttpsProxy. The SSL policy specifies the server-side support for SSL features. This affects connections between clients and the HTTPS proxy load balancer. They do not affect the connection between the load balancer and the backends. - * @alias compute.targetHttpsProxies.setSslPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetHttpsProxy Name of the TargetHttpsProxy resource whose SSL policy is to be set. The name must be 1-63 characters long, and comply with RFC1035. - * @param {().SslPolicyReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setSslPolicy( - params?: Params$Resource$Targethttpsproxies$Setsslpolicy, - options?: MethodOptions - ): GaxiosPromise; - setSslPolicy( - params: Params$Resource$Targethttpsproxies$Setsslpolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setSslPolicy( - params: Params$Resource$Targethttpsproxies$Setsslpolicy, - callback: BodyResponseCallback - ): void; - setSslPolicy(callback: BodyResponseCallback): void; - setSslPolicy( - paramsOrCallback?: - | Params$Resource$Targethttpsproxies$Setsslpolicy - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpsproxies$Setsslpolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpsproxies$Setsslpolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetHttpsProxies/{targetHttpsProxy}/setSslPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'targetHttpsProxy'], - pathParams: ['project', 'targetHttpsProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpsProxies.setUrlMap - * @desc Changes the URL map for TargetHttpsProxy. - * @alias compute.targetHttpsProxies.setUrlMap - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetHttpsProxy Name of the TargetHttpsProxy resource whose URL map is to be set. - * @param {().UrlMapReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setUrlMap( - params?: Params$Resource$Targethttpsproxies$Seturlmap, - options?: MethodOptions - ): GaxiosPromise; - setUrlMap( - params: Params$Resource$Targethttpsproxies$Seturlmap, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setUrlMap( - params: Params$Resource$Targethttpsproxies$Seturlmap, - callback: BodyResponseCallback - ): void; - setUrlMap(callback: BodyResponseCallback): void; - setUrlMap( - paramsOrCallback?: - | Params$Resource$Targethttpsproxies$Seturlmap - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpsproxies$Seturlmap; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpsproxies$Seturlmap; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/targetHttpsProxies/{targetHttpsProxy}/setUrlMap' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'targetHttpsProxy'], - pathParams: ['project', 'targetHttpsProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetHttpsProxies.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.targetHttpsProxies.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Targethttpsproxies$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Targethttpsproxies$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Targethttpsproxies$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Targethttpsproxies$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targethttpsproxies$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targethttpsproxies$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetHttpsProxies/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Targethttpsproxies$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Name of the project scoping this request. - */ - project?: string; - } - export interface Params$Resource$Targethttpsproxies$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetHttpsProxy resource to delete. - */ - targetHttpsProxy?: string; - } - export interface Params$Resource$Targethttpsproxies$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the TargetHttpsProxy resource to return. - */ - targetHttpsProxy?: string; - } - export interface Params$Resource$Targethttpsproxies$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetHttpsProxy; - } - export interface Params$Resource$Targethttpsproxies$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Targethttpsproxies$Setquicoverride - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetHttpsProxy resource to set the QUIC override policy for. The name should conform to RFC1035. - */ - targetHttpsProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetHttpsProxiesSetQuicOverrideRequest; - } - export interface Params$Resource$Targethttpsproxies$Setsslcertificates - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetHttpsProxy resource to set an SslCertificates resource for. - */ - targetHttpsProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetHttpsProxiesSetSslCertificatesRequest; - } - export interface Params$Resource$Targethttpsproxies$Setsslpolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetHttpsProxy resource whose SSL policy is to be set. The name must be 1-63 characters long, and comply with RFC1035. - */ - targetHttpsProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SslPolicyReference; - } - export interface Params$Resource$Targethttpsproxies$Seturlmap - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetHttpsProxy resource whose URL map is to be set. - */ - targetHttpsProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$UrlMapReference; - } - export interface Params$Resource$Targethttpsproxies$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Targetinstances { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.targetInstances.aggregatedList - * @desc Retrieves an aggregated list of target instances. - * @alias compute.targetInstances.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Targetinstances$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Targetinstances$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Targetinstances$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Targetinstances$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetinstances$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetinstances$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/targetInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.targetInstances.delete - * @desc Deletes the specified TargetInstance resource. - * @alias compute.targetInstances.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetInstance Name of the TargetInstance resource to delete. - * @param {string} params.zone Name of the zone scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Targetinstances$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Targetinstances$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Targetinstances$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Targetinstances$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetinstances$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetinstances$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/targetInstances/{targetInstance}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'targetInstance'], - pathParams: ['project', 'targetInstance', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetInstances.get - * @desc Returns the specified TargetInstance resource. Gets a list of available target instances by making a list() request. - * @alias compute.targetInstances.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.targetInstance Name of the TargetInstance resource to return. - * @param {string} params.zone Name of the zone scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Targetinstances$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Targetinstances$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Targetinstances$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Targetinstances$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetinstances$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetinstances$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/targetInstances/{targetInstance}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'targetInstance'], - pathParams: ['project', 'targetInstance', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetInstances.insert - * @desc Creates a TargetInstance resource in the specified project and zone using the data included in the request. - * @alias compute.targetInstances.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.zone Name of the zone scoping this request. - * @param {().TargetInstance} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Targetinstances$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Targetinstances$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Targetinstances$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Targetinstances$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetinstances$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetinstances$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/targetInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetInstances.list - * @desc Retrieves a list of TargetInstance resources available to the specified project and zone. - * @alias compute.targetInstances.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone Name of the zone scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Targetinstances$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Targetinstances$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Targetinstances$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Targetinstances$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetinstances$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetinstances$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/targetInstances' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetInstances.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.targetInstances.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {string} params.zone The name of the zone for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Targetinstances$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Targetinstances$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Targetinstances$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Targetinstances$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetinstances$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetinstances$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/targetInstances/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'resource'], - pathParams: ['project', 'resource', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Targetinstances$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Targetinstances$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetInstance resource to delete. - */ - targetInstance?: string; - /** - * Name of the zone scoping this request. - */ - zone?: string; - } - export interface Params$Resource$Targetinstances$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the TargetInstance resource to return. - */ - targetInstance?: string; - /** - * Name of the zone scoping this request. - */ - zone?: string; - } - export interface Params$Resource$Targetinstances$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the zone scoping this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetInstance; - } - export interface Params$Resource$Targetinstances$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the zone scoping this request. - */ - zone?: string; - } - export interface Params$Resource$Targetinstances$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - /** - * The name of the zone for this request. - */ - zone?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Targetpools { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.targetPools.addHealthCheck - * @desc Adds health check URLs to a target pool. - * @alias compute.targetPools.addHealthCheck - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetPool Name of the target pool to add a health check to. - * @param {().TargetPoolsAddHealthCheckRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addHealthCheck( - params?: Params$Resource$Targetpools$Addhealthcheck, - options?: MethodOptions - ): GaxiosPromise; - addHealthCheck( - params: Params$Resource$Targetpools$Addhealthcheck, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addHealthCheck( - params: Params$Resource$Targetpools$Addhealthcheck, - callback: BodyResponseCallback - ): void; - addHealthCheck(callback: BodyResponseCallback): void; - addHealthCheck( - paramsOrCallback?: - | Params$Resource$Targetpools$Addhealthcheck - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetpools$Addhealthcheck; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetpools$Addhealthcheck; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetPools/{targetPool}/addHealthCheck' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetPool'], - pathParams: ['project', 'region', 'targetPool'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetPools.addInstance - * @desc Adds an instance to a target pool. - * @alias compute.targetPools.addInstance - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetPool Name of the TargetPool resource to add instances to. - * @param {().TargetPoolsAddInstanceRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - addInstance( - params?: Params$Resource$Targetpools$Addinstance, - options?: MethodOptions - ): GaxiosPromise; - addInstance( - params: Params$Resource$Targetpools$Addinstance, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - addInstance( - params: Params$Resource$Targetpools$Addinstance, - callback: BodyResponseCallback - ): void; - addInstance(callback: BodyResponseCallback): void; - addInstance( - paramsOrCallback?: - | Params$Resource$Targetpools$Addinstance - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetpools$Addinstance; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetpools$Addinstance; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetPools/{targetPool}/addInstance' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetPool'], - pathParams: ['project', 'region', 'targetPool'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetPools.aggregatedList - * @desc Retrieves an aggregated list of target pools. - * @alias compute.targetPools.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Targetpools$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Targetpools$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Targetpools$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Targetpools$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetpools$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetpools$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/targetPools' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetPools.delete - * @desc Deletes the specified target pool. - * @alias compute.targetPools.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetPool Name of the TargetPool resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Targetpools$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Targetpools$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Targetpools$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Targetpools$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetpools$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetpools$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetPools/{targetPool}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetPool'], - pathParams: ['project', 'region', 'targetPool'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetPools.get - * @desc Returns the specified target pool. Gets a list of available target pools by making a list() request. - * @alias compute.targetPools.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string} params.targetPool Name of the TargetPool resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Targetpools$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Targetpools$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Targetpools$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Targetpools$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Targetpools$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetpools$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetPools/{targetPool}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetPool'], - pathParams: ['project', 'region', 'targetPool'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetPools.getHealth - * @desc Gets the most recent health check results for each IP for the instance that is referenced by the given target pool. - * @alias compute.targetPools.getHealth - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string} params.targetPool Name of the TargetPool resource to which the queried instance belongs. - * @param {().InstanceReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getHealth( - params?: Params$Resource$Targetpools$Gethealth, - options?: MethodOptions - ): GaxiosPromise; - getHealth( - params: Params$Resource$Targetpools$Gethealth, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getHealth( - params: Params$Resource$Targetpools$Gethealth, - callback: BodyResponseCallback - ): void; - getHealth( - callback: BodyResponseCallback - ): void; - getHealth( - paramsOrCallback?: - | Params$Resource$Targetpools$Gethealth - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetpools$Gethealth; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetpools$Gethealth; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetPools/{targetPool}/getHealth' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetPool'], - pathParams: ['project', 'region', 'targetPool'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetPools.insert - * @desc Creates a target pool in the specified project and region using the data included in the request. - * @alias compute.targetPools.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().TargetPool} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Targetpools$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Targetpools$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Targetpools$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Targetpools$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetpools$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetpools$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetPools' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetPools.list - * @desc Retrieves a list of target pools available to the specified project and region. - * @alias compute.targetPools.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Targetpools$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Targetpools$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Targetpools$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Targetpools$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Targetpools$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetpools$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetPools' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetPools.removeHealthCheck - * @desc Removes health check URL from a target pool. - * @alias compute.targetPools.removeHealthCheck - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetPool Name of the target pool to remove health checks from. - * @param {().TargetPoolsRemoveHealthCheckRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - removeHealthCheck( - params?: Params$Resource$Targetpools$Removehealthcheck, - options?: MethodOptions - ): GaxiosPromise; - removeHealthCheck( - params: Params$Resource$Targetpools$Removehealthcheck, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - removeHealthCheck( - params: Params$Resource$Targetpools$Removehealthcheck, - callback: BodyResponseCallback - ): void; - removeHealthCheck(callback: BodyResponseCallback): void; - removeHealthCheck( - paramsOrCallback?: - | Params$Resource$Targetpools$Removehealthcheck - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetpools$Removehealthcheck; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetpools$Removehealthcheck; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetPools/{targetPool}/removeHealthCheck' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetPool'], - pathParams: ['project', 'region', 'targetPool'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetPools.removeInstance - * @desc Removes instance URL from a target pool. - * @alias compute.targetPools.removeInstance - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetPool Name of the TargetPool resource to remove instances from. - * @param {().TargetPoolsRemoveInstanceRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - removeInstance( - params?: Params$Resource$Targetpools$Removeinstance, - options?: MethodOptions - ): GaxiosPromise; - removeInstance( - params: Params$Resource$Targetpools$Removeinstance, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - removeInstance( - params: Params$Resource$Targetpools$Removeinstance, - callback: BodyResponseCallback - ): void; - removeInstance(callback: BodyResponseCallback): void; - removeInstance( - paramsOrCallback?: - | Params$Resource$Targetpools$Removeinstance - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetpools$Removeinstance; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetpools$Removeinstance; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetPools/{targetPool}/removeInstance' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetPool'], - pathParams: ['project', 'region', 'targetPool'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetPools.setBackup - * @desc Changes a backup target pool's configurations. - * @alias compute.targetPools.setBackup - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {number=} params.failoverRatio New failoverRatio value for the target pool. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region scoping this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetPool Name of the TargetPool resource to set a backup pool for. - * @param {().TargetReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setBackup( - params?: Params$Resource$Targetpools$Setbackup, - options?: MethodOptions - ): GaxiosPromise; - setBackup( - params: Params$Resource$Targetpools$Setbackup, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setBackup( - params: Params$Resource$Targetpools$Setbackup, - callback: BodyResponseCallback - ): void; - setBackup(callback: BodyResponseCallback): void; - setBackup( - paramsOrCallback?: - | Params$Resource$Targetpools$Setbackup - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetpools$Setbackup; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetpools$Setbackup; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetPools/{targetPool}/setBackup' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetPool'], - pathParams: ['project', 'region', 'targetPool'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetPools.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.targetPools.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Targetpools$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Targetpools$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Targetpools$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Targetpools$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetpools$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetpools$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetPools/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Targetpools$Addhealthcheck - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the target pool to add a health check to. - */ - targetPool?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetPoolsAddHealthCheckRequest; - } - export interface Params$Resource$Targetpools$Addinstance - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetPool resource to add instances to. - */ - targetPool?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetPoolsAddInstanceRequest; - } - export interface Params$Resource$Targetpools$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Targetpools$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetPool resource to delete. - */ - targetPool?: string; - } - export interface Params$Resource$Targetpools$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * Name of the TargetPool resource to return. - */ - targetPool?: string; - } - export interface Params$Resource$Targetpools$Gethealth - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * Name of the TargetPool resource to which the queried instance belongs. - */ - targetPool?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstanceReference; - } - export interface Params$Resource$Targetpools$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetPool; - } - export interface Params$Resource$Targetpools$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - } - export interface Params$Resource$Targetpools$Removehealthcheck - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the target pool to remove health checks from. - */ - targetPool?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetPoolsRemoveHealthCheckRequest; - } - export interface Params$Resource$Targetpools$Removeinstance - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetPool resource to remove instances from. - */ - targetPool?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetPoolsRemoveInstanceRequest; - } - export interface Params$Resource$Targetpools$Setbackup - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * New failoverRatio value for the target pool. - */ - failoverRatio?: number; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region scoping this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetPool resource to set a backup pool for. - */ - targetPool?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetReference; - } - export interface Params$Resource$Targetpools$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Targetsslproxies { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.targetSslProxies.delete - * @desc Deletes the specified TargetSslProxy resource. - * @alias compute.targetSslProxies.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetSslProxy Name of the TargetSslProxy resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Targetsslproxies$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Targetsslproxies$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Targetsslproxies$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Targetsslproxies$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetsslproxies$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetsslproxies$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetSslProxies/{targetSslProxy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'targetSslProxy'], - pathParams: ['project', 'targetSslProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetSslProxies.get - * @desc Returns the specified TargetSslProxy resource. Gets a list of available target SSL proxies by making a list() request. - * @alias compute.targetSslProxies.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.targetSslProxy Name of the TargetSslProxy resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Targetsslproxies$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Targetsslproxies$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Targetsslproxies$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Targetsslproxies$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetsslproxies$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetsslproxies$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetSslProxies/{targetSslProxy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'targetSslProxy'], - pathParams: ['project', 'targetSslProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetSslProxies.insert - * @desc Creates a TargetSslProxy resource in the specified project using the data included in the request. - * @alias compute.targetSslProxies.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().TargetSslProxy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Targetsslproxies$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Targetsslproxies$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Targetsslproxies$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Targetsslproxies$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetsslproxies$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetsslproxies$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetSslProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetSslProxies.list - * @desc Retrieves the list of TargetSslProxy resources available to the specified project. - * @alias compute.targetSslProxies.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Targetsslproxies$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Targetsslproxies$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Targetsslproxies$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Targetsslproxies$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetsslproxies$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetsslproxies$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetSslProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetSslProxies.setBackendService - * @desc Changes the BackendService for TargetSslProxy. - * @alias compute.targetSslProxies.setBackendService - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetSslProxy Name of the TargetSslProxy resource whose BackendService resource is to be set. - * @param {().TargetSslProxiesSetBackendServiceRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setBackendService( - params?: Params$Resource$Targetsslproxies$Setbackendservice, - options?: MethodOptions - ): GaxiosPromise; - setBackendService( - params: Params$Resource$Targetsslproxies$Setbackendservice, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setBackendService( - params: Params$Resource$Targetsslproxies$Setbackendservice, - callback: BodyResponseCallback - ): void; - setBackendService(callback: BodyResponseCallback): void; - setBackendService( - paramsOrCallback?: - | Params$Resource$Targetsslproxies$Setbackendservice - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetsslproxies$Setbackendservice; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetsslproxies$Setbackendservice; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetSslProxies/{targetSslProxy}/setBackendService' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'targetSslProxy'], - pathParams: ['project', 'targetSslProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetSslProxies.setProxyHeader - * @desc Changes the ProxyHeaderType for TargetSslProxy. - * @alias compute.targetSslProxies.setProxyHeader - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetSslProxy Name of the TargetSslProxy resource whose ProxyHeader is to be set. - * @param {().TargetSslProxiesSetProxyHeaderRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setProxyHeader( - params?: Params$Resource$Targetsslproxies$Setproxyheader, - options?: MethodOptions - ): GaxiosPromise; - setProxyHeader( - params: Params$Resource$Targetsslproxies$Setproxyheader, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setProxyHeader( - params: Params$Resource$Targetsslproxies$Setproxyheader, - callback: BodyResponseCallback - ): void; - setProxyHeader(callback: BodyResponseCallback): void; - setProxyHeader( - paramsOrCallback?: - | Params$Resource$Targetsslproxies$Setproxyheader - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetsslproxies$Setproxyheader; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetsslproxies$Setproxyheader; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetSslProxies/{targetSslProxy}/setProxyHeader' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'targetSslProxy'], - pathParams: ['project', 'targetSslProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetSslProxies.setSslCertificates - * @desc Changes SslCertificates for TargetSslProxy. - * @alias compute.targetSslProxies.setSslCertificates - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetSslProxy Name of the TargetSslProxy resource whose SslCertificate resource is to be set. - * @param {().TargetSslProxiesSetSslCertificatesRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setSslCertificates( - params?: Params$Resource$Targetsslproxies$Setsslcertificates, - options?: MethodOptions - ): GaxiosPromise; - setSslCertificates( - params: Params$Resource$Targetsslproxies$Setsslcertificates, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setSslCertificates( - params: Params$Resource$Targetsslproxies$Setsslcertificates, - callback: BodyResponseCallback - ): void; - setSslCertificates(callback: BodyResponseCallback): void; - setSslCertificates( - paramsOrCallback?: - | Params$Resource$Targetsslproxies$Setsslcertificates - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetsslproxies$Setsslcertificates; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetsslproxies$Setsslcertificates; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetSslProxies/{targetSslProxy}/setSslCertificates' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'targetSslProxy'], - pathParams: ['project', 'targetSslProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetSslProxies.setSslPolicy - * @desc Sets the SSL policy for TargetSslProxy. The SSL policy specifies the server-side support for SSL features. This affects connections between clients and the SSL proxy load balancer. They do not affect the connection between the load balancer and the backends. - * @alias compute.targetSslProxies.setSslPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetSslProxy Name of the TargetSslProxy resource whose SSL policy is to be set. The name must be 1-63 characters long, and comply with RFC1035. - * @param {().SslPolicyReference} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setSslPolicy( - params?: Params$Resource$Targetsslproxies$Setsslpolicy, - options?: MethodOptions - ): GaxiosPromise; - setSslPolicy( - params: Params$Resource$Targetsslproxies$Setsslpolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setSslPolicy( - params: Params$Resource$Targetsslproxies$Setsslpolicy, - callback: BodyResponseCallback - ): void; - setSslPolicy(callback: BodyResponseCallback): void; - setSslPolicy( - paramsOrCallback?: - | Params$Resource$Targetsslproxies$Setsslpolicy - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetsslproxies$Setsslpolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetsslproxies$Setsslpolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetSslProxies/{targetSslProxy}/setSslPolicy' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'targetSslProxy'], - pathParams: ['project', 'targetSslProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetSslProxies.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.targetSslProxies.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Targetsslproxies$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Targetsslproxies$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Targetsslproxies$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Targetsslproxies$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetsslproxies$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetsslproxies$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetSslProxies/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Targetsslproxies$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetSslProxy resource to delete. - */ - targetSslProxy?: string; - } - export interface Params$Resource$Targetsslproxies$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the TargetSslProxy resource to return. - */ - targetSslProxy?: string; - } - export interface Params$Resource$Targetsslproxies$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetSslProxy; - } - export interface Params$Resource$Targetsslproxies$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Targetsslproxies$Setbackendservice - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetSslProxy resource whose BackendService resource is to be set. - */ - targetSslProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetSslProxiesSetBackendServiceRequest; - } - export interface Params$Resource$Targetsslproxies$Setproxyheader - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetSslProxy resource whose ProxyHeader is to be set. - */ - targetSslProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetSslProxiesSetProxyHeaderRequest; - } - export interface Params$Resource$Targetsslproxies$Setsslcertificates - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetSslProxy resource whose SslCertificate resource is to be set. - */ - targetSslProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetSslProxiesSetSslCertificatesRequest; - } - export interface Params$Resource$Targetsslproxies$Setsslpolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetSslProxy resource whose SSL policy is to be set. The name must be 1-63 characters long, and comply with RFC1035. - */ - targetSslProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SslPolicyReference; - } - export interface Params$Resource$Targetsslproxies$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Targettcpproxies { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.targetTcpProxies.delete - * @desc Deletes the specified TargetTcpProxy resource. - * @alias compute.targetTcpProxies.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetTcpProxy Name of the TargetTcpProxy resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Targettcpproxies$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Targettcpproxies$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Targettcpproxies$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Targettcpproxies$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targettcpproxies$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targettcpproxies$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetTcpProxies/{targetTcpProxy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'targetTcpProxy'], - pathParams: ['project', 'targetTcpProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetTcpProxies.get - * @desc Returns the specified TargetTcpProxy resource. Gets a list of available target TCP proxies by making a list() request. - * @alias compute.targetTcpProxies.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.targetTcpProxy Name of the TargetTcpProxy resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Targettcpproxies$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Targettcpproxies$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Targettcpproxies$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Targettcpproxies$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targettcpproxies$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targettcpproxies$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetTcpProxies/{targetTcpProxy}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'targetTcpProxy'], - pathParams: ['project', 'targetTcpProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetTcpProxies.insert - * @desc Creates a TargetTcpProxy resource in the specified project using the data included in the request. - * @alias compute.targetTcpProxies.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().TargetTcpProxy} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Targettcpproxies$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Targettcpproxies$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Targettcpproxies$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Targettcpproxies$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targettcpproxies$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targettcpproxies$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetTcpProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetTcpProxies.list - * @desc Retrieves the list of TargetTcpProxy resources available to the specified project. - * @alias compute.targetTcpProxies.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Targettcpproxies$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Targettcpproxies$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Targettcpproxies$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Targettcpproxies$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targettcpproxies$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targettcpproxies$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetTcpProxies' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetTcpProxies.setBackendService - * @desc Changes the BackendService for TargetTcpProxy. - * @alias compute.targetTcpProxies.setBackendService - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetTcpProxy Name of the TargetTcpProxy resource whose BackendService resource is to be set. - * @param {().TargetTcpProxiesSetBackendServiceRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setBackendService( - params?: Params$Resource$Targettcpproxies$Setbackendservice, - options?: MethodOptions - ): GaxiosPromise; - setBackendService( - params: Params$Resource$Targettcpproxies$Setbackendservice, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setBackendService( - params: Params$Resource$Targettcpproxies$Setbackendservice, - callback: BodyResponseCallback - ): void; - setBackendService(callback: BodyResponseCallback): void; - setBackendService( - paramsOrCallback?: - | Params$Resource$Targettcpproxies$Setbackendservice - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targettcpproxies$Setbackendservice; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targettcpproxies$Setbackendservice; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetTcpProxies/{targetTcpProxy}/setBackendService' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'targetTcpProxy'], - pathParams: ['project', 'targetTcpProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetTcpProxies.setProxyHeader - * @desc Changes the ProxyHeaderType for TargetTcpProxy. - * @alias compute.targetTcpProxies.setProxyHeader - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetTcpProxy Name of the TargetTcpProxy resource whose ProxyHeader is to be set. - * @param {().TargetTcpProxiesSetProxyHeaderRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setProxyHeader( - params?: Params$Resource$Targettcpproxies$Setproxyheader, - options?: MethodOptions - ): GaxiosPromise; - setProxyHeader( - params: Params$Resource$Targettcpproxies$Setproxyheader, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setProxyHeader( - params: Params$Resource$Targettcpproxies$Setproxyheader, - callback: BodyResponseCallback - ): void; - setProxyHeader(callback: BodyResponseCallback): void; - setProxyHeader( - paramsOrCallback?: - | Params$Resource$Targettcpproxies$Setproxyheader - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targettcpproxies$Setproxyheader; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targettcpproxies$Setproxyheader; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetTcpProxies/{targetTcpProxy}/setProxyHeader' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'targetTcpProxy'], - pathParams: ['project', 'targetTcpProxy'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetTcpProxies.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.targetTcpProxies.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Targettcpproxies$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Targettcpproxies$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Targettcpproxies$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Targettcpproxies$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targettcpproxies$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targettcpproxies$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/targetTcpProxies/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Targettcpproxies$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetTcpProxy resource to delete. - */ - targetTcpProxy?: string; - } - export interface Params$Resource$Targettcpproxies$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the TargetTcpProxy resource to return. - */ - targetTcpProxy?: string; - } - export interface Params$Resource$Targettcpproxies$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetTcpProxy; - } - export interface Params$Resource$Targettcpproxies$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Targettcpproxies$Setbackendservice - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetTcpProxy resource whose BackendService resource is to be set. - */ - targetTcpProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetTcpProxiesSetBackendServiceRequest; - } - export interface Params$Resource$Targettcpproxies$Setproxyheader - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the TargetTcpProxy resource whose ProxyHeader is to be set. - */ - targetTcpProxy?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetTcpProxiesSetProxyHeaderRequest; - } - export interface Params$Resource$Targettcpproxies$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Targetvpngateways { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.targetVpnGateways.aggregatedList - * @desc Retrieves an aggregated list of target VPN gateways. - * @alias compute.targetVpnGateways.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Targetvpngateways$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Targetvpngateways$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Targetvpngateways$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Targetvpngateways$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetvpngateways$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetvpngateways$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/targetVpnGateways' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.targetVpnGateways.delete - * @desc Deletes the specified target VPN gateway. - * @alias compute.targetVpnGateways.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.targetVpnGateway Name of the target VPN gateway to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Targetvpngateways$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Targetvpngateways$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Targetvpngateways$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Targetvpngateways$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetvpngateways$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetvpngateways$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetVpnGateways/{targetVpnGateway}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetVpnGateway'], - pathParams: ['project', 'region', 'targetVpnGateway'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetVpnGateways.get - * @desc Returns the specified target VPN gateway. Gets a list of available target VPN gateways by making a list() request. - * @alias compute.targetVpnGateways.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string} params.targetVpnGateway Name of the target VPN gateway to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Targetvpngateways$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Targetvpngateways$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Targetvpngateways$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Targetvpngateways$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetvpngateways$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetvpngateways$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetVpnGateways/{targetVpnGateway}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'targetVpnGateway'], - pathParams: ['project', 'region', 'targetVpnGateway'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetVpnGateways.insert - * @desc Creates a target VPN gateway in the specified project and region using the data included in the request. - * @alias compute.targetVpnGateways.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().TargetVpnGateway} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Targetvpngateways$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Targetvpngateways$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Targetvpngateways$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Targetvpngateways$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetvpngateways$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetvpngateways$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetVpnGateways' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetVpnGateways.list - * @desc Retrieves a list of target VPN gateways available to the specified project and region. - * @alias compute.targetVpnGateways.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Targetvpngateways$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Targetvpngateways$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Targetvpngateways$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Targetvpngateways$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetvpngateways$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetvpngateways$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetVpnGateways' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetVpnGateways.setLabels - * @desc Sets the labels on a TargetVpnGateway. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.targetVpnGateways.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().RegionSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Targetvpngateways$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Targetvpngateways$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Targetvpngateways$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Targetvpngateways$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetvpngateways$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetvpngateways$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetVpnGateways/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.targetVpnGateways.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.targetVpnGateways.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Targetvpngateways$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Targetvpngateways$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Targetvpngateways$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Targetvpngateways$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Targetvpngateways$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Targetvpngateways$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/targetVpnGateways/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Targetvpngateways$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Targetvpngateways$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the target VPN gateway to delete. - */ - targetVpnGateway?: string; - } - export interface Params$Resource$Targetvpngateways$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * Name of the target VPN gateway to return. - */ - targetVpnGateway?: string; - } - export interface Params$Resource$Targetvpngateways$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TargetVpnGateway; - } - export interface Params$Resource$Targetvpngateways$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Targetvpngateways$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionSetLabelsRequest; - } - export interface Params$Resource$Targetvpngateways$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Urlmaps { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.urlMaps.aggregatedList - * @desc Retrieves the list of all UrlMap resources, regional and global, available to the specified project. - * @alias compute.urlMaps.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Name of the project scoping this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Urlmaps$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Urlmaps$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Urlmaps$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Urlmaps$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Urlmaps$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Urlmaps$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/aggregated/urlMaps' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.urlMaps.delete - * @desc Deletes the specified UrlMap resource. - * @alias compute.urlMaps.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.urlMap Name of the UrlMap resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Urlmaps$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Urlmaps$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Urlmaps$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Urlmaps$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Urlmaps$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Urlmaps$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/urlMaps/{urlMap}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'urlMap'], - pathParams: ['project', 'urlMap'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.urlMaps.get - * @desc Returns the specified UrlMap resource. Gets a list of available URL maps by making a list() request. - * @alias compute.urlMaps.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.urlMap Name of the UrlMap resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Urlmaps$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Urlmaps$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Urlmaps$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Urlmaps$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Urlmaps$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Urlmaps$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/urlMaps/{urlMap}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'urlMap'], - pathParams: ['project', 'urlMap'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.urlMaps.insert - * @desc Creates a UrlMap resource in the specified project using the data included in the request. - * @alias compute.urlMaps.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().UrlMap} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Urlmaps$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Urlmaps$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Urlmaps$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Urlmaps$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Urlmaps$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Urlmaps$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/urlMaps' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.urlMaps.invalidateCache - * @desc Initiates a cache invalidation operation, invalidating the specified path, scoped to the specified UrlMap. - * @alias compute.urlMaps.invalidateCache - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.urlMap Name of the UrlMap scoping this request. - * @param {().CacheInvalidationRule} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - invalidateCache( - params?: Params$Resource$Urlmaps$Invalidatecache, - options?: MethodOptions - ): GaxiosPromise; - invalidateCache( - params: Params$Resource$Urlmaps$Invalidatecache, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - invalidateCache( - params: Params$Resource$Urlmaps$Invalidatecache, - callback: BodyResponseCallback - ): void; - invalidateCache(callback: BodyResponseCallback): void; - invalidateCache( - paramsOrCallback?: - | Params$Resource$Urlmaps$Invalidatecache - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Urlmaps$Invalidatecache; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Urlmaps$Invalidatecache; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/urlMaps/{urlMap}/invalidateCache' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'urlMap'], - pathParams: ['project', 'urlMap'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.urlMaps.list - * @desc Retrieves the list of UrlMap resources available to the specified project. - * @alias compute.urlMaps.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Urlmaps$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Urlmaps$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Urlmaps$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Urlmaps$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Urlmaps$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Urlmaps$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/global/urlMaps' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.urlMaps.patch - * @desc Patches the specified UrlMap resource with the data included in the request. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. - * @alias compute.urlMaps.patch - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.urlMap Name of the UrlMap resource to patch. - * @param {().UrlMap} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - patch( - params?: Params$Resource$Urlmaps$Patch, - options?: MethodOptions - ): GaxiosPromise; - patch( - params: Params$Resource$Urlmaps$Patch, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - patch( - params: Params$Resource$Urlmaps$Patch, - callback: BodyResponseCallback - ): void; - patch(callback: BodyResponseCallback): void; - patch( - paramsOrCallback?: - | Params$Resource$Urlmaps$Patch - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Urlmaps$Patch; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Urlmaps$Patch; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/urlMaps/{urlMap}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PATCH', - }, - options - ), - params, - requiredParams: ['project', 'urlMap'], - pathParams: ['project', 'urlMap'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.urlMaps.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.urlMaps.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Urlmaps$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Urlmaps$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Urlmaps$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Urlmaps$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Urlmaps$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Urlmaps$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/urlMaps/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'resource'], - pathParams: ['project', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.urlMaps.update - * @desc Updates the specified UrlMap resource with the data included in the request. - * @alias compute.urlMaps.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.urlMap Name of the UrlMap resource to update. - * @param {().UrlMap} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Urlmaps$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Urlmaps$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Urlmaps$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Urlmaps$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Urlmaps$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Urlmaps$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/urlMaps/{urlMap}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['project', 'urlMap'], - pathParams: ['project', 'urlMap'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.urlMaps.validate - * @desc Runs static validation for the UrlMap. In particular, the tests of the provided UrlMap will be run. Calling this method does NOT create the UrlMap. - * @alias compute.urlMaps.validate - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.urlMap Name of the UrlMap resource to be validated as. - * @param {().UrlMapsValidateRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - validate( - params?: Params$Resource$Urlmaps$Validate, - options?: MethodOptions - ): GaxiosPromise; - validate( - params: Params$Resource$Urlmaps$Validate, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - validate( - params: Params$Resource$Urlmaps$Validate, - callback: BodyResponseCallback - ): void; - validate( - callback: BodyResponseCallback - ): void; - validate( - paramsOrCallback?: - | Params$Resource$Urlmaps$Validate - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Urlmaps$Validate; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Urlmaps$Validate; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/global/urlMaps/{urlMap}/validate' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'urlMap'], - pathParams: ['project', 'urlMap'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Urlmaps$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Name of the project scoping this request. - */ - project?: string; - } - export interface Params$Resource$Urlmaps$Delete extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the UrlMap resource to delete. - */ - urlMap?: string; - } - export interface Params$Resource$Urlmaps$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the UrlMap resource to return. - */ - urlMap?: string; - } - export interface Params$Resource$Urlmaps$Insert extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$UrlMap; - } - export interface Params$Resource$Urlmaps$Invalidatecache - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the UrlMap scoping this request. - */ - urlMap?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$CacheInvalidationRule; - } - export interface Params$Resource$Urlmaps$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Urlmaps$Patch extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the UrlMap resource to patch. - */ - urlMap?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$UrlMap; - } - export interface Params$Resource$Urlmaps$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - export interface Params$Resource$Urlmaps$Update extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the UrlMap resource to update. - */ - urlMap?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$UrlMap; - } - export interface Params$Resource$Urlmaps$Validate extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the UrlMap resource to be validated as. - */ - urlMap?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$UrlMapsValidateRequest; - } - - export class Resource$Vpngateways { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.vpnGateways.aggregatedList - * @desc Retrieves an aggregated list of VPN gateways. - * @alias compute.vpnGateways.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Vpngateways$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Vpngateways$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Vpngateways$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Vpngateways$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Vpngateways$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpngateways$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/vpnGateways' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.vpnGateways.delete - * @desc Deletes the specified VPN gateway. - * @alias compute.vpnGateways.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.vpnGateway Name of the VPN gateway to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Vpngateways$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Vpngateways$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Vpngateways$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Vpngateways$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Vpngateways$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpngateways$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnGateways/{vpnGateway}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'vpnGateway'], - pathParams: ['project', 'region', 'vpnGateway'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.vpnGateways.get - * @desc Returns the specified VPN gateway. Gets a list of available VPN gateways by making a list() request. - * @alias compute.vpnGateways.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string} params.vpnGateway Name of the VPN gateway to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Vpngateways$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Vpngateways$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Vpngateways$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Vpngateways$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Vpngateways$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpngateways$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnGateways/{vpnGateway}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'vpnGateway'], - pathParams: ['project', 'region', 'vpnGateway'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.vpnGateways.getStatus - * @desc Returns the status for the specified VPN gateway. - * @alias compute.vpnGateways.getStatus - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string} params.vpnGateway Name of the VPN gateway to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getStatus( - params?: Params$Resource$Vpngateways$Getstatus, - options?: MethodOptions - ): GaxiosPromise; - getStatus( - params: Params$Resource$Vpngateways$Getstatus, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getStatus( - params: Params$Resource$Vpngateways$Getstatus, - callback: BodyResponseCallback - ): void; - getStatus( - callback: BodyResponseCallback - ): void; - getStatus( - paramsOrCallback?: - | Params$Resource$Vpngateways$Getstatus - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Vpngateways$Getstatus; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpngateways$Getstatus; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnGateways/{vpnGateway}/getStatus' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'vpnGateway'], - pathParams: ['project', 'region', 'vpnGateway'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * compute.vpnGateways.insert - * @desc Creates a VPN gateway in the specified project and region using the data included in the request. - * @alias compute.vpnGateways.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().VpnGateway} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Vpngateways$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Vpngateways$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Vpngateways$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Vpngateways$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Vpngateways$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpngateways$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnGateways' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.vpnGateways.list - * @desc Retrieves a list of VPN gateways available to the specified project and region. - * @alias compute.vpnGateways.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Vpngateways$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Vpngateways$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Vpngateways$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Vpngateways$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Vpngateways$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpngateways$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnGateways' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.vpnGateways.setLabels - * @desc Sets the labels on a VpnGateway. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.vpnGateways.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().RegionSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Vpngateways$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Vpngateways$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Vpngateways$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Vpngateways$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Vpngateways$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpngateways$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnGateways/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.vpnGateways.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.vpnGateways.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Vpngateways$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Vpngateways$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Vpngateways$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Vpngateways$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Vpngateways$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpngateways$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnGateways/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Vpngateways$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Vpngateways$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the VPN gateway to delete. - */ - vpnGateway?: string; - } - export interface Params$Resource$Vpngateways$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * Name of the VPN gateway to return. - */ - vpnGateway?: string; - } - export interface Params$Resource$Vpngateways$Getstatus - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * Name of the VPN gateway to return. - */ - vpnGateway?: string; - } - export interface Params$Resource$Vpngateways$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$VpnGateway; - } - export interface Params$Resource$Vpngateways$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Vpngateways$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionSetLabelsRequest; - } - export interface Params$Resource$Vpngateways$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Vpntunnels { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.vpnTunnels.aggregatedList - * @desc Retrieves an aggregated list of VPN tunnels. - * @alias compute.vpnTunnels.aggregatedList - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - aggregatedList( - params?: Params$Resource$Vpntunnels$Aggregatedlist, - options?: MethodOptions - ): GaxiosPromise; - aggregatedList( - params: Params$Resource$Vpntunnels$Aggregatedlist, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - aggregatedList( - params: Params$Resource$Vpntunnels$Aggregatedlist, - callback: BodyResponseCallback - ): void; - aggregatedList( - callback: BodyResponseCallback - ): void; - aggregatedList( - paramsOrCallback?: - | Params$Resource$Vpntunnels$Aggregatedlist - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Vpntunnels$Aggregatedlist; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpntunnels$Aggregatedlist; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/aggregated/vpnTunnels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.vpnTunnels.delete - * @desc Deletes the specified VpnTunnel resource. - * @alias compute.vpnTunnels.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.vpnTunnel Name of the VpnTunnel resource to delete. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Vpntunnels$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Vpntunnels$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Vpntunnels$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Vpntunnels$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Vpntunnels$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpntunnels$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnTunnels/{vpnTunnel}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'region', 'vpnTunnel'], - pathParams: ['project', 'region', 'vpnTunnel'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.vpnTunnels.get - * @desc Returns the specified VpnTunnel resource. Gets a list of available VPN tunnels by making a list() request. - * @alias compute.vpnTunnels.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string} params.vpnTunnel Name of the VpnTunnel resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Vpntunnels$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Vpntunnels$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Vpntunnels$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Vpntunnels$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Vpntunnels$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpntunnels$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnTunnels/{vpnTunnel}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region', 'vpnTunnel'], - pathParams: ['project', 'region', 'vpnTunnel'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.vpnTunnels.insert - * @desc Creates a VpnTunnel resource in the specified project and region using the data included in the request. - * @alias compute.vpnTunnels.insert - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {().VpnTunnel} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - insert( - params?: Params$Resource$Vpntunnels$Insert, - options?: MethodOptions - ): GaxiosPromise; - insert( - params: Params$Resource$Vpntunnels$Insert, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - insert( - params: Params$Resource$Vpntunnels$Insert, - callback: BodyResponseCallback - ): void; - insert(callback: BodyResponseCallback): void; - insert( - paramsOrCallback?: - | Params$Resource$Vpntunnels$Insert - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Vpntunnels$Insert; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpntunnels$Insert; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnTunnels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.vpnTunnels.list - * @desc Retrieves a list of VpnTunnel resources contained in the specified project and region. - * @alias compute.vpnTunnels.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.region Name of the region for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Vpntunnels$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Vpntunnels$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Vpntunnels$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Vpntunnels$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Vpntunnels$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpntunnels$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnTunnels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'region'], - pathParams: ['project', 'region'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.vpnTunnels.setLabels - * @desc Sets the labels on a VpnTunnel. To learn more about labels, read the Labeling Resources documentation. - * @alias compute.vpnTunnels.setLabels - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The region for this request. - * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().RegionSetLabelsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setLabels( - params?: Params$Resource$Vpntunnels$Setlabels, - options?: MethodOptions - ): GaxiosPromise; - setLabels( - params: Params$Resource$Vpntunnels$Setlabels, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setLabels( - params: Params$Resource$Vpntunnels$Setlabels, - callback: BodyResponseCallback - ): void; - setLabels(callback: BodyResponseCallback): void; - setLabels( - paramsOrCallback?: - | Params$Resource$Vpntunnels$Setlabels - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Vpntunnels$Setlabels; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpntunnels$Setlabels; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnTunnels/{resource}/setLabels' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.vpnTunnels.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. - * @alias compute.vpnTunnels.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.region The name of the region for this request. - * @param {string} params.resource_ Name or id of the resource for this request. - * @param {().TestPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Vpntunnels$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Vpntunnels$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Vpntunnels$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Vpntunnels$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Vpntunnels$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Vpntunnels$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/regions/{region}/vpnTunnels/{resource}/testIamPermissions' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'region', 'resource'], - pathParams: ['project', 'region', 'resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Vpntunnels$Aggregatedlist - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } - export interface Params$Resource$Vpntunnels$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name of the VpnTunnel resource to delete. - */ - vpnTunnel?: string; - } - export interface Params$Resource$Vpntunnels$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * Name of the VpnTunnel resource to return. - */ - vpnTunnel?: string; - } - export interface Params$Resource$Vpntunnels$Insert - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$VpnTunnel; - } - export interface Params$Resource$Vpntunnels$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the region for this request. - */ - region?: string; - } - export interface Params$Resource$Vpntunnels$Setlabels - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The region for this request. - */ - region?: string; - /** - * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). - */ - requestId?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$RegionSetLabelsRequest; - } - export interface Params$Resource$Vpntunnels$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * The name of the region for this request. - */ - region?: string; - /** - * Name or id of the resource for this request. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestPermissionsRequest; - } - - export class Resource$Zoneoperations { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.zoneOperations.delete - * @desc Deletes the specified zone-specific Operations resource. - * @alias compute.zoneOperations.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.operation Name of the Operations resource to delete. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone Name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Zoneoperations$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Zoneoperations$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Zoneoperations$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Zoneoperations$Delete - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Zoneoperations$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Zoneoperations$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/operations/{operation}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'operation'], - pathParams: ['operation', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.zoneOperations.get - * @desc Retrieves the specified zone-specific Operations resource. - * @alias compute.zoneOperations.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.operation Name of the Operations resource to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone Name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Zoneoperations$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Zoneoperations$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Zoneoperations$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Zoneoperations$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Zoneoperations$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Zoneoperations$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/operations/{operation}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'operation'], - pathParams: ['operation', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.zoneOperations.list - * @desc Retrieves a list of Operation resources contained within the specified zone. - * @alias compute.zoneOperations.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone Name of the zone for request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Zoneoperations$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Zoneoperations$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Zoneoperations$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Zoneoperations$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Zoneoperations$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Zoneoperations$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/operations' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.zoneOperations.wait - * @desc Waits for the specified zone-specific Operations resource until it is done or timeout, and retrieves the specified Operations resource. 1. Immediately returns when the operation is already done. 2. Waits for no more than the default deadline (2 minutes, subject to change) and then returns the current state of the operation, which may be DONE or still in progress. 3. Is best-effort: a. The server can wait less than the default deadline or zero seconds, in overload situations. b. There is no guarantee that the operation is actually done when returns. 4. User should be prepared to retry if the operation is not DONE. - * @alias compute.zoneOperations.wait - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.operation Name of the Operations resource to return. - * @param {string} params.project Project ID for this request. - * @param {string} params.zone Name of the zone for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - wait( - params?: Params$Resource$Zoneoperations$Wait, - options?: MethodOptions - ): GaxiosPromise; - wait( - params: Params$Resource$Zoneoperations$Wait, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - wait( - params: Params$Resource$Zoneoperations$Wait, - callback: BodyResponseCallback - ): void; - wait(callback: BodyResponseCallback): void; - wait( - paramsOrCallback?: - | Params$Resource$Zoneoperations$Wait - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Zoneoperations$Wait; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Zoneoperations$Wait; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/compute/alpha/projects/{project}/zones/{zone}/operations/{operation}/wait' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['project', 'zone', 'operation'], - pathParams: ['operation', 'project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Zoneoperations$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the Operations resource to delete. - */ - operation?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Zoneoperations$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the Operations resource to return. - */ - operation?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - } - export interface Params$Resource$Zoneoperations$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the zone for request. - */ - zone?: string; - } - export interface Params$Resource$Zoneoperations$Wait - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Name of the Operations resource to return. - */ - operation?: string; - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the zone for this request. - */ - zone?: string; - } - - export class Resource$Zones { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * compute.zones.get - * @desc Returns the specified Zone resource. Gets a list of available zones by making a list() request. - * @alias compute.zones.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.project Project ID for this request. - * @param {string} params.zone Name of the zone resource to return. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Zones$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Zones$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Zones$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Zones$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Zones$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Zones$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/compute/alpha/projects/{project}/zones/{zone}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project', 'zone'], - pathParams: ['project', 'zone'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * compute.zones.list - * @desc Retrieves the list of Zone resources available to the specified project. - * @alias compute.zones.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - * @param {string} params.project Project ID for this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Zones$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Zones$List, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Zones$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Zones$List - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Zones$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Zones$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/compute/alpha/projects/{project}/zones').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'GET', - }, - options - ), - params, - requiredParams: ['project'], - pathParams: ['project'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Zones$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Project ID for this request. - */ - project?: string; - /** - * Name of the zone resource to return. - */ - zone?: string; - } - export interface Params$Resource$Zones$List extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). - */ - filter?: string; - /** - * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) - */ - maxResults?: number; - /** - * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. - */ - orderBy?: string; - /** - * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. - */ - pageToken?: string; - /** - * Project ID for this request. - */ - project?: string; - } -} diff --git a/src/apis/compute/beta.ts b/src/apis/compute/beta.ts index 3cd048a3fc0..1369ec4a828 100644 --- a/src/apis/compute/beta.ts +++ b/src/apis/compute/beta.ts @@ -628,15 +628,15 @@ export namespace compute_beta { */ export interface Schema$AllocationSpecificSKUReservation { /** - * Specifies number of resources that are allocated. + * Specifies the number of resources that are allocated. */ count?: string; /** - * The instance properties for this specific sku reservation. + * The instance properties for the reservation. */ instanceProperties?: Schema$AllocationSpecificSKUAllocationReservedInstanceProperties; /** - * [OutputOnly] Indicates how many resource are in use. + * [OutputOnly] Indicates how many instances are in use. */ inUseCount?: string; } @@ -710,7 +710,7 @@ export namespace compute_beta { */ diskName?: string; /** - * Specifies the size of the disk in base-2 GB. + * Specifies the size of the disk in base-2 GB. If not specified, the disk will be the same size as the image (usually 10GB). If specified, the size must be equal to or larger than 10GB. */ diskSizeGb?: string; /** @@ -747,7 +747,7 @@ export namespace compute_beta { sourceSnapshotEncryptionKey?: Schema$CustomerEncryptionKey; } /** - * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "fooservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:bar@gmail.com" ] } ] } ] } For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts foo@gmail.com from DATA_READ logging, and bar@gmail.com from DATA_WRITE logging. + * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "sampleservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts jose@example.com from DATA_READ logging, and aliya@example.com from DATA_WRITE logging. */ export interface Schema$AuditConfig { /** @@ -761,13 +761,17 @@ export namespace compute_beta { service?: string; } /** - * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting foo@gmail.com from DATA_READ logging. + * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ logging. */ export interface Schema$AuditLogConfig { /** * Specifies the identities that do not cause logging for this type of permission. Follows the same format of [Binding.members][]. */ exemptedMembers?: string[]; + /** + * Specifies whether principals can be exempted for the same LogType in lower-level resource policies. If true, any lower-level exemptions will be ignored. + */ + ignoreChildExemptions?: boolean; /** * The log type that this config enables. */ @@ -999,7 +1003,7 @@ export namespace compute_beta { */ export interface Schema$Backend { /** - * Specifies the balancing mode for the backend. When choosing a balancing mode, you need to consider the loadBalancingScheme, and protocol for the backend service, as well as the type of backend (instance group or NEG). - If the load balancing mode is CONNECTION, then the load is spread based on how many concurrent connections the backend can handle. The CONNECTION balancing mode is only available if the protocol for the backend service is SSL, TCP, or UDP. If the loadBalancingScheme for the backend service is EXTERNAL (SSL Proxy and TCP Proxy load balancers), you must also specify exactly one of the following parameters: maxConnections, maxConnectionsPerInstance, or maxConnectionsPerEndpoint. If the loadBalancingScheme for the backend service is INTERNAL (internal TCP/UDP load balancers), you cannot specify any additional parameters. - If the load balancing mode is RATE, then the load is spread based on the rate of HTTP requests per second (RPS). The RATE balancing mode is only available if the protocol for the backend service is HTTP or HTTPS. You must specify exactly one of the following parameters: maxRate, maxRatePerInstance, or maxRatePerEndpoint. - If the load balancing mode is UTILIZATION, then the load is spread based on the CPU utilization of instances in an instance group. The UTILIZATION balancing mode is only available if the loadBalancingScheme of the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED and the backend is made up of instance groups. There are no restrictions on the backend service protocol. + * Specifies the balancing mode for the backend. When choosing a balancing mode, you need to consider the loadBalancingScheme, and protocol for the backend service, as well as the type of backend (instance group or NEG). - If the load balancing mode is CONNECTION, then the load is spread based on how many concurrent connections the backend can handle. You can use the CONNECTION balancing mode if the protocol for the backend service is SSL, TCP, or UDP. If the loadBalancingScheme for the backend service is EXTERNAL (SSL Proxy and TCP Proxy load balancers), you must also specify exactly one of the following parameters: maxConnections, maxConnectionsPerInstance, or maxConnectionsPerEndpoint. If the loadBalancingScheme for the backend service is INTERNAL (internal TCP/UDP load balancers), you cannot specify any additional parameters. - If the load balancing mode is RATE, the load is spread based on the rate of HTTP requests per second (RPS). You can use the RATE balancing mode if the protocol for the backend service is HTTP or HTTPS. You must specify exactly one of the following parameters: maxRate, maxRatePerInstance, or maxRatePerEndpoint. - If the load balancing mode is UTILIZATION, the load is spread based on the CPU utilization of instances in an instance group. You can use the UTILIZATION balancing mode if the loadBalancingScheme of the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED and the backends are instance groups. There are no restrictions on the backend service protocol. */ balancingMode?: string; /** @@ -1212,6 +1216,10 @@ export namespace compute_beta { * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. */ name?: string; + /** + * The URL of the network to which this backend service belongs. This field can only be spcified when the load balancing scheme is set to INTERNAL. + */ + network?: string; /** * Settings controlling eviction of unhealthy hosts from the load balancing pool. This field is applicable to either: - A regional backend service with the service_protocol set to HTTP, HTTPS, or HTTP2, and load_balancing_scheme set to INTERNAL_MANAGED. - A global backend service with the load_balancing_scheme set to INTERNAL_SELF_MANAGED. */ @@ -1241,7 +1249,7 @@ export namespace compute_beta { */ selfLink?: string; /** - * Type of session affinity to use. The default is NONE. Session affinity is not applicable if the --protocol is UDP. When the loadBalancingScheme is EXTERNAL, possible values are NONE, CLIENT_IP, or GENERATED_COOKIE. GENERATED_COOKIE is only available if the protocol is HTTP or HTTPS. When the loadBalancingScheme is INTERNAL, possible values are NONE, CLIENT_IP, CLIENT_IP_PROTO, or CLIENT_IP_PORT_PROTO. When the loadBalancingScheme is INTERNAL_SELF_MANAGED, possible values are NONE, CLIENT_IP, GENERATED_COOKIE, HEADER_FIELD, or HTTP_COOKIE. + * Type of session affinity to use. The default is NONE. Session affinity is not applicable if the --protocol is UDP. When the loadBalancingScheme is EXTERNAL, possible values are NONE, CLIENT_IP, or GENERATED_COOKIE. You can use GENERATED_COOKIE if the protocol is HTTP or HTTPS. When the loadBalancingScheme is INTERNAL, possible values are NONE, CLIENT_IP, CLIENT_IP_PROTO, or CLIENT_IP_PORT_PROTO. When the loadBalancingScheme is INTERNAL_SELF_MANAGED, possible values are NONE, CLIENT_IP, GENERATED_COOKIE, HEADER_FIELD, or HTTP_COOKIE. */ sessionAffinity?: string; /** @@ -1398,6 +1406,135 @@ export namespace compute_beta { message?: string; }; } + export interface Schema$BfdPacket { + /** + * The Authentication Present bit of the BFD packet. This is specified in section 4.1 of RFC5880 + */ + authenticationPresent?: boolean; + /** + * The Control Plane Independent bit of the BFD packet. This is specified in section 4.1 of RFC5880 + */ + controlPlaneIndependent?: boolean; + /** + * The demand bit of the BFD packet. This is specified in section 4.1 of RFC5880 + */ + demand?: boolean; + /** + * The diagnostic code specifies the local system's reason for the last change in session state. This allows remote systems to determine the reason that the previous session failed, for example. These diagnostic codes are specified in section 4.1 of RFC5880 + */ + diagnostic?: string; + /** + * The Final bit of the BFD packet. This is specified in section 4.1 of RFC5880 + */ + final?: boolean; + /** + * The length of the BFD Control packet in bytes. This is specified in section 4.1 of RFC5880 + */ + length?: number; + /** + * The Required Min Echo RX Interval value in the BFD packet. This is specified in section 4.1 of RFC5880 + */ + minEchoRxIntervalMs?: number; + /** + * The Required Min RX Interval value in the BFD packet. This is specified in section 4.1 of RFC5880 + */ + minRxIntervalMs?: number; + /** + * The Desired Min TX Interval value in the BFD packet. This is specified in section 4.1 of RFC5880 + */ + minTxIntervalMs?: number; + /** + * The detection time multiplier of the BFD packet. This is specified in section 4.1 of RFC5880 + */ + multiplier?: number; + /** + * The multipoint bit of the BFD packet. This is specified in section 4.1 of RFC5880 + */ + multipoint?: boolean; + /** + * The My Discriminator value in the BFD packet. This is specified in section 4.1 of RFC5880 + */ + myDiscriminator?: number; + /** + * The Poll bit of the BFD packet. This is specified in section 4.1 of RFC5880 + */ + poll?: boolean; + /** + * The current BFD session state as seen by the transmitting system. These states are specified in section 4.1 of RFC5880 + */ + state?: string; + /** + * The version number of the BFD protocol, as specified in section 4.1 of RFC5880. + */ + version?: number; + /** + * The Your Discriminator value in the BFD packet. This is specified in section 4.1 of RFC5880 + */ + yourDiscriminator?: number; + } + /** + * Next free: 15 + */ + export interface Schema$BfdStatus { + /** + * The BFD session initialization mode for this BGP peer. If set to ACTIVE, the Cloud Router will initiate the BFD session for this BGP peer. If set to PASSIVE, the Cloud Router will wait for the peer router to initiate the BFD session for this BGP peer. If set to DISABLED, BFD is disabled for this BGP peer. + */ + bfdSessionInitializationMode?: string; + /** + * Unix timestamp of the most recent config update. + */ + configUpdateTimestampMicros?: string; + /** + * Control packet counts for the current BFD session. + */ + controlPacketCounts?: Schema$BfdStatusPacketCounts; + /** + * Inter-packet time interval statistics for control packets. + */ + controlPacketIntervals?: Schema$PacketIntervals[]; + /** + * The diagnostic code specifies the local system's reason for the last change in session state. This allows remote systems to determine the reason that the previous session failed, for example. These diagnostic codes are specified in section 4.1 of RFC5880 + */ + localDiagnostic?: string; + /** + * The current BFD session state as seen by the transmitting system. These states are specified in section 4.1 of RFC5880 + */ + localState?: string; + /** + * Negotiated transmit interval for control packets. + */ + negotiatedLocalControlTxIntervalMs?: number; + /** + * The most recent Rx control packet for this BFD session. + */ + rxPacket?: Schema$BfdPacket; + /** + * The most recent Tx control packet for this BFD session. + */ + txPacket?: Schema$BfdPacket; + /** + * Session uptime in milliseconds. Value will be 0 if session is not up. + */ + uptimeMs?: string; + } + export interface Schema$BfdStatusPacketCounts { + /** + * Number of packets received since the beginning of the current BFD session. + */ + numRx?: number; + /** + * Number of packets received that were rejected because of errors since the beginning of the current BFD session. + */ + numRxRejected?: number; + /** + * Number of packets received that were successfully processed since the beginning of the current BFD session. + */ + numRxSuccessful?: number; + /** + * Number of packets transmitted since the beginning of the current BFD session. + */ + numTx?: number; + } /** * Associates `members` with a `role`. */ @@ -1407,7 +1544,7 @@ export namespace compute_beta { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -1513,7 +1650,7 @@ export namespace compute_beta { */ region?: string; /** - * List of reservations for this commitment. + * List of reservations in this commitment. */ reservations?: Schema$Reservation[]; /** @@ -1888,7 +2025,7 @@ export namespace compute_beta { */ sourceSnapshotId?: string; /** - * [Output Only] The status of disk creation. + * [Output Only] The status of disk creation. CREATING: Disk is provisioning. RESTORING: Source data is being copied into the disk. FAILED: Disk creation failed. READY: Disk is ready for use. DELETING: Disk is deleting. */ status?: string; /** @@ -2536,7 +2673,7 @@ export namespace compute_beta { */ id?: string; /** - * The IP address that this forwarding rule is serving on behalf of. Addresses are restricted based on the forwarding rule's load balancing scheme (EXTERNAL or INTERNAL) and scope (global or regional). When the load balancing scheme is EXTERNAL, for global forwarding rules, the address must be a global IP, and for regional forwarding rules, the address must live in the same region as the forwarding rule. If this field is empty, an ephemeral IPv4 address from the same scope (global or regional) will be assigned. A regional forwarding rule supports IPv4 only. A global forwarding rule supports either IPv4 or IPv6. When the load balancing scheme is INTERNAL_SELF_MANAGED, this must be a URL reference to an existing Address resource ( internal regional static IP address), with a purpose of GCE_END_POINT and address_type of INTERNAL. When the load balancing scheme is INTERNAL, this can only be an RFC 1918 IP address belonging to the network/subnet configured for the forwarding rule. By default, if this field is empty, an ephemeral internal IP address will be automatically allocated from the IP range of the subnet or network configured for this forwarding rule. An address can be specified either by a literal IP address or a URL reference to an existing Address resource. The following examples are all valid: - 100.1.2.3 - https://www.googleapis.com/compute/v1/projects/project/regions/region/addresses/address - projects/project/regions/region/addresses/address - regions/region/addresses/address - global/addresses/address - address + * IP address that this forwarding rule serves. When a client sends traffic to this IP address, the forwarding rule directs the traffic to the target that you specify in the forwarding rule. If you don't specify a reserved IP address, an ephemeral IP address is assigned. Methods for specifying an IP address: * IPv4 dotted decimal, as in `100.1.2.3` * Full URL, as in https://www.googleapis.com/compute/v1/projects/project_id/regions/region/addresses/address-name * Partial URL or by name, as in: * projects/project_id/regions/region/addresses/address-name * regions/region/addresses/address-name * global/addresses/address-name * address-name The loadBalancingScheme and the forwarding rule's target determine the type of IP address that you can use. For detailed information, refer to [IP address specifications](/load-balancing/docs/forwarding-rule-concepts#ip_address_specifications). */ IPAddress?: string; /** @@ -2580,11 +2717,11 @@ export namespace compute_beta { */ networkTier?: string; /** - * This field is used along with the target field for TargetHttpProxy, TargetHttpsProxy, TargetSslProxy, TargetTcpProxy, TargetVpnGateway, TargetPool, TargetInstance. Applicable only when IPProtocol is TCP, UDP, or SCTP, only packets addressed to ports in the specified range will be forwarded to target. Forwarding rules with the same [IPAddress, IPProtocol] pair must have disjoint port ranges. Some types of forwarding target have constraints on the acceptable ports: - TargetHttpProxy: 80, 8080 - TargetHttpsProxy: 443 - TargetTcpProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 - TargetSslProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 - TargetVpnGateway: 500, 4500 + * This field is deprecated. See the port field. */ portRange?: string; /** - * This field is used along with the backend_service field for internal load balancing. When the load balancing scheme is INTERNAL, a list of ports can be configured, for example, ['80'], ['8000','9000'] etc. Only packets addressed to these ports will be forwarded to the backends configured with this forwarding rule. You may specify a maximum of up to 5 ports. + * List of comma-separated ports. The forwarding rule forwards packets with matching destination ports. If the forwarding rule's loadBalancingScheme is EXTERNAL, and the forwarding rule references a target pool, specifying ports is optional. You can specify an unlimited number of ports, but they must be contiguous. If you omit ports, GCP forwards traffic on any port of the forwarding rule's protocol. If the forwarding rule's loadBalancingScheme is EXTERNAL, and the forwarding rule references a target HTTP proxy, target HTTPS proxy, target TCP proxy, target SSL proxy, or target VPN gateway, you must specify ports using the following constraints: - TargetHttpProxy: 80, 8080 - TargetHttpsProxy: 443 - TargetTcpProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 - TargetSslProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 - TargetVpnGateway: 500, 4500 If the forwarding rule's loadBalancingScheme is INTERNAL, you must specify ports in one of the following ways: * A list of up to five ports, which can be non-contiguous * Keyword ALL, which causes the forwarding rule to forward traffic on any port of the forwarding rule's protocol. The ports field is used along with the target field for TargetHttpProxy, TargetHttpsProxy, TargetSslProxy, TargetTcpProxy, TargetVpnGateway, TargetPool, TargetInstance. Applicable only when IPProtocol is TCP, UDP, or SCTP. Forwarding rules with the same [IPAddress, IPProtocol] pair must have disjoint port ranges. */ ports?: string[]; /** @@ -2596,7 +2733,7 @@ export namespace compute_beta { */ selfLink?: string; /** - * An optional prefix to the service name for this Forwarding Rule. If specified, will be the first label of the fully qualified service name. The label must be 1-63 characters long, and comply with RFC1035. Specifically, the label must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. This field is only used for internal load balancing. + * An optional prefix to the service name for this Forwarding Rule. If specified, the prefix is the first label of the fully qualified service name. The label must be 1-63 characters long, and comply with RFC1035. Specifically, the label must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. This field is only used for internal load balancing. */ serviceLabel?: string; /** @@ -3115,36 +3252,6 @@ export namespace compute_beta { */ replace?: boolean; } - export interface Schema$HTTPHealthCheck { - /** - * The value of the host header in the HTTP health check request. If left empty (default value), the IP on behalf of which this health check is performed will be used. - */ - host?: string; - /** - * The TCP port number for the health check request. The default value is 80. Valid values are 1 through 65535. - */ - port?: number; - /** - * Port name as defined in InstanceGroup#NamedPort#name. If both port and port_name are defined, port takes precedence. - */ - portName?: string; - /** - * Specifies how port is selected for health checking, can be one of following values: USE_FIXED_PORT: The port number in port is used for health checking. USE_NAMED_PORT: The portName is used for health checking. USE_SERVING_PORT: For NetworkEndpointGroup, the port specified for each network endpoint is used for health checking. For other backends, the port or named port specified in the Backend Service is used for health checking. If not specified, HTTP health check follows behavior specified in port and portName fields. - */ - portSpecification?: string; - /** - * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. - */ - proxyHeader?: string; - /** - * The request path of the HTTP health check request. The default value is /. - */ - requestPath?: string; - /** - * The string to match anywhere in the first 1024 bytes of the response body. If left empty (the default value), the status code determines health. The response data can only be ASCII. - */ - response?: string; - } /** * Represents a legacy HTTP Health Check resource. Legacy health checks are required by network load balancers. For more information, read Health Check Concepts. */ @@ -3202,6 +3309,36 @@ export namespace compute_beta { */ unhealthyThreshold?: number; } + export interface Schema$HTTPHealthCheck { + /** + * The value of the host header in the HTTP health check request. If left empty (default value), the IP on behalf of which this health check is performed will be used. + */ + host?: string; + /** + * The TCP port number for the health check request. The default value is 80. Valid values are 1 through 65535. + */ + port?: number; + /** + * Port name as defined in InstanceGroup#NamedPort#name. If both port and port_name are defined, port takes precedence. + */ + portName?: string; + /** + * Specifies how port is selected for health checking, can be one of following values: USE_FIXED_PORT: The port number in port is used for health checking. USE_NAMED_PORT: The portName is used for health checking. USE_SERVING_PORT: For NetworkEndpointGroup, the port specified for each network endpoint is used for health checking. For other backends, the port or named port specified in the Backend Service is used for health checking. If not specified, HTTP health check follows behavior specified in port and portName fields. + */ + portSpecification?: string; + /** + * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. + */ + proxyHeader?: string; + /** + * The request path of the HTTP health check request. The default value is /. + */ + requestPath?: string; + /** + * The string to match anywhere in the first 1024 bytes of the response body. If left empty (the default value), the status code determines health. The response data can only be ASCII. + */ + response?: string; + } /** * Contains a list of HttpHealthCheck resources. */ @@ -3387,36 +3524,6 @@ export namespace compute_beta { */ regexMatch?: string; } - export interface Schema$HTTPSHealthCheck { - /** - * The value of the host header in the HTTPS health check request. If left empty (default value), the IP on behalf of which this health check is performed will be used. - */ - host?: string; - /** - * The TCP port number for the health check request. The default value is 443. Valid values are 1 through 65535. - */ - port?: number; - /** - * Port name as defined in InstanceGroup#NamedPort#name. If both port and port_name are defined, port takes precedence. - */ - portName?: string; - /** - * Specifies how port is selected for health checking, can be one of following values: USE_FIXED_PORT: The port number in port is used for health checking. USE_NAMED_PORT: The portName is used for health checking. USE_SERVING_PORT: For NetworkEndpointGroup, the port specified for each network endpoint is used for health checking. For other backends, the port or named port specified in the Backend Service is used for health checking. If not specified, HTTPS health check follows behavior specified in port and portName fields. - */ - portSpecification?: string; - /** - * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. - */ - proxyHeader?: string; - /** - * The request path of the HTTPS health check request. The default value is /. - */ - requestPath?: string; - /** - * The string to match anywhere in the first 1024 bytes of the response body. If left empty (the default value), the status code determines health. The response data can only be ASCII. - */ - response?: string; - } /** * Represents a legacy HTTPS Health Check resource. Legacy health checks are required by network load balancers. For more information, read Health Check Concepts. */ @@ -3474,6 +3581,36 @@ export namespace compute_beta { */ unhealthyThreshold?: number; } + export interface Schema$HTTPSHealthCheck { + /** + * The value of the host header in the HTTPS health check request. If left empty (default value), the IP on behalf of which this health check is performed will be used. + */ + host?: string; + /** + * The TCP port number for the health check request. The default value is 443. Valid values are 1 through 65535. + */ + port?: number; + /** + * Port name as defined in InstanceGroup#NamedPort#name. If both port and port_name are defined, port takes precedence. + */ + portName?: string; + /** + * Specifies how port is selected for health checking, can be one of following values: USE_FIXED_PORT: The port number in port is used for health checking. USE_NAMED_PORT: The portName is used for health checking. USE_SERVING_PORT: For NetworkEndpointGroup, the port specified for each network endpoint is used for health checking. For other backends, the port or named port specified in the Backend Service is used for health checking. If not specified, HTTPS health check follows behavior specified in port and portName fields. + */ + portSpecification?: string; + /** + * Specifies the type of proxy header to append before sending data to the backend, either NONE or PROXY_V1. The default is NONE. + */ + proxyHeader?: string; + /** + * The request path of the HTTPS health check request. The default value is /. + */ + requestPath?: string; + /** + * The string to match anywhere in the first 1024 bytes of the response body. If left empty (the default value), the status code determines health. The response data can only be ASCII. + */ + response?: string; + } /** * Contains a list of HttpsHealthCheck resources. */ @@ -3624,7 +3761,7 @@ export namespace compute_beta { */ status?: string; /** - * GCS bucket storage location of the image (regional or multi-regional). + * Cloud Storage bucket storage location of the image (regional or multi-regional). */ storageLocations?: string[]; } @@ -3697,6 +3834,9 @@ export namespace compute_beta { * A list of the type and count of accelerator cards attached to the instance. */ guestAccelerators?: Schema$AcceleratorConfig[]; + /** + * Specifies the hostname of the instance. The specified hostname must be RFC1035 compliant. If hostname is not specified, the default hostname is [INSTANCE_NAME].c.[PROJECT_ID].internal when using the global DNS, and [INSTANCE_NAME].[ZONE].c.[PROJECT_ID].internal when using zonal DNS. + */ hostname?: string; /** * [Output Only] The unique identifier for the resource. This identifier is defined by the server. @@ -4260,6 +4400,9 @@ export namespace compute_beta { isReached?: boolean; } export interface Schema$InstanceGroupManagerUpdatePolicy { + /** + * The instance redistribution policy for regional managed instance groups. Valid values are: - PROACTIVE (default): The group attempts to maintain an even distribution of VM instances across zones in the region. - NONE: For non-autoscaled groups, proactive redistribution is disabled. + */ instanceRedistributionType?: string; /** * The maximum number of instances that can be created above the specified targetSize during the update process. By default, a fixed value of 1 is used. This value can be either a fixed number or a percentage if the instance group has 10 or more instances. If you set a percentage, the number of instances will be rounded up if necessary. At least one of either maxSurge or maxUnavailable must be greater than 0. Learn more about maxSurge. @@ -4789,7 +4932,7 @@ export namespace compute_beta { */ adminEnabled?: boolean; /** - * Provisioned bandwidth capacity for the interconnect attachment. For attachments of type DEDICATED, the user can set the bandwidth. For attachments of type PARTNER, the Google Partner that is operating the interconnect must set the bandwidth. Output only for PARTNER type, mutable for PARTNER_PROVIDER and DEDICATED, and can take one of the following values: - BPS_50M: 50 Mbit/s - BPS_100M: 100 Mbit/s - BPS_200M: 200 Mbit/s - BPS_300M: 300 Mbit/s - BPS_400M: 400 Mbit/s - BPS_500M: 500 Mbit/s - BPS_1G: 1 Gbit/s - BPS_2G: 2 Gbit/s - BPS_5G: 5 Gbit/s - BPS_10G: 10 Gbit/s + * Provisioned bandwidth capacity for the interconnect attachment. For attachments of type DEDICATED, the user can set the bandwidth. For attachments of type PARTNER, the Google Partner that is operating the interconnect must set the bandwidth. Output only for PARTNER type, mutable for PARTNER_PROVIDER and DEDICATED, and can take one of the following values: - BPS_50M: 50 Mbit/s - BPS_100M: 100 Mbit/s - BPS_200M: 200 Mbit/s - BPS_300M: 300 Mbit/s - BPS_400M: 400 Mbit/s - BPS_500M: 500 Mbit/s - BPS_1G: 1 Gbit/s - BPS_2G: 2 Gbit/s - BPS_5G: 5 Gbit/s - BPS_10G: 10 Gbit/s - BPS_20G: 20 Gbit/s - BPS_50G: 50 Gbit/s */ bandwidth?: string; /** @@ -5754,7 +5897,7 @@ export namespace compute_beta { */ instance?: string; /** - * Optional IPv4 address of network endpoint. The IP address must belong to a VM in GCE (either the primary IP or as part of an aliased IP range). If the IP address is not specified, then the primary IP address for the VM instance in the network that the network endpoint group belongs to will be used. + * Optional IPv4 address of network endpoint. The IP address must belong to a VM in Compute Engine (either the primary IP or as part of an aliased IP range). If the IP address is not specified, then the primary IP address for the VM instance in the network that the network endpoint group belongs to will be used. */ ipAddress?: string; /** @@ -6242,6 +6385,9 @@ export namespace compute_beta { additionalNodeCount?: number; } export interface Schema$NodeGroupsDeleteNodesRequest { + /** + * Names of the nodes to delete. + */ nodes?: string[]; } export interface Schema$NodeGroupsListNodes { @@ -6598,7 +6744,7 @@ export namespace compute_beta { */ httpErrorStatusCode?: number; /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. + * [Output Only] The unique identifier for the operation. This identifier is defined by the server. */ id?: string; /** @@ -6610,7 +6756,7 @@ export namespace compute_beta { */ kind?: string; /** - * [Output Only] Name of the resource. + * [Output Only] Name of the operation. */ name?: string; /** @@ -6792,6 +6938,35 @@ export namespace compute_beta { */ successRateStdevFactor?: number; } + /** + * Next free: 7 + */ + export interface Schema$PacketIntervals { + /** + * Average observed inter-packet interval in milliseconds. + */ + avgMs?: string; + /** + * From how long ago in the past these intervals were observed. + */ + duration?: string; + /** + * Maximum observed inter-packet interval in milliseconds. + */ + maxMs?: string; + /** + * Minimum observed inter-packet interval in milliseconds. + */ + minMs?: string; + /** + * Number of inter-packet intervals from which these statistics were derived. + */ + numIntervals?: string; + /** + * The type of packets for which inter-packet intervals were computed. + */ + type?: string; + } /** * A matcher for the path portion of the URL. The BackendService from the longest-matched rule will serve the URL. If no rule was matched, the default service will be used. */ @@ -6863,7 +7038,7 @@ export namespace compute_beta { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; iamOwned?: boolean; @@ -7099,7 +7274,7 @@ export namespace compute_beta { } export interface Schema$RegionCommitmentsUpdateReservationsRequest { /** - * List of reservations for the capacity move of VMs with accelerators and local ssds. + * List of two reservations to transfer GPUs and local SSD between. */ reservations?: Schema$Reservation[]; } @@ -7410,11 +7585,11 @@ export namespace compute_beta { backendService?: string; } /** - * Represents a reservation resource. A reservation ensures that capacity is held in a specific zone even if the reserved VMs are not running. For more information, read Reserving zonal resources. (== resource_for beta.reservations ==) (== resource_for v1.reservations ==) (== NextID: 13 ==) + * Represents a reservation resource. A reservation ensures that capacity is held in a specific zone even if the reserved VMs are not running. For more information, read Reserving zonal resources. (== resource_for beta.reservations ==) (== resource_for v1.reservations ==) */ export interface Schema$Reservation { /** - * [OutputOnly] Full or partial url for parent commitment for reservations which are tied to a commitment. + * [OutputOnly] Full or partial URL to a parent commitment. This field displays for reservations that are tied to a commitment. */ commitment?: string; /** @@ -7454,7 +7629,7 @@ export namespace compute_beta { */ status?: string; /** - * Zone in which the reservation resides, must be provided if reservation is created with commitment creation. + * Zone in which the reservation resides. A zone must be provided if the reservation is created within a commitment. */ zone?: string; } @@ -7777,7 +7952,7 @@ export namespace compute_beta { */ labels?: {[key: string]: string}; /** - * GCS bucket storage location of the auto snapshot (regional or multi-regional). + * Cloud Storage bucket storage location of the auto snapshot (regional or multi-regional). */ storageLocations?: string[]; } @@ -8038,6 +8213,10 @@ export namespace compute_beta { * Local BGP Autonomous System Number (ASN). Must be an RFC6996 private ASN, either 16-bit or 32-bit. The value will be fixed for this router resource. All VPN tunnels that link to this router will have the same local ASN. */ asn?: number; + /** + * The interval in seconds between BGP keepalive messages that are sent to the peer. Hold time is three times the interval at which keepalive messages are sent, and the hold time is the maximum number of seconds allowed to elapse between successive keepalive messages that BGP receives from a peer. BGP will use the smaller of either the local hold time value or the peer?s hold time value as the hold time for the BGP connection between the two peers. If set, this value must be between 1 and 120. The default is 20. + */ + keepaliveInterval?: number; } export interface Schema$RouterBgpPeer { /** @@ -8056,6 +8235,14 @@ export namespace compute_beta { * User-specified flag to indicate which mode to use for advertisement. */ advertiseMode?: string; + /** + * BFD configuration for the BGP peering. + */ + bfd?: Schema$RouterBgpPeerBfd; + /** + * The status of the BGP peer connection. If set to FALSE, any active session with the peer is terminated and all associated routing information is removed. If set to TRUE, the peer connection can be established with routing information. The default is TRUE. + */ + enable?: string; /** * Name of the interface the BGP peer is associated with. */ @@ -8069,7 +8256,7 @@ export namespace compute_beta { */ managementType?: string; /** - * Name of this BGP peer. The name must be 1-63 characters long and comply with RFC1035. + * Name of this BGP peer. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. */ name?: string; /** @@ -8081,6 +8268,24 @@ export namespace compute_beta { */ peerIpAddress?: string; } + export interface Schema$RouterBgpPeerBfd { + /** + * The minimum interval, in milliseconds, between BFD control packets received from the peer router. The actual value is negotiated between the two routers and is equal to the greater of this value and the transmit interval of the other router. If set, this value must be between 100 and 30000. The default is 300. + */ + minReceiveInterval?: number; + /** + * The minimum interval, in milliseconds, between BFD control packets transmitted to the peer router. The actual value is negotiated between the two routers and is equal to the greater of this value and the corresponding receive interval of the other router. If set, this value must be between 100 and 30000. The default is 300. + */ + minTransmitInterval?: number; + /** + * The number of consecutive BFD packets that must be missed before BFD declares that a peer is unavailable. If set, the value must be a value between 2 and 16. The default is 3. + */ + multiplier?: number; + /** + * The BFD session initialization mode for this BGP peer. If set to ACTIVE, the Cloud Router will initiate the BFD session for this BGP peer. If set to PASSIVE, the Cloud Router will wait for the peer router to initiate the BFD session for this BGP peer. If set to DISABLED, BFD is disabled for this BGP peer. The default is PASSIVE. + */ + sessionInitializationMode?: string; + } export interface Schema$RouterInterface { /** * IP address and range of the interface. The IP range must be in the RFC3927 link-local IP address space. The value must be a CIDR-formatted string, for example: 169.254.0.1/30. NOTE: Do not truncate the address as it represents the IP address of the interface. @@ -8099,7 +8304,7 @@ export namespace compute_beta { */ managementType?: string; /** - * Name of this interface entry. The name must be 1-63 characters long and comply with RFC1035. + * Name of this interface entry. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. */ name?: string; } @@ -8140,6 +8345,10 @@ export namespace compute_beta { * Represents a Nat resource. It enables the VMs within the specified subnetworks to access Internet without external IP addresses. It specifies a list of subnetworks (and the ranges within) that want to use NAT. Customers can also provide the external IPs that would be used for NAT. GCP would auto-allocate ephemeral IPs if no external IPs are provided. */ export interface Schema$RouterNat { + /** + * A list of URLs of the IP resources to be drained. These IPs must be valid static external IPs that have been assigned to the NAT. These IPs should be used for updating/patching a NAT only. + */ + drainNatIps?: string[]; /** * Timeout (in seconds) for ICMP connections. Defaults to 30s if not set. */ @@ -8256,6 +8465,7 @@ export namespace compute_beta { * Routes that were advertised to the remote BGP peer */ advertisedRoutes?: Schema$Route[]; + bfdStatus?: Schema$BfdStatus; /** * IP address of the local BGP interface. */ @@ -8301,6 +8511,14 @@ export namespace compute_beta { * A list of IPs auto-allocated for NAT. Example: ["1.1.1.1", "129.2.16.89"] */ autoAllocatedNatIps?: string[]; + /** + * A list of IPs auto-allocated for NAT that are in drain mode. Example: ["1.1.1.1", ?179.12.26.133?]. + */ + drainAutoAllocatedNatIps?: string[]; + /** + * A list of IPs user-allocated for NAT that are in drain mode. Example: ["1.1.1.1", ?179.12.26.133?]. + */ + drainUserAllocatedNatIps?: string[]; /** * The number of extra IPs to allocate. This will be greater than 0 only if user-specified IPs are NOT enough to allow all configured VMs to use NAT. This value is meaningful only when auto-allocation of NAT IPs is *not* used. */ @@ -8779,7 +8997,7 @@ export namespace compute_beta { */ storageBytesStatus?: string; /** - * GCS bucket storage location of the snapshot (regional or multi-regional). + * Cloud Storage bucket storage location of the snapshot (regional or multi-regional). */ storageLocations?: string[]; } @@ -10513,10 +10731,18 @@ export namespace compute_beta { * Contain information of Nat mapping for an interface of this endpoint. */ export interface Schema$VmEndpointNatMappingsInterfaceNatMappings { + /** + * List of all drain IP:port-range mappings assigned to this interface. These ranges are inclusive, that is, both the first and the last ports can be used for NAT. Example: ["2.2.2.2:12345-12355", "1.1.1.1:2234-2234"]. + */ + drainNatIpPortRanges?: string[]; /** * A list of all IP:port-range mappings assigned to this interface. These ranges are inclusive, that is, both the first and the last ports can be used for NAT. Example: ["2.2.2.2:12345-12355", "1.1.1.1:2234-2234"]. */ natIpPortRanges?: string[]; + /** + * Total number of drain ports across all NAT IPs allocated to this interface. It equals to the aggregated port number in the field drain_nat_ip_port_ranges. + */ + numTotalDrainNatPorts?: number; /** * Total number of ports across all NAT IPs allocated to this interface. It equals to the aggregated port number in the field nat_ip_port_ranges. */ @@ -17679,6 +17905,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.optionsRequestedPolicyVersion Requested IAM Policy version. * @param {string} params.project Project ID for this request. * @param {string} params.resource_ Name or id of the resource for this request. * @param {string} params.zone The name of the zone for this request. @@ -18730,6 +18957,10 @@ export namespace compute_beta { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Requested IAM Policy version. + */ + optionsRequestedPolicyVersion?: number; /** * Project ID for this request. */ @@ -29245,6 +29476,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.optionsRequestedPolicyVersion Requested IAM Policy version. * @param {string} params.project Project ID for this request. * @param {string} params.resource_ Name or id of the resource for this request. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. @@ -30004,6 +30236,10 @@ export namespace compute_beta { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Requested IAM Policy version. + */ + optionsRequestedPolicyVersion?: number; /** * Project ID for this request. */ @@ -35876,6 +36112,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.optionsRequestedPolicyVersion Requested IAM Policy version. * @param {string} params.project Project ID for this request. * @param {string} params.resource_ Name or id of the resource for this request. * @param {string} params.zone The name of the zone for this request. @@ -39958,6 +40195,10 @@ export namespace compute_beta { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Requested IAM Policy version. + */ + optionsRequestedPolicyVersion?: number; /** * Project ID for this request. */ @@ -41132,6 +41373,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.optionsRequestedPolicyVersion Requested IAM Policy version. * @param {string} params.project Project ID for this request. * @param {string} params.resource_ Name or id of the resource for this request. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. @@ -41726,6 +41968,10 @@ export namespace compute_beta { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Requested IAM Policy version. + */ + optionsRequestedPolicyVersion?: number; /** * Project ID for this request. */ @@ -44826,6 +45072,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.optionsRequestedPolicyVersion Requested IAM Policy version. * @param {string} params.project Project ID for this request. * @param {string} params.resource_ Name or id of the resource for this request. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. @@ -45160,6 +45407,10 @@ export namespace compute_beta { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Requested IAM Policy version. + */ + optionsRequestedPolicyVersion?: number; /** * Project ID for this request. */ @@ -48631,7 +48882,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.nodeGroup Name of the NodeGroup resource to delete. + * @param {string} params.nodeGroup Name of the NodeGroup resource whose nodes will be deleted. * @param {string} params.project Project ID for this request. * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). * @param {string} params.zone The name of the zone for this request. @@ -48784,6 +49035,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.optionsRequestedPolicyVersion Requested IAM Policy version. * @param {string} params.project Project ID for this request. * @param {string} params.resource_ Name or id of the resource for this request. * @param {string} params.zone The name of the zone for this request. @@ -49411,7 +49663,7 @@ export namespace compute_beta { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Name of the NodeGroup resource to delete. + * Name of the NodeGroup resource whose nodes will be deleted. */ nodeGroup?: string; /** @@ -49458,6 +49710,10 @@ export namespace compute_beta { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Requested IAM Policy version. + */ + optionsRequestedPolicyVersion?: number; /** * Project ID for this request. */ @@ -49898,6 +50154,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.optionsRequestedPolicyVersion Requested IAM Policy version. * @param {string} params.project Project ID for this request. * @param {string} params.region The name of the region for this request. * @param {string} params.resource_ Name or id of the resource for this request. @@ -50357,6 +50614,10 @@ export namespace compute_beta { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Requested IAM Policy version. + */ + optionsRequestedPolicyVersion?: number; /** * Project ID for this request. */ @@ -55745,7 +56006,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.commitment Name of the commitment of which the reservation's capacities are being updated. + * @param {string} params.commitment Name of the commitment for which the reservation is being updated. * @param {string} params.project Project ID for this request. * @param {string} params.region Name of the region for this request. * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). @@ -55930,7 +56191,7 @@ export namespace compute_beta { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Name of the commitment of which the reservation's capacities are being updated. + * Name of the commitment for which the reservation is being updated. */ commitment?: string; /** @@ -56271,6 +56532,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.optionsRequestedPolicyVersion Requested IAM Policy version. * @param {string} params.project Project ID for this request. * @param {string} params.region The name of the region for this request. * @param {string} params.resource_ Name or id of the resource for this request. @@ -56993,6 +57255,10 @@ export namespace compute_beta { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Requested IAM Policy version. + */ + optionsRequestedPolicyVersion?: number; /** * Project ID for this request. */ @@ -64961,7 +65227,7 @@ export namespace compute_beta { /** * compute.reservations.get - * @desc Retrieves all information of the specified reservation. + * @desc Retrieves information about the specified reservation. * @alias compute.reservations.get * @memberOf! () * @@ -65041,6 +65307,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.optionsRequestedPolicyVersion Requested IAM Policy version. * @param {string} params.project Project ID for this request. * @param {string} params.resource_ Name or id of the resource for this request. * @param {string} params.zone The name of the zone for this request. @@ -65187,7 +65454,7 @@ export namespace compute_beta { /** * compute.reservations.list - * @desc A list all the reservations that have been configured for the specified project in specified zone. + * @desc A list of all the reservations that have been configured for the specified project in specified zone. * @alias compute.reservations.list * @memberOf! () * @@ -65266,7 +65533,7 @@ export namespace compute_beta { /** * compute.reservations.resize - * @desc Resizes the reservation (applicable to standalone reservations only) + * @desc Resizes the reservation (applicable to standalone reservations only). For more information, read Modifying reservations. * @alias compute.reservations.resize * @memberOf! () * @@ -65577,6 +65844,10 @@ export namespace compute_beta { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Requested IAM Policy version. + */ + optionsRequestedPolicyVersion?: number; /** * Project ID for this request. */ @@ -65980,6 +66251,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.optionsRequestedPolicyVersion Requested IAM Policy version. * @param {string} params.project Project ID for this request. * @param {string} params.region The name of the region for this request. * @param {string} params.resource_ Name or id of the resource for this request. @@ -66439,6 +66711,10 @@ export namespace compute_beta { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Requested IAM Policy version. + */ + optionsRequestedPolicyVersion?: number; /** * Project ID for this request. */ @@ -66980,6 +67256,7 @@ export namespace compute_beta { * @param {object} params Parameters for request * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) + * @param {string=} params.natName Name of the nat service to filter the Nat Mapping information. If it is omitted, all nats for this router will be returned. Name should conform to RFC1035. * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. * @param {string} params.project Project ID for this request. @@ -68114,6 +68391,10 @@ export namespace compute_beta { * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) */ maxResults?: number; + /** + * Name of the nat service to filter the Nat Mapping information. If it is omitted, all nats for this router will be returned. Name should conform to RFC1035. + */ + natName?: string; /** * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. */ @@ -70921,6 +71202,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.optionsRequestedPolicyVersion Requested IAM Policy version. * @param {string} params.project Project ID for this request. * @param {string} params.resource_ Name or id of the resource for this request. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. @@ -71512,6 +71794,10 @@ export namespace compute_beta { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Requested IAM Policy version. + */ + optionsRequestedPolicyVersion?: number; /** * Project ID for this request. */ @@ -73840,6 +74126,7 @@ export namespace compute_beta { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.optionsRequestedPolicyVersion Requested IAM Policy version. * @param {string} params.project Project ID for this request. * @param {string} params.region The name of the region for this request. * @param {string} params.resource_ Name or id of the resource for this request. @@ -74187,7 +74474,7 @@ export namespace compute_beta { /** * compute.subnetworks.listUsable - * @desc Retrieves an aggregated list of usable subnetworks. + * @desc Retrieves an aggregated list of all usable subnetworks in the project. The list contains all of the subnetworks in the project and the subnetworks that were shared by a Shared VPC host project. * @alias compute.subnetworks.listUsable * @memberOf! () * @@ -74936,6 +75223,10 @@ export namespace compute_beta { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Requested IAM Policy version. + */ + optionsRequestedPolicyVersion?: number; /** * Project ID for this request. */ diff --git a/src/apis/compute/index.ts b/src/apis/compute/index.ts index 8b3fb18daf2..996574b5326 100644 --- a/src/apis/compute/index.ts +++ b/src/apis/compute/index.ts @@ -14,33 +14,21 @@ /*! THIS FILE IS AUTO-GENERATED */ import {AuthPlus, getAPI, GoogleConfigurable} from 'googleapis-common'; -import {compute_alpha} from './alpha'; import {compute_beta} from './beta'; import {compute_v1} from './v1'; export const VERSIONS = { - alpha: compute_alpha.Compute, beta: compute_beta.Compute, v1: compute_v1.Compute, }; -export function compute(version: 'alpha'): compute_alpha.Compute; -export function compute(options: compute_alpha.Options): compute_alpha.Compute; export function compute(version: 'beta'): compute_beta.Compute; export function compute(options: compute_beta.Options): compute_beta.Compute; export function compute(version: 'v1'): compute_v1.Compute; export function compute(options: compute_v1.Options): compute_v1.Compute; -export function compute< - T = compute_alpha.Compute | compute_beta.Compute | compute_v1.Compute ->( +export function compute( this: GoogleConfigurable, - versionOrOptions: - | 'alpha' - | compute_alpha.Options - | 'beta' - | compute_beta.Options - | 'v1' - | compute_v1.Options + versionOrOptions: 'beta' | compute_beta.Options | 'v1' | compute_v1.Options ) { return getAPI('compute', versionOrOptions, VERSIONS, this); } diff --git a/src/apis/compute/v1.ts b/src/apis/compute/v1.ts index f27789e84df..8c218599eb4 100644 --- a/src/apis/compute/v1.ts +++ b/src/apis/compute/v1.ts @@ -96,6 +96,7 @@ export namespace compute_v1 { backendServices: Resource$Backendservices; disks: Resource$Disks; diskTypes: Resource$Disktypes; + externalVpnGateways: Resource$Externalvpngateways; firewalls: Resource$Firewalls; forwardingRules: Resource$Forwardingrules; globalAddresses: Resource$Globaladdresses; @@ -147,6 +148,7 @@ export namespace compute_v1 { targetTcpProxies: Resource$Targettcpproxies; targetVpnGateways: Resource$Targetvpngateways; urlMaps: Resource$Urlmaps; + vpnGateways: Resource$Vpngateways; vpnTunnels: Resource$Vpntunnels; zoneOperations: Resource$Zoneoperations; zones: Resource$Zones; @@ -164,6 +166,7 @@ export namespace compute_v1 { this.backendServices = new Resource$Backendservices(this.context); this.disks = new Resource$Disks(this.context); this.diskTypes = new Resource$Disktypes(this.context); + this.externalVpnGateways = new Resource$Externalvpngateways(this.context); this.firewalls = new Resource$Firewalls(this.context); this.forwardingRules = new Resource$Forwardingrules(this.context); this.globalAddresses = new Resource$Globaladdresses(this.context); @@ -231,6 +234,7 @@ export namespace compute_v1 { this.targetTcpProxies = new Resource$Targettcpproxies(this.context); this.targetVpnGateways = new Resource$Targetvpngateways(this.context); this.urlMaps = new Resource$Urlmaps(this.context); + this.vpnGateways = new Resource$Vpngateways(this.context); this.vpnTunnels = new Resource$Vpntunnels(this.context); this.zoneOperations = new Resource$Zoneoperations(this.context); this.zones = new Resource$Zones(this.context); @@ -600,15 +604,15 @@ export namespace compute_v1 { */ export interface Schema$AllocationSpecificSKUReservation { /** - * Specifies number of resources that are allocated. + * Specifies the number of resources that are allocated. */ count?: string; /** - * The instance properties for this specific sku reservation. + * The instance properties for the reservation. */ instanceProperties?: Schema$AllocationSpecificSKUAllocationReservedInstanceProperties; /** - * [OutputOnly] Indicates how many resource are in use. + * [OutputOnly] Indicates how many instances are in use. */ inUseCount?: string; } @@ -682,7 +686,7 @@ export namespace compute_v1 { */ diskName?: string; /** - * Specifies the size of the disk in base-2 GB. + * Specifies the size of the disk in base-2 GB. If not specified, the disk will be the same size as the image (usually 10GB). If specified, the size must be equal to or larger than 10GB. */ diskSizeGb?: string; /** @@ -715,7 +719,7 @@ export namespace compute_v1 { sourceSnapshotEncryptionKey?: Schema$CustomerEncryptionKey; } /** - * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "fooservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:bar@gmail.com" ] } ] } ] } For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts foo@gmail.com from DATA_READ logging, and bar@gmail.com from DATA_WRITE logging. + * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "sampleservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts jose@example.com from DATA_READ logging, and aliya@example.com from DATA_WRITE logging. */ export interface Schema$AuditConfig { /** @@ -729,13 +733,17 @@ export namespace compute_v1 { service?: string; } /** - * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting foo@gmail.com from DATA_READ logging. + * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ logging. */ export interface Schema$AuditLogConfig { /** * Specifies the identities that do not cause logging for this type of permission. Follows the same format of [Binding.members][]. */ exemptedMembers?: string[]; + /** + * Specifies whether principals can be exempted for the same LogType in lower-level resource policies. If true, any lower-level exemptions will be ignored. + */ + ignoreChildExemptions?: boolean; /** * The log type that this config enables. */ @@ -959,7 +967,7 @@ export namespace compute_v1 { */ export interface Schema$Backend { /** - * Specifies the balancing mode for the backend. When choosing a balancing mode, you need to consider the loadBalancingScheme, and protocol for the backend service, as well as the type of backend (instance group or NEG). - If the load balancing mode is CONNECTION, then the load is spread based on how many concurrent connections the backend can handle. The CONNECTION balancing mode is only available if the protocol for the backend service is SSL, TCP, or UDP. If the loadBalancingScheme for the backend service is EXTERNAL (SSL Proxy and TCP Proxy load balancers), you must also specify exactly one of the following parameters: maxConnections, maxConnectionsPerInstance, or maxConnectionsPerEndpoint. If the loadBalancingScheme for the backend service is INTERNAL (internal TCP/UDP load balancers), you cannot specify any additional parameters. - If the load balancing mode is RATE, then the load is spread based on the rate of HTTP requests per second (RPS). The RATE balancing mode is only available if the protocol for the backend service is HTTP or HTTPS. You must specify exactly one of the following parameters: maxRate, maxRatePerInstance, or maxRatePerEndpoint. - If the load balancing mode is UTILIZATION, then the load is spread based on the CPU utilization of instances in an instance group. The UTILIZATION balancing mode is only available if the loadBalancingScheme of the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED and the backend is made up of instance groups. There are no restrictions on the backend service protocol. + * Specifies the balancing mode for the backend. When choosing a balancing mode, you need to consider the loadBalancingScheme, and protocol for the backend service, as well as the type of backend (instance group or NEG). - If the load balancing mode is CONNECTION, then the load is spread based on how many concurrent connections the backend can handle. You can use the CONNECTION balancing mode if the protocol for the backend service is SSL, TCP, or UDP. If the loadBalancingScheme for the backend service is EXTERNAL (SSL Proxy and TCP Proxy load balancers), you must also specify exactly one of the following parameters: maxConnections, maxConnectionsPerInstance, or maxConnectionsPerEndpoint. If the loadBalancingScheme for the backend service is INTERNAL (internal TCP/UDP load balancers), you cannot specify any additional parameters. - If the load balancing mode is RATE, the load is spread based on the rate of HTTP requests per second (RPS). You can use the RATE balancing mode if the protocol for the backend service is HTTP or HTTPS. You must specify exactly one of the following parameters: maxRate, maxRatePerInstance, or maxRatePerEndpoint. - If the load balancing mode is UTILIZATION, the load is spread based on the CPU utilization of instances in an instance group. You can use the UTILIZATION balancing mode if the loadBalancingScheme of the backend service is EXTERNAL, INTERNAL_SELF_MANAGED, or INTERNAL_MANAGED and the backends are instance groups. There are no restrictions on the backend service protocol. */ balancingMode?: string; /** @@ -1173,7 +1181,7 @@ export namespace compute_v1 { */ selfLink?: string; /** - * Type of session affinity to use. The default is NONE. Session affinity is not applicable if the --protocol is UDP. When the loadBalancingScheme is EXTERNAL, possible values are NONE, CLIENT_IP, or GENERATED_COOKIE. GENERATED_COOKIE is only available if the protocol is HTTP or HTTPS. When the loadBalancingScheme is INTERNAL, possible values are NONE, CLIENT_IP, CLIENT_IP_PROTO, or CLIENT_IP_PORT_PROTO. When the loadBalancingScheme is INTERNAL_SELF_MANAGED, possible values are NONE, CLIENT_IP, GENERATED_COOKIE, HEADER_FIELD, or HTTP_COOKIE. + * Type of session affinity to use. The default is NONE. Session affinity is not applicable if the --protocol is UDP. When the loadBalancingScheme is EXTERNAL, possible values are NONE, CLIENT_IP, or GENERATED_COOKIE. You can use GENERATED_COOKIE if the protocol is HTTP or HTTPS. When the loadBalancingScheme is INTERNAL, possible values are NONE, CLIENT_IP, CLIENT_IP_PROTO, or CLIENT_IP_PORT_PROTO. When the loadBalancingScheme is INTERNAL_SELF_MANAGED, possible values are NONE, CLIENT_IP, GENERATED_COOKIE, HEADER_FIELD, or HTTP_COOKIE. */ sessionAffinity?: string; /** @@ -1312,7 +1320,7 @@ export namespace compute_v1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -1389,7 +1397,7 @@ export namespace compute_v1 { */ region?: string; /** - * List of reservations for this commitment. + * List of reservations in this commitment. */ reservations?: Schema$Reservation[]; /** @@ -1685,7 +1693,7 @@ export namespace compute_v1 { */ sourceSnapshotId?: string; /** - * [Output Only] The status of disk creation. + * [Output Only] The status of disk creation. CREATING: Disk is provisioning. RESTORING: Source data is being copied into the disk. FAILED: Disk creation failed. READY: Disk is ready for use. DELETING: Disk is deleting. */ status?: string; /** @@ -1953,6 +1961,15 @@ export namespace compute_v1 { message?: string; }; } + /** + * A set of Display Device options + */ + export interface Schema$DisplayDevice { + /** + * Defines whether the instance has Display enabled. + */ + enableDisplay?: boolean; + } export interface Schema$DistributionPolicy { /** * Zones where the regional managed instance group will create and manage instances. @@ -1986,6 +2003,98 @@ export namespace compute_v1 { */ title?: string; } + /** + * External VPN gateway is the on-premises VPN gateway(s) or another cloud provider?s VPN gateway that connects to your Google Cloud VPN gateway. To create a highly available VPN from Google Cloud to your on-premises side or another Cloud provider's VPN gateway, you must create a external VPN gateway resource in GCP, which provides the information to GCP about your external VPN gateway. + */ + export interface Schema$ExternalVpnGateway { + /** + * [Output Only] Creation timestamp in RFC3339 text format. + */ + creationTimestamp?: string; + /** + * An optional description of this resource. Provide this property when you create the resource. + */ + description?: string; + /** + * [Output Only] The unique identifier for the resource. This identifier is defined by the server. + */ + id?: string; + /** + * List of interfaces for this external VPN gateway. + */ + interfaces?: Schema$ExternalVpnGatewayInterface[]; + /** + * [Output Only] Type of the resource. Always compute#externalVpnGateway for externalVpnGateways. + */ + kind?: string; + /** + * A fingerprint for the labels being applied to this ExternalVpnGateway, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an ExternalVpnGateway. + */ + labelFingerprint?: string; + /** + * Labels to apply to this ExternalVpnGateway resource. These can be later modified by the setLabels method. Each label key/value must comply with RFC1035. Label values may be empty. + */ + labels?: {[key: string]: string}; + /** + * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. + */ + name?: string; + /** + * Indicates the user-supplied redundancy type of this external VPN gateway. + */ + redundancyType?: string; + /** + * [Output Only] Server-defined URL for the resource. + */ + selfLink?: string; + } + /** + * The interface for the external VPN gateway. + */ + export interface Schema$ExternalVpnGatewayInterface { + /** + * The numeric ID of this interface. The allowed input values for this id for different redundancy types of external VPN gateway: SINGLE_IP_INTERNALLY_REDUNDANT - 0 TWO_IPS_REDUNDANCY - 0, 1 FOUR_IPS_REDUNDANCY - 0, 1, 2, 3 + */ + id?: number; + /** + * IP address of the interface in the external VPN gateway. Only IPv4 is supported. This IP address can be either from your on-premise gateway or another Cloud provider?s VPN gateway, it cannot be an IP address from Google Compute Engine. + */ + ipAddress?: string; + } + /** + * Response to the list request, and contains a list of externalVpnGateways. + */ + export interface Schema$ExternalVpnGatewayList { + etag?: string; + /** + * [Output Only] Unique identifier for the resource; defined by the server. + */ + id?: string; + /** + * A list of ExternalVpnGateway resources. + */ + items?: Schema$ExternalVpnGateway[]; + /** + * [Output Only] Type of resource. Always compute#externalVpnGatewayList for lists of externalVpnGateways. + */ + kind?: string; + /** + * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. + */ + nextPageToken?: string; + /** + * [Output Only] Server-defined URL for this resource. + */ + selfLink?: string; + /** + * [Output Only] Informational warning message. + */ + warning?: { + code?: string; + data?: Array<{key?: string; value?: string}>; + message?: string; + }; + } /** * Represents a Firewall Rule resource. Firewall rules allow or deny ingress traffic to, and egress traffic from your instances. For more information, read Firewall rules. */ @@ -2151,7 +2260,7 @@ export namespace compute_v1 { */ id?: string; /** - * The IP address that this forwarding rule is serving on behalf of. Addresses are restricted based on the forwarding rule's load balancing scheme (EXTERNAL or INTERNAL) and scope (global or regional). When the load balancing scheme is EXTERNAL, for global forwarding rules, the address must be a global IP, and for regional forwarding rules, the address must live in the same region as the forwarding rule. If this field is empty, an ephemeral IPv4 address from the same scope (global or regional) will be assigned. A regional forwarding rule supports IPv4 only. A global forwarding rule supports either IPv4 or IPv6. When the load balancing scheme is INTERNAL_SELF_MANAGED, this must be a URL reference to an existing Address resource ( internal regional static IP address), with a purpose of GCE_END_POINT and address_type of INTERNAL. When the load balancing scheme is INTERNAL, this can only be an RFC 1918 IP address belonging to the network/subnet configured for the forwarding rule. By default, if this field is empty, an ephemeral internal IP address will be automatically allocated from the IP range of the subnet or network configured for this forwarding rule. An address can be specified either by a literal IP address or a URL reference to an existing Address resource. The following examples are all valid: - 100.1.2.3 - https://www.googleapis.com/compute/v1/projects/project/regions/region/addresses/address - projects/project/regions/region/addresses/address - regions/region/addresses/address - global/addresses/address - address + * IP address that this forwarding rule serves. When a client sends traffic to this IP address, the forwarding rule directs the traffic to the target that you specify in the forwarding rule. If you don't specify a reserved IP address, an ephemeral IP address is assigned. Methods for specifying an IP address: * IPv4 dotted decimal, as in `100.1.2.3` * Full URL, as in https://www.googleapis.com/compute/v1/projects/project_id/regions/region/addresses/address-name * Partial URL or by name, as in: * projects/project_id/regions/region/addresses/address-name * regions/region/addresses/address-name * global/addresses/address-name * address-name The loadBalancingScheme and the forwarding rule's target determine the type of IP address that you can use. For detailed information, refer to [IP address specifications](/load-balancing/docs/forwarding-rule-concepts#ip_address_specifications). */ IPAddress?: string; /** @@ -2183,11 +2292,11 @@ export namespace compute_v1 { */ networkTier?: string; /** - * This field is used along with the target field for TargetHttpProxy, TargetHttpsProxy, TargetSslProxy, TargetTcpProxy, TargetVpnGateway, TargetPool, TargetInstance. Applicable only when IPProtocol is TCP, UDP, or SCTP, only packets addressed to ports in the specified range will be forwarded to target. Forwarding rules with the same [IPAddress, IPProtocol] pair must have disjoint port ranges. Some types of forwarding target have constraints on the acceptable ports: - TargetHttpProxy: 80, 8080 - TargetHttpsProxy: 443 - TargetTcpProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 - TargetSslProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 - TargetVpnGateway: 500, 4500 + * This field is deprecated. See the port field. */ portRange?: string; /** - * This field is used along with the backend_service field for internal load balancing. When the load balancing scheme is INTERNAL, a list of ports can be configured, for example, ['80'], ['8000','9000'] etc. Only packets addressed to these ports will be forwarded to the backends configured with this forwarding rule. You may specify a maximum of up to 5 ports. + * List of comma-separated ports. The forwarding rule forwards packets with matching destination ports. If the forwarding rule's loadBalancingScheme is EXTERNAL, and the forwarding rule references a target pool, specifying ports is optional. You can specify an unlimited number of ports, but they must be contiguous. If you omit ports, GCP forwards traffic on any port of the forwarding rule's protocol. If the forwarding rule's loadBalancingScheme is EXTERNAL, and the forwarding rule references a target HTTP proxy, target HTTPS proxy, target TCP proxy, target SSL proxy, or target VPN gateway, you must specify ports using the following constraints: - TargetHttpProxy: 80, 8080 - TargetHttpsProxy: 443 - TargetTcpProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 - TargetSslProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 - TargetVpnGateway: 500, 4500 If the forwarding rule's loadBalancingScheme is INTERNAL, you must specify ports in one of the following ways: * A list of up to five ports, which can be non-contiguous * Keyword ALL, which causes the forwarding rule to forward traffic on any port of the forwarding rule's protocol. The ports field is used along with the target field for TargetHttpProxy, TargetHttpsProxy, TargetSslProxy, TargetTcpProxy, TargetVpnGateway, TargetPool, TargetInstance. Applicable only when IPProtocol is TCP, UDP, or SCTP. Forwarding rules with the same [IPAddress, IPProtocol] pair must have disjoint port ranges. */ ports?: string[]; /** @@ -2199,7 +2308,7 @@ export namespace compute_v1 { */ selfLink?: string; /** - * An optional prefix to the service name for this Forwarding Rule. If specified, will be the first label of the fully qualified service name. The label must be 1-63 characters long, and comply with RFC1035. Specifically, the label must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. This field is only used for internal load balancing. + * An optional prefix to the service name for this Forwarding Rule. If specified, the prefix is the first label of the fully qualified service name. The label must be 1-63 characters long, and comply with RFC1035. Specifically, the label must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. This field is only used for internal load balancing. */ serviceLabel?: string; /** @@ -2974,10 +3083,17 @@ export namespace compute_v1 { * Array of disks associated with this instance. Persistent disks must be created before you can assign them. */ disks?: Schema$AttachedDisk[]; + /** + * Enables display device for the instance. + */ + displayDevice?: Schema$DisplayDevice; /** * A list of the type and count of accelerator cards attached to the instance. */ guestAccelerators?: Schema$AcceleratorConfig[]; + /** + * Specifies the hostname of the instance. The specified hostname must be RFC1035 compliant. If hostname is not specified, the default hostname is [INSTANCE_NAME].c.[PROJECT_ID].internal when using the global DNS, and [INSTANCE_NAME].[ZONE].c.[PROJECT_ID].internal when using zonal DNS. + */ hostname?: string; /** * [Output Only] The unique identifier for the resource. This identifier is defined by the server. @@ -3950,7 +4066,7 @@ export namespace compute_v1 { */ adminEnabled?: boolean; /** - * Provisioned bandwidth capacity for the interconnect attachment. For attachments of type DEDICATED, the user can set the bandwidth. For attachments of type PARTNER, the Google Partner that is operating the interconnect must set the bandwidth. Output only for PARTNER type, mutable for PARTNER_PROVIDER and DEDICATED, and can take one of the following values: - BPS_50M: 50 Mbit/s - BPS_100M: 100 Mbit/s - BPS_200M: 200 Mbit/s - BPS_300M: 300 Mbit/s - BPS_400M: 400 Mbit/s - BPS_500M: 500 Mbit/s - BPS_1G: 1 Gbit/s - BPS_2G: 2 Gbit/s - BPS_5G: 5 Gbit/s - BPS_10G: 10 Gbit/s + * Provisioned bandwidth capacity for the interconnect attachment. For attachments of type DEDICATED, the user can set the bandwidth. For attachments of type PARTNER, the Google Partner that is operating the interconnect must set the bandwidth. Output only for PARTNER type, mutable for PARTNER_PROVIDER and DEDICATED, and can take one of the following values: - BPS_50M: 50 Mbit/s - BPS_100M: 100 Mbit/s - BPS_200M: 200 Mbit/s - BPS_300M: 300 Mbit/s - BPS_400M: 400 Mbit/s - BPS_500M: 500 Mbit/s - BPS_1G: 1 Gbit/s - BPS_2G: 2 Gbit/s - BPS_5G: 5 Gbit/s - BPS_10G: 10 Gbit/s - BPS_20G: 20 Gbit/s - BPS_50G: 50 Gbit/s */ bandwidth?: string; /** @@ -4889,7 +5005,7 @@ export namespace compute_v1 { */ instance?: string; /** - * Optional IPv4 address of network endpoint. The IP address must belong to a VM in GCE (either the primary IP or as part of an aliased IP range). If the IP address is not specified, then the primary IP address for the VM instance in the network that the network endpoint group belongs to will be used. + * Optional IPv4 address of network endpoint. The IP address must belong to a VM in Compute Engine (either the primary IP or as part of an aliased IP range). If the IP address is not specified, then the primary IP address for the VM instance in the network that the network endpoint group belongs to will be used. */ ipAddress?: string; /** @@ -5160,6 +5276,14 @@ export namespace compute_v1 { * Indicates whether full mesh connectivity is created and managed automatically between peered networks. Currently this field should always be true since Google Compute Engine will automatically create and manage subnetwork routes between two networks when peering state is ACTIVE. */ exchangeSubnetRoutes?: boolean; + /** + * Whether to export the custom routes to peer network. + */ + exportCustomRoutes?: boolean; + /** + * Whether to import the custom routes from peer network. + */ + importCustomRoutes?: boolean; /** * Name of this peering. Provided by the client when the peering is created. The name must comply with RFC1035. Specifically, the name must be 1-63 characters long and match regular expression `[a-z]([-a-z0-9]*[a-z0-9])?`. The first character must be a lowercase letter, and all the following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. */ @@ -5210,6 +5334,9 @@ export namespace compute_v1 { */ name?: string; } + export interface Schema$NetworksUpdatePeeringRequest { + networkPeering?: Schema$NetworkPeering; + } /** * Represent a sole-tenant Node Group resource. A sole-tenant node is a physical server that is dedicated to hosting VM instances only for your specific project. Use sole-tenant nodes to keep your instances physically separated from instances in other projects, or to group your instances together on the same host hardware. For more information, read Sole-tenant nodes. (== resource_for beta.nodeGroups ==) (== resource_for v1.nodeGroups ==) NextID: 15 */ @@ -5341,6 +5468,9 @@ export namespace compute_v1 { additionalNodeCount?: number; } export interface Schema$NodeGroupsDeleteNodesRequest { + /** + * Names of the nodes to delete. + */ nodes?: string[]; } export interface Schema$NodeGroupsListNodes { @@ -5697,7 +5827,7 @@ export namespace compute_v1 { */ httpErrorStatusCode?: number; /** - * [Output Only] The unique identifier for the resource. This identifier is defined by the server. + * [Output Only] The unique identifier for the operation. This identifier is defined by the server. */ id?: string; /** @@ -5709,7 +5839,7 @@ export namespace compute_v1 { */ kind?: string; /** - * [Output Only] Name of the resource. + * [Output Only] Name of the operation. */ name?: string; /** @@ -5889,7 +6019,7 @@ export namespace compute_v1 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; iamOwned?: boolean; @@ -6379,11 +6509,11 @@ export namespace compute_v1 { policy?: Schema$Policy; } /** - * Represents a reservation resource. A reservation ensures that capacity is held in a specific zone even if the reserved VMs are not running. For more information, read Reserving zonal resources. (== resource_for beta.reservations ==) (== resource_for v1.reservations ==) (== NextID: 13 ==) + * Represents a reservation resource. A reservation ensures that capacity is held in a specific zone even if the reserved VMs are not running. For more information, read Reserving zonal resources. (== resource_for beta.reservations ==) (== resource_for v1.reservations ==) */ export interface Schema$Reservation { /** - * [OutputOnly] Full or partial url for parent commitment for reservations which are tied to a commitment. + * [OutputOnly] Full or partial URL to a parent commitment. This field displays for reservations that are tied to a commitment. */ commitment?: string; /** @@ -6423,7 +6553,7 @@ export namespace compute_v1 { */ status?: string; /** - * Zone in which the reservation resides, must be provided if reservation is created with commitment creation. + * Zone in which the reservation resides. A zone must be provided if the reservation is created within a commitment. */ zone?: string; } @@ -6746,7 +6876,7 @@ export namespace compute_v1 { */ labels?: {[key: string]: string}; /** - * GCS bucket storage location of the auto snapshot (regional or multi-regional). + * Cloud Storage bucket storage location of the auto snapshot (regional or multi-regional). */ storageLocations?: string[]; } @@ -7030,7 +7160,7 @@ export namespace compute_v1 { */ managementType?: string; /** - * Name of this BGP peer. The name must be 1-63 characters long and comply with RFC1035. + * Name of this BGP peer. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. */ name?: string; /** @@ -7060,7 +7190,7 @@ export namespace compute_v1 { */ managementType?: string; /** - * Name of this interface entry. The name must be 1-63 characters long and comply with RFC1035. + * Name of this interface entry. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. */ name?: string; } @@ -7666,7 +7796,7 @@ export namespace compute_v1 { */ storageBytesStatus?: string; /** - * GCS bucket storage location of the snapshot (regional or multi-regional). + * Cloud Storage bucket storage location of the snapshot (regional or multi-regional). */ storageLocations?: string[]; } @@ -7940,6 +8070,10 @@ export namespace compute_v1 { * [Output Only] Type of the resource. Always compute#subnetwork for Subnetwork resources. */ kind?: string; + /** + * This field denotes the VPC flow logging options for this subnetwork. If logging is enabled, logs are exported to Stackdriver. + */ + logConfig?: Schema$SubnetworkLogConfig; /** * The name of the resource, provided by the client when initially creating the resource. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. */ @@ -8028,6 +8162,27 @@ export namespace compute_v1 { message?: string; }; } + /** + * The available logging options for this subnetwork. + */ + export interface Schema$SubnetworkLogConfig { + /** + * Can only be specified if VPC flow logging for this subnetwork is enabled. Toggles the aggregation interval for collecting flow logs. Increasing the interval time will reduce the amount of generated flow logs for long lasting connections. Default is an interval of 5 seconds per connection. + */ + aggregationInterval?: string; + /** + * Whether to enable flow logging for this subnetwork. If this field is not explicitly set, it will not appear in get listings. If not set the default behavior is to disable flow logging. + */ + enable?: boolean; + /** + * Can only be specified if VPC flow logging for this subnetwork is enabled. The value of the field must be in [0, 1]. Set the sampling rate of VPC flow logs within the subnetwork where 1.0 means all collected logs are reported and 0.0 means no logs are reported. Default is 0.5, which means half of all collected logs are reported. + */ + flowSampling?: number; + /** + * Can only be specified if VPC flow logs for this subnetwork is enabled. Configures whether all, none or a subset of metadata fields should be added to the reported VPC flow logs. Default is INCLUDE_ALL_METADATA. + */ + metadata?: string; + } /** * Represents a secondary IP range of a subnetwork. */ @@ -9134,6 +9289,205 @@ export namespace compute_v1 { message?: string; }; } + /** + * Represents a VPN gateway resource. + */ + export interface Schema$VpnGateway { + /** + * [Output Only] Creation timestamp in RFC3339 text format. + */ + creationTimestamp?: string; + /** + * An optional description of this resource. Provide this property when you create the resource. + */ + description?: string; + /** + * [Output Only] The unique identifier for the resource. This identifier is defined by the server. + */ + id?: string; + /** + * [Output Only] Type of resource. Always compute#vpnGateway for VPN gateways. + */ + kind?: string; + /** + * A fingerprint for the labels being applied to this VpnGateway, which is essentially a hash of the labels set used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update labels. You must always provide an up-to-date fingerprint hash in order to update or change labels, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an VpnGateway. + */ + labelFingerprint?: string; + /** + * Labels to apply to this VpnGateway resource. These can be later modified by the setLabels method. Each label key/value must comply with RFC1035. Label values may be empty. + */ + labels?: {[key: string]: string}; + /** + * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. + */ + name?: string; + /** + * URL of the network to which this VPN gateway is attached. Provided by the client when the VPN gateway is created. + */ + network?: string; + /** + * [Output Only] URL of the region where the VPN gateway resides. + */ + region?: string; + /** + * [Output Only] Server-defined URL for the resource. + */ + selfLink?: string; + /** + * [Output Only] A list of interfaces on this VPN gateway. + */ + vpnInterfaces?: Schema$VpnGatewayVpnGatewayInterface[]; + } + export interface Schema$VpnGatewayAggregatedList { + /** + * [Output Only] Unique identifier for the resource; defined by the server. + */ + id?: string; + /** + * A list of VpnGateway resources. + */ + items?: {[key: string]: Schema$VpnGatewaysScopedList}; + /** + * [Output Only] Type of resource. Always compute#vpnGateway for VPN gateways. + */ + kind?: string; + /** + * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. + */ + nextPageToken?: string; + /** + * [Output Only] Server-defined URL for this resource. + */ + selfLink?: string; + /** + * [Output Only] Informational warning message. + */ + warning?: { + code?: string; + data?: Array<{key?: string; value?: string}>; + message?: string; + }; + } + /** + * Contains a list of VpnGateway resources. + */ + export interface Schema$VpnGatewayList { + /** + * [Output Only] Unique identifier for the resource; defined by the server. + */ + id?: string; + /** + * A list of VpnGateway resources. + */ + items?: Schema$VpnGateway[]; + /** + * [Output Only] Type of resource. Always compute#vpnGateway for VPN gateways. + */ + kind?: string; + /** + * [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results. + */ + nextPageToken?: string; + /** + * [Output Only] Server-defined URL for this resource. + */ + selfLink?: string; + /** + * [Output Only] Informational warning message. + */ + warning?: { + code?: string; + data?: Array<{key?: string; value?: string}>; + message?: string; + }; + } + export interface Schema$VpnGatewaysGetStatusResponse { + result?: Schema$VpnGatewayStatus; + } + export interface Schema$VpnGatewaysScopedList { + /** + * [Output Only] A list of VPN gateways contained in this scope. + */ + vpnGateways?: Schema$VpnGateway[]; + /** + * [Output Only] Informational warning which replaces the list of addresses when the list is empty. + */ + warning?: { + code?: string; + data?: Array<{key?: string; value?: string}>; + message?: string; + }; + } + export interface Schema$VpnGatewayStatus { + /** + * List of VPN connection for this VpnGateway. + */ + vpnConnections?: Schema$VpnGatewayStatusVpnConnection[]; + } + /** + * Describes the high availability requirement state for the VPN connection between this Cloud VPN gateway and a peer gateway. + */ + export interface Schema$VpnGatewayStatusHighAvailabilityRequirementState { + /** + * Indicates the high availability requirement state for the VPN connection. Valid values are CONNECTION_REDUNDANCY_MET, CONNECTION_REDUNDANCY_NOT_MET. + */ + state?: string; + /** + * Indicates the reason why the VPN connection does not meet the high availability redundancy criteria/requirement. Valid values is INCOMPLETE_TUNNELS_COVERAGE. + */ + unsatisfiedReason?: string; + } + /** + * Contains some information about a VPN tunnel. + */ + export interface Schema$VpnGatewayStatusTunnel { + /** + * The VPN gateway interface this VPN tunnel is associated with. + */ + localGatewayInterface?: number; + /** + * The peer gateway interface this VPN tunnel is connected to, the peer gateway could either be an external VPN gateway or GCP VPN gateway. + */ + peerGatewayInterface?: number; + /** + * URL reference to the VPN tunnel. + */ + tunnelUrl?: string; + } + /** + * A VPN connection contains all VPN tunnels connected from this VpnGateway to the same peer gateway. The peer gateway could either be a external VPN gateway or GCP VPN gateway. + */ + export interface Schema$VpnGatewayStatusVpnConnection { + /** + * URL reference to the peer external VPN gateways to which the VPN tunnels in this VPN connection are connected. This field is mutually exclusive with peer_gcp_gateway. + */ + peerExternalGateway?: string; + /** + * URL reference to the peer side VPN gateways to which the VPN tunnels in this VPN connection are connected. This field is mutually exclusive with peer_gcp_gateway. + */ + peerGcpGateway?: string; + /** + * HighAvailabilityRequirementState for the VPN connection. + */ + state?: Schema$VpnGatewayStatusHighAvailabilityRequirementState; + /** + * List of VPN tunnels that are in this VPN connection. + */ + tunnels?: Schema$VpnGatewayStatusTunnel[]; + } + /** + * A VPN gateway interface. + */ + export interface Schema$VpnGatewayVpnGatewayInterface { + /** + * The numeric ID of this VPN gateway interface. + */ + id?: number; + /** + * The external IP address for this VPN gateway interface. + */ + ipAddress?: string; + } /** * Represents a Cloud VPN Tunnel resource. For more information about VPN, read the the Cloud VPN Overview. (== resource_for beta.vpnTunnels ==) (== resource_for v1.vpnTunnels ==) */ @@ -9170,6 +9524,18 @@ export namespace compute_v1 { * Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. */ name?: string; + /** + * URL of the peer side external VPN gateway to which this VPN tunnel is connected. Provided by the client when the VPN tunnel is created. This field is exclusive with the field peerGcpGateway. + */ + peerExternalGateway?: string; + /** + * The interface ID of the external VPN gateway to which this VPN tunnel is connected. Provided by the client when the VPN tunnel is created. + */ + peerExternalGatewayInterface?: number; + /** + * URL of the peer side HA GCP VPN gateway to which this VPN tunnel is connected. Provided by the client when the VPN tunnel is created. This field can be used when creating highly available VPN from VPC network to VPC network, the field is exclusive with the field peerExternalGateway. If provided, the VPN tunnel will automatically use the same vpnGatewayInterface ID in the peer GCP VPN gateway. + */ + peerGcpGateway?: string; /** * IP address of the peer VPN gateway. Only IPv4 is supported. */ @@ -9206,6 +9572,14 @@ export namespace compute_v1 { * URL of the Target VPN gateway with which this VPN tunnel is associated. Provided by the client when the VPN tunnel is created. */ targetVpnGateway?: string; + /** + * URL of the VPN gateway with which this VPN tunnel is associated. Provided by the client when the VPN tunnel is created. This must be used (instead of target_vpn_gateway) if a High Availability VPN gateway resource is created. + */ + vpnGateway?: string; + /** + * The interface ID of the VPN gateway with which this VPN tunnel is associated. + */ + vpnGatewayInterface?: number; } export interface Schema$VpnTunnelAggregatedList { /** @@ -9557,7 +9931,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -9694,7 +10068,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -9839,7 +10213,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -10072,7 +10446,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -10203,7 +10577,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -10332,7 +10706,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -10465,7 +10839,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -10609,7 +10983,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -10887,7 +11261,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -11019,7 +11393,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -11150,7 +11524,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -11284,7 +11658,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -11428,7 +11802,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -11564,7 +11938,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -11700,7 +12074,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -11970,7 +12344,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -12099,7 +12473,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -12176,7 +12550,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -12304,7 +12678,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -12434,7 +12808,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -12574,7 +12948,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -12708,7 +13082,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -12843,7 +13217,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -13112,7 +13486,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -13257,7 +13631,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -13391,7 +13765,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -13468,7 +13842,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -13596,7 +13970,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -13732,7 +14106,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -13865,7 +14239,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -14005,7 +14379,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -14139,7 +14513,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -14216,7 +14590,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -14351,7 +14725,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -14695,7 +15069,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -14838,7 +15212,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -14976,7 +15350,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -15108,7 +15482,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -15237,7 +15611,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -15311,7 +15685,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -15445,7 +15819,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -15586,7 +15960,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -15665,7 +16039,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -15802,7 +16176,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -15877,7 +16251,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -16014,7 +16388,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -16095,7 +16469,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -16594,7 +16968,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -16722,7 +17096,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -16866,7 +17240,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -16969,6 +17343,604 @@ export namespace compute_v1 { zone?: string; } + export class Resource$Externalvpngateways { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * compute.externalVpnGateways.delete + * @desc Deletes the specified externalVpnGateway. + * @alias compute.externalVpnGateways.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.externalVpnGateway Name of the externalVpnGateways to delete. + * @param {string} params.project Project ID for this request. + * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + delete( + params?: Params$Resource$Externalvpngateways$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Externalvpngateways$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Externalvpngateways$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Externalvpngateways$Delete + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Externalvpngateways$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Externalvpngateways$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/global/externalVpnGateways/{externalVpnGateway}' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['project', 'externalVpnGateway'], + pathParams: ['externalVpnGateway', 'project'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * compute.externalVpnGateways.get + * @desc Returns the specified externalVpnGateway. Get a list of available externalVpnGateways by making a list() request. + * @alias compute.externalVpnGateways.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.externalVpnGateway Name of the externalVpnGateway to return. + * @param {string} params.project Project ID for this request. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Externalvpngateways$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Externalvpngateways$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Externalvpngateways$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Externalvpngateways$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Externalvpngateways$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Externalvpngateways$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/global/externalVpnGateways/{externalVpnGateway}' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['project', 'externalVpnGateway'], + pathParams: ['externalVpnGateway', 'project'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * compute.externalVpnGateways.insert + * @desc Creates a ExternalVpnGateway in the specified project using the data included in the request. + * @alias compute.externalVpnGateways.insert + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.project Project ID for this request. + * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + * @param {().ExternalVpnGateway} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + insert( + params?: Params$Resource$Externalvpngateways$Insert, + options?: MethodOptions + ): GaxiosPromise; + insert( + params: Params$Resource$Externalvpngateways$Insert, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + insert( + params: Params$Resource$Externalvpngateways$Insert, + callback: BodyResponseCallback + ): void; + insert(callback: BodyResponseCallback): void; + insert( + paramsOrCallback?: + | Params$Resource$Externalvpngateways$Insert + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Externalvpngateways$Insert; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Externalvpngateways$Insert; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/global/externalVpnGateways' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['project'], + pathParams: ['project'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * compute.externalVpnGateways.list + * @desc Retrieves the list of ExternalVpnGateway available to the specified project. + * @alias compute.externalVpnGateways.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). + * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) + * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. + * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. + * @param {string} params.project Project ID for this request. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Externalvpngateways$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Externalvpngateways$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Externalvpngateways$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Externalvpngateways$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Externalvpngateways$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Externalvpngateways$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/global/externalVpnGateways' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['project'], + pathParams: ['project'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * compute.externalVpnGateways.setLabels + * @desc Sets the labels on an ExternalVpnGateway. To learn more about labels, read the Labeling Resources documentation. + * @alias compute.externalVpnGateways.setLabels + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.project Project ID for this request. + * @param {string} params.resource_ Name or id of the resource for this request. + * @param {().GlobalSetLabelsRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + setLabels( + params?: Params$Resource$Externalvpngateways$Setlabels, + options?: MethodOptions + ): GaxiosPromise; + setLabels( + params: Params$Resource$Externalvpngateways$Setlabels, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + setLabels( + params: Params$Resource$Externalvpngateways$Setlabels, + callback: BodyResponseCallback + ): void; + setLabels(callback: BodyResponseCallback): void; + setLabels( + paramsOrCallback?: + | Params$Resource$Externalvpngateways$Setlabels + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Externalvpngateways$Setlabels; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Externalvpngateways$Setlabels; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/global/externalVpnGateways/{resource}/setLabels' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['project', 'resource'], + pathParams: ['project', 'resource'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * compute.externalVpnGateways.testIamPermissions + * @desc Returns permissions that a caller has on the specified resource. + * @alias compute.externalVpnGateways.testIamPermissions + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.project Project ID for this request. + * @param {string} params.resource_ Name or id of the resource for this request. + * @param {().TestPermissionsRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + testIamPermissions( + params?: Params$Resource$Externalvpngateways$Testiampermissions, + options?: MethodOptions + ): GaxiosPromise; + testIamPermissions( + params: Params$Resource$Externalvpngateways$Testiampermissions, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + testIamPermissions( + params: Params$Resource$Externalvpngateways$Testiampermissions, + callback: BodyResponseCallback + ): void; + testIamPermissions( + callback: BodyResponseCallback + ): void; + testIamPermissions( + paramsOrCallback?: + | Params$Resource$Externalvpngateways$Testiampermissions + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Externalvpngateways$Testiampermissions; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Externalvpngateways$Testiampermissions; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/global/externalVpnGateways/{resource}/testIamPermissions' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['project', 'resource'], + pathParams: ['project', 'resource'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Externalvpngateways$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Name of the externalVpnGateways to delete. + */ + externalVpnGateway?: string; + /** + * Project ID for this request. + */ + project?: string; + /** + * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + */ + requestId?: string; + } + export interface Params$Resource$Externalvpngateways$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Name of the externalVpnGateway to return. + */ + externalVpnGateway?: string; + /** + * Project ID for this request. + */ + project?: string; + } + export interface Params$Resource$Externalvpngateways$Insert + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Project ID for this request. + */ + project?: string; + /** + * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + */ + requestId?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$ExternalVpnGateway; + } + export interface Params$Resource$Externalvpngateways$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). + */ + filter?: string; + /** + * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) + */ + maxResults?: number; + /** + * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. + */ + orderBy?: string; + /** + * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. + */ + pageToken?: string; + /** + * Project ID for this request. + */ + project?: string; + } + export interface Params$Resource$Externalvpngateways$Setlabels + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Project ID for this request. + */ + project?: string; + /** + * Name or id of the resource for this request. + */ + resource?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$GlobalSetLabelsRequest; + } + export interface Params$Resource$Externalvpngateways$Testiampermissions + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Project ID for this request. + */ + project?: string; + /** + * Name or id of the resource for this request. + */ + resource?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$TestPermissionsRequest; + } + export class Resource$Firewalls { context: APIRequestContext; constructor(context: APIRequestContext) { @@ -17079,7 +18051,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -17204,7 +18176,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -17333,7 +18305,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -17472,7 +18444,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -17605,7 +18577,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -17739,7 +18711,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -18021,7 +18993,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -18159,7 +19131,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -18291,7 +19263,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -18425,7 +19397,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -18570,7 +19542,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -18708,7 +19680,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -19003,7 +19975,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -19129,7 +20101,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -19259,7 +20231,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -19399,7 +20371,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -19620,7 +20592,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -19748,7 +20720,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -19878,7 +20850,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -20018,7 +20990,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -20151,7 +21123,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -20414,7 +21386,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -20536,7 +21508,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -20664,7 +21636,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -20805,7 +21777,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -21029,7 +22001,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -21156,7 +22128,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -21286,7 +22258,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -21426,7 +22398,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -21560,7 +22532,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -21695,7 +22667,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -21966,7 +22938,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -22094,7 +23066,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -22224,7 +23196,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -22364,7 +23336,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -22498,7 +23470,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -22633,7 +23605,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -22905,7 +23877,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -23033,7 +24005,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -23163,7 +24135,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -23306,7 +24278,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -23441,7 +24413,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -23576,7 +24548,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -23847,7 +24819,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -23979,7 +24951,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -24104,7 +25076,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -24229,7 +25201,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -24302,7 +25274,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -24432,7 +25404,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -24571,7 +25543,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -24644,7 +25616,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -24776,7 +25748,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -24856,7 +25828,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -25205,7 +26177,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -25350,7 +26322,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -25488,7 +26460,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -25626,7 +26598,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -25760,7 +26732,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -25894,7 +26866,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -26041,7 +27013,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -26197,7 +27169,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -26279,7 +27251,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -26417,7 +27389,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -26556,7 +27528,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -26694,7 +27666,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -26832,7 +27804,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -27345,7 +28317,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -27490,7 +28462,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -27626,7 +28598,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -27758,7 +28730,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -27892,7 +28864,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -28037,7 +29009,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -28195,7 +29167,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -28336,7 +29308,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -28474,7 +29446,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -28881,7 +29853,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -29026,7 +29998,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -29164,7 +30136,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -29296,7 +30268,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -29437,7 +30409,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -29580,7 +30552,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -29709,7 +30681,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -29789,7 +30761,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -29863,7 +30835,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -29999,7 +30971,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -30079,7 +31051,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -30213,7 +31185,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -30356,7 +31328,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -30439,7 +31411,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -30571,7 +31543,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -30707,7 +31679,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -30848,7 +31820,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -30929,7 +31901,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -31067,7 +32039,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -31205,7 +32177,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -31343,7 +32315,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -31481,7 +32453,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -31619,7 +32591,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -31757,7 +32729,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -31895,7 +32867,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -31975,7 +32947,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -32113,7 +33085,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -32191,7 +33163,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -32323,7 +33295,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -32463,7 +33435,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -32595,7 +33567,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -32676,7 +33648,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -32755,7 +33727,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -32779,6 +33751,84 @@ export namespace compute_v1 { } } + /** + * compute.instances.updateDisplayDevice + * @desc Updates the Display config for a VM instance. You can only use this method on a stopped VM instance. This method supports PATCH semantics and uses the JSON merge patch format and processing rules. + * @alias compute.instances.updateDisplayDevice + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.instance Name of the instance scoping this request. + * @param {string} params.project Project ID for this request. + * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + * @param {string} params.zone The name of the zone for this request. + * @param {().DisplayDevice} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + updateDisplayDevice( + params?: Params$Resource$Instances$Updatedisplaydevice, + options?: MethodOptions + ): GaxiosPromise; + updateDisplayDevice( + params: Params$Resource$Instances$Updatedisplaydevice, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + updateDisplayDevice( + params: Params$Resource$Instances$Updatedisplaydevice, + callback: BodyResponseCallback + ): void; + updateDisplayDevice(callback: BodyResponseCallback): void; + updateDisplayDevice( + paramsOrCallback?: + | Params$Resource$Instances$Updatedisplaydevice + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Instances$Updatedisplaydevice; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Instances$Updatedisplaydevice; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/zones/{zone}/instances/{instance}/updateDisplayDevice' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'PATCH', + }, + options + ), + params, + requiredParams: ['project', 'zone', 'instance'], + pathParams: ['instance', 'project', 'zone'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + /** * compute.instances.updateNetworkInterface * @desc Updates an instance's network interface. This method follows PATCH semantics. @@ -32836,7 +33886,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -32916,7 +33966,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -33850,6 +34900,35 @@ export namespace compute_v1 { */ requestBody?: Schema$AccessConfig; } + export interface Params$Resource$Instances$Updatedisplaydevice + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Name of the instance scoping this request. + */ + instance?: string; + /** + * Project ID for this request. + */ + project?: string; + /** + * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + */ + requestId?: string; + /** + * The name of the zone for this request. + */ + zone?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$DisplayDevice; + } export interface Params$Resource$Instances$Updatenetworkinterface extends StandardParameters { /** @@ -34024,7 +35103,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -34152,7 +35231,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -34225,7 +35304,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -34355,7 +35434,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -34498,7 +35577,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -34572,7 +35651,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -34652,7 +35731,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -34956,7 +36035,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -35094,7 +36173,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -35228,7 +36307,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -35362,7 +36441,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -35511,7 +36590,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -35592,7 +36671,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -35888,7 +36967,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -36031,7 +37110,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -36212,7 +37291,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -36340,7 +37419,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -36421,7 +37500,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -36556,7 +37635,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -36696,7 +37775,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -36830,7 +37909,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -37038,7 +38117,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -37118,7 +38197,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -37237,7 +38316,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -37362,7 +38441,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -37435,7 +38514,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -37510,7 +38589,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -37588,7 +38667,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -37661,7 +38740,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -37741,7 +38820,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -38033,7 +39112,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -38166,7 +39245,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -38311,7 +39390,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -38480,7 +39559,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -38565,7 +39644,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -38642,7 +39721,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -38722,7 +39801,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -38800,7 +39879,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -38877,7 +39956,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -38958,7 +40037,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -39057,7 +40136,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -39143,7 +40222,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -39538,7 +40617,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -39666,7 +40745,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -39791,7 +40870,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -39920,7 +40999,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -40059,7 +41138,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -40192,7 +41271,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -40326,7 +41405,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -40455,7 +41534,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -40478,6 +41557,83 @@ export namespace compute_v1 { return createAPIRequest(parameters); } } + + /** + * compute.networks.updatePeering + * @desc Updates the specified network peering with the data included in the request Only the following fields can be modified: NetworkPeering.export_custom_routes, and NetworkPeering.import_custom_routes + * @alias compute.networks.updatePeering + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.network Name of the network resource which the updated peering is belonging to. + * @param {string} params.project Project ID for this request. + * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + * @param {().NetworksUpdatePeeringRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + updatePeering( + params?: Params$Resource$Networks$Updatepeering, + options?: MethodOptions + ): GaxiosPromise; + updatePeering( + params: Params$Resource$Networks$Updatepeering, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + updatePeering( + params: Params$Resource$Networks$Updatepeering, + callback: BodyResponseCallback + ): void; + updatePeering(callback: BodyResponseCallback): void; + updatePeering( + paramsOrCallback?: + | Params$Resource$Networks$Updatepeering + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Networks$Updatepeering; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Networks$Updatepeering; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/global/networks/{network}/updatePeering' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'PATCH', + }, + options + ), + params, + requiredParams: ['project', 'network'], + pathParams: ['network', 'project'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } export interface Params$Resource$Networks$Addpeering @@ -40655,6 +41811,31 @@ export namespace compute_v1 { */ requestId?: string; } + export interface Params$Resource$Networks$Updatepeering + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Name of the network resource which the updated peering is belonging to. + */ + network?: string; + /** + * Project ID for this request. + */ + project?: string; + /** + * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + */ + requestId?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$NetworksUpdatePeeringRequest; + } export class Resource$Nodegroups { context: APIRequestContext; @@ -40716,7 +41897,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -40798,7 +41979,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -40874,7 +42055,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -40905,7 +42086,7 @@ export namespace compute_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.nodeGroup Name of the NodeGroup resource to delete. + * @param {string} params.nodeGroup Name of the NodeGroup resource whose nodes will be deleted. * @param {string} params.project Project ID for this request. * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). * @param {string} params.zone The name of the zone for this request. @@ -40952,7 +42133,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -41027,7 +42208,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -41101,7 +42282,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -41179,7 +42360,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -41256,7 +42437,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -41335,7 +42516,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -41410,7 +42591,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -41488,7 +42669,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -41569,7 +42750,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -41683,7 +42864,7 @@ export namespace compute_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Name of the NodeGroup resource to delete. + * Name of the NodeGroup resource whose nodes will be deleted. */ nodeGroup?: string; /** @@ -41983,7 +43164,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -42063,7 +43244,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -42139,7 +43320,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -42213,7 +43394,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -42290,7 +43471,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -42369,7 +43550,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -42444,7 +43625,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -42525,7 +43706,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -42814,7 +43995,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -42886,7 +44067,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -42964,7 +44145,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -43174,7 +44355,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -43303,7 +44484,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -43427,7 +44608,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -43556,7 +44737,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -43676,7 +44857,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -43798,7 +44979,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -43942,7 +45123,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -44087,7 +45268,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -44216,7 +45397,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -44346,7 +45527,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -44477,7 +45658,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -44555,7 +45736,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -44686,7 +45867,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -45089,7 +46270,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -45221,7 +46402,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -45355,7 +46536,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -45502,7 +46683,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -45638,7 +46819,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -45774,7 +46955,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -46074,7 +47255,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -46206,7 +47387,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -46346,7 +47527,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -46483,7 +47664,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -46628,7 +47809,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -46767,7 +47948,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -46906,7 +48087,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -47243,7 +48424,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -47374,7 +48555,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -47508,7 +48689,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -47653,7 +48834,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -47844,7 +49025,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -47922,7 +49103,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -47999,7 +49180,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -48072,7 +49253,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -48150,7 +49331,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -48225,7 +49406,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -48304,7 +49485,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -48382,7 +49563,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -48460,7 +49641,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -48541,7 +49722,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -48896,7 +50077,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -48975,7 +50156,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -49173,7 +50354,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -49306,7 +50487,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -49444,7 +50625,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -49578,7 +50759,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -49712,7 +50893,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -49861,7 +51042,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -50022,7 +51203,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -50104,7 +51285,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -50242,7 +51423,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -50379,7 +51560,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -50517,7 +51698,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -50655,7 +51836,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -51134,7 +52315,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -51281,7 +52462,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -51439,7 +52620,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -51582,7 +52763,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -51839,7 +53020,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -51971,7 +53152,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -52116,7 +53297,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -52321,7 +53502,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -52460,7 +53641,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -52592,7 +53773,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -52671,7 +53852,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -52697,7 +53878,7 @@ export namespace compute_v1 { /** * compute.reservations.get - * @desc Retrieves all information of the specified reservation. + * @desc Retrieves information about the specified reservation. * @alias compute.reservations.get * @memberOf! () * @@ -52746,7 +53927,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -52820,7 +54001,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -52897,7 +54078,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -52923,7 +54104,7 @@ export namespace compute_v1 { /** * compute.reservations.list - * @desc A list all the reservations that have been configured for the specified project in specified zone. + * @desc A list of all the reservations that have been configured for the specified project in specified zone. * @alias compute.reservations.list * @memberOf! () * @@ -52976,7 +54157,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -53002,7 +54183,7 @@ export namespace compute_v1 { /** * compute.reservations.resize - * @desc Resizes the reservation (applicable to standalone reservations only) + * @desc Resizes the reservation (applicable to standalone reservations only). For more information, read Modifying reservations. * @alias compute.reservations.resize * @memberOf! () * @@ -53054,7 +54235,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -53129,7 +54310,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -53210,7 +54391,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -53527,7 +54708,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -53609,7 +54790,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -53685,7 +54866,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -53759,7 +54940,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -53836,7 +55017,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -53915,7 +55096,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -53990,7 +55171,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -54071,7 +55252,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -54423,7 +55604,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -54554,7 +55735,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -54683,7 +55864,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -54767,7 +55948,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -54906,7 +56087,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -55039,7 +56220,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -55183,7 +56364,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -55321,7 +56502,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -55461,7 +56642,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -55599,7 +56780,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -55996,7 +57177,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -56120,7 +57301,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -56248,7 +57429,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -56387,7 +57568,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -56551,7 +57732,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -56627,7 +57808,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -56702,7 +57883,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -56778,7 +57959,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -56854,7 +58035,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -56931,7 +58112,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -57007,7 +58188,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -57084,7 +58265,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -57160,7 +58341,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -57492,7 +58673,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -57617,7 +58798,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -57690,7 +58871,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -57830,7 +59011,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -57903,7 +59084,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -58036,7 +59217,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -58116,7 +59297,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -58393,7 +59574,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -58521,7 +59702,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -58651,7 +59832,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -58791,7 +59972,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -58959,7 +60140,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -59033,7 +60214,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -59109,7 +60290,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -59185,7 +60366,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -59274,7 +60455,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -59356,7 +60537,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -59645,7 +60826,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -59777,7 +60958,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -59915,7 +61096,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -60046,7 +61227,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -60120,7 +61301,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -60254,7 +61435,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -60398,7 +61579,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -60424,7 +61605,7 @@ export namespace compute_v1 { /** * compute.subnetworks.listUsable - * @desc Retrieves an aggregated list of usable subnetworks. + * @desc Retrieves an aggregated list of all usable subnetworks in the project. The list contains all of the subnetworks in the project and the subnetworks that were shared by a Shared VPC host project. * @alias compute.subnetworks.listUsable * @memberOf! () * @@ -60480,7 +61661,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -60563,7 +61744,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -60638,7 +61819,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -60778,7 +61959,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -60859,7 +62040,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -61308,7 +62489,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -61436,7 +62617,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -61566,7 +62747,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -61707,7 +62888,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -61841,7 +63022,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -62088,7 +63269,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -62216,7 +63397,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -62346,7 +63527,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -62489,7 +63670,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -62566,7 +63747,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -62700,7 +63881,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -62777,7 +63958,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -62911,7 +64092,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -63249,7 +64430,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -63387,7 +64568,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -63519,7 +64700,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -63653,7 +64834,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -63798,7 +64979,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -64073,7 +65254,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -64211,7 +65392,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -64356,7 +65537,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -64488,7 +65669,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -64619,7 +65800,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -64760,7 +65941,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -64894,7 +66075,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -65038,7 +66219,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -65176,7 +66357,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -65314,7 +66495,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -65453,7 +66634,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -65891,7 +67072,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -66019,7 +67200,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -66149,7 +67330,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -66289,7 +67470,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -66422,7 +67603,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -66556,7 +67737,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -66690,7 +67871,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -66767,7 +67948,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -67089,7 +68270,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -67217,7 +68398,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -67347,7 +68528,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -67487,7 +68668,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -67620,7 +68801,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -67754,7 +68935,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -68042,7 +69223,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -68180,7 +69361,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -68312,7 +69493,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -68446,7 +69627,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -68593,7 +69774,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -68858,7 +70039,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -68982,7 +70163,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -69110,7 +70291,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -69243,7 +70424,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -69383,7 +70564,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -69516,7 +70697,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -69649,7 +70830,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -69784,7 +70965,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -69984,6 +71165,847 @@ export namespace compute_v1 { requestBody?: Schema$UrlMapsValidateRequest; } + export class Resource$Vpngateways { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * compute.vpnGateways.aggregatedList + * @desc Retrieves an aggregated list of VPN gateways. + * @alias compute.vpnGateways.aggregatedList + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). + * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) + * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. + * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. + * @param {string} params.project Project ID for this request. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + aggregatedList( + params?: Params$Resource$Vpngateways$Aggregatedlist, + options?: MethodOptions + ): GaxiosPromise; + aggregatedList( + params: Params$Resource$Vpngateways$Aggregatedlist, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + aggregatedList( + params: Params$Resource$Vpngateways$Aggregatedlist, + callback: BodyResponseCallback + ): void; + aggregatedList( + callback: BodyResponseCallback + ): void; + aggregatedList( + paramsOrCallback?: + | Params$Resource$Vpngateways$Aggregatedlist + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Vpngateways$Aggregatedlist; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Vpngateways$Aggregatedlist; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + '/compute/v1/projects/{project}/aggregated/vpnGateways' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['project'], + pathParams: ['project'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * compute.vpnGateways.delete + * @desc Deletes the specified VPN gateway. + * @alias compute.vpnGateways.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.project Project ID for this request. + * @param {string} params.region Name of the region for this request. + * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + * @param {string} params.vpnGateway Name of the VPN gateway to delete. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + delete( + params?: Params$Resource$Vpngateways$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Vpngateways$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Vpngateways$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Vpngateways$Delete + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Vpngateways$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Vpngateways$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/regions/{region}/vpnGateways/{vpnGateway}' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['project', 'region', 'vpnGateway'], + pathParams: ['project', 'region', 'vpnGateway'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * compute.vpnGateways.get + * @desc Returns the specified VPN gateway. Gets a list of available VPN gateways by making a list() request. + * @alias compute.vpnGateways.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.project Project ID for this request. + * @param {string} params.region Name of the region for this request. + * @param {string} params.vpnGateway Name of the VPN gateway to return. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Vpngateways$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Vpngateways$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Vpngateways$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Vpngateways$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Vpngateways$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Vpngateways$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/regions/{region}/vpnGateways/{vpnGateway}' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['project', 'region', 'vpnGateway'], + pathParams: ['project', 'region', 'vpnGateway'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * compute.vpnGateways.getStatus + * @desc Returns the status for the specified VPN gateway. + * @alias compute.vpnGateways.getStatus + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.project Project ID for this request. + * @param {string} params.region Name of the region for this request. + * @param {string} params.vpnGateway Name of the VPN gateway to return. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + getStatus( + params?: Params$Resource$Vpngateways$Getstatus, + options?: MethodOptions + ): GaxiosPromise; + getStatus( + params: Params$Resource$Vpngateways$Getstatus, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + getStatus( + params: Params$Resource$Vpngateways$Getstatus, + callback: BodyResponseCallback + ): void; + getStatus( + callback: BodyResponseCallback + ): void; + getStatus( + paramsOrCallback?: + | Params$Resource$Vpngateways$Getstatus + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Vpngateways$Getstatus; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Vpngateways$Getstatus; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/regions/{region}/vpnGateways/{vpnGateway}/getStatus' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['project', 'region', 'vpnGateway'], + pathParams: ['project', 'region', 'vpnGateway'], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest( + parameters + ); + } + } + + /** + * compute.vpnGateways.insert + * @desc Creates a VPN gateway in the specified project and region using the data included in the request. + * @alias compute.vpnGateways.insert + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.project Project ID for this request. + * @param {string} params.region Name of the region for this request. + * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + * @param {().VpnGateway} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + insert( + params?: Params$Resource$Vpngateways$Insert, + options?: MethodOptions + ): GaxiosPromise; + insert( + params: Params$Resource$Vpngateways$Insert, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + insert( + params: Params$Resource$Vpngateways$Insert, + callback: BodyResponseCallback + ): void; + insert(callback: BodyResponseCallback): void; + insert( + paramsOrCallback?: + | Params$Resource$Vpngateways$Insert + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Vpngateways$Insert; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Vpngateways$Insert; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/regions/{region}/vpnGateways' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['project', 'region'], + pathParams: ['project', 'region'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * compute.vpnGateways.list + * @desc Retrieves a list of VPN gateways available to the specified project and region. + * @alias compute.vpnGateways.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.filter A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). + * @param {integer=} params.maxResults The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) + * @param {string=} params.orderBy Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. + * @param {string=} params.pageToken Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. + * @param {string} params.project Project ID for this request. + * @param {string} params.region Name of the region for this request. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Vpngateways$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Vpngateways$List, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Vpngateways$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Vpngateways$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Vpngateways$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Vpngateways$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/regions/{region}/vpnGateways' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['project', 'region'], + pathParams: ['project', 'region'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * compute.vpnGateways.setLabels + * @desc Sets the labels on a VpnGateway. To learn more about labels, read the Labeling Resources documentation. + * @alias compute.vpnGateways.setLabels + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.project Project ID for this request. + * @param {string} params.region The region for this request. + * @param {string=} params.requestId An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + * @param {string} params.resource_ Name or id of the resource for this request. + * @param {().RegionSetLabelsRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + setLabels( + params?: Params$Resource$Vpngateways$Setlabels, + options?: MethodOptions + ): GaxiosPromise; + setLabels( + params: Params$Resource$Vpngateways$Setlabels, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + setLabels( + params: Params$Resource$Vpngateways$Setlabels, + callback: BodyResponseCallback + ): void; + setLabels(callback: BodyResponseCallback): void; + setLabels( + paramsOrCallback?: + | Params$Resource$Vpngateways$Setlabels + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Vpngateways$Setlabels; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Vpngateways$Setlabels; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/regions/{region}/vpnGateways/{resource}/setLabels' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['project', 'region', 'resource'], + pathParams: ['project', 'region', 'resource'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * compute.vpnGateways.testIamPermissions + * @desc Returns permissions that a caller has on the specified resource. + * @alias compute.vpnGateways.testIamPermissions + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.project Project ID for this request. + * @param {string} params.region The name of the region for this request. + * @param {string} params.resource_ Name or id of the resource for this request. + * @param {().TestPermissionsRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + testIamPermissions( + params?: Params$Resource$Vpngateways$Testiampermissions, + options?: MethodOptions + ): GaxiosPromise; + testIamPermissions( + params: Params$Resource$Vpngateways$Testiampermissions, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + testIamPermissions( + params: Params$Resource$Vpngateways$Testiampermissions, + callback: BodyResponseCallback + ): void; + testIamPermissions( + callback: BodyResponseCallback + ): void; + testIamPermissions( + paramsOrCallback?: + | Params$Resource$Vpngateways$Testiampermissions + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Vpngateways$Testiampermissions; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Vpngateways$Testiampermissions; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/compute/v1/projects/{project}/regions/{region}/vpnGateways/{resource}/testIamPermissions' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['project', 'region', 'resource'], + pathParams: ['project', 'region', 'resource'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Vpngateways$Aggregatedlist + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). + */ + filter?: string; + /** + * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) + */ + maxResults?: number; + /** + * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. + */ + orderBy?: string; + /** + * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. + */ + pageToken?: string; + /** + * Project ID for this request. + */ + project?: string; + } + export interface Params$Resource$Vpngateways$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Project ID for this request. + */ + project?: string; + /** + * Name of the region for this request. + */ + region?: string; + /** + * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + */ + requestId?: string; + /** + * Name of the VPN gateway to delete. + */ + vpnGateway?: string; + } + export interface Params$Resource$Vpngateways$Get extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Project ID for this request. + */ + project?: string; + /** + * Name of the region for this request. + */ + region?: string; + /** + * Name of the VPN gateway to return. + */ + vpnGateway?: string; + } + export interface Params$Resource$Vpngateways$Getstatus + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Project ID for this request. + */ + project?: string; + /** + * Name of the region for this request. + */ + region?: string; + /** + * Name of the VPN gateway to return. + */ + vpnGateway?: string; + } + export interface Params$Resource$Vpngateways$Insert + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Project ID for this request. + */ + project?: string; + /** + * Name of the region for this request. + */ + region?: string; + /** + * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + */ + requestId?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$VpnGateway; + } + export interface Params$Resource$Vpngateways$List extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). + */ + filter?: string; + /** + * The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500) + */ + maxResults?: number; + /** + * Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. Currently, only sorting by name or creationTimestamp desc is supported. + */ + orderBy?: string; + /** + * Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results. + */ + pageToken?: string; + /** + * Project ID for this request. + */ + project?: string; + /** + * Name of the region for this request. + */ + region?: string; + } + export interface Params$Resource$Vpngateways$Setlabels + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Project ID for this request. + */ + project?: string; + /** + * The region for this request. + */ + region?: string; + /** + * An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). + */ + requestId?: string; + /** + * Name or id of the resource for this request. + */ + resource?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$RegionSetLabelsRequest; + } + export interface Params$Resource$Vpngateways$Testiampermissions + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Project ID for this request. + */ + project?: string; + /** + * The name of the region for this request. + */ + region?: string; + /** + * Name or id of the resource for this request. + */ + resource?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$TestPermissionsRequest; + } + export class Resource$Vpntunnels { context: APIRequestContext; constructor(context: APIRequestContext) { @@ -70111,7 +72133,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -70243,7 +72265,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -70374,7 +72396,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -70508,7 +72530,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -70652,7 +72674,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -70914,7 +72936,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -71046,7 +73068,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -71191,7 +73213,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -71395,7 +73417,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { @@ -71532,7 +73554,7 @@ export namespace compute_v1 { options = {}; } - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const rootUrl = options.rootUrl || 'https://compute.googleapis.com/'; const parameters = { options: Object.assign( { diff --git a/src/apis/container/v1.ts b/src/apis/container/v1.ts index 7bb831b5fe5..b0fefd2a829 100644 --- a/src/apis/container/v1.ts +++ b/src/apis/container/v1.ts @@ -405,6 +405,10 @@ export namespace container_v1 { * The desired image type for the node pool. NOTE: Set the "desired_node_pool" field as well. */ desiredImageType?: string; + /** + * The desired config of Intra-node visibility. + */ + desiredIntraNodeVisibilityConfig?: Schema$IntraNodeVisibilityConfig; /** * The desired list of Google Compute Engine [zones](/compute/docs/zones#available) in which the cluster's nodes should be located. Changing the locations a cluster is in will result in nodes being either created or removed from the cluster, depending on whether locations are being added or removed. This list must always include the cluster's primary zone. */ @@ -539,6 +543,10 @@ export namespace container_v1 { * GetJSONWebKeysResponse is a valid JSON Web Key Set as specififed in rfc 7517 */ export interface Schema$GetJSONWebKeysResponse { + /** + * OnePlatform automatically extracts this field and uses it to set the HTTP Cache-Control header. + */ + cacheHeader?: Schema$HttpCacheControlResponseHeader; /** * The public component of the keys used by the cluster to sign token requests. */ @@ -548,6 +556,10 @@ export namespace container_v1 { * GetOpenIDConfigResponse is an OIDC discovery document for the cluster. See the OpenID Connect Discovery 1.0 specification for details. */ export interface Schema$GetOpenIDConfigResponse { + /** + * OnePlatform automatically extracts this field and uses it to set the HTTP Cache-Control header. + */ + cacheHeader?: Schema$HttpCacheControlResponseHeader; /** * Supported claims. */ @@ -586,6 +598,23 @@ export namespace container_v1 { */ disabled?: boolean; } + /** + * RFC-2616: cache control support + */ + export interface Schema$HttpCacheControlResponseHeader { + /** + * 14.6 response cache age, in seconds since the response is generated + */ + age?: string; + /** + * 14.9 request and response directives + */ + directive?: string; + /** + * 14.21 response cache expires, in RFC 1123 date format + */ + expires?: string; + } /** * Configuration options for the HTTP (L7) load balancing controller addon, which makes it easy to set up HTTP load balancers for services in a cluster. */ @@ -595,6 +624,15 @@ export namespace container_v1 { */ disabled?: boolean; } + /** + * IntraNodeVisibilityConfig contains the desired config of the intra-node visibility on this cluster. + */ + export interface Schema$IntraNodeVisibilityConfig { + /** + * Enables intra node visibility for this cluster. + */ + enabled?: boolean; + } /** * Configuration for controlling how IPs are allocated in the cluster. */ @@ -828,6 +866,10 @@ export namespace container_v1 { * NetworkConfig reports the relative names of network & subnetwork. */ export interface Schema$NetworkConfig { + /** + * Whether Intra-node visibility is enabled for this cluster. This makes same node pod to pod traffic visible for VPC network. + */ + enableIntraNodeVisibility?: boolean; /** * Output only. The relative name of the Google Compute Engine network(/compute/docs/networks-and-firewalls#networks) to which the cluster is connected. Example: projects/my-project/global/networks/my-network */ diff --git a/src/apis/container/v1beta1.ts b/src/apis/container/v1beta1.ts index efe16497a3a..fd5549cfa6e 100644 --- a/src/apis/container/v1beta1.ts +++ b/src/apis/container/v1beta1.ts @@ -436,6 +436,10 @@ export namespace container_v1beta1 { * Configuration for private cluster. */ privateClusterConfig?: Schema$PrivateClusterConfig; + /** + * Release channel configuration. + */ + releaseChannel?: Schema$ReleaseChannel; /** * The resource labels for the cluster to use to annotate any related Google Compute Engine resources. */ @@ -452,6 +456,10 @@ export namespace container_v1beta1 { * [Output only] The IP address range of the Kubernetes services in this cluster, in [CIDR](http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing) notation (e.g. `1.2.3.4/29`). Service addresses are typically put in the last `/16` from the container CIDR. */ servicesIpv4Cidr?: string; + /** + * Shielded Nodes configuration. + */ + shieldedNodes?: Schema$ShieldedNodes; /** * [Output only] The current status of this cluster. */ @@ -578,6 +586,10 @@ export namespace container_v1beta1 { * The desired configuration for exporting resource usage. */ desiredResourceUsageExportConfig?: Schema$ResourceUsageExportConfig; + /** + * Configuration for Shielded Nodes. + */ + desiredShieldedNodes?: Schema$ShieldedNodes; /** * Cluster-level Vertical Pod Autoscaling configuration. */ @@ -693,10 +705,27 @@ export namespace container_v1beta1 { * A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`. */ export interface Schema$Empty {} + /** + * FeatureConfig is the configuration for a specific feature including the definition of the feature as well as the tier in which it resides. + */ + export interface Schema$FeatureConfig { + /** + * The feature that is being configured with this value. + */ + feature?: string; + /** + * The tier in which the configured feature resides. + */ + tier?: string; + } /** * GetJSONWebKeysResponse is a valid JSON Web Key Set as specififed in rfc 7517 */ export interface Schema$GetJSONWebKeysResponse { + /** + * OnePlatform automatically extracts this field and uses it to set the HTTP Cache-Control header. + */ + cacheHeader?: Schema$HttpCacheControlResponseHeader; /** * The public component of the keys used by the cluster to sign token requests. */ @@ -706,6 +735,10 @@ export namespace container_v1beta1 { * GetOpenIDConfigResponse is an OIDC discovery document for the cluster. See the OpenID Connect Discovery 1.0 specification for details. */ export interface Schema$GetOpenIDConfigResponse { + /** + * OnePlatform automatically extracts this field and uses it to set the HTTP Cache-Control header. + */ + cacheHeader?: Schema$HttpCacheControlResponseHeader; /** * Supported claims. */ @@ -744,6 +777,23 @@ export namespace container_v1beta1 { */ disabled?: boolean; } + /** + * RFC-2616: cache control support + */ + export interface Schema$HttpCacheControlResponseHeader { + /** + * 14.6 response cache age, in seconds since the response is generated + */ + age?: string; + /** + * 14.9 request and response directives + */ + directive?: string; + /** + * 14.21 response cache expires, in RFC 1123 date format + */ + expires?: string; + } /** * Configuration options for the HTTP (L7) load balancing controller addon, which makes it easy to set up HTTP load balancers for services in a cluster. */ @@ -1375,6 +1425,19 @@ export namespace container_v1beta1 { */ enabled?: boolean; } + /** + * PremiumConfig is the configuration for all premium features and tiers. + */ + export interface Schema$PremiumConfig { + /** + * The features that GKE provides. + */ + features?: Schema$FeatureConfig[]; + /** + * The tiers that are part of the premium offering. + */ + tiers?: Schema$TierConfig[]; + } /** * Configuration options for private clusters. */ @@ -1404,6 +1467,28 @@ export namespace container_v1beta1 { */ publicEndpoint?: string; } + /** + * ReleaseChannel indicates which release channel a cluster is subscribed to. Release channels are arranged in order of risk and frequency of updates. When a cluster is subscribed to a release channel, Google maintains both the master version and the node version. Node auto-upgrade defaults to true and cannot be disabled. Updates to version related fields (e.g. current_master_version) return an error. + */ + export interface Schema$ReleaseChannel { + /** + * channel specifies which release channel the cluster is subscribed to. + */ + channel?: string; + } + /** + * ReleaseChannelConfig exposes configuration for a release channel. + */ + export interface Schema$ReleaseChannelConfig { + /** + * The release channel this configuration applies to. + */ + channel?: string; + /** + * The default version for newly created clusters on the channel. + */ + defaultVersion?: string; + } /** * Contains information about amount of some resource in the cluster. For memory, value should be in GB. */ @@ -1476,6 +1561,10 @@ export namespace container_v1beta1 { * Kubernetes Engine service configuration. */ export interface Schema$ServerConfig { + /** + * List of release channel configurations. + */ + channels?: Schema$ReleaseChannelConfig[]; /** * Version of Kubernetes the service deploys by default. */ @@ -1484,6 +1573,10 @@ export namespace container_v1beta1 { * Default image type. */ defaultImageType?: string; + /** + * Premium configuration for service. + */ + premiumConfig?: Schema$PremiumConfig; /** * List of valid image types. */ @@ -1830,6 +1923,15 @@ export namespace container_v1beta1 { */ enableSecureBoot?: boolean; } + /** + * Configuration of Shielded Nodes feature. + */ + export interface Schema$ShieldedNodes { + /** + * Whether Shielded Nodes features are enabled on all nodes in this cluster. + */ + enabled?: boolean; + } /** * StartIPRotationRequest creates a new IP for the cluster and then performs a node upgrade on each node pool to point to the new IP. */ @@ -1868,6 +1970,19 @@ export namespace container_v1beta1 { */ message?: string; } + /** + * TierConfig is the configuration for a tier offering. For example the GKE standard or advanced offerings which contain different levels of functionality and possibly cost. + */ + export interface Schema$TierConfig { + /** + * The tier from which the tier being configured inherits. The configured tier will inherit all the features from its parent tier. + */ + parent?: string; + /** + * The tier that is being configured with this value. + */ + tier?: string; + } /** * Cluster tier settings. */ diff --git a/src/apis/containeranalysis/v1alpha1.ts b/src/apis/containeranalysis/v1alpha1.ts index 27789df5d9e..cf2fc422980 100644 --- a/src/apis/containeranalysis/v1alpha1.ts +++ b/src/apis/containeranalysis/v1alpha1.ts @@ -161,32 +161,6 @@ export namespace containeranalysis_v1alpha1 { */ humanReadableName?: string; } - /** - * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "fooservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:bar@gmail.com" ] } ] } ] } For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts foo@gmail.com from DATA_READ logging, and bar@gmail.com from DATA_WRITE logging. - */ - export interface Schema$AuditConfig { - /** - * The configuration for logging of each type of permission. - */ - auditLogConfigs?: Schema$AuditLogConfig[]; - /** - * Specifies a service that will be enabled for audit logging. For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. `allServices` is a special value that covers all services. - */ - service?: string; - } - /** - * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting foo@gmail.com from DATA_READ logging. - */ - export interface Schema$AuditLogConfig { - /** - * Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members. - */ - exemptedMembers?: string[]; - /** - * The log type that this config enables. - */ - logType?: string; - } /** * Basis describes the base image portion (Note) of the DockerImage relationship. Linked occurrences are derived from this or an equivalent image via: FROM <Basis.resource_url> Or an equivalent reference, e.g. a tag of the resource_url. */ @@ -209,7 +183,7 @@ export namespace containeranalysis_v1alpha1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -591,7 +565,7 @@ export namespace containeranalysis_v1alpha1 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ requestedPolicyVersion?: number; } @@ -877,7 +851,7 @@ export namespace containeranalysis_v1alpha1 { */ longDescription?: string; /** - * The name of the note in the form "providers/{provider_id}/notes/{NOTE_ID}" + * The name of the note in the form "projects/{provider_project_id}/notes/{NOTE_ID}" */ name?: string; /** @@ -896,6 +870,10 @@ export namespace containeranalysis_v1alpha1 { * Output only. The time this note was last updated. This field can be used as a filter in list requests. */ updateTime?: string; + /** + * A note describing an upgrade. + */ + upgrade?: Schema$UpgradeNote; /** * A package vulnerability type of note. */ @@ -961,6 +939,10 @@ export namespace containeranalysis_v1alpha1 { * Output only. The time this `Occurrence` was last updated. */ updateTime?: string; + /** + * Describes an upgrade. + */ + upgrade?: Schema$UpgradeOccurrence; /** * Details of a security vulnerability note. */ @@ -1039,16 +1021,12 @@ export namespace containeranalysis_v1alpha1 { * Defines an Identity and Access Management (IAM) policy. It is used to specify access control policies for Cloud Platform resources. A `Policy` consists of a list of `bindings`. A `binding` binds a list of `members` to a `role`, where the members can be user accounts, Google groups, Google domains, and service accounts. A `role` is a named list of permissions defined by IAM. **JSON Example** { "bindings": [ { "role": "roles/owner", "members": [ "user:mike@example.com", "group:admins@example.com", "domain:google.com", "serviceAccount:my-other-app@appspot.gserviceaccount.com" ] }, { "role": "roles/viewer", "members": ["user:sean@example.com"] } ] } **YAML Example** bindings: - members: - user:mike@example.com - group:admins@example.com - domain:google.com - serviceAccount:my-other-app@appspot.gserviceaccount.com role: roles/owner - members: - user:sean@example.com role: roles/viewer For a description of IAM and its features, see the [IAM developer's guide](https://cloud.google.com/iam/docs). */ export interface Schema$Policy { - /** - * Specifies cloud audit logging configuration for this policy. - */ - auditConfigs?: Schema$AuditConfig[]; /** * Associates a list of `members` to a `role`. `bindings` with no members will result in an error. */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** @@ -1144,10 +1122,6 @@ export namespace containeranalysis_v1alpha1 { * REQUIRED: The complete policy to be applied to the `resource`. The size of the policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud Platform services (such as Projects) might reject them. */ policy?: Schema$Policy; - /** - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only the fields in the mask will be modified. If no mask is provided, the following default mask is used: paths: "bindings, etag" This field is only used by Cloud IAM. - */ - updateMask?: string; } /** * The number of occurrences created for a specific severity. @@ -1256,6 +1230,61 @@ export namespace containeranalysis_v1alpha1 { */ updateMask?: string; } + /** + * The Upgrade Distribution represents metadata about the Upgrade for each operating system (CPE). Some distributions have additional metadata around updates, classifying them into various categories and severities. + */ + export interface Schema$UpgradeDistribution { + /** + * The operating system classification of this Upgrade, as specified by the upstream operating system upgrade feed. + */ + classification?: string; + /** + * Required - The specific operating system this metadata applies to. See https://cpe.mitre.org/specification/. + */ + cpeUri?: string; + /** + * The cve that would be resolved by this upgrade. + */ + cve?: string[]; + /** + * The severity as specified by the upstream operating system. + */ + severity?: string; + } + /** + * An Upgrade Note represents a potential upgrade of a package to a given version. For each package version combination (i.e. bash 4.0, bash 4.1, bash 4.1.2), there will be a Upgrade Note. + */ + export interface Schema$UpgradeNote { + /** + * Metadata about the upgrade for each specific operating system. + */ + distributions?: Schema$UpgradeDistribution[]; + /** + * Required - The package this Upgrade is for. + */ + package?: string; + /** + * Required - The version of the package in machine + human readable form. + */ + version?: Schema$Version; + } + /** + * An Upgrade Occurrence represents that a specific resource_url could install a specific upgrade. This presence is supplied via local sources (i.e. it is present in the mirror and the running system has noticed its availability). + */ + export interface Schema$UpgradeOccurrence { + /** + * Metadata about the upgrade for available for the specific operating system for the resource_url. This allows efficient filtering, as well as making it easier to use the occurrence. + */ + distribution?: Schema$UpgradeDistribution; + /** + * Required - The package this Upgrade is for. + */ + package?: string; + /** + * Required - The version of the package in a machine + human readable form. + */ + parsedVersion?: Schema$Version; + } /** * Version contains structured information about the version of the package. For a discussion of this in Debian/Ubuntu: http://serverfault.com/questions/604541/debian-packages-version-convention For a discussion of this in Redhat/Fedora/Centos: http://blog.jasonantman.com/2014/07/how-yum-and-rpm-compare-versions/ */ diff --git a/src/apis/containeranalysis/v1beta1.ts b/src/apis/containeranalysis/v1beta1.ts index ab7e7400a7d..c3a822bf68b 100644 --- a/src/apis/containeranalysis/v1beta1.ts +++ b/src/apis/containeranalysis/v1beta1.ts @@ -157,32 +157,6 @@ export namespace containeranalysis_v1beta1 { */ pgpSignedAttestation?: Schema$PgpSignedAttestation; } - /** - * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "fooservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:bar@gmail.com" ] } ] } ] } For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts foo@gmail.com from DATA_READ logging, and bar@gmail.com from DATA_WRITE logging. - */ - export interface Schema$AuditConfig { - /** - * The configuration for logging of each type of permission. - */ - auditLogConfigs?: Schema$AuditLogConfig[]; - /** - * Specifies a service that will be enabled for audit logging. For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. `allServices` is a special value that covers all services. - */ - service?: string; - } - /** - * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting foo@gmail.com from DATA_READ logging. - */ - export interface Schema$AuditLogConfig { - /** - * Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members. - */ - exemptedMembers?: string[]; - /** - * The log type that this config enables. - */ - logType?: string; - } /** * Note kind that represents a logical attestation "role" or "authority". For example, an organization might have one `Authority` for "QA" and one for "build". This note is intended to act strictly as a grouping mechanism for the attached occurrences (Attestations). This grouping mechanism also provides a security boundary, since IAM ACLs gate the ability for a principle to attach an occurrence to a given note. It also provides a single point of lookup to find all attached attestation occurrences, even if they don't all live in the same project. */ @@ -250,7 +224,7 @@ export namespace containeranalysis_v1beta1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -520,6 +494,10 @@ export namespace containeranalysis_v1beta1 { * The severity (eg: distro assigned severity) for this vulnerability. */ severityName?: string; + /** + * The time this information was last changed at the source. This is an upstream timestamp from the underlying information source - e.g. Ubuntu security tracker. + */ + sourceUpdateTime?: string; } /** * Details of an attestation occurrence. @@ -713,7 +691,7 @@ export namespace containeranalysis_v1beta1 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ requestedPolicyVersion?: number; } @@ -1137,16 +1115,12 @@ export namespace containeranalysis_v1beta1 { * Defines an Identity and Access Management (IAM) policy. It is used to specify access control policies for Cloud Platform resources. A `Policy` consists of a list of `bindings`. A `binding` binds a list of `members` to a `role`, where the members can be user accounts, Google groups, Google domains, and service accounts. A `role` is a named list of permissions defined by IAM. **JSON Example** { "bindings": [ { "role": "roles/owner", "members": [ "user:mike@example.com", "group:admins@example.com", "domain:google.com", "serviceAccount:my-other-app@appspot.gserviceaccount.com" ] }, { "role": "roles/viewer", "members": ["user:sean@example.com"] } ] } **YAML Example** bindings: - members: - user:mike@example.com - group:admins@example.com - domain:google.com - serviceAccount:my-other-app@appspot.gserviceaccount.com role: roles/owner - members: - user:sean@example.com role: roles/viewer For a description of IAM and its features, see the [IAM developer's guide](https://cloud.google.com/iam/docs). */ export interface Schema$Policy { - /** - * Specifies cloud audit logging configuration for this policy. - */ - auditConfigs?: Schema$AuditConfig[]; /** * Associates a list of `members` to a `role`. `bindings` with no members will result in an error. */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** @@ -1243,10 +1217,6 @@ export namespace containeranalysis_v1beta1 { * REQUIRED: The complete policy to be applied to the `resource`. The size of the policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud Platform services (such as Projects) might reject them. */ policy?: Schema$Policy; - /** - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only the fields in the mask will be modified. If no mask is provided, the following default mask is used: paths: "bindings, etag" This field is only used by Cloud IAM. - */ - updateMask?: string; } /** * Verifiers (e.g. Kritis implementations) MUST verify signatures with respect to the trust anchors defined in policy (e.g. a Kritis policy). Typically this means that the verifier has been configured with a map from `public_key_id` to public key material (and any required parameters, e.g. signing algorithm). In particular, verification implementations MUST NOT treat the signature `public_key_id` as anything more than a key lookup hint. The `public_key_id` DOES NOT validate or authenticate a public key; it only provides a mechanism for quickly selecting a public key ALREADY CONFIGURED on the verifier through a trusted channel. Verification implementations MUST reject signatures in any of the following circumstances: * The `public_key_id` is not recognized by the verifier. * The public key that `public_key_id` refers to does not verify the signature with respect to the payload. The `signature` contents SHOULD NOT be "attached" (where the payload is included with the serialized `signature` bytes). Verifiers MUST ignore any "attached" payload and only verify signatures with respect to explicitly provided payload (e.g. a `payload` field on the proto message that holds this Signature, or the canonical serialization of the proto message that holds this signature). @@ -1379,6 +1349,10 @@ export namespace containeranalysis_v1beta1 { * Note provider assigned impact of the vulnerability. */ severity?: string; + /** + * The time this information was last changed at the source. This is an upstream timestamp from the underlying information source - e.g. Ubuntu security tracker. + */ + sourceUpdateTime?: string; /** * Windows details get their own format because the information format and model don't match a normal detail. Specifically Windows updates are done as patches, thus Windows vulnerabilities really are a missing package, rather than a package being at an incorrect version. */ diff --git a/src/apis/content/v2.1.ts b/src/apis/content/v2.1.ts index 599919f751e..b748da1cb90 100644 --- a/src/apis/content/v2.1.ts +++ b/src/apis/content/v2.1.ts @@ -103,6 +103,8 @@ export namespace content_v2_1 { products: Resource$Products; productstatuses: Resource$Productstatuses; regionalinventory: Resource$Regionalinventory; + returnaddress: Resource$Returnaddress; + returnpolicy: Resource$Returnpolicy; shippingsettings: Resource$Shippingsettings; constructor(options: GlobalOptions, google?: GoogleConfigurable) { @@ -125,6 +127,8 @@ export namespace content_v2_1 { this.products = new Resource$Products(this.context); this.productstatuses = new Resource$Productstatuses(this.context); this.regionalinventory = new Resource$Regionalinventory(this.context); + this.returnaddress = new Resource$Returnaddress(this.context); + this.returnpolicy = new Resource$Returnpolicy(this.context); this.shippingsettings = new Resource$Shippingsettings(this.context); } } @@ -1154,7 +1158,7 @@ export namespace content_v2_1 { */ excludedDestinations?: string[]; /** - * The list of destinations to include for this target (corresponds to checked check boxes in Merchant Center). Default destinations are always included unless provided in the excluded_destination field. + * The list of destinations to include for this target (corresponds to checked check boxes in Merchant Center). Default destinations are always included unless provided in excludedDestinations. */ includedDestinations?: string[]; /** @@ -1657,7 +1661,7 @@ export namespace content_v2_1 { */ customer?: Schema$OrderCustomer; /** - * Delivery details for shipments. + * Delivery details for shipments of type delivery. */ deliveryDetails?: Schema$OrderDeliveryDetails; /** @@ -1783,11 +1787,29 @@ export namespace content_v2_1 { * Full name of the customer. */ fullName?: string; + /** + * Email address for receiving merchant issued value-added tax or invoice documentation of this order. + */ + invoiceReceivingEmail?: string; + /** + * Loyalty program information. + */ + loyaltyInfo?: Schema$OrderCustomerLoyaltyInfo; /** * Customer's marketing preferences. Contains the marketing opt-in information that is current at the time that the merchant call. User preference selections can change from one order to the next so preferences must be checked with every order. */ marketingRightsInfo?: Schema$OrderCustomerMarketingRightsInfo; } + export interface Schema$OrderCustomerLoyaltyInfo { + /** + * The loyalty card/membership number. + */ + loyaltyNumber?: string; + /** + * Name of card/membership holder, this field will be populated when + */ + name?: string; + } export interface Schema$OrderCustomerMarketingRightsInfo { /** * Last known customer selection regarding marketing preferences. In certain cases this selection might not be known, so this field would be empty. If a customer selected granted in their most recent order, they can be subscribed to marketing emails. Customers who have chosen denied must not be subscribed, or must be unsubscribed if already opted-in. @@ -1945,6 +1967,10 @@ export namespace content_v2_1 { * Number of items shipped. */ quantityShipped?: number; + /** + * Number of items undeliverable. + */ + quantityUndeliverable?: number; /** * Details of the return policy for the line item. */ @@ -2490,7 +2516,7 @@ export namespace content_v2_1 { } export interface Schema$OrderShipment { /** - * The carrier handling the shipment. Acceptable values for US are: - "gsx" - "ups" - "usps" - "fedex" - "dhl" - "ecourier" - "cxt" - "google" - "ontrac" - "emsy" - "ont" - "deliv" - "dynamex" - "lasership" - "mpx" - "uds" - "efw" Acceptable values for FR are: - "colissimo" - "chronopost" - "gls" - "dpd" - "bpost" + * The carrier handling the shipment. Acceptable values for US are: - "gsx" - "ups" - "usps" - "fedex" - "dhl" - "ecourier" - "cxt" - "google" - "ontrac" - "emsy" - "ont" - "deliv" - "dynamex" - "lasership" - "mpx" - "uds" - "efw" Acceptable values for FR are: - "colissimo" - "chronopost" - "gls" - "dpd" - "bpost" - "colis prive" - "boxtal" - "geodis" */ carrier?: string; /** @@ -2509,6 +2535,10 @@ export namespace content_v2_1 { * The line items that are shipped. */ lineItems?: Schema$OrderShipmentLineItemShipment[]; + /** + * The shipment group ID of the shipment. This is set in shiplineitems request. + */ + shipmentGroupId?: string; /** * The status of the shipment. */ @@ -3346,7 +3376,7 @@ export namespace content_v2_1 { */ imageLink?: string; /** - * The list of destinations to include for this target (corresponds to checked check boxes in Merchant Center). Default destinations are always included unless provided in the excluded_destination field. + * The list of destinations to include for this target (corresponds to checked check boxes in Merchant Center). Default destinations are always included unless provided in excludedDestinations. */ includedDestinations?: string[]; /** @@ -3965,6 +3995,254 @@ export namespace content_v2_1 { */ regionalInventory?: Schema$RegionalInventory; } + /** + * Return address resource. + */ + export interface Schema$ReturnAddress { + /** + * The address. + */ + address?: Schema$ReturnAddressAddress; + /** + * The country of sale where the return address is applicable. + */ + country?: string; + /** + * Identifies what kind of resource this is. Value: the fixed string "content#returnAddress". + */ + kind?: string; + /** + * The user-defined label of the return address. For the default address, use the label "default". + */ + label?: string; + /** + * The merchant's contact phone number regarding the return. + */ + phoneNumber?: string; + /** + * Return address ID generated by Google. + */ + returnAddressId?: string; + } + export interface Schema$ReturnAddressAddress { + /** + * CLDR country code (e.g. "US"). + */ + country?: string; + /** + * City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs). + */ + locality?: string; + /** + * Postal code or ZIP (e.g. "94043"). + */ + postalCode?: string; + /** + * Name of the recipient to address returns to. + */ + recipientName?: string; + /** + * Top-level administrative subdivision of the country. For example, a state like California ("CA") or a province like Quebec ("QC"). + */ + region?: string; + /** + * Street-level part of the address. May be up to two lines, each line specified as an array element. + */ + streetAddress?: string[]; + } + export interface Schema$ReturnaddressCustomBatchRequest { + /** + * The request entries to be processed in the batch. + */ + entries?: Schema$ReturnaddressCustomBatchRequestEntry[]; + } + export interface Schema$ReturnaddressCustomBatchRequestEntry { + /** + * An entry ID, unique within the batch request. + */ + batchId?: number; + /** + * The Merchant Center account ID. + */ + merchantId?: string; + method?: string; + /** + * The return address to submit. Set this only if the method is insert. + */ + returnAddress?: Schema$ReturnAddress; + /** + * The return address ID. Set this only if the method is delete or get. + */ + returnAddressId?: string; + } + export interface Schema$ReturnaddressCustomBatchResponse { + /** + * The result of the execution of the batch requests. + */ + entries?: Schema$ReturnaddressCustomBatchResponseEntry[]; + /** + * Identifies what kind of resource this is. Value: the fixed string "content#returnaddressCustomBatchResponse". + */ + kind?: string; + } + export interface Schema$ReturnaddressCustomBatchResponseEntry { + /** + * The ID of the request entry to which this entry responds. + */ + batchId?: number; + /** + * A list of errors defined if, and only if, the request failed. + */ + errors?: Schema$Errors; + /** + * Identifies what kind of resource this is. Value: the fixed string "content#returnaddressCustomBatchResponseEntry". + */ + kind?: string; + /** + * The retrieved return address. + */ + returnAddress?: Schema$ReturnAddress; + } + export interface Schema$ReturnaddressListResponse { + /** + * Identifies what kind of resource this is. Value: the fixed string "content#returnaddressListResponse". + */ + kind?: string; + /** + * The token for the retrieval of the next page of addresses. + */ + nextPageToken?: string; + resources?: Schema$ReturnAddress[]; + } + /** + * Return policy resource. + */ + export interface Schema$ReturnPolicy { + /** + * The country of sale where the return policy is applicable. + */ + country?: string; + /** + * Identifies what kind of resource this is. Value: the fixed string "content#returnPolicy". + */ + kind?: string; + /** + * The user-defined label of the return policy. For the default policy, use the label "default". + */ + label?: string; + /** + * The name of the policy as shown in Merchant Center. + */ + name?: string; + /** + * Return reasons that will incur return fees. + */ + nonFreeReturnReasons?: string[]; + /** + * The policy. + */ + policy?: Schema$ReturnPolicyPolicy; + /** + * Return policy ID generated by Google. + */ + returnPolicyId?: string; + /** + * An optional list of seasonal overrides. + */ + seasonalOverrides?: Schema$ReturnPolicySeasonalOverride[]; + } + export interface Schema$ReturnpolicyCustomBatchRequest { + /** + * The request entries to be processed in the batch. + */ + entries?: Schema$ReturnpolicyCustomBatchRequestEntry[]; + } + export interface Schema$ReturnpolicyCustomBatchRequestEntry { + /** + * An entry ID, unique within the batch request. + */ + batchId?: number; + /** + * The Merchant Center account ID. + */ + merchantId?: string; + method?: string; + /** + * The return policy to submit. Set this only if the method is insert. + */ + returnPolicy?: Schema$ReturnPolicy; + /** + * The return policy ID. Set this only if the method is delete or get. + */ + returnPolicyId?: string; + } + export interface Schema$ReturnpolicyCustomBatchResponse { + /** + * The result of the execution of the batch requests. + */ + entries?: Schema$ReturnpolicyCustomBatchResponseEntry[]; + /** + * Identifies what kind of resource this is. Value: the fixed string "content#returnpolicyCustomBatchResponse". + */ + kind?: string; + } + export interface Schema$ReturnpolicyCustomBatchResponseEntry { + /** + * The ID of the request entry to which this entry responds. + */ + batchId?: number; + /** + * A list of errors defined if, and only if, the request failed. + */ + errors?: Schema$Errors; + /** + * Identifies what kind of resource this is. Value: the fixed string "content#returnpolicyCustomBatchResponseEntry". + */ + kind?: string; + /** + * The retrieved return policy. + */ + returnPolicy?: Schema$ReturnPolicy; + } + export interface Schema$ReturnpolicyListResponse { + /** + * Identifies what kind of resource this is. Value: the fixed string "content#returnpolicyListResponse". + */ + kind?: string; + resources?: Schema$ReturnPolicy[]; + } + export interface Schema$ReturnPolicyPolicy { + /** + * Last day for returning the items. In ISO 8601 format. When specifying the return window like this, set the policy type to "lastReturnDate". Use this for seasonal overrides only. + */ + lastReturnDate?: string; + /** + * The number of days items can be returned after delivery, where one day is defined to be 24 hours after the delivery timestamp. When specifying the return window like this, set the policy type to "numberOfDaysAfterDelivery". Acceptable values are 30, 45, 60, 90, 100, 180, 270 and 365 for the default policy. Additional policies further allow 14, 15, 21 and 28 days, but note that for most items a minimum of 30 days is required for returns. Exceptions may be made for electronics. A policy of less than 30 days can only be applied to those items. + */ + numberOfDays?: string; + /** + * Policy type. Use "lastReturnDate" for seasonal overrides only. Note that for most items a minimum of 30 days is required for returns. Exceptions may be made for electronics or non-returnable items such as food, perishables, and living things. A policy of less than 30 days can only be applied to those items. + */ + type?: string; + } + export interface Schema$ReturnPolicySeasonalOverride { + /** + * Last day on which the override applies. In ISO 8601 format. + */ + endDate?: string; + /** + * The name of the seasonal override as shown in Merchant Center. + */ + name?: string; + /** + * The policy which is in effect during that time. + */ + policy?: Schema$ReturnPolicyPolicy; + /** + * First day on which the override applies. In ISO 8601 format. + */ + startDate?: string; + } export interface Schema$ReturnShipment { creationDate?: string; deliveryDate?: string; @@ -4209,7 +4487,7 @@ export namespace content_v2_1 { */ promotions?: Schema$OrderPromotion[]; /** - * The price of shipping for all items. Shipping tax is automatically calculated for MFL orders. For non-MFL orders, tax settings from Merchant Center are applied. Note that shipping is not taxed in certain states. + * The price of shipping for all items. Shipping tax is automatically calculated for orders where marketplace facilitator tax laws are applicable. Otherwise, tax settings from Merchant Center are applied. Note that shipping is not taxed in certain states. */ shippingCost?: Schema$Price; /** @@ -4273,7 +4551,7 @@ export namespace content_v2_1 { */ offerId?: string; /** - * The price for the product. Tax is automatically calculated for MFL orders. For non-MFL orders, tax settings from Merchant Center are applied. + * The price for the product. Tax is automatically calculated for orders where marketplace facilitator tax laws are applicable. Otherwise, tax settings from Merchant Center are applied. */ price?: Schema$Price; /** @@ -9504,7 +9782,7 @@ export namespace content_v2_1 { /** * content.orders.instorerefundlineitem - * @desc Notifies that item return and refund was handled directly by merchant outside of Google payments processing (e.g. cash refund done in store). Note: We recommend calling the returnrefundlineitem method to refund in-store returns. We will issue the refund directly to the customer. This helps to prevent possible differences arising between merchant and Google transaction records. We also recommend having the point of sale system communicate with Google to ensure that customers do not receive a double refund by first refunding via Google then via an in-store return. + * @desc Deprecated. Notifies that item return and refund was handled directly by merchant outside of Google payments processing (e.g. cash refund done in store). Note: We recommend calling the returnrefundlineitem method to refund in-store returns. We will issue the refund directly to the customer. This helps to prevent possible differences arising between merchant and Google transaction records. We also recommend having the point of sale system communicate with Google to ensure that customers do not receive a double refund by first refunding via Google then via an in-store return. * @alias content.orders.instorerefundlineitem * @memberOf! () * @@ -12312,6 +12590,950 @@ export namespace content_v2_1 { requestBody?: Schema$RegionalInventory; } + export class Resource$Returnaddress { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * content.returnaddress.custombatch + * @desc Batches multiple return address related calls in a single request. + * @alias content.returnaddress.custombatch + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().ReturnaddressCustomBatchRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + custombatch( + params?: Params$Resource$Returnaddress$Custombatch, + options?: MethodOptions + ): GaxiosPromise; + custombatch( + params: Params$Resource$Returnaddress$Custombatch, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + custombatch( + params: Params$Resource$Returnaddress$Custombatch, + callback: BodyResponseCallback + ): void; + custombatch( + callback: BodyResponseCallback + ): void; + custombatch( + paramsOrCallback?: + | Params$Resource$Returnaddress$Custombatch + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Returnaddress$Custombatch; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Returnaddress$Custombatch; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/content/v2.1/returnaddress/batch').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest( + parameters + ); + } + } + + /** + * content.returnaddress.delete + * @desc Deletes a return address for the given Merchant Center account. + * @alias content.returnaddress.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.merchantId The Merchant Center account from which to delete the given return address. + * @param {string} params.returnAddressId Return address ID generated by Google. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + delete( + params?: Params$Resource$Returnaddress$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Returnaddress$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Returnaddress$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Returnaddress$Delete + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Returnaddress$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Returnaddress$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/content/v2.1/{merchantId}/returnaddress/{returnAddressId}' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['merchantId', 'returnAddressId'], + pathParams: ['merchantId', 'returnAddressId'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * content.returnaddress.get + * @desc Gets a return address of the Merchant Center account. + * @alias content.returnaddress.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.merchantId The Merchant Center account to get a return address for. + * @param {string} params.returnAddressId Return address ID generated by Google. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Returnaddress$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Returnaddress$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Returnaddress$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Returnaddress$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Returnaddress$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Returnaddress$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/content/v2.1/{merchantId}/returnaddress/{returnAddressId}' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['merchantId', 'returnAddressId'], + pathParams: ['merchantId', 'returnAddressId'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * content.returnaddress.insert + * @desc Inserts a return address for the Merchant Center account. + * @alias content.returnaddress.insert + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.merchantId The Merchant Center account to insert a return address for. + * @param {().ReturnAddress} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + insert( + params?: Params$Resource$Returnaddress$Insert, + options?: MethodOptions + ): GaxiosPromise; + insert( + params: Params$Resource$Returnaddress$Insert, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + insert( + params: Params$Resource$Returnaddress$Insert, + callback: BodyResponseCallback + ): void; + insert(callback: BodyResponseCallback): void; + insert( + paramsOrCallback?: + | Params$Resource$Returnaddress$Insert + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Returnaddress$Insert; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Returnaddress$Insert; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/content/v2.1/{merchantId}/returnaddress').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['merchantId'], + pathParams: ['merchantId'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * content.returnaddress.list + * @desc Lists the return addresses of the Merchant Center account. + * @alias content.returnaddress.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.country List only return addresses applicable to the given country of sale. When omitted, all return addresses are listed. + * @param {integer=} params.maxResults The maximum number of addresses in the response, used for paging. + * @param {string} params.merchantId The Merchant Center account to list return addresses for. + * @param {string=} params.pageToken The token returned by the previous request. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Returnaddress$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Returnaddress$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Returnaddress$List, + callback: BodyResponseCallback + ): void; + list( + callback: BodyResponseCallback + ): void; + list( + paramsOrCallback?: + | Params$Resource$Returnaddress$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Returnaddress$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Returnaddress$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/content/v2.1/{merchantId}/returnaddress').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['merchantId'], + pathParams: ['merchantId'], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Returnaddress$Custombatch + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Request body metadata + */ + requestBody?: Schema$ReturnaddressCustomBatchRequest; + } + export interface Params$Resource$Returnaddress$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The Merchant Center account from which to delete the given return address. + */ + merchantId?: string; + /** + * Return address ID generated by Google. + */ + returnAddressId?: string; + } + export interface Params$Resource$Returnaddress$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The Merchant Center account to get a return address for. + */ + merchantId?: string; + /** + * Return address ID generated by Google. + */ + returnAddressId?: string; + } + export interface Params$Resource$Returnaddress$Insert + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The Merchant Center account to insert a return address for. + */ + merchantId?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$ReturnAddress; + } + export interface Params$Resource$Returnaddress$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * List only return addresses applicable to the given country of sale. When omitted, all return addresses are listed. + */ + country?: string; + /** + * The maximum number of addresses in the response, used for paging. + */ + maxResults?: number; + /** + * The Merchant Center account to list return addresses for. + */ + merchantId?: string; + /** + * The token returned by the previous request. + */ + pageToken?: string; + } + + export class Resource$Returnpolicy { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * content.returnpolicy.custombatch + * @desc Batches multiple return policy related calls in a single request. + * @alias content.returnpolicy.custombatch + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().ReturnpolicyCustomBatchRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + custombatch( + params?: Params$Resource$Returnpolicy$Custombatch, + options?: MethodOptions + ): GaxiosPromise; + custombatch( + params: Params$Resource$Returnpolicy$Custombatch, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + custombatch( + params: Params$Resource$Returnpolicy$Custombatch, + callback: BodyResponseCallback + ): void; + custombatch( + callback: BodyResponseCallback + ): void; + custombatch( + paramsOrCallback?: + | Params$Resource$Returnpolicy$Custombatch + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Returnpolicy$Custombatch; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Returnpolicy$Custombatch; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/content/v2.1/returnpolicy/batch').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest( + parameters + ); + } + } + + /** + * content.returnpolicy.delete + * @desc Deletes a return policy for the given Merchant Center account. + * @alias content.returnpolicy.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.merchantId The Merchant Center account from which to delete the given return policy. + * @param {string} params.returnPolicyId Return policy ID generated by Google. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + delete( + params?: Params$Resource$Returnpolicy$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Returnpolicy$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Returnpolicy$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Returnpolicy$Delete + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Returnpolicy$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Returnpolicy$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/content/v2.1/{merchantId}/returnpolicy/{returnPolicyId}' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['merchantId', 'returnPolicyId'], + pathParams: ['merchantId', 'returnPolicyId'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * content.returnpolicy.get + * @desc Gets a return policy of the Merchant Center account. + * @alias content.returnpolicy.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.merchantId The Merchant Center account to get a return policy for. + * @param {string} params.returnPolicyId Return policy ID generated by Google. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Returnpolicy$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Returnpolicy$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Returnpolicy$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Returnpolicy$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Returnpolicy$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Returnpolicy$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + + '/content/v2.1/{merchantId}/returnpolicy/{returnPolicyId}' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['merchantId', 'returnPolicyId'], + pathParams: ['merchantId', 'returnPolicyId'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * content.returnpolicy.insert + * @desc Inserts a return policy for the Merchant Center account. + * @alias content.returnpolicy.insert + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.merchantId The Merchant Center account to insert a return policy for. + * @param {().ReturnPolicy} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + insert( + params?: Params$Resource$Returnpolicy$Insert, + options?: MethodOptions + ): GaxiosPromise; + insert( + params: Params$Resource$Returnpolicy$Insert, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + insert( + params: Params$Resource$Returnpolicy$Insert, + callback: BodyResponseCallback + ): void; + insert(callback: BodyResponseCallback): void; + insert( + paramsOrCallback?: + | Params$Resource$Returnpolicy$Insert + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Returnpolicy$Insert; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Returnpolicy$Insert; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/content/v2.1/{merchantId}/returnpolicy').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['merchantId'], + pathParams: ['merchantId'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * content.returnpolicy.list + * @desc Lists the return policies of the Merchant Center account. + * @alias content.returnpolicy.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.merchantId The Merchant Center account to list return policies for. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Returnpolicy$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Returnpolicy$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Returnpolicy$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Returnpolicy$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Returnpolicy$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Returnpolicy$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/content/v2.1/{merchantId}/returnpolicy').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['merchantId'], + pathParams: ['merchantId'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Returnpolicy$Custombatch + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Request body metadata + */ + requestBody?: Schema$ReturnpolicyCustomBatchRequest; + } + export interface Params$Resource$Returnpolicy$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The Merchant Center account from which to delete the given return policy. + */ + merchantId?: string; + /** + * Return policy ID generated by Google. + */ + returnPolicyId?: string; + } + export interface Params$Resource$Returnpolicy$Get extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The Merchant Center account to get a return policy for. + */ + merchantId?: string; + /** + * Return policy ID generated by Google. + */ + returnPolicyId?: string; + } + export interface Params$Resource$Returnpolicy$Insert + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The Merchant Center account to insert a return policy for. + */ + merchantId?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$ReturnPolicy; + } + export interface Params$Resource$Returnpolicy$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The Merchant Center account to list return policies for. + */ + merchantId?: string; + } + export class Resource$Shippingsettings { context: APIRequestContext; constructor(context: APIRequestContext) { diff --git a/src/apis/content/v2.ts b/src/apis/content/v2.ts index af79a8f7984..e9fbc9740a9 100644 --- a/src/apis/content/v2.ts +++ b/src/apis/content/v2.ts @@ -1214,7 +1214,7 @@ export namespace content_v2 { */ excludedDestinations?: string[]; /** - * The list of destinations to include for this target (corresponds to checked check boxes in Merchant Center). Default destinations are always included unless provided in the excluded_destination field. + * The list of destinations to include for this target (corresponds to checked check boxes in Merchant Center). Default destinations are always included unless provided in excludedDestinations. */ includedDestinations?: string[]; /** @@ -1935,7 +1935,7 @@ export namespace content_v2 { */ customer?: Schema$OrderCustomer; /** - * Delivery details for shipments. + * Delivery details for shipments of type delivery. */ deliveryDetails?: Schema$OrderDeliveryDetails; /** @@ -2073,6 +2073,10 @@ export namespace content_v2 { * Full name of the customer. */ fullName?: string; + /** + * Email address for receiving merchant issued value-added tax or invoice documentation of this order. + */ + invoiceReceivingEmail?: string; /** * Customer's marketing preferences. Contains the marketing opt-in information that is current at the time that the merchant call. User preference selections can change from one order to the next so preferences must be checked with every order. */ @@ -3246,7 +3250,7 @@ export namespace content_v2 { } export interface Schema$OrderShipment { /** - * The carrier handling the shipment. Acceptable values for US are: - "gsx" - "ups" - "usps" - "fedex" - "dhl" - "ecourier" - "cxt" - "google" - "ontrac" - "emsy" - "ont" - "deliv" - "dynamex" - "lasership" - "mpx" - "uds" - "efw" Acceptable values for FR are: - "colissimo" - "chronopost" - "gls" - "dpd" - "bpost" + * The carrier handling the shipment. Acceptable values for US are: - "gsx" - "ups" - "usps" - "fedex" - "dhl" - "ecourier" - "cxt" - "google" - "ontrac" - "emsy" - "ont" - "deliv" - "dynamex" - "lasership" - "mpx" - "uds" - "efw" Acceptable values for FR are: - "colissimo" - "chronopost" - "gls" - "dpd" - "bpost" - "colis prive" - "boxtal" - "geodis" */ carrier?: string; /** @@ -5029,7 +5033,7 @@ export namespace content_v2 { */ promotions?: Schema$OrderLegacyPromotion[]; /** - * The price of shipping for all items. Shipping tax is automatically calculated for MFL orders. For non-MFL orders, tax settings from Merchant Center are applied. Note that shipping is not taxed in certain states. + * The price of shipping for all items. Shipping tax is automatically calculated for orders where marketplace facilitator tax laws are applicable. Otherwise, tax settings from Merchant Center are applied. Note that shipping is not taxed in certain states. */ shippingCost?: Schema$Price; /** @@ -5133,7 +5137,7 @@ export namespace content_v2 { */ offerId?: string; /** - * The price for the product. Tax is automatically calculated for MFL orders. For non-MFL orders, tax settings from Merchant Center are applied. + * The price for the product. Tax is automatically calculated for orders where marketplace facilitator tax laws are applicable. Otherwise, tax settings from Merchant Center are applied. */ price?: Schema$Price; /** @@ -11601,7 +11605,7 @@ export namespace content_v2 { /** * content.orders.instorerefundlineitem - * @desc Notifies that item return and refund was handled directly by merchant outside of Google payments processing (e.g. cash refund done in store). Note: We recommend calling the returnrefundlineitem method to refund in-store returns. We will issue the refund directly to the customer. This helps to prevent possible differences arising between merchant and Google transaction records. We also recommend having the point of sale system communicate with Google to ensure that customers do not receive a double refund by first refunding via Google then via an in-store return. + * @desc Deprecated. Notifies that item return and refund was handled directly by merchant outside of Google payments processing (e.g. cash refund done in store). Note: We recommend calling the returnrefundlineitem method to refund in-store returns. We will issue the refund directly to the customer. This helps to prevent possible differences arising between merchant and Google transaction records. We also recommend having the point of sale system communicate with Google to ensure that customers do not receive a double refund by first refunding via Google then via an in-store return. * @alias content.orders.instorerefundlineitem * @memberOf! () * diff --git a/src/apis/dataflow/v1b3.ts b/src/apis/dataflow/v1b3.ts index 5bd1237da7a..023894eb818 100644 --- a/src/apis/dataflow/v1b3.ts +++ b/src/apis/dataflow/v1b3.ts @@ -549,10 +549,6 @@ export namespace dataflow_v1b3 { */ projectId?: string; } - /** - * Response from deleting a snapshot. - */ - export interface Schema$DeleteSnapshotResponse {} /** * Specification of one of the bundles produced as a result of splitting a Source (e.g. when executing a SourceSplitRequest, or when splitting an active task using WorkItemStatus.dynamic_source_split), relative to the source being split. */ @@ -1318,15 +1314,6 @@ export namespace dataflow_v1b3 { */ nextPageToken?: string; } - /** - * List of snapshots. - */ - export interface Schema$ListSnapshotsResponse { - /** - * Returned snapshots. - */ - snapshots?: Schema$Snapshot[]; - } /** * MapTask consists of an ordered set of instructions, each of which describes one particular low-level operation for the worker to perform in order to accomplish the MapTask's WorkItem. Each instruction must appear in the list before any instructions which depends on its output. */ @@ -1971,48 +1958,6 @@ export namespace dataflow_v1b3 { */ spec?: {[key: string]: any}; } - /** - * Represents a snapshot of a job. - */ - export interface Schema$Snapshot { - /** - * The time this snapshot was created. - */ - creationTime?: string; - /** - * The unique ID of this snapshot. - */ - id?: string; - /** - * The project this snapshot belongs to. - */ - projectId?: string; - /** - * The job this snapshot was created from. - */ - sourceJobId?: string; - /** - * State of the snapshot. - */ - state?: string; - /** - * The time after which this snapshot will be automatically deleted. - */ - ttl?: string; - } - /** - * Request to create a snapshot of a job. - */ - export interface Schema$SnapshotJobRequest { - /** - * The location that contains this job. - */ - location?: string; - /** - * TTL for the snapshot. - */ - ttl?: string; - } /** * A source that records can be read and decoded from. */ @@ -3072,96 +3017,14 @@ export namespace dataflow_v1b3 { context: APIRequestContext; jobs: Resource$Projects$Jobs; locations: Resource$Projects$Locations; - snapshots: Resource$Projects$Snapshots; templates: Resource$Projects$Templates; constructor(context: APIRequestContext) { this.context = context; this.jobs = new Resource$Projects$Jobs(this.context); this.locations = new Resource$Projects$Locations(this.context); - this.snapshots = new Resource$Projects$Snapshots(this.context); this.templates = new Resource$Projects$Templates(this.context); } - /** - * dataflow.projects.deleteSnapshots - * @desc Deletes a snapshot. - * @alias dataflow.projects.deleteSnapshots - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.location The location that contains this snapshot. - * @param {string} params.projectId The ID of the Cloud Platform project that the snapshot belongs to. - * @param {string=} params.snapshotId The ID of the snapshot. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - deleteSnapshots( - params?: Params$Resource$Projects$Deletesnapshots, - options?: MethodOptions - ): GaxiosPromise; - deleteSnapshots( - params: Params$Resource$Projects$Deletesnapshots, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - deleteSnapshots( - params: Params$Resource$Projects$Deletesnapshots, - callback: BodyResponseCallback - ): void; - deleteSnapshots( - callback: BodyResponseCallback - ): void; - deleteSnapshots( - paramsOrCallback?: - | Params$Resource$Projects$Deletesnapshots - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Deletesnapshots; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Deletesnapshots; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataflow.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1b3/projects/{projectId}/snapshots').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['projectId'], - pathParams: ['projectId'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - /** * dataflow.projects.workerMessages * @desc Send a worker_message to the service. @@ -3244,26 +3107,6 @@ export namespace dataflow_v1b3 { } } - export interface Params$Resource$Projects$Deletesnapshots - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The location that contains this snapshot. - */ - location?: string; - /** - * The ID of the Cloud Platform project that the snapshot belongs to. - */ - projectId?: string; - /** - * The ID of the snapshot. - */ - snapshotId?: string; - } export interface Params$Resource$Projects$Workermessages extends StandardParameters { /** @@ -3678,79 +3521,6 @@ export namespace dataflow_v1b3 { } } - /** - * dataflow.projects.jobs.snapshot - * @desc Snapshot the state of a streaming job. - * @alias dataflow.projects.jobs.snapshot - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.jobId The job to be snapshotted. - * @param {string} params.projectId The project which owns the job to be snapshotted. - * @param {().SnapshotJobRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - snapshot( - params?: Params$Resource$Projects$Jobs$Snapshot, - options?: MethodOptions - ): GaxiosPromise; - snapshot( - params: Params$Resource$Projects$Jobs$Snapshot, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - snapshot( - params: Params$Resource$Projects$Jobs$Snapshot, - callback: BodyResponseCallback - ): void; - snapshot(callback: BodyResponseCallback): void; - snapshot( - paramsOrCallback?: - | Params$Resource$Projects$Jobs$Snapshot - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Jobs$Snapshot; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Jobs$Snapshot; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataflow.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/v1b3/projects/{projectId}/jobs/{jobId}:snapshot' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['projectId', 'jobId'], - pathParams: ['jobId', 'projectId'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - /** * dataflow.projects.jobs.update * @desc Updates the state of an existing Cloud Dataflow job. To update the state of an existing job, we recommend using `projects.locations.jobs.update` with a [regional endpoint] (https://cloud.google.com/dataflow/docs/concepts/regional-endpoints). Using `projects.jobs.update` is not recommended, as you can only update the state of jobs that are running in `us-central1`. @@ -3968,27 +3738,6 @@ export namespace dataflow_v1b3 { */ view?: string; } - export interface Params$Resource$Projects$Jobs$Snapshot - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The job to be snapshotted. - */ - jobId?: string; - /** - * The project which owns the job to be snapshotted. - */ - projectId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SnapshotJobRequest; - } export interface Params$Resource$Projects$Jobs$Update extends StandardParameters { /** @@ -4571,13 +4320,11 @@ export namespace dataflow_v1b3 { export class Resource$Projects$Locations { context: APIRequestContext; jobs: Resource$Projects$Locations$Jobs; - snapshots: Resource$Projects$Locations$Snapshots; sql: Resource$Projects$Locations$Sql; templates: Resource$Projects$Locations$Templates; constructor(context: APIRequestContext) { this.context = context; this.jobs = new Resource$Projects$Locations$Jobs(this.context); - this.snapshots = new Resource$Projects$Locations$Snapshots(this.context); this.sql = new Resource$Projects$Locations$Sql(this.context); this.templates = new Resource$Projects$Locations$Templates(this.context); } @@ -4692,7 +4439,6 @@ export namespace dataflow_v1b3 { context: APIRequestContext; debug: Resource$Projects$Locations$Jobs$Debug; messages: Resource$Projects$Locations$Jobs$Messages; - snapshots: Resource$Projects$Locations$Jobs$Snapshots; workItems: Resource$Projects$Locations$Jobs$Workitems; constructor(context: APIRequestContext) { this.context = context; @@ -4700,9 +4446,6 @@ export namespace dataflow_v1b3 { this.messages = new Resource$Projects$Locations$Jobs$Messages( this.context ); - this.snapshots = new Resource$Projects$Locations$Jobs$Snapshots( - this.context - ); this.workItems = new Resource$Projects$Locations$Jobs$Workitems( this.context ); @@ -5013,81 +4756,6 @@ export namespace dataflow_v1b3 { } } - /** - * dataflow.projects.locations.jobs.snapshot - * @desc Snapshot the state of a streaming job. - * @alias dataflow.projects.locations.jobs.snapshot - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.jobId The job to be snapshotted. - * @param {string} params.location The location that contains this job. - * @param {string} params.projectId The project which owns the job to be snapshotted. - * @param {().SnapshotJobRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - snapshot( - params?: Params$Resource$Projects$Locations$Jobs$Snapshot, - options?: MethodOptions - ): GaxiosPromise; - snapshot( - params: Params$Resource$Projects$Locations$Jobs$Snapshot, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - snapshot( - params: Params$Resource$Projects$Locations$Jobs$Snapshot, - callback: BodyResponseCallback - ): void; - snapshot(callback: BodyResponseCallback): void; - snapshot( - paramsOrCallback?: - | Params$Resource$Projects$Locations$Jobs$Snapshot - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Jobs$Snapshot; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Jobs$Snapshot; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataflow.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/v1b3/projects/{projectId}/locations/{location}/jobs/{jobId}:snapshot' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['projectId', 'location', 'jobId'], - pathParams: ['jobId', 'location', 'projectId'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - /** * dataflow.projects.locations.jobs.update * @desc Updates the state of an existing Cloud Dataflow job. To update the state of an existing job, we recommend using `projects.locations.jobs.update` with a [regional endpoint] (https://cloud.google.com/dataflow/docs/concepts/regional-endpoints). Using `projects.jobs.update` is not recommended, as you can only update the state of jobs that are running in `us-central1`. @@ -5273,31 +4941,6 @@ export namespace dataflow_v1b3 { */ view?: string; } - export interface Params$Resource$Projects$Locations$Jobs$Snapshot - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The job to be snapshotted. - */ - jobId?: string; - /** - * The location that contains this job. - */ - location?: string; - /** - * The project which owns the job to be snapshotted. - */ - projectId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SnapshotJobRequest; - } export interface Params$Resource$Projects$Locations$Jobs$Update extends StandardParameters { /** @@ -5675,153 +5318,47 @@ export namespace dataflow_v1b3 { startTime?: string; } - export class Resource$Projects$Locations$Jobs$Snapshots { + export class Resource$Projects$Locations$Jobs$Workitems { context: APIRequestContext; constructor(context: APIRequestContext) { this.context = context; } /** - * dataflow.projects.locations.jobs.snapshots.list - * @desc Lists snapshots. - * @alias dataflow.projects.locations.jobs.snapshots.list + * dataflow.projects.locations.jobs.workItems.lease + * @desc Leases a dataflow WorkItem to run. + * @alias dataflow.projects.locations.jobs.workItems.lease * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.jobId If specified, list snapshots created from this job. - * @param {string} params.location The location to list snapshots in. - * @param {string} params.projectId The project ID to list snapshots for. + * @param {string} params.jobId Identifies the workflow job this worker belongs to. + * @param {string} params.location The [regional endpoint] (https://cloud.google.com/dataflow/docs/concepts/regional-endpoints) that contains the WorkItem's job. + * @param {string} params.projectId Identifies the project this worker belongs to. + * @param {().LeaseWorkItemRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - list( - params?: Params$Resource$Projects$Locations$Jobs$Snapshots$List, + lease( + params?: Params$Resource$Projects$Locations$Jobs$Workitems$Lease, options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Projects$Locations$Jobs$Snapshots$List, + ): GaxiosPromise; + lease( + params: Params$Resource$Projects$Locations$Jobs$Workitems$Lease, options: | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback + | BodyResponseCallback, + callback: BodyResponseCallback ): void; - list( - params: Params$Resource$Projects$Locations$Jobs$Snapshots$List, - callback: BodyResponseCallback + lease( + params: Params$Resource$Projects$Locations$Jobs$Workitems$Lease, + callback: BodyResponseCallback ): void; - list(callback: BodyResponseCallback): void; - list( + lease(callback: BodyResponseCallback): void; + lease( paramsOrCallback?: - | Params$Resource$Projects$Locations$Jobs$Snapshots$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Jobs$Snapshots$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Jobs$Snapshots$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataflow.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/v1b3/projects/{projectId}/locations/{location}/jobs/{jobId}/snapshots' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['projectId', 'location', 'jobId'], - pathParams: ['jobId', 'location', 'projectId'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Projects$Locations$Jobs$Snapshots$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * If specified, list snapshots created from this job. - */ - jobId?: string; - /** - * The location to list snapshots in. - */ - location?: string; - /** - * The project ID to list snapshots for. - */ - projectId?: string; - } - - export class Resource$Projects$Locations$Jobs$Workitems { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * dataflow.projects.locations.jobs.workItems.lease - * @desc Leases a dataflow WorkItem to run. - * @alias dataflow.projects.locations.jobs.workItems.lease - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.jobId Identifies the workflow job this worker belongs to. - * @param {string} params.location The [regional endpoint] (https://cloud.google.com/dataflow/docs/concepts/regional-endpoints) that contains the WorkItem's job. - * @param {string} params.projectId Identifies the project this worker belongs to. - * @param {().LeaseWorkItemRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - lease( - params?: Params$Resource$Projects$Locations$Jobs$Workitems$Lease, - options?: MethodOptions - ): GaxiosPromise; - lease( - params: Params$Resource$Projects$Locations$Jobs$Workitems$Lease, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - lease( - params: Params$Resource$Projects$Locations$Jobs$Workitems$Lease, - callback: BodyResponseCallback - ): void; - lease(callback: BodyResponseCallback): void; - lease( - paramsOrCallback?: - | Params$Resource$Projects$Locations$Jobs$Workitems$Lease - | BodyResponseCallback, + | Params$Resource$Projects$Locations$Jobs$Workitems$Lease + | BodyResponseCallback, optionsOrCallback?: | MethodOptions | BodyResponseCallback, @@ -6004,304 +5541,6 @@ export namespace dataflow_v1b3 { requestBody?: Schema$ReportWorkItemStatusRequest; } - export class Resource$Projects$Locations$Snapshots { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * dataflow.projects.locations.snapshots.delete - * @desc Deletes a snapshot. - * @alias dataflow.projects.locations.snapshots.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.location The location that contains this snapshot. - * @param {string} params.projectId The ID of the Cloud Platform project that the snapshot belongs to. - * @param {string} params.snapshotId The ID of the snapshot. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Projects$Locations$Snapshots$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Projects$Locations$Snapshots$Delete, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Projects$Locations$Snapshots$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Projects$Locations$Snapshots$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Snapshots$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Snapshots$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataflow.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/v1b3/projects/{projectId}/locations/{location}/snapshots/{snapshotId}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['projectId', 'location', 'snapshotId'], - pathParams: ['location', 'projectId', 'snapshotId'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * dataflow.projects.locations.snapshots.get - * @desc Gets information about a snapshot. - * @alias dataflow.projects.locations.snapshots.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.location The location that contains this snapshot. - * @param {string} params.projectId The ID of the Cloud Platform project that the snapshot belongs to. - * @param {string} params.snapshotId The ID of the snapshot. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Projects$Locations$Snapshots$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Projects$Locations$Snapshots$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Projects$Locations$Snapshots$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Projects$Locations$Snapshots$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Snapshots$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Snapshots$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataflow.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/v1b3/projects/{projectId}/locations/{location}/snapshots/{snapshotId}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['projectId', 'location', 'snapshotId'], - pathParams: ['location', 'projectId', 'snapshotId'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * dataflow.projects.locations.snapshots.list - * @desc Lists snapshots. - * @alias dataflow.projects.locations.snapshots.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.jobId If specified, list snapshots created from this job. - * @param {string} params.location The location to list snapshots in. - * @param {string} params.projectId The project ID to list snapshots for. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Projects$Locations$Snapshots$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Projects$Locations$Snapshots$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Projects$Locations$Snapshots$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Projects$Locations$Snapshots$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Snapshots$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Snapshots$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataflow.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/v1b3/projects/{projectId}/locations/{location}/snapshots' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['projectId', 'location'], - pathParams: ['location', 'projectId'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Projects$Locations$Snapshots$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The location that contains this snapshot. - */ - location?: string; - /** - * The ID of the Cloud Platform project that the snapshot belongs to. - */ - projectId?: string; - /** - * The ID of the snapshot. - */ - snapshotId?: string; - } - export interface Params$Resource$Projects$Locations$Snapshots$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The location that contains this snapshot. - */ - location?: string; - /** - * The ID of the Cloud Platform project that the snapshot belongs to. - */ - projectId?: string; - /** - * The ID of the snapshot. - */ - snapshotId?: string; - } - export interface Params$Resource$Projects$Locations$Snapshots$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * If specified, list snapshots created from this job. - */ - jobId?: string; - /** - * The location to list snapshots in. - */ - location?: string; - /** - * The project ID to list snapshots for. - */ - projectId?: string; - } - export class Resource$Projects$Locations$Sql { context: APIRequestContext; constructor(context: APIRequestContext) { @@ -6729,205 +5968,6 @@ export namespace dataflow_v1b3 { requestBody?: Schema$LaunchTemplateParameters; } - export class Resource$Projects$Snapshots { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * dataflow.projects.snapshots.get - * @desc Gets information about a snapshot. - * @alias dataflow.projects.snapshots.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.location The location that contains this snapshot. - * @param {string} params.projectId The ID of the Cloud Platform project that the snapshot belongs to. - * @param {string} params.snapshotId The ID of the snapshot. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Projects$Snapshots$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Projects$Snapshots$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Projects$Snapshots$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Projects$Snapshots$Get - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Snapshots$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Snapshots$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataflow.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/v1b3/projects/{projectId}/snapshots/{snapshotId}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['projectId', 'snapshotId'], - pathParams: ['projectId', 'snapshotId'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * dataflow.projects.snapshots.list - * @desc Lists snapshots. - * @alias dataflow.projects.snapshots.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.jobId If specified, list snapshots created from this job. - * @param {string=} params.location The location to list snapshots in. - * @param {string} params.projectId The project ID to list snapshots for. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Projects$Snapshots$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Projects$Snapshots$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Projects$Snapshots$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Projects$Snapshots$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Snapshots$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Snapshots$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataflow.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1b3/projects/{projectId}/snapshots').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'GET', - }, - options - ), - params, - requiredParams: ['projectId'], - pathParams: ['projectId'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Projects$Snapshots$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The location that contains this snapshot. - */ - location?: string; - /** - * The ID of the Cloud Platform project that the snapshot belongs to. - */ - projectId?: string; - /** - * The ID of the snapshot. - */ - snapshotId?: string; - } - export interface Params$Resource$Projects$Snapshots$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * If specified, list snapshots created from this job. - */ - jobId?: string; - /** - * The location to list snapshots in. - */ - location?: string; - /** - * The project ID to list snapshots for. - */ - projectId?: string; - } - export class Resource$Projects$Templates { context: APIRequestContext; constructor(context: APIRequestContext) { diff --git a/src/apis/dataproc/v1.ts b/src/apis/dataproc/v1.ts index 6e12179b668..2807391916e 100644 --- a/src/apis/dataproc/v1.ts +++ b/src/apis/dataproc/v1.ts @@ -139,7 +139,7 @@ export namespace dataproc_v1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. members can have the following values: allUsers: A special identifier that represents anyone who is on the internet; with or without a Google account. allAuthenticatedUsers: A special identifier that represents anyone who is authenticated with a Google account or a service account. user:{emailid}: An email address that represents a specific Google account. For example, alice@gmail.com . serviceAccount:{emailid}: An email address that represents a service account. For example, my-other-app@appspot.gserviceaccount.com. group:{emailid}: An email address that represents a Google group. For example, admins@example.com. domain:{domain}: The G Suite domain (primary) that represents all the users of that domain. For example, google.com or example.com. + * Specifies the identities requesting access for a Cloud Platform resource. members can have the following values: allUsers: A special identifier that represents anyone who is on the internet; with or without a Google account. allAuthenticatedUsers: A special identifier that represents anyone who is authenticated with a Google account or a service account. user:{emailid}: An email address that represents a specific Google account. For example, alice@example.com . serviceAccount:{emailid}: An email address that represents a service account. For example, my-other-app@appspot.gserviceaccount.com. group:{emailid}: An email address that represents a Google group. For example, admins@example.com. domain:{domain}: The G Suite domain (primary) that represents all the users of that domain. For example, google.com or example.com. */ members?: string[]; /** @@ -208,6 +208,10 @@ export namespace dataproc_v1 { * Optional. Commands to execute on each node after config is completed. By default, executables are run on master and all worker nodes. You can test a node's role metadata to run an executable on a master or worker node, as shown below using curl (you can also use wget): ROLE=$(curl -H Metadata-Flavor:Google http://metadata/computeMetadata/v1/instance/attributes/dataproc-role) if [[ "${ROLE}" == 'Master' ]]; then ... master specific actions ... else ... worker specific actions ... fi */ initializationActions?: Schema$NodeInitializationAction[]; + /** + * Optional. Lifecycle setting for the cluster. + */ + lifecycleConfig?: Schema$LifecycleConfig; /** * Optional. The Compute Engine config settings for the master instance in a cluster. */ @@ -455,7 +459,21 @@ export namespace dataproc_v1 { /** * Request message for GetIamPolicy method. */ - export interface Schema$GetIamPolicyRequest {} + export interface Schema$GetIamPolicyRequest { + /** + * OPTIONAL: A GetPolicyOptions object for specifying options to GetIamPolicy. This field is only used by Cloud IAM. + */ + options?: Schema$GetPolicyOptions; + } + /** + * Encapsulates settings provided to GetIamPolicy. + */ + export interface Schema$GetPolicyOptions { + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + requestedPolicyVersion?: number; + } /** * A Cloud Dataproc job for running Apache Hadoop MapReduce (https://hadoop.apache.org/docs/current/hadoop-mapreduce-client/hadoop-mapreduce-client-core/MapReduceTutorial.html) jobs on Apache Hadoop YARN (https://hadoop.apache.org/docs/r2.7.1/hadoop-yarn/hadoop-yarn-site/YARN.html). */ @@ -745,6 +763,10 @@ export namespace dataproc_v1 { * Required. The uri of the KMS key used to encrypt various sensitive files. */ kmsKeyUri?: string; + /** + * Optional. The name of the on-cluster Kerberos realm. If not specified, the uppercased domain of hostnames will be the realm. + */ + realm?: string; /** * Required. The Cloud Storage URI of a KMS encrypted file containing the root principal password. */ @@ -762,6 +784,27 @@ export namespace dataproc_v1 { */ truststoreUri?: string; } + /** + * Specifies the cluster auto-delete schedule configuration. + */ + export interface Schema$LifecycleConfig { + /** + * Optional. The time when cluster will be auto-deleted. + */ + autoDeleteTime?: string; + /** + * Optional. The lifetime duration of cluster. The cluster will be auto-deleted at the end of this period. Valid range: 10m, 14d.Example: "1d", to delete the cluster 1 day after its creation.. + */ + autoDeleteTtl?: string; + /** + * Optional. The duration to keep the cluster alive while idling. Passing this threshold will cause the cluster to be deleted. Valid range: 10m, 14d.Example: "10m", the minimum value, to delete the cluster when it has had no jobs running for 10 minutes. + */ + idleDeleteTtl?: string; + /** + * Output only. The time when cluster became idle (most recent job finished) and became eligible for deletion due to idleness. + */ + idleStartTime?: string; + } /** * The list of all clusters in a project. */ @@ -991,7 +1034,7 @@ export namespace dataproc_v1 { */ bindings?: Schema$Binding[]; /** - * etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the etag in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An etag is returned in the response to getIamPolicy, and systems are expected to put that etag in the request to setIamPolicy to ensure that their change will be applied to the same version of the policy.If no etag is provided in the call to setIamPolicy, then the existing policy is overwritten blindly. + * etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the etag in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An etag is returned in the response to getIamPolicy, and systems are expected to put that etag in the request to setIamPolicy to ensure that their change will be applied to the same version of the policy.If no etag is provided in the call to setIamPolicy, then the existing policy is overwritten. */ etag?: string; /** @@ -1283,7 +1326,7 @@ export namespace dataproc_v1 { */ state?: string; /** - * Output only. The "resource name" of the template. + * Output only. The resource name of the workflow template as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ template?: string; /** @@ -1337,7 +1380,7 @@ export namespace dataproc_v1 { */ labels?: {[key: string]: string}; /** - * Output only. The "resource name" of the template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Output only. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; /** @@ -1405,28 +1448,24 @@ export namespace dataproc_v1 { export class Resource$Projects$Locations { context: APIRequestContext; - autoscalingPolicies: Resource$Projects$Locations$Autoscalingpolicies; workflowTemplates: Resource$Projects$Locations$Workflowtemplates; constructor(context: APIRequestContext) { this.context = context; - this.autoscalingPolicies = new Resource$Projects$Locations$Autoscalingpolicies( - this.context - ); this.workflowTemplates = new Resource$Projects$Locations$Workflowtemplates( this.context ); } } - export class Resource$Projects$Locations$Autoscalingpolicies { + export class Resource$Projects$Locations$Workflowtemplates { context: APIRequestContext; constructor(context: APIRequestContext) { this.context = context; } /** - * dataproc.projects.locations.autoscalingPolicies.getIamPolicy - * @desc Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set. + * dataproc.projects.locations.workflowTemplates.create + * @desc Creates new workflow template. * @example * * // BEFORE RUNNING: * // --------------- @@ -1447,9 +1486,10 @@ export namespace dataproc_v1 { * * authorize(function(authClient) { * var request = { - * // REQUIRED: The resource for which the policy is being requested. See the operation documentation for - * // the appropriate value for this field. - * resource_: 'projects/my-project/locations/my-location/autoscalingPolicies/my-autoscaling-policy', // TODO: Update placeholder value. + * // Required. The "resource name" of the region, as described in + * // https://cloud.google.com/apis/design/resource_names of the form + * // projects/{project_id}/regions/{region} + * parent: 'projects/my-project/locations/my-location', // TODO: Update placeholder value. * * resource: { * // TODO: Add desired properties to the request body. @@ -1458,7 +1498,7 @@ export namespace dataproc_v1 { * auth: authClient, * }; * - * dataproc.projects.locations.autoscalingPolicies.getIamPolicy(request, function(err, response) { + * dataproc.projects.locations.workflowTemplates.create(request, function(err, response) { * if (err) { * console.error(err); * return; @@ -1478,44 +1518,46 @@ export namespace dataproc_v1 { * console.error('authentication failed: ', err); * }); * } - * @alias dataproc.projects.locations.autoscalingPolicies.getIamPolicy + * @alias dataproc.projects.locations.workflowTemplates.create * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. - * @param {().GetIamPolicyRequest} params.resource Request body data + * @param {string} params.parent Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,create, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.create, the resource name of the location has the following format: projects/{project_id}/locations/{location} + * @param {().WorkflowTemplate} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - getIamPolicy( - params?: Params$Resource$Projects$Locations$Autoscalingpolicies$Getiampolicy, + create( + params?: Params$Resource$Projects$Locations$Workflowtemplates$Create, options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Projects$Locations$Autoscalingpolicies$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + create( + params: Params$Resource$Projects$Locations$Workflowtemplates$Create, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback ): void; - getIamPolicy( - params: Params$Resource$Projects$Locations$Autoscalingpolicies$Getiampolicy, - callback: BodyResponseCallback + create( + params: Params$Resource$Projects$Locations$Workflowtemplates$Create, + callback: BodyResponseCallback ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( + create(callback: BodyResponseCallback): void; + create( paramsOrCallback?: - | Params$Resource$Projects$Locations$Autoscalingpolicies$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | Params$Resource$Projects$Locations$Workflowtemplates$Create + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Autoscalingpolicies$Getiampolicy; + {}) as Params$Resource$Projects$Locations$Workflowtemplates$Create; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Autoscalingpolicies$Getiampolicy; + params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Create; options = {}; } @@ -1528,7 +1570,7 @@ export namespace dataproc_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+resource}:getIamPolicy').replace( + url: (rootUrl + '/v1/{+parent}/workflowTemplates').replace( /([^:]\/)\/+/g, '$1' ), @@ -1537,20 +1579,20 @@ export namespace dataproc_v1 { options ), params, - requiredParams: ['resource'], - pathParams: ['resource'], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest(parameters, callback); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } /** - * dataproc.projects.locations.autoscalingPolicies.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. + * dataproc.projects.locations.workflowTemplates.delete + * @desc Deletes a workflow template. It does not cancel in-progress workflows. * @example * * // BEFORE RUNNING: * // --------------- @@ -1571,25 +1613,19 @@ export namespace dataproc_v1 { * * authorize(function(authClient) { * var request = { - * // REQUIRED: The resource for which the policy is being specified. See the operation documentation for - * // the appropriate value for this field. - * resource_: 'projects/my-project/locations/my-location/autoscalingPolicies/my-autoscaling-policy', // TODO: Update placeholder value. - * - * resource: { - * // TODO: Add desired properties to the request body. - * }, + * // Required. The "resource name" of the workflow template, as described in + * // https://cloud.google.com/apis/design/resource_names of the form + * // projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * name: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. * * auth: authClient, * }; * - * dataproc.projects.locations.autoscalingPolicies.setIamPolicy(request, function(err, response) { + * dataproc.projects.locations.workflowTemplates.delete(request, function(err) { * if (err) { * console.error(err); * return; * } - * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); * }); * }); * @@ -1602,44 +1638,44 @@ export namespace dataproc_v1 { * console.error('authentication failed: ', err); * }); * } - * @alias dataproc.projects.locations.autoscalingPolicies.setIamPolicy + * @alias dataproc.projects.locations.workflowTemplates.delete * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.resource_ REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. - * @param {().SetIamPolicyRequest} params.resource Request body data + * @param {string} params.name Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.delete, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} + * @param {integer=} params.version Optional. The version of workflow template to delete. If specified, will only delete the template if the current server version matches specified version. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - setIamPolicy( - params?: Params$Resource$Projects$Locations$Autoscalingpolicies$Setiampolicy, + delete( + params?: Params$Resource$Projects$Locations$Workflowtemplates$Delete, options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Projects$Locations$Autoscalingpolicies$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + delete( + params: Params$Resource$Projects$Locations$Workflowtemplates$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback ): void; - setIamPolicy( - params: Params$Resource$Projects$Locations$Autoscalingpolicies$Setiampolicy, - callback: BodyResponseCallback + delete( + params: Params$Resource$Projects$Locations$Workflowtemplates$Delete, + callback: BodyResponseCallback ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( + delete(callback: BodyResponseCallback): void; + delete( paramsOrCallback?: - | Params$Resource$Projects$Locations$Autoscalingpolicies$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | Params$Resource$Projects$Locations$Workflowtemplates$Delete + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Autoscalingpolicies$Setiampolicy; + {}) as Params$Resource$Projects$Locations$Workflowtemplates$Delete; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Autoscalingpolicies$Setiampolicy; + params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Delete; options = {}; } @@ -1652,29 +1688,26 @@ export namespace dataproc_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+resource}:setIamPolicy').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'POST', + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', }, options ), params, - requiredParams: ['resource'], - pathParams: ['resource'], + requiredParams: ['name'], + pathParams: ['name'], context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest(parameters, callback); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } /** - * dataproc.projects.locations.autoscalingPolicies.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may "fail open" without warning. + * dataproc.projects.locations.workflowTemplates.get + * @desc Retrieves the latest workflow template.Can retrieve previously instantiated template by specifying optional version parameter. * @example * * // BEFORE RUNNING: * // --------------- @@ -1695,18 +1728,15 @@ export namespace dataproc_v1 { * * authorize(function(authClient) { * var request = { - * // REQUIRED: The resource for which the policy detail is being requested. See the operation - * // documentation for the appropriate value for this field. - * resource_: 'projects/my-project/locations/my-location/autoscalingPolicies/my-autoscaling-policy', // TODO: Update placeholder value. - * - * resource: { - * // TODO: Add desired properties to the request body. - * }, + * // Required. The "resource name" of the workflow template, as described in + * // https://cloud.google.com/apis/design/resource_names of the form + * // projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * name: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. * * auth: authClient, * }; * - * dataproc.projects.locations.autoscalingPolicies.testIamPermissions(request, function(err, response) { + * dataproc.projects.locations.workflowTemplates.get(request, function(err, response) { * if (err) { * console.error(err); * return; @@ -1726,50 +1756,46 @@ export namespace dataproc_v1 { * console.error('authentication failed: ', err); * }); * } - * @alias dataproc.projects.locations.autoscalingPolicies.testIamPermissions + * @alias dataproc.projects.locations.workflowTemplates.get * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.resource_ REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field. - * @param {().TestIamPermissionsRequest} params.resource Request body data + * @param {string} params.name Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} + * @param {integer=} params.version Optional. The version of workflow template to retrieve. Only previously instantiated versions can be retrieved.If unspecified, retrieves the current version. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - testIamPermissions( - params?: Params$Resource$Projects$Locations$Autoscalingpolicies$Testiampermissions, + get( + params?: Params$Resource$Projects$Locations$Workflowtemplates$Get, options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Projects$Locations$Autoscalingpolicies$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Projects$Locations$Autoscalingpolicies$Testiampermissions, - callback: BodyResponseCallback + ): GaxiosPromise; + get( + params: Params$Resource$Projects$Locations$Workflowtemplates$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback ): void; - testIamPermissions( - callback: BodyResponseCallback + get( + params: Params$Resource$Projects$Locations$Workflowtemplates$Get, + callback: BodyResponseCallback ): void; - testIamPermissions( + get(callback: BodyResponseCallback): void; + get( paramsOrCallback?: - | Params$Resource$Projects$Locations$Autoscalingpolicies$Testiampermissions - | BodyResponseCallback, + | Params$Resource$Projects$Locations$Workflowtemplates$Get + | BodyResponseCallback, optionsOrCallback?: | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Autoscalingpolicies$Testiampermissions; + {}) as Params$Resource$Projects$Locations$Workflowtemplates$Get; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Autoscalingpolicies$Testiampermissions; + params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Get; options = {}; } @@ -1782,91 +1808,26 @@ export namespace dataproc_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+resource}:testIamPermissions').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'POST', + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', }, options ), params, - requiredParams: ['resource'], - pathParams: ['resource'], + requiredParams: ['name'], + pathParams: ['name'], context: this.context, }; if (callback) { - createAPIRequest( - parameters, - callback - ); + createAPIRequest(parameters, callback); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } - } - - export interface Params$Resource$Projects$Locations$Autoscalingpolicies$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GetIamPolicyRequest; - } - export interface Params$Resource$Projects$Locations$Autoscalingpolicies$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. - */ - resource?: string; /** - * Request body metadata - */ - requestBody?: Schema$SetIamPolicyRequest; - } - export interface Params$Resource$Projects$Locations$Autoscalingpolicies$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestIamPermissionsRequest; - } - - export class Resource$Projects$Locations$Workflowtemplates { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * dataproc.projects.locations.workflowTemplates.create - * @desc Creates new workflow template. + * dataproc.projects.locations.workflowTemplates.getIamPolicy + * @desc Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set. * @example * * // BEFORE RUNNING: * // --------------- @@ -1887,10 +1848,9 @@ export namespace dataproc_v1 { * * authorize(function(authClient) { * var request = { - * // Required. The "resource name" of the region, as described in - * // https://cloud.google.com/apis/design/resource_names of the form - * // projects/{project_id}/regions/{region} - * parent: 'projects/my-project/locations/my-location', // TODO: Update placeholder value. + * // REQUIRED: The resource for which the policy is being requested. See the operation documentation for + * // the appropriate value for this field. + * resource_: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. * * resource: { * // TODO: Add desired properties to the request body. @@ -1899,7 +1859,7 @@ export namespace dataproc_v1 { * auth: authClient, * }; * - * dataproc.projects.locations.workflowTemplates.create(request, function(err, response) { + * dataproc.projects.locations.workflowTemplates.getIamPolicy(request, function(err, response) { * if (err) { * console.error(err); * return; @@ -1919,46 +1879,44 @@ export namespace dataproc_v1 { * console.error('authentication failed: ', err); * }); * } - * @alias dataproc.projects.locations.workflowTemplates.create + * @alias dataproc.projects.locations.workflowTemplates.getIamPolicy * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} - * @param {().WorkflowTemplate} params.resource Request body data + * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. + * @param {().GetIamPolicyRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - create( - params?: Params$Resource$Projects$Locations$Workflowtemplates$Create, + getIamPolicy( + params?: Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy, options?: MethodOptions - ): GaxiosPromise; - create( - params: Params$Resource$Projects$Locations$Workflowtemplates$Create, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + getIamPolicy( + params: Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback ): void; - create( - params: Params$Resource$Projects$Locations$Workflowtemplates$Create, - callback: BodyResponseCallback + getIamPolicy( + params: Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy, + callback: BodyResponseCallback ): void; - create(callback: BodyResponseCallback): void; - create( + getIamPolicy(callback: BodyResponseCallback): void; + getIamPolicy( paramsOrCallback?: - | Params$Resource$Projects$Locations$Workflowtemplates$Create - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Workflowtemplates$Create; + {}) as Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Create; + params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy; options = {}; } @@ -1971,7 +1929,7 @@ export namespace dataproc_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+parent}/workflowTemplates').replace( + url: (rootUrl + '/v1/{+resource}:getIamPolicy').replace( /([^:]\/)\/+/g, '$1' ), @@ -1980,20 +1938,20 @@ export namespace dataproc_v1 { options ), params, - requiredParams: ['parent'], - pathParams: ['parent'], + requiredParams: ['resource'], + pathParams: ['resource'], context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest(parameters, callback); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } /** - * dataproc.projects.locations.workflowTemplates.delete - * @desc Deletes a workflow template. It does not cancel in-progress workflows. + * dataproc.projects.locations.workflowTemplates.instantiate + * @desc Instantiates a template and begins execution.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata. Also see Using WorkflowMetadata.On successful completion, Operation.response will be Empty. * @example * * // BEFORE RUNNING: * // --------------- @@ -2019,14 +1977,21 @@ export namespace dataproc_v1 { * // projects/{project_id}/regions/{region}/workflowTemplates/{template_id} * name: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. * + * resource: { + * // TODO: Add desired properties to the request body. + * }, + * * auth: authClient, * }; * - * dataproc.projects.locations.workflowTemplates.delete(request, function(err) { + * dataproc.projects.locations.workflowTemplates.instantiate(request, function(err, response) { * if (err) { * console.error(err); * return; * } + * + * // TODO: Change code below to process the `response` object: + * console.log(JSON.stringify(response, null, 2)); * }); * }); * @@ -2039,44 +2004,46 @@ export namespace dataproc_v1 { * console.error('authentication failed: ', err); * }); * } - * @alias dataproc.projects.locations.workflowTemplates.delete + * @alias dataproc.projects.locations.workflowTemplates.instantiate * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - * @param {integer=} params.version Optional. The version of workflow template to delete. If specified, will only delete the template if the current server version matches specified version. + * @param {string} params.name Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} + * @param {().InstantiateWorkflowTemplateRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - delete( - params?: Params$Resource$Projects$Locations$Workflowtemplates$Delete, + instantiate( + params?: Params$Resource$Projects$Locations$Workflowtemplates$Instantiate, options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Projects$Locations$Workflowtemplates$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + instantiate( + params: Params$Resource$Projects$Locations$Workflowtemplates$Instantiate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback ): void; - delete( - params: Params$Resource$Projects$Locations$Workflowtemplates$Delete, - callback: BodyResponseCallback + instantiate( + params: Params$Resource$Projects$Locations$Workflowtemplates$Instantiate, + callback: BodyResponseCallback ): void; - delete(callback: BodyResponseCallback): void; - delete( + instantiate(callback: BodyResponseCallback): void; + instantiate( paramsOrCallback?: - | Params$Resource$Projects$Locations$Workflowtemplates$Delete - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | Params$Resource$Projects$Locations$Workflowtemplates$Instantiate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Workflowtemplates$Delete; + {}) as Params$Resource$Projects$Locations$Workflowtemplates$Instantiate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Delete; + params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Instantiate; options = {}; } @@ -2089,8 +2056,11 @@ export namespace dataproc_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', + url: (rootUrl + '/v1/{+name}:instantiate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', }, options ), @@ -2100,15 +2070,15 @@ export namespace dataproc_v1 { context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest(parameters, callback); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } /** - * dataproc.projects.locations.workflowTemplates.get - * @desc Retrieves the latest workflow template.Can retrieve previously instantiated template by specifying optional version parameter. + * dataproc.projects.locations.workflowTemplates.instantiateInline + * @desc Instantiates a template and begins execution.This method is equivalent to executing the sequence CreateWorkflowTemplate, InstantiateWorkflowTemplate, DeleteWorkflowTemplate.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata. Also see Using WorkflowMetadata.On successful completion, Operation.response will be Empty. * @example * * // BEFORE RUNNING: * // --------------- @@ -2129,15 +2099,19 @@ export namespace dataproc_v1 { * * authorize(function(authClient) { * var request = { - * // Required. The "resource name" of the workflow template, as described in + * // Required. The "resource name" of the workflow template region, as described in * // https://cloud.google.com/apis/design/resource_names of the form - * // projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - * name: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. + * // projects/{project_id}/regions/{region} + * parent: 'projects/my-project/locations/my-location', // TODO: Update placeholder value. + * + * resource: { + * // TODO: Add desired properties to the request body. + * }, * * auth: authClient, * }; * - * dataproc.projects.locations.workflowTemplates.get(request, function(err, response) { + * dataproc.projects.locations.workflowTemplates.instantiateInline(request, function(err, response) { * if (err) { * console.error(err); * return; @@ -2157,46 +2131,47 @@ export namespace dataproc_v1 { * console.error('authentication failed: ', err); * }); * } - * @alias dataproc.projects.locations.workflowTemplates.get + * @alias dataproc.projects.locations.workflowTemplates.instantiateInline * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - * @param {integer=} params.version Optional. The version of workflow template to retrieve. Only previously instatiated versions can be retrieved.If unspecified, retrieves the current version. + * @param {string} params.parent Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,instantiateinline, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.instantiateinline, the resource name of the location has the following format: projects/{project_id}/locations/{location} + * @param {string=} params.requestId Optional. A tag that prevents multiple concurrent workflow instances with the same tag from running. This mitigates risk of concurrent instances started due to retries.It is recommended to always set this value to a UUID (https://en.wikipedia.org/wiki/Universally_unique_identifier).The tag must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters. + * @param {().WorkflowTemplate} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - get( - params?: Params$Resource$Projects$Locations$Workflowtemplates$Get, + instantiateInline( + params?: Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline, options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Projects$Locations$Workflowtemplates$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + instantiateInline( + params: Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback ): void; - get( - params: Params$Resource$Projects$Locations$Workflowtemplates$Get, - callback: BodyResponseCallback + instantiateInline( + params: Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline, + callback: BodyResponseCallback ): void; - get(callback: BodyResponseCallback): void; - get( + instantiateInline(callback: BodyResponseCallback): void; + instantiateInline( paramsOrCallback?: - | Params$Resource$Projects$Locations$Workflowtemplates$Get - | BodyResponseCallback, + | Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline + | BodyResponseCallback, optionsOrCallback?: | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Workflowtemplates$Get; + {}) as Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Get; + params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline; options = {}; } @@ -2209,26 +2184,28 @@ export namespace dataproc_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', + url: ( + rootUrl + '/v1/{+parent}/workflowTemplates:instantiateInline' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', }, options ), params, - requiredParams: ['name'], - pathParams: ['name'], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest(parameters, callback); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } /** - * dataproc.projects.locations.workflowTemplates.getIamPolicy - * @desc Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set. + * dataproc.projects.locations.workflowTemplates.list + * @desc Lists workflows that match the specified filter in the request. * @example * * // BEFORE RUNNING: * // --------------- @@ -2249,75 +2226,92 @@ export namespace dataproc_v1 { * * authorize(function(authClient) { * var request = { - * // REQUIRED: The resource for which the policy is being requested. See the operation documentation for - * // the appropriate value for this field. - * resource_: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. - * - * resource: { - * // TODO: Add desired properties to the request body. - * }, + * // Required. The "resource name" of the region, as described in + * // https://cloud.google.com/apis/design/resource_names of the form + * // projects/{project_id}/regions/{region} + * parent: 'projects/my-project/locations/my-location', // TODO: Update placeholder value. * * auth: authClient, * }; * - * dataproc.projects.locations.workflowTemplates.getIamPolicy(request, function(err, response) { + * var handlePage = function(err, response) { * if (err) { * console.error(err); * return; * } * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); - * }); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); + * var templatesPage = response['templates']; + * if (!templatesPage) { + * return; + * } + * for (var i = 0; i < templatesPage.length; i++) { + * // TODO: Change code below to process each resource in `templatesPage`: + * console.log(JSON.stringify(templatesPage[i], null, 2)); + * } + * + * if (response.nextPageToken) { + * request.pageToken = response.nextPageToken; + * dataproc.projects.locations.workflowTemplates.list(request, handlePage); + * } + * }; + * + * dataproc.projects.locations.workflowTemplates.list(request, handlePage); + * }); + * + * function authorize(callback) { + * google.auth.getClient({ + * scopes: ['https://www.googleapis.com/auth/cloud-platform'] + * }).then(client => { + * callback(client); * }).catch(err => { * console.error('authentication failed: ', err); * }); * } - * @alias dataproc.projects.locations.workflowTemplates.getIamPolicy + * @alias dataproc.projects.locations.workflowTemplates.list * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. - * @param {().GetIamPolicyRequest} params.resource Request body data + * @param {integer=} params.pageSize Optional. The maximum number of results to return in each response. + * @param {string=} params.pageToken Optional. The page token, returned by a previous call, to request the next page of results. + * @param {string} params.parent Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.list, the resource name of the location has the following format: projects/{project_id}/locations/{location} * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - getIamPolicy( - params?: Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy, + list( + params?: Params$Resource$Projects$Locations$Workflowtemplates$List, options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Locations$Workflowtemplates$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback ): void; - getIamPolicy( - params: Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy, - callback: BodyResponseCallback + list( + params: Params$Resource$Projects$Locations$Workflowtemplates$List, + callback: BodyResponseCallback ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( + list( + callback: BodyResponseCallback + ): void; + list( paramsOrCallback?: - | Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | Params$Resource$Projects$Locations$Workflowtemplates$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy; + {}) as Params$Resource$Projects$Locations$Workflowtemplates$List; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy; + params = {} as Params$Resource$Projects$Locations$Workflowtemplates$List; options = {}; } @@ -2330,29 +2324,34 @@ export namespace dataproc_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+resource}:getIamPolicy').replace( + url: (rootUrl + '/v1/{+parent}/workflowTemplates').replace( /([^:]\/)\/+/g, '$1' ), - method: 'POST', + method: 'GET', }, options ), params, - requiredParams: ['resource'], - pathParams: ['resource'], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest( + parameters, + callback + ); } else { - return createAPIRequest(parameters); + return createAPIRequest( + parameters + ); } } /** - * dataproc.projects.locations.workflowTemplates.instantiate - * @desc Instantiates a template and begins execution.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata.On successful completion, Operation.response will be Empty. + * dataproc.projects.locations.workflowTemplates.setIamPolicy + * @desc Sets the access control policy on the specified resource. Replaces any existing policy. * @example * * // BEFORE RUNNING: * // --------------- @@ -2373,10 +2372,9 @@ export namespace dataproc_v1 { * * authorize(function(authClient) { * var request = { - * // Required. The "resource name" of the workflow template, as described in - * // https://cloud.google.com/apis/design/resource_names of the form - * // projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - * name: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. + * // REQUIRED: The resource for which the policy is being specified. See the operation documentation for + * // the appropriate value for this field. + * resource_: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. * * resource: { * // TODO: Add desired properties to the request body. @@ -2385,7 +2383,7 @@ export namespace dataproc_v1 { * auth: authClient, * }; * - * dataproc.projects.locations.workflowTemplates.instantiate(request, function(err, response) { + * dataproc.projects.locations.workflowTemplates.setIamPolicy(request, function(err, response) { * if (err) { * console.error(err); * return; @@ -2405,46 +2403,44 @@ export namespace dataproc_v1 { * console.error('authentication failed: ', err); * }); * } - * @alias dataproc.projects.locations.workflowTemplates.instantiate + * @alias dataproc.projects.locations.workflowTemplates.setIamPolicy * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - * @param {().InstantiateWorkflowTemplateRequest} params.resource Request body data + * @param {string} params.resource_ REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. + * @param {().SetIamPolicyRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - instantiate( - params?: Params$Resource$Projects$Locations$Workflowtemplates$Instantiate, + setIamPolicy( + params?: Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy, options?: MethodOptions - ): GaxiosPromise; - instantiate( - params: Params$Resource$Projects$Locations$Workflowtemplates$Instantiate, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + setIamPolicy( + params: Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback ): void; - instantiate( - params: Params$Resource$Projects$Locations$Workflowtemplates$Instantiate, - callback: BodyResponseCallback + setIamPolicy( + params: Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy, + callback: BodyResponseCallback ): void; - instantiate(callback: BodyResponseCallback): void; - instantiate( + setIamPolicy(callback: BodyResponseCallback): void; + setIamPolicy( paramsOrCallback?: - | Params$Resource$Projects$Locations$Workflowtemplates$Instantiate - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Workflowtemplates$Instantiate; + {}) as Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Instantiate; + params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy; options = {}; } @@ -2457,7 +2453,7 @@ export namespace dataproc_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+name}:instantiate').replace( + url: (rootUrl + '/v1/{+resource}:setIamPolicy').replace( /([^:]\/)\/+/g, '$1' ), @@ -2466,20 +2462,20 @@ export namespace dataproc_v1 { options ), params, - requiredParams: ['name'], - pathParams: ['name'], + requiredParams: ['resource'], + pathParams: ['resource'], context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest(parameters, callback); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } /** - * dataproc.projects.locations.workflowTemplates.instantiateInline - * @desc Instantiates a template and begins execution.This method is equivalent to executing the sequence CreateWorkflowTemplate, InstantiateWorkflowTemplate, DeleteWorkflowTemplate.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata.On successful completion, Operation.response will be Empty. + * dataproc.projects.locations.workflowTemplates.testIamPermissions + * @desc Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may "fail open" without warning. * @example * * // BEFORE RUNNING: * // --------------- @@ -2500,10 +2496,9 @@ export namespace dataproc_v1 { * * authorize(function(authClient) { * var request = { - * // Required. The "resource name" of the workflow template region, as described in - * // https://cloud.google.com/apis/design/resource_names of the form - * // projects/{project_id}/regions/{region} - * parent: 'projects/my-project/locations/my-location', // TODO: Update placeholder value. + * // REQUIRED: The resource for which the policy detail is being requested. See the operation + * // documentation for the appropriate value for this field. + * resource_: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. * * resource: { * // TODO: Add desired properties to the request body. @@ -2512,7 +2507,7 @@ export namespace dataproc_v1 { * auth: authClient, * }; * - * dataproc.projects.locations.workflowTemplates.instantiateInline(request, function(err, response) { + * dataproc.projects.locations.workflowTemplates.testIamPermissions(request, function(err, response) { * if (err) { * console.error(err); * return; @@ -2532,47 +2527,50 @@ export namespace dataproc_v1 { * console.error('authentication failed: ', err); * }); * } - * @alias dataproc.projects.locations.workflowTemplates.instantiateInline + * @alias dataproc.projects.locations.workflowTemplates.testIamPermissions * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The "resource name" of the workflow template region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} - * @param {string=} params.requestId Optional. A tag that prevents multiple concurrent workflow instances with the same tag from running. This mitigates risk of concurrent instances started due to retries.It is recommended to always set this value to a UUID (https://en.wikipedia.org/wiki/Universally_unique_identifier).The tag must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters. - * @param {().WorkflowTemplate} params.resource Request body data + * @param {string} params.resource_ REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field. + * @param {().TestIamPermissionsRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - instantiateInline( - params?: Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline, + testIamPermissions( + params?: Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions, options?: MethodOptions - ): GaxiosPromise; - instantiateInline( - params: Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + testIamPermissions( + params: Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback ): void; - instantiateInline( - params: Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline, - callback: BodyResponseCallback + testIamPermissions( + params: Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions, + callback: BodyResponseCallback ): void; - instantiateInline(callback: BodyResponseCallback): void; - instantiateInline( + testIamPermissions( + callback: BodyResponseCallback + ): void; + testIamPermissions( paramsOrCallback?: - | Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline - | BodyResponseCallback, + | Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions + | BodyResponseCallback, optionsOrCallback?: | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline; + {}) as Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline; + params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions; options = {}; } @@ -2585,28 +2583,32 @@ export namespace dataproc_v1 { const parameters = { options: Object.assign( { - url: ( - rootUrl + '/v1/{+parent}/workflowTemplates:instantiateInline' - ).replace(/([^:]\/)\/+/g, '$1'), + url: (rootUrl + '/v1/{+resource}:testIamPermissions').replace( + /([^:]\/)\/+/g, + '$1' + ), method: 'POST', }, options ), params, - requiredParams: ['parent'], - pathParams: ['parent'], + requiredParams: ['resource'], + pathParams: ['resource'], context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest( + parameters, + callback + ); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } /** - * dataproc.projects.locations.workflowTemplates.list - * @desc Lists workflows that match the specified filter in the request. + * dataproc.projects.locations.workflowTemplates.update + * @desc Updates (replaces) workflow template. The updated template must contain version that matches the current server version. * @example * * // BEFORE RUNNING: * // --------------- @@ -2627,998 +2629,20 @@ export namespace dataproc_v1 { * * authorize(function(authClient) { * var request = { - * // Required. The "resource name" of the region, as described in + * // Output only. The "resource name" of the template, as described in * // https://cloud.google.com/apis/design/resource_names of the form - * // projects/{project_id}/regions/{region} - * parent: 'projects/my-project/locations/my-location', // TODO: Update placeholder value. + * // projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * name: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. + * + * resource: { + * // TODO: Add desired properties to the request body. All existing properties + * // will be replaced. + * }, * * auth: authClient, * }; * - * var handlePage = function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * var templatesPage = response['templates']; - * if (!templatesPage) { - * return; - * } - * for (var i = 0; i < templatesPage.length; i++) { - * // TODO: Change code below to process each resource in `templatesPage`: - * console.log(JSON.stringify(templatesPage[i], null, 2)); - * } - * - * if (response.nextPageToken) { - * request.pageToken = response.nextPageToken; - * dataproc.projects.locations.workflowTemplates.list(request, handlePage); - * } - * }; - * - * dataproc.projects.locations.workflowTemplates.list(request, handlePage); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias dataproc.projects.locations.workflowTemplates.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {integer=} params.pageSize Optional. The maximum number of results to return in each response. - * @param {string=} params.pageToken Optional. The page token, returned by a previous call, to request the next page of results. - * @param {string} params.parent Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Projects$Locations$Workflowtemplates$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Projects$Locations$Workflowtemplates$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Projects$Locations$Workflowtemplates$List, - callback: BodyResponseCallback - ): void; - list( - callback: BodyResponseCallback - ): void; - list( - paramsOrCallback?: - | Params$Resource$Projects$Locations$Workflowtemplates$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Workflowtemplates$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Workflowtemplates$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataproc.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1/{+parent}/workflowTemplates').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'GET', - }, - options - ), - params, - requiredParams: ['parent'], - pathParams: ['parent'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - - /** - * dataproc.projects.locations.workflowTemplates.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Dataproc API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/dataproc - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var dataproc = google.dataproc('v1'); - * - * authorize(function(authClient) { - * var request = { - * // REQUIRED: The resource for which the policy is being specified. See the operation documentation for - * // the appropriate value for this field. - * resource_: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. - * - * resource: { - * // TODO: Add desired properties to the request body. - * }, - * - * auth: authClient, - * }; - * - * dataproc.projects.locations.workflowTemplates.setIamPolicy(request, function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); - * }); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias dataproc.projects.locations.workflowTemplates.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.resource_ REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. - * @param {().SetIamPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataproc.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1/{+resource}:setIamPolicy').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'POST', - }, - options - ), - params, - requiredParams: ['resource'], - pathParams: ['resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * dataproc.projects.locations.workflowTemplates.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may "fail open" without warning. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Dataproc API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/dataproc - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var dataproc = google.dataproc('v1'); - * - * authorize(function(authClient) { - * var request = { - * // REQUIRED: The resource for which the policy detail is being requested. See the operation - * // documentation for the appropriate value for this field. - * resource_: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. - * - * resource: { - * // TODO: Add desired properties to the request body. - * }, - * - * auth: authClient, - * }; - * - * dataproc.projects.locations.workflowTemplates.testIamPermissions(request, function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); - * }); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias dataproc.projects.locations.workflowTemplates.testIamPermissions - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.resource_ REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field. - * @param {().TestIamPermissionsRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - testIamPermissions( - params?: Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions, - options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions, - callback: BodyResponseCallback - ): void; - testIamPermissions( - callback: BodyResponseCallback - ): void; - testIamPermissions( - paramsOrCallback?: - | Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataproc.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1/{+resource}:testIamPermissions').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'POST', - }, - options - ), - params, - requiredParams: ['resource'], - pathParams: ['resource'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - - /** - * dataproc.projects.locations.workflowTemplates.update - * @desc Updates (replaces) workflow template. The updated template must contain version that matches the current server version. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Dataproc API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/dataproc - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var dataproc = google.dataproc('v1'); - * - * authorize(function(authClient) { - * var request = { - * // Output only. The "resource name" of the template, as described in - * // https://cloud.google.com/apis/design/resource_names of the form - * // projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - * name: 'projects/my-project/locations/my-location/workflowTemplates/my-workflow-template', // TODO: Update placeholder value. - * - * resource: { - * // TODO: Add desired properties to the request body. All existing properties - * // will be replaced. - * }, - * - * auth: authClient, - * }; - * - * dataproc.projects.locations.workflowTemplates.update(request, function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); - * }); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias dataproc.projects.locations.workflowTemplates.update - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.name Output only. The "resource name" of the template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - * @param {().WorkflowTemplate} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - update( - params?: Params$Resource$Projects$Locations$Workflowtemplates$Update, - options?: MethodOptions - ): GaxiosPromise; - update( - params: Params$Resource$Projects$Locations$Workflowtemplates$Update, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - update( - params: Params$Resource$Projects$Locations$Workflowtemplates$Update, - callback: BodyResponseCallback - ): void; - update(callback: BodyResponseCallback): void; - update( - paramsOrCallback?: - | Params$Resource$Projects$Locations$Workflowtemplates$Update - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Workflowtemplates$Update; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Update; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataproc.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), - method: 'PUT', - }, - options - ), - params, - requiredParams: ['name'], - pathParams: ['name'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Projects$Locations$Workflowtemplates$Create - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} - */ - parent?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$WorkflowTemplate; - } - export interface Params$Resource$Projects$Locations$Workflowtemplates$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - */ - name?: string; - /** - * Optional. The version of workflow template to delete. If specified, will only delete the template if the current server version matches specified version. - */ - version?: number; - } - export interface Params$Resource$Projects$Locations$Workflowtemplates$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - */ - name?: string; - /** - * Optional. The version of workflow template to retrieve. Only previously instatiated versions can be retrieved.If unspecified, retrieves the current version. - */ - version?: number; - } - export interface Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GetIamPolicyRequest; - } - export interface Params$Resource$Projects$Locations$Workflowtemplates$Instantiate - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - */ - name?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$InstantiateWorkflowTemplateRequest; - } - export interface Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Required. The "resource name" of the workflow template region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} - */ - parent?: string; - /** - * Optional. A tag that prevents multiple concurrent workflow instances with the same tag from running. This mitigates risk of concurrent instances started due to retries.It is recommended to always set this value to a UUID (https://en.wikipedia.org/wiki/Universally_unique_identifier).The tag must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters. - */ - requestId?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$WorkflowTemplate; - } - export interface Params$Resource$Projects$Locations$Workflowtemplates$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Optional. The maximum number of results to return in each response. - */ - pageSize?: number; - /** - * Optional. The page token, returned by a previous call, to request the next page of results. - */ - pageToken?: string; - /** - * Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} - */ - parent?: string; - } - export interface Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SetIamPolicyRequest; - } - export interface Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$TestIamPermissionsRequest; - } - export interface Params$Resource$Projects$Locations$Workflowtemplates$Update - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Output only. The "resource name" of the template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - */ - name?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$WorkflowTemplate; - } - - export class Resource$Projects$Regions { - context: APIRequestContext; - autoscalingPolicies: Resource$Projects$Regions$Autoscalingpolicies; - clusters: Resource$Projects$Regions$Clusters; - jobs: Resource$Projects$Regions$Jobs; - operations: Resource$Projects$Regions$Operations; - workflowTemplates: Resource$Projects$Regions$Workflowtemplates; - constructor(context: APIRequestContext) { - this.context = context; - this.autoscalingPolicies = new Resource$Projects$Regions$Autoscalingpolicies( - this.context - ); - this.clusters = new Resource$Projects$Regions$Clusters(this.context); - this.jobs = new Resource$Projects$Regions$Jobs(this.context); - this.operations = new Resource$Projects$Regions$Operations(this.context); - this.workflowTemplates = new Resource$Projects$Regions$Workflowtemplates( - this.context - ); - } - } - - export class Resource$Projects$Regions$Autoscalingpolicies { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * dataproc.projects.regions.autoscalingPolicies.getIamPolicy - * @desc Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Dataproc API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/dataproc - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var dataproc = google.dataproc('v1'); - * - * authorize(function(authClient) { - * var request = { - * // REQUIRED: The resource for which the policy is being requested. See the operation documentation for - * // the appropriate value for this field. - * resource_: 'projects/my-project/regions/my-region/autoscalingPolicies/my-autoscaling-policy', // TODO: Update placeholder value. - * - * resource: { - * // TODO: Add desired properties to the request body. - * }, - * - * auth: authClient, - * }; - * - * dataproc.projects.regions.autoscalingPolicies.getIamPolicy(request, function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); - * }); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias dataproc.projects.regions.autoscalingPolicies.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. - * @param {().GetIamPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Projects$Regions$Autoscalingpolicies$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Projects$Regions$Autoscalingpolicies$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Projects$Regions$Autoscalingpolicies$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Projects$Regions$Autoscalingpolicies$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Regions$Autoscalingpolicies$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Regions$Autoscalingpolicies$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataproc.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1/{+resource}:getIamPolicy').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'POST', - }, - options - ), - params, - requiredParams: ['resource'], - pathParams: ['resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * dataproc.projects.regions.autoscalingPolicies.setIamPolicy - * @desc Sets the access control policy on the specified resource. Replaces any existing policy. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Dataproc API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/dataproc - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var dataproc = google.dataproc('v1'); - * - * authorize(function(authClient) { - * var request = { - * // REQUIRED: The resource for which the policy is being specified. See the operation documentation for - * // the appropriate value for this field. - * resource_: 'projects/my-project/regions/my-region/autoscalingPolicies/my-autoscaling-policy', // TODO: Update placeholder value. - * - * resource: { - * // TODO: Add desired properties to the request body. - * }, - * - * auth: authClient, - * }; - * - * dataproc.projects.regions.autoscalingPolicies.setIamPolicy(request, function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); - * }); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias dataproc.projects.regions.autoscalingPolicies.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.resource_ REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. - * @param {().SetIamPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Projects$Regions$Autoscalingpolicies$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Projects$Regions$Autoscalingpolicies$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Projects$Regions$Autoscalingpolicies$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Projects$Regions$Autoscalingpolicies$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Regions$Autoscalingpolicies$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Regions$Autoscalingpolicies$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://dataproc.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1/{+resource}:setIamPolicy').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'POST', - }, - options - ), - params, - requiredParams: ['resource'], - pathParams: ['resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * dataproc.projects.regions.autoscalingPolicies.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may "fail open" without warning. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Dataproc API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/dataproc - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var dataproc = google.dataproc('v1'); - * - * authorize(function(authClient) { - * var request = { - * // REQUIRED: The resource for which the policy detail is being requested. See the operation - * // documentation for the appropriate value for this field. - * resource_: 'projects/my-project/regions/my-region/autoscalingPolicies/my-autoscaling-policy', // TODO: Update placeholder value. - * - * resource: { - * // TODO: Add desired properties to the request body. - * }, - * - * auth: authClient, - * }; - * - * dataproc.projects.regions.autoscalingPolicies.testIamPermissions(request, function(err, response) { + * dataproc.projects.locations.workflowTemplates.update(request, function(err, response) { * if (err) { * console.error(err); * return; @@ -3638,50 +2662,46 @@ export namespace dataproc_v1 { * console.error('authentication failed: ', err); * }); * } - * @alias dataproc.projects.regions.autoscalingPolicies.testIamPermissions + * @alias dataproc.projects.locations.workflowTemplates.update * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.resource_ REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field. - * @param {().TestIamPermissionsRequest} params.resource Request body data + * @param {string} params.name Output only. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} + * @param {().WorkflowTemplate} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - testIamPermissions( - params?: Params$Resource$Projects$Regions$Autoscalingpolicies$Testiampermissions, + update( + params?: Params$Resource$Projects$Locations$Workflowtemplates$Update, options?: MethodOptions - ): GaxiosPromise; - testIamPermissions( - params: Params$Resource$Projects$Regions$Autoscalingpolicies$Testiampermissions, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - testIamPermissions( - params: Params$Resource$Projects$Regions$Autoscalingpolicies$Testiampermissions, - callback: BodyResponseCallback + ): GaxiosPromise; + update( + params: Params$Resource$Projects$Locations$Workflowtemplates$Update, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback ): void; - testIamPermissions( - callback: BodyResponseCallback + update( + params: Params$Resource$Projects$Locations$Workflowtemplates$Update, + callback: BodyResponseCallback ): void; - testIamPermissions( + update(callback: BodyResponseCallback): void; + update( paramsOrCallback?: - | Params$Resource$Projects$Regions$Autoscalingpolicies$Testiampermissions - | BodyResponseCallback, + | Params$Resource$Projects$Locations$Workflowtemplates$Update + | BodyResponseCallback, optionsOrCallback?: | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Regions$Autoscalingpolicies$Testiampermissions; + {}) as Params$Resource$Projects$Locations$Workflowtemplates$Update; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Regions$Autoscalingpolicies$Testiampermissions; + params = {} as Params$Resource$Projects$Locations$Workflowtemplates$Update; options = {}; } @@ -3694,31 +2714,74 @@ export namespace dataproc_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+resource}:testIamPermissions').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'POST', + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'PUT', }, options ), params, - requiredParams: ['resource'], - pathParams: ['resource'], + requiredParams: ['name'], + pathParams: ['name'], context: this.context, }; if (callback) { - createAPIRequest( - parameters, - callback - ); + createAPIRequest(parameters, callback); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } } - export interface Params$Resource$Projects$Regions$Autoscalingpolicies$Getiampolicy + export interface Params$Resource$Projects$Locations$Workflowtemplates$Create + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,create, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.create, the resource name of the location has the following format: projects/{project_id}/locations/{location} + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$WorkflowTemplate; + } + export interface Params$Resource$Projects$Locations$Workflowtemplates$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.delete, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} + */ + name?: string; + /** + * Optional. The version of workflow template to delete. If specified, will only delete the template if the current server version matches specified version. + */ + version?: number; + } + export interface Params$Resource$Projects$Locations$Workflowtemplates$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} + */ + name?: string; + /** + * Optional. The version of workflow template to retrieve. Only previously instantiated versions can be retrieved.If unspecified, retrieves the current version. + */ + version?: number; + } + export interface Params$Resource$Projects$Locations$Workflowtemplates$Getiampolicy extends StandardParameters { /** * Auth client or API Key for the request @@ -3735,7 +2798,65 @@ export namespace dataproc_v1 { */ requestBody?: Schema$GetIamPolicyRequest; } - export interface Params$Resource$Projects$Regions$Autoscalingpolicies$Setiampolicy + export interface Params$Resource$Projects$Locations$Workflowtemplates$Instantiate + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} + */ + name?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$InstantiateWorkflowTemplateRequest; + } + export interface Params$Resource$Projects$Locations$Workflowtemplates$Instantiateinline + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,instantiateinline, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.instantiateinline, the resource name of the location has the following format: projects/{project_id}/locations/{location} + */ + parent?: string; + /** + * Optional. A tag that prevents multiple concurrent workflow instances with the same tag from running. This mitigates risk of concurrent instances started due to retries.It is recommended to always set this value to a UUID (https://en.wikipedia.org/wiki/Universally_unique_identifier).The tag must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters. + */ + requestId?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$WorkflowTemplate; + } + export interface Params$Resource$Projects$Locations$Workflowtemplates$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Optional. The maximum number of results to return in each response. + */ + pageSize?: number; + /** + * Optional. The page token, returned by a previous call, to request the next page of results. + */ + pageToken?: string; + /** + * Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.list, the resource name of the location has the following format: projects/{project_id}/locations/{location} + */ + parent?: string; + } + export interface Params$Resource$Projects$Locations$Workflowtemplates$Setiampolicy extends StandardParameters { /** * Auth client or API Key for the request @@ -3752,7 +2873,7 @@ export namespace dataproc_v1 { */ requestBody?: Schema$SetIamPolicyRequest; } - export interface Params$Resource$Projects$Regions$Autoscalingpolicies$Testiampermissions + export interface Params$Resource$Projects$Locations$Workflowtemplates$Testiampermissions extends StandardParameters { /** * Auth client or API Key for the request @@ -3769,6 +2890,40 @@ export namespace dataproc_v1 { */ requestBody?: Schema$TestIamPermissionsRequest; } + export interface Params$Resource$Projects$Locations$Workflowtemplates$Update + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Output only. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} + */ + name?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$WorkflowTemplate; + } + + export class Resource$Projects$Regions { + context: APIRequestContext; + clusters: Resource$Projects$Regions$Clusters; + jobs: Resource$Projects$Regions$Jobs; + operations: Resource$Projects$Regions$Operations; + workflowTemplates: Resource$Projects$Regions$Workflowtemplates; + constructor(context: APIRequestContext) { + this.context = context; + this.clusters = new Resource$Projects$Regions$Clusters(this.context); + this.jobs = new Resource$Projects$Regions$Jobs(this.context); + this.operations = new Resource$Projects$Regions$Operations(this.context); + this.workflowTemplates = new Resource$Projects$Regions$Workflowtemplates( + this.context + ); + } + } export class Resource$Projects$Regions$Clusters { context: APIRequestContext; @@ -3778,7 +2933,7 @@ export namespace dataproc_v1 { /** * dataproc.projects.regions.clusters.create - * @desc Creates a cluster in a project. + * @desc Creates a cluster in a project. The returned Operation.metadata will be ClusterOperationMetadata. * @example * * // BEFORE RUNNING: * // --------------- @@ -3907,7 +3062,7 @@ export namespace dataproc_v1 { /** * dataproc.projects.regions.clusters.delete - * @desc Deletes a cluster in a project. + * @desc Deletes a cluster in a project. The returned Operation.metadata will be ClusterOperationMetadata. * @example * * // BEFORE RUNNING: * // --------------- @@ -4037,7 +3192,7 @@ export namespace dataproc_v1 { /** * dataproc.projects.regions.clusters.diagnose - * @desc Gets cluster diagnostic information. After the operation completes, the Operation.response field contains DiagnoseClusterOutputLocation. + * @desc Gets cluster diagnostic information. The returned Operation.metadata will be ClusterOperationMetadata. After the operation completes, Operation.response contains DiagnoseClusterResults. * @example * * // BEFORE RUNNING: * // --------------- @@ -4561,7 +3716,7 @@ export namespace dataproc_v1 { /** * dataproc.projects.regions.clusters.patch - * @desc Updates a cluster in a project. + * @desc Updates a cluster in a project. The returned Operation.metadata will be ClusterOperationMetadata. * @example * * // BEFORE RUNNING: * // --------------- @@ -7578,7 +6733,7 @@ export namespace dataproc_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * @param {string} params.parent Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,create, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.create, the resource name of the location has the following format: projects/{project_id}/locations/{location} * @param {().WorkflowTemplate} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -7698,7 +6853,7 @@ export namespace dataproc_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * @param {string} params.name Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.delete, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} * @param {integer=} params.version Optional. The version of workflow template to delete. If specified, will only delete the template if the current server version matches specified version. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -7816,8 +6971,8 @@ export namespace dataproc_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - * @param {integer=} params.version Optional. The version of workflow template to retrieve. Only previously instatiated versions can be retrieved.If unspecified, retrieves the current version. + * @param {string} params.name Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} + * @param {integer=} params.version Optional. The version of workflow template to retrieve. Only previously instantiated versions can be retrieved.If unspecified, retrieves the current version. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -8007,7 +7162,7 @@ export namespace dataproc_v1 { /** * dataproc.projects.regions.workflowTemplates.instantiate - * @desc Instantiates a template and begins execution.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata.On successful completion, Operation.response will be Empty. + * @desc Instantiates a template and begins execution.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata. Also see Using WorkflowMetadata.On successful completion, Operation.response will be Empty. * @example * * // BEFORE RUNNING: * // --------------- @@ -8064,7 +7219,7 @@ export namespace dataproc_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * @param {string} params.name Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} * @param {().InstantiateWorkflowTemplateRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -8134,7 +7289,7 @@ export namespace dataproc_v1 { /** * dataproc.projects.regions.workflowTemplates.instantiateInline - * @desc Instantiates a template and begins execution.This method is equivalent to executing the sequence CreateWorkflowTemplate, InstantiateWorkflowTemplate, DeleteWorkflowTemplate.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata.On successful completion, Operation.response will be Empty. + * @desc Instantiates a template and begins execution.This method is equivalent to executing the sequence CreateWorkflowTemplate, InstantiateWorkflowTemplate, DeleteWorkflowTemplate.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata. Also see Using WorkflowMetadata.On successful completion, Operation.response will be Empty. * @example * * // BEFORE RUNNING: * // --------------- @@ -8191,7 +7346,7 @@ export namespace dataproc_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The "resource name" of the workflow template region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * @param {string} params.parent Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,instantiateinline, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.instantiateinline, the resource name of the location has the following format: projects/{project_id}/locations/{location} * @param {string=} params.requestId Optional. A tag that prevents multiple concurrent workflow instances with the same tag from running. This mitigates risk of concurrent instances started due to retries.It is recommended to always set this value to a UUID (https://en.wikipedia.org/wiki/Universally_unique_identifier).The tag must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters. * @param {().WorkflowTemplate} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. @@ -8329,7 +7484,7 @@ export namespace dataproc_v1 { * @param {object} params Parameters for request * @param {integer=} params.pageSize Optional. The maximum number of results to return in each response. * @param {string=} params.pageToken Optional. The page token, returned by a previous call, to request the next page of results. - * @param {string} params.parent Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * @param {string} params.parent Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.list, the resource name of the location has the following format: projects/{project_id}/locations/{location} * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -8722,7 +7877,7 @@ export namespace dataproc_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Output only. The "resource name" of the template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * @param {string} params.name Output only. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} * @param {().WorkflowTemplate} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -8796,7 +7951,7 @@ export namespace dataproc_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,create, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.create, the resource name of the location has the following format: projects/{project_id}/locations/{location} */ parent?: string; @@ -8813,7 +7968,7 @@ export namespace dataproc_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.delete, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; /** @@ -8829,11 +7984,11 @@ export namespace dataproc_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; /** - * Optional. The version of workflow template to retrieve. Only previously instatiated versions can be retrieved.If unspecified, retrieves the current version. + * Optional. The version of workflow template to retrieve. Only previously instantiated versions can be retrieved.If unspecified, retrieves the current version. */ version?: number; } @@ -8862,7 +8017,7 @@ export namespace dataproc_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; @@ -8879,7 +8034,7 @@ export namespace dataproc_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the workflow template region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,instantiateinline, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.instantiateinline, the resource name of the location has the following format: projects/{project_id}/locations/{location} */ parent?: string; /** @@ -8908,7 +8063,7 @@ export namespace dataproc_v1 { */ pageToken?: string; /** - * Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.list, the resource name of the location has the following format: projects/{project_id}/locations/{location} */ parent?: string; } @@ -8954,7 +8109,7 @@ export namespace dataproc_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Output only. The "resource name" of the template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Output only. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; diff --git a/src/apis/dataproc/v1beta2.ts b/src/apis/dataproc/v1beta2.ts index 134c52809b3..30a3b6e625c 100644 --- a/src/apis/dataproc/v1beta2.ts +++ b/src/apis/dataproc/v1beta2.ts @@ -149,7 +149,7 @@ export namespace dataproc_v1beta2 { */ id?: string; /** - * Output only. The "resource name" of the policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * Output only. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} */ name?: string; /** @@ -208,7 +208,7 @@ export namespace dataproc_v1beta2 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. members can have the following values: allUsers: A special identifier that represents anyone who is on the internet; with or without a Google account. allAuthenticatedUsers: A special identifier that represents anyone who is authenticated with a Google account or a service account. user:{emailid}: An email address that represents a specific Google account. For example, alice@gmail.com . serviceAccount:{emailid}: An email address that represents a service account. For example, my-other-app@appspot.gserviceaccount.com. group:{emailid}: An email address that represents a Google group. For example, admins@example.com. domain:{domain}: The G Suite domain (primary) that represents all the users of that domain. For example, google.com or example.com. + * Specifies the identities requesting access for a Cloud Platform resource. members can have the following values: allUsers: A special identifier that represents anyone who is on the internet; with or without a Google account. allAuthenticatedUsers: A special identifier that represents anyone who is authenticated with a Google account or a service account. user:{emailid}: An email address that represents a specific Google account. For example, alice@example.com . serviceAccount:{emailid}: An email address that represents a service account. For example, my-other-app@appspot.gserviceaccount.com. group:{emailid}: An email address that represents a Google group. For example, admins@example.com. domain:{domain}: The G Suite domain (primary) that represents all the users of that domain. For example, google.com or example.com. */ members?: string[]; /** @@ -553,7 +553,21 @@ export namespace dataproc_v1beta2 { /** * Request message for GetIamPolicy method. */ - export interface Schema$GetIamPolicyRequest {} + export interface Schema$GetIamPolicyRequest { + /** + * OPTIONAL: A GetPolicyOptions object for specifying options to GetIamPolicy. This field is only used by Cloud IAM. + */ + options?: Schema$GetPolicyOptions; + } + /** + * Encapsulates settings provided to GetIamPolicy. + */ + export interface Schema$GetPolicyOptions { + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + requestedPolicyVersion?: number; + } /** * A Cloud Dataproc job for running Apache Hadoop MapReduce (https://hadoop.apache.org/docs/current/hadoop-mapreduce-client/hadoop-mapreduce-client-core/MapReduceTutorial.html) jobs on Apache Hadoop YARN (https://hadoop.apache.org/docs/r2.7.1/hadoop-yarn/hadoop-yarn-site/YARN.html). */ @@ -880,6 +894,10 @@ export namespace dataproc_v1beta2 { * Required. The uri of the KMS key used to encrypt various sensitive files. */ kmsKeyUri?: string; + /** + * Optional. The name of the on-cluster Kerberos realm. If not specified, the uppercased domain of hostnames will be the realm. + */ + realm?: string; /** * Required. The Cloud Storage URI of a KMS encrypted file containing the root principal password. */ @@ -913,6 +931,10 @@ export namespace dataproc_v1beta2 { * Optional. The duration to keep the cluster alive while idling. Passing this threshold will cause the cluster to be deleted. Valid range: 10m, 14d.Example: "10m", the minimum value, to delete the cluster when it has had no jobs running for 10 minutes. */ idleDeleteTtl?: string; + /** + * Output only. The time when cluster became idle (most recent job finished) and became eligible for deletion due to idleness. + */ + idleStartTime?: string; } /** * A response to a request to list autoscaling policies in a project. @@ -1156,7 +1178,7 @@ export namespace dataproc_v1beta2 { */ bindings?: Schema$Binding[]; /** - * etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the etag in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An etag is returned in the response to getIamPolicy, and systems are expected to put that etag in the request to setIamPolicy to ensure that their change will be applied to the same version of the policy.If no etag is provided in the call to setIamPolicy, then the existing policy is overwritten blindly. + * etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the etag in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An etag is returned in the response to getIamPolicy, and systems are expected to put that etag in the request to setIamPolicy to ensure that their change will be applied to the same version of the policy.If no etag is provided in the call to setIamPolicy, then the existing policy is overwritten. */ etag?: string; /** @@ -1527,7 +1549,7 @@ export namespace dataproc_v1beta2 { */ state?: string; /** - * Output only. The "resource name" of the template. + * Output only. The resource name of the workflow template as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ template?: string; /** @@ -1581,7 +1603,7 @@ export namespace dataproc_v1beta2 { */ labels?: {[key: string]: string}; /** - * Output only. The "resource name" of the template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Output only. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; /** @@ -1675,7 +1697,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}. + * @param {string} params.parent Required. The "resource name" of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.create, the resource name has the following format: projects/{project_id}/regions/{region} For projects.locations.autoscalingPolicies.create, the resource name has the following format: projects/{project_id}/locations/{location} * @param {().AutoscalingPolicy} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1750,7 +1772,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * @param {string} params.name Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.delete, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies.delete, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1819,7 +1841,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * @param {string} params.name Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.get, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies.get, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1890,6 +1912,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1964,7 +1987,7 @@ export namespace dataproc_v1beta2 { * @param {object} params Parameters for request * @param {integer=} params.pageSize Optional. The maximum number of results to return in each response. Must be less than or equal to 1000. Defaults to 100. * @param {string=} params.pageToken Optional. The page token, returned by a previous call, to request the next page of results. - * @param {string} params.parent Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * @param {string} params.parent Required. The "resource name" of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.autoscalingPolicies.list, the resource name of the location has the following format: projects/{project_id}/locations/{location} * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2202,7 +2225,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Output only. The "resource name" of the policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * @param {string} params.name Output only. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} * @param {().AutoscalingPolicy} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2276,7 +2299,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}. + * Required. The "resource name" of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.create, the resource name has the following format: projects/{project_id}/regions/{region} For projects.locations.autoscalingPolicies.create, the resource name has the following format: projects/{project_id}/locations/{location} */ parent?: string; @@ -2293,7 +2316,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.delete, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies.delete, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} */ name?: string; } @@ -2305,7 +2328,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.get, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies.get, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} */ name?: string; } @@ -2316,6 +2339,10 @@ export namespace dataproc_v1beta2 { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + 'options.requestedPolicyVersion'?: number; /** * REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. */ @@ -2337,7 +2364,7 @@ export namespace dataproc_v1beta2 { */ pageToken?: string; /** - * Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * Required. The "resource name" of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.autoscalingPolicies.list, the resource name of the location has the following format: projects/{project_id}/locations/{location} */ parent?: string; } @@ -2383,7 +2410,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Output only. The "resource name" of the policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * Output only. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} */ name?: string; @@ -2406,7 +2433,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * @param {string} params.parent Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,create, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.create, the resource name of the location has the following format: projects/{project_id}/locations/{location} * @param {().WorkflowTemplate} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2481,7 +2508,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * @param {string} params.name Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.delete, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} * @param {integer=} params.version Optional. The version of workflow template to delete. If specified, will only delete the template if the current server version matches specified version. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2551,8 +2578,8 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - * @param {integer=} params.version Optional. The version of workflow template to retrieve. Only previously instatiated versions can be retrieved.If unspecified, retrieves the current version. + * @param {string} params.name Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} + * @param {integer=} params.version Optional. The version of workflow template to retrieve. Only previously instantiated versions can be retrieved.If unspecified, retrieves the current version. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2623,6 +2650,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2690,12 +2718,12 @@ export namespace dataproc_v1beta2 { /** * dataproc.projects.locations.workflowTemplates.instantiate - * @desc Instantiates a template and begins execution.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata.On successful completion, Operation.response will be Empty. + * @desc Instantiates a template and begins execution.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata. Also see Using WorkflowMetadata.On successful completion, Operation.response will be Empty. * @alias dataproc.projects.locations.workflowTemplates.instantiate * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * @param {string} params.name Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} * @param {().InstantiateWorkflowTemplateRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2765,13 +2793,13 @@ export namespace dataproc_v1beta2 { /** * dataproc.projects.locations.workflowTemplates.instantiateInline - * @desc Instantiates a template and begins execution.This method is equivalent to executing the sequence CreateWorkflowTemplate, InstantiateWorkflowTemplate, DeleteWorkflowTemplate.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata.On successful completion, Operation.response will be Empty. + * @desc Instantiates a template and begins execution.This method is equivalent to executing the sequence CreateWorkflowTemplate, InstantiateWorkflowTemplate, DeleteWorkflowTemplate.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata. Also see Using WorkflowMetadata.On successful completion, Operation.response will be Empty. * @alias dataproc.projects.locations.workflowTemplates.instantiateInline * @memberOf! () * * @param {object} params Parameters for request * @param {string=} params.instanceId Deprecated. Please use request_id field instead. - * @param {string} params.parent Required. The "resource name" of the workflow template region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * @param {string} params.parent Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,instantiateinline, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.instantiateinline, the resource name of the location has the following format: projects/{project_id}/locations/{location} * @param {string=} params.requestId Optional. A tag that prevents multiple concurrent workflow instances with the same tag from running. This mitigates risk of concurrent instances started due to retries.It is recommended to always set this value to a UUID (https://en.wikipedia.org/wiki/Universally_unique_identifier).The tag must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters. * @param {().WorkflowTemplate} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. @@ -2848,7 +2876,7 @@ export namespace dataproc_v1beta2 { * @param {object} params Parameters for request * @param {integer=} params.pageSize Optional. The maximum number of results to return in each response. * @param {string=} params.pageToken Optional. The page token, returned by a previous call, to request the next page of results. - * @param {string} params.parent Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * @param {string} params.parent Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.list, the resource name of the location has the following format: projects/{project_id}/locations/{location} * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -3086,7 +3114,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Output only. The "resource name" of the template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * @param {string} params.name Output only. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} * @param {().WorkflowTemplate} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3160,7 +3188,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,create, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.create, the resource name of the location has the following format: projects/{project_id}/locations/{location} */ parent?: string; @@ -3177,7 +3205,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.delete, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; /** @@ -3193,11 +3221,11 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; /** - * Optional. The version of workflow template to retrieve. Only previously instatiated versions can be retrieved.If unspecified, retrieves the current version. + * Optional. The version of workflow template to retrieve. Only previously instantiated versions can be retrieved.If unspecified, retrieves the current version. */ version?: number; } @@ -3208,6 +3236,10 @@ export namespace dataproc_v1beta2 { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + 'options.requestedPolicyVersion'?: number; /** * REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. */ @@ -3221,7 +3253,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; @@ -3242,7 +3274,7 @@ export namespace dataproc_v1beta2 { */ instanceId?: string; /** - * Required. The "resource name" of the workflow template region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,instantiateinline, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.instantiateinline, the resource name of the location has the following format: projects/{project_id}/locations/{location} */ parent?: string; /** @@ -3271,7 +3303,7 @@ export namespace dataproc_v1beta2 { */ pageToken?: string; /** - * Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.list, the resource name of the location has the following format: projects/{project_id}/locations/{location} */ parent?: string; } @@ -3317,7 +3349,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Output only. The "resource name" of the template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Output only. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; @@ -3361,7 +3393,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}. + * @param {string} params.parent Required. The "resource name" of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.create, the resource name has the following format: projects/{project_id}/regions/{region} For projects.locations.autoscalingPolicies.create, the resource name has the following format: projects/{project_id}/locations/{location} * @param {().AutoscalingPolicy} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3436,7 +3468,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * @param {string} params.name Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.delete, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies.delete, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -3505,7 +3537,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * @param {string} params.name Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.get, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies.get, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -3576,6 +3608,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3650,7 +3683,7 @@ export namespace dataproc_v1beta2 { * @param {object} params Parameters for request * @param {integer=} params.pageSize Optional. The maximum number of results to return in each response. Must be less than or equal to 1000. Defaults to 100. * @param {string=} params.pageToken Optional. The page token, returned by a previous call, to request the next page of results. - * @param {string} params.parent Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * @param {string} params.parent Required. The "resource name" of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.autoscalingPolicies.list, the resource name of the location has the following format: projects/{project_id}/locations/{location} * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -3888,7 +3921,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Output only. The "resource name" of the policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * @param {string} params.name Output only. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} * @param {().AutoscalingPolicy} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3962,7 +3995,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}. + * Required. The "resource name" of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.create, the resource name has the following format: projects/{project_id}/regions/{region} For projects.locations.autoscalingPolicies.create, the resource name has the following format: projects/{project_id}/locations/{location} */ parent?: string; @@ -3979,7 +4012,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.delete, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies.delete, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} */ name?: string; } @@ -3991,7 +4024,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.get, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies.get, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} */ name?: string; } @@ -4002,6 +4035,10 @@ export namespace dataproc_v1beta2 { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + 'options.requestedPolicyVersion'?: number; /** * REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. */ @@ -4023,7 +4060,7 @@ export namespace dataproc_v1beta2 { */ pageToken?: string; /** - * Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * Required. The "resource name" of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies.list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.autoscalingPolicies.list, the resource name of the location has the following format: projects/{project_id}/locations/{location} */ parent?: string; } @@ -4069,7 +4106,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Output only. The "resource name" of the policy, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}. + * Output only. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.autoscalingPolicies, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id} For projects.locations.autoscalingPolicies, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id} */ name?: string; @@ -4087,7 +4124,7 @@ export namespace dataproc_v1beta2 { /** * dataproc.projects.regions.clusters.create - * @desc Creates a cluster in a project. + * @desc Creates a cluster in a project. The returned Operation.metadata will be ClusterOperationMetadata. * @alias dataproc.projects.regions.clusters.create * @memberOf! () * @@ -4164,7 +4201,7 @@ export namespace dataproc_v1beta2 { /** * dataproc.projects.regions.clusters.delete - * @desc Deletes a cluster in a project. + * @desc Deletes a cluster in a project. The returned Operation.metadata will be ClusterOperationMetadata. * @alias dataproc.projects.regions.clusters.delete * @memberOf! () * @@ -4242,7 +4279,7 @@ export namespace dataproc_v1beta2 { /** * dataproc.projects.regions.clusters.diagnose - * @desc Gets cluster diagnostic information. After the operation completes, the Operation.response field contains DiagnoseClusterOutputLocation. + * @desc Gets cluster diagnostic information. The returned Operation.metadata will be ClusterOperationMetadata. After the operation completes, Operation.response contains DiagnoseClusterResults. * @alias dataproc.projects.regions.clusters.diagnose * @memberOf! () * @@ -4398,6 +4435,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -4545,7 +4583,7 @@ export namespace dataproc_v1beta2 { /** * dataproc.projects.regions.clusters.patch - * @desc Updates a cluster in a project. + * @desc Updates a cluster in a project. The returned Operation.metadata will be ClusterOperationMetadata. * @alias dataproc.projects.regions.clusters.patch * @memberOf! () * @@ -4884,6 +4922,10 @@ export namespace dataproc_v1beta2 { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + 'options.requestedPolicyVersion'?: number; /** * REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. */ @@ -5225,6 +5267,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -5747,6 +5790,10 @@ export namespace dataproc_v1beta2 { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + 'options.requestedPolicyVersion'?: number; /** * REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. */ @@ -6098,6 +6145,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -6438,6 +6486,10 @@ export namespace dataproc_v1beta2 { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + 'options.requestedPolicyVersion'?: number; /** * REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. */ @@ -6515,7 +6567,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * @param {string} params.parent Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,create, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.create, the resource name of the location has the following format: projects/{project_id}/locations/{location} * @param {().WorkflowTemplate} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -6590,7 +6642,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * @param {string} params.name Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.delete, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} * @param {integer=} params.version Optional. The version of workflow template to delete. If specified, will only delete the template if the current server version matches specified version. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -6660,8 +6712,8 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} - * @param {integer=} params.version Optional. The version of workflow template to retrieve. Only previously instatiated versions can be retrieved.If unspecified, retrieves the current version. + * @param {string} params.name Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} + * @param {integer=} params.version Optional. The version of workflow template to retrieve. Only previously instantiated versions can be retrieved.If unspecified, retrieves the current version. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -6732,6 +6784,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -6799,12 +6852,12 @@ export namespace dataproc_v1beta2 { /** * dataproc.projects.regions.workflowTemplates.instantiate - * @desc Instantiates a template and begins execution.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata.On successful completion, Operation.response will be Empty. + * @desc Instantiates a template and begins execution.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata. Also see Using WorkflowMetadata.On successful completion, Operation.response will be Empty. * @alias dataproc.projects.regions.workflowTemplates.instantiate * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * @param {string} params.name Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} * @param {().InstantiateWorkflowTemplateRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -6874,13 +6927,13 @@ export namespace dataproc_v1beta2 { /** * dataproc.projects.regions.workflowTemplates.instantiateInline - * @desc Instantiates a template and begins execution.This method is equivalent to executing the sequence CreateWorkflowTemplate, InstantiateWorkflowTemplate, DeleteWorkflowTemplate.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata.On successful completion, Operation.response will be Empty. + * @desc Instantiates a template and begins execution.This method is equivalent to executing the sequence CreateWorkflowTemplate, InstantiateWorkflowTemplate, DeleteWorkflowTemplate.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata. Also see Using WorkflowMetadata.On successful completion, Operation.response will be Empty. * @alias dataproc.projects.regions.workflowTemplates.instantiateInline * @memberOf! () * * @param {object} params Parameters for request * @param {string=} params.instanceId Deprecated. Please use request_id field instead. - * @param {string} params.parent Required. The "resource name" of the workflow template region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * @param {string} params.parent Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,instantiateinline, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.instantiateinline, the resource name of the location has the following format: projects/{project_id}/locations/{location} * @param {string=} params.requestId Optional. A tag that prevents multiple concurrent workflow instances with the same tag from running. This mitigates risk of concurrent instances started due to retries.It is recommended to always set this value to a UUID (https://en.wikipedia.org/wiki/Universally_unique_identifier).The tag must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters. * @param {().WorkflowTemplate} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. @@ -6957,7 +7010,7 @@ export namespace dataproc_v1beta2 { * @param {object} params Parameters for request * @param {integer=} params.pageSize Optional. The maximum number of results to return in each response. * @param {string=} params.pageToken Optional. The page token, returned by a previous call, to request the next page of results. - * @param {string} params.parent Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * @param {string} params.parent Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.list, the resource name of the location has the following format: projects/{project_id}/locations/{location} * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -7195,7 +7248,7 @@ export namespace dataproc_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Output only. The "resource name" of the template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * @param {string} params.name Output only. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} * @param {().WorkflowTemplate} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -7269,7 +7322,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,create, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.create, the resource name of the location has the following format: projects/{project_id}/locations/{location} */ parent?: string; @@ -7286,7 +7339,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.delete, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; /** @@ -7302,11 +7355,11 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; /** - * Optional. The version of workflow template to retrieve. Only previously instatiated versions can be retrieved.If unspecified, retrieves the current version. + * Optional. The version of workflow template to retrieve. Only previously instantiated versions can be retrieved.If unspecified, retrieves the current version. */ version?: number; } @@ -7317,6 +7370,10 @@ export namespace dataproc_v1beta2 { */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + 'options.requestedPolicyVersion'?: number; /** * REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. */ @@ -7330,7 +7387,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The "resource name" of the workflow template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; @@ -7351,7 +7408,7 @@ export namespace dataproc_v1beta2 { */ instanceId?: string; /** - * Required. The "resource name" of the workflow template region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,instantiateinline, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.instantiateinline, the resource name of the location has the following format: projects/{project_id}/locations/{location} */ parent?: string; /** @@ -7380,7 +7437,7 @@ export namespace dataproc_v1beta2 { */ pageToken?: string; /** - * Required. The "resource name" of the region, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region} + * Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.list, the resource name of the location has the following format: projects/{project_id}/locations/{location} */ parent?: string; } @@ -7426,7 +7483,7 @@ export namespace dataproc_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Output only. The "resource name" of the template, as described in https://cloud.google.com/apis/design/resource_names of the form projects/{project_id}/regions/{region}/workflowTemplates/{template_id} + * Output only. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id} */ name?: string; diff --git a/src/apis/datastore/v1.ts b/src/apis/datastore/v1.ts index d8744b28dbc..af93cd071e4 100644 --- a/src/apis/datastore/v1.ts +++ b/src/apis/datastore/v1.ts @@ -608,7 +608,7 @@ export namespace datastore_v1 { */ metadata?: {[key: string]: any}; /** - * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should have the format of `operations/some/unique/name`. + * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. */ name?: string; /** @@ -1000,7 +1000,7 @@ export namespace datastore_v1 { query?: Schema$Query; } /** - * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). The error model is designed to be: - Simple to use and understand for most users - Flexible enough to meet unexpected needs # Overview The `Status` message contains three pieces of data: error code, error message, and error details. The error code should be an enum value of google.rpc.Code, but it may accept additional error codes if needed. The error message should be a developer-facing English message that helps developers *understand* and *resolve* the error. If a localized user-facing error message is needed, put the localized message in the error details or localize it in the client. The optional error details may contain arbitrary information about the error. There is a predefined set of error detail types in the package `google.rpc` that can be used for common error conditions. # Language mapping The `Status` message is the logical representation of the error model, but it is not necessarily the actual wire format. When the `Status` message is exposed in different client libraries and different wire protocols, it can be mapped differently. For example, it will likely be mapped to some exceptions in Java, but more likely mapped to some error codes in C. # Other uses The error model and the `Status` message can be used in a variety of environments, either with or without APIs, to provide a consistent developer experience across different environments. Example uses of this error model include: - Partial errors. If a service needs to return partial errors to the client, it may embed the `Status` in the normal response to indicate the partial errors. - Workflow errors. A typical workflow has multiple steps. Each step may have a `Status` message for error reporting. - Batch operations. If a client uses batch request and batch response, the `Status` message should be used directly inside batch response, one for each error sub-response. - Asynchronous operations. If an API call embeds asynchronous operation results in its response, the status of those operations should be represented directly using the `Status` message. - Logging. If some API errors are stored in logs, the message `Status` could be used directly after any stripping needed for security/privacy reasons. + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). */ export interface Schema$Status { /** diff --git a/src/apis/datastore/v1beta1.ts b/src/apis/datastore/v1beta1.ts index c3482905651..bb73a73d96b 100644 --- a/src/apis/datastore/v1beta1.ts +++ b/src/apis/datastore/v1beta1.ts @@ -405,7 +405,7 @@ export namespace datastore_v1beta1 { */ metadata?: {[key: string]: any}; /** - * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should have the format of `operations/some/unique/name`. + * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. */ name?: string; /** @@ -414,7 +414,7 @@ export namespace datastore_v1beta1 { response?: {[key: string]: any}; } /** - * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). The error model is designed to be: - Simple to use and understand for most users - Flexible enough to meet unexpected needs # Overview The `Status` message contains three pieces of data: error code, error message, and error details. The error code should be an enum value of google.rpc.Code, but it may accept additional error codes if needed. The error message should be a developer-facing English message that helps developers *understand* and *resolve* the error. If a localized user-facing error message is needed, put the localized message in the error details or localize it in the client. The optional error details may contain arbitrary information about the error. There is a predefined set of error detail types in the package `google.rpc` that can be used for common error conditions. # Language mapping The `Status` message is the logical representation of the error model, but it is not necessarily the actual wire format. When the `Status` message is exposed in different client libraries and different wire protocols, it can be mapped differently. For example, it will likely be mapped to some exceptions in Java, but more likely mapped to some error codes in C. # Other uses The error model and the `Status` message can be used in a variety of environments, either with or without APIs, to provide a consistent developer experience across different environments. Example uses of this error model include: - Partial errors. If a service needs to return partial errors to the client, it may embed the `Status` in the normal response to indicate the partial errors. - Workflow errors. A typical workflow has multiple steps. Each step may have a `Status` message for error reporting. - Batch operations. If a client uses batch request and batch response, the `Status` message should be used directly inside batch response, one for each error sub-response. - Asynchronous operations. If an API call embeds asynchronous operation results in its response, the status of those operations should be represented directly using the `Status` message. - Logging. If some API errors are stored in logs, the message `Status` could be used directly after any stripping needed for security/privacy reasons. + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). */ export interface Schema$Status { /** diff --git a/src/apis/dfareporting/v3.1.ts b/src/apis/dfareporting/v3.1.ts index cfe34ec2114..3434c85acb3 100644 --- a/src/apis/dfareporting/v3.1.ts +++ b/src/apis/dfareporting/v3.1.ts @@ -113,7 +113,6 @@ export namespace dfareporting_v3_1 { creativeGroups: Resource$Creativegroups; creatives: Resource$Creatives; dimensionValues: Resource$Dimensionvalues; - directorySiteContacts: Resource$Directorysitecontacts; directorySites: Resource$Directorysites; dynamicTargetingKeys: Resource$Dynamictargetingkeys; eventTags: Resource$Eventtags; @@ -189,9 +188,6 @@ export namespace dfareporting_v3_1 { this.creativeGroups = new Resource$Creativegroups(this.context); this.creatives = new Resource$Creatives(this.context); this.dimensionValues = new Resource$Dimensionvalues(this.context); - this.directorySiteContacts = new Resource$Directorysitecontacts( - this.context - ); this.directorySites = new Resource$Directorysites(this.context); this.dynamicTargetingKeys = new Resource$Dynamictargetingkeys( this.context @@ -1090,10 +1086,6 @@ export namespace dfareporting_v3_1 { * Information about the most recent modification of this campaign. This is a read-only field. */ lastModifiedInfo?: Schema$LastModifiedInfo; - /** - * Lookback window settings for the campaign. - */ - lookbackConfiguration?: Schema$LookbackConfiguration; /** * Name of this campaign. This is a required field and must be less than 256 characters long and unique among campaigns of the same advertiser. */ @@ -1481,7 +1473,7 @@ export namespace dfareporting_v3_1 { */ export interface Schema$Conversion { /** - * Whether the conversion was directed toward children. + * Whether this particular request may come from a user under the age of 13, under COPPA compliance. */ childDirectedTreatment?: boolean; /** @@ -1520,6 +1512,10 @@ export namespace dfareporting_v3_1 { * The mobile device ID. This field is mutually exclusive with encryptedUserId, encryptedUserIdCandidates[] and gclid. This or encryptedUserId or encryptedUserIdCandidates[] or gclid is a required field. */ mobileDeviceId?: string; + /** + * Whether the conversion was for a non personalized ad. + */ + nonPersonalizedAd?: boolean; /** * The ordinal of the conversion. Use this field to control how conversions of the same user and day are de-duplicated. This is a required field. */ @@ -1532,6 +1528,10 @@ export namespace dfareporting_v3_1 { * The timestamp of conversion, in Unix epoch micros. This is a required field. */ timestampMicros?: string; + /** + * Whether this particular request may come from a user under the age of 16 (may differ by country), under compliance with the European Union's General Data Protection Regulation (GDPR). + */ + treatmentForUnderage?: boolean; /** * The value of the conversion. */ @@ -1689,6 +1689,10 @@ export namespace dfareporting_v3_1 { * Whether the creative is active. Applicable to all creative types. */ active?: boolean; + /** + * Additional sizes associated with a responsive creative. When inserting or updating a creative either the size ID field or size width and height fields can be used. Applicable to DISPLAY creatives when the primary asset type is HTML_IMAGE. + */ + additionalSizes?: Schema$Size[]; /** * Ad parameters user for VPAID creative. This is a read-only field. Applicable to the following creative types: all VPAID. */ @@ -1841,10 +1845,6 @@ export namespace dfareporting_v3_1 { * Override CSS value for rich media creatives. Applicable to the following creative types: all RICH_MEDIA. */ overrideCss?: string; - /** - * The asset ID of the polite load image asset. Applicable to the creative type: DISPLAY. - */ - politeLoadAssetId?: string; /** * Amount of time to play the video before counting a view. Applicable to the following creative types: all INSTREAM_VIDEO. */ @@ -1950,6 +1950,10 @@ export namespace dfareporting_v3_1 { * Whether the video or audio asset is active. This is a read-only field for VPAID_NON_LINEAR_VIDEO assets. Applicable to the following creative types: INSTREAM_AUDIO, INSTREAM_VIDEO and all VPAID. */ active?: boolean; + /** + * Additional sizes associated with this creative asset. HTML5 asset generated by compatible software such as GWD will be able to support more sizes this creative asset can render. + */ + additionalSizes?: Schema$Size[]; /** * Possible alignments for an asset. This is a read-only field. Applicable to the following creative types: RICH_MEDIA_DISPLAY_MULTI_FLOATING_INTERSTITIAL. */ @@ -2507,19 +2511,6 @@ export namespace dfareporting_v3_1 { */ weightCalculationStrategy?: string; } - /** - * Creative Settings - */ - export interface Schema$CreativeSettings { - /** - * Header text for iFrames for this site. Must be less than or equal to 2000 characters long. - */ - iFrameFooter?: string; - /** - * Header text for iFrames for this site. Must be less than or equal to 2000 characters long. - */ - iFrameHeader?: string; - } /** * Creative List Response */ @@ -2827,22 +2818,6 @@ export namespace dfareporting_v3_1 { * Whether this directory site is active. */ active?: boolean; - /** - * Directory site contacts. - */ - contactAssignments?: Schema$DirectorySiteContactAssignment[]; - /** - * Country ID of this directory site. This is a read-only field. - */ - countryId?: string; - /** - * Currency ID of this directory site. This is a read-only field. Possible values are: - "1" for USD - "2" for GBP - "3" for ESP - "4" for SEK - "5" for CAD - "6" for JPY - "7" for DEM - "8" for AUD - "9" for FRF - "10" for ITL - "11" for DKK - "12" for NOK - "13" for FIM - "14" for ZAR - "15" for IEP - "16" for NLG - "17" for EUR - "18" for KRW - "19" for TWD - "20" for SGD - "21" for CNY - "22" for HKD - "23" for NZD - "24" for MYR - "25" for BRL - "26" for PTE - "27" for MXP - "28" for CLP - "29" for TRY - "30" for ARS - "31" for PEN - "32" for ILS - "33" for CHF - "34" for VEF - "35" for COP - "36" for GTQ - "37" for PLN - "39" for INR - "40" for THB - "41" for IDR - "42" for CZK - "43" for RON - "44" for HUF - "45" for RUB - "46" for AED - "47" for BGN - "48" for HRK - "49" for MXN - "50" for NGN - */ - currencyId?: string; - /** - * Description of this directory site. This is a read-only field. - */ - description?: string; /** * ID of this directory site. This is a read-only, auto-generated field. */ @@ -2867,10 +2842,6 @@ export namespace dfareporting_v3_1 { * Name of this directory site. */ name?: string; - /** - * Parent directory site ID. - */ - parentId?: string; /** * Directory site settings. */ @@ -2880,81 +2851,6 @@ export namespace dfareporting_v3_1 { */ url?: string; } - /** - * Contains properties of a Site Directory contact. - */ - export interface Schema$DirectorySiteContact { - /** - * Address of this directory site contact. - */ - address?: string; - /** - * Email address of this directory site contact. - */ - email?: string; - /** - * First name of this directory site contact. - */ - firstName?: string; - /** - * ID of this directory site contact. This is a read-only, auto-generated field. - */ - id?: string; - /** - * Identifies what kind of resource this is. Value: the fixed string "dfareporting#directorySiteContact". - */ - kind?: string; - /** - * Last name of this directory site contact. - */ - lastName?: string; - /** - * Phone number of this directory site contact. - */ - phone?: string; - /** - * Directory site contact role. - */ - role?: string; - /** - * Title or designation of this directory site contact. - */ - title?: string; - /** - * Directory site contact type. - */ - type?: string; - } - /** - * Directory Site Contact Assignment - */ - export interface Schema$DirectorySiteContactAssignment { - /** - * ID of this directory site contact. This is a read-only, auto-generated field. - */ - contactId?: string; - /** - * Visibility of this directory site contact assignment. When set to PUBLIC this contact assignment is visible to all account and agency users; when set to PRIVATE it is visible only to the site. - */ - visibility?: string; - } - /** - * Directory Site Contact List Response - */ - export interface Schema$DirectorySiteContactsListResponse { - /** - * Directory site contact collection - */ - directorySiteContacts?: Schema$DirectorySiteContact[]; - /** - * Identifies what kind of resource this is. Value: the fixed string "dfareporting#directorySiteContactsListResponse". - */ - kind?: string; - /** - * Pagination token to be used for the next list operation. - */ - nextPageToken?: string; - } /** * Directory Site Settings */ @@ -2975,18 +2871,6 @@ export namespace dfareporting_v3_1 { * Whether this site accepts interstitial ads. */ interstitialPlacementAccepted?: boolean; - /** - * Whether this directory site has disabled Nielsen OCR reach ratings. - */ - nielsenOcrOptOut?: boolean; - /** - * Whether this directory site has disabled generation of Verification ins tags. - */ - verificationTagOptOut?: boolean; - /** - * Whether this directory site has disabled active view for in-stream video creatives. This is a read-only field. - */ - videoActiveViewOptOut?: boolean; } /** * Directory Site List Response @@ -3344,10 +3228,6 @@ export namespace dfareporting_v3_1 { * The type of Floodlight tag this activity will generate. This is a required field. */ floodlightTagType?: string; - /** - * Whether this activity is archived. - */ - hidden?: boolean; /** * ID of this floodlight activity. This is a read-only, auto-generated field. */ @@ -4505,6 +4385,10 @@ export namespace dfareporting_v3_1 { * Whether this placement opts out of ad blocking. When true, ad blocking is disabled for this placement. When false, the campaign and site settings take effect. */ adBlockingOptOut?: boolean; + /** + * Additional sizes associated with this placement. When inserting or updating a placement, only the size ID field is used. + */ + additionalSizes?: Schema$Size[]; /** * Advertiser ID of this placement. This field can be left blank. */ @@ -5032,10 +4916,6 @@ export namespace dfareporting_v3_1 { * Placement cap cost option. */ capCostOption?: string; - /** - * Whether cap costs are ignored by ad serving. - */ - disregardOverdelivery?: boolean; /** * Placement end date. This date must be later than, or the same day as, the placement start date, but not later than the campaign end date. If, for example, you set 6/25/2015 as both the start and end dates, the effective placement date is just that day only, 6/25/2015. The hours, minutes, and seconds of the end date should not be set, as doing so will result in an error. This field is required on insertion. */ @@ -5728,18 +5608,10 @@ export namespace dfareporting_v3_1 { * Whether this site opts out of ad blocking. When true, ad blocking is disabled for all placements under the site, regardless of the individual placement settings. When false, the campaign and placement settings take effect. */ adBlockingOptOut?: boolean; - /** - * Site-wide creative settings. - */ - creativeSettings?: Schema$CreativeSettings; /** * Whether new cookies are disabled for this site. */ disableNewCookie?: boolean; - /** - * Lookback window settings for this site. - */ - lookbackConfiguration?: Schema$LookbackConfiguration; /** * Configuration settings for dynamic and image floodlight tags. */ @@ -10596,6 +10468,7 @@ export namespace dfareporting_v3_1 { * @param {object} params Parameters for request * @param {string=} params.advertiserIds Select only landing pages that belong to these advertisers. * @param {boolean=} params.archived Select only archived landing pages. Don't set this field to select both archived and non-archived landing pages. + * @param {string=} params.campaignIds Select only landing pages that are associated with these campaigns. * @param {string=} params.ids Select only landing pages with these IDs. * @param {integer=} params.maxResults Maximum number of results to return. * @param {string=} params.pageToken Value of the nextPageToken from the previous result page. @@ -10982,6 +10855,10 @@ export namespace dfareporting_v3_1 { * Select only archived landing pages. Don't set this field to select both archived and non-archived landing pages. */ archived?: boolean; + /** + * Select only landing pages that are associated with these campaigns. + */ + campaignIds?: string[]; /** * Select only landing pages with these IDs. */ @@ -19108,343 +18985,6 @@ export namespace dfareporting_v3_1 { requestBody?: Schema$DimensionValueRequest; } - export class Resource$Directorysitecontacts { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * dfareporting.directorySiteContacts.get - * @desc Gets one directory site contact by ID. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the DCM/DFA Reporting And Trafficking API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/dfareporting - * // 2. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var dfareporting = google.dfareporting('v3.1'); - * - * authorize(function(authClient) { - * var request = { - * // User profile ID associated with this request. - * profileId: '0', // TODO: Update placeholder value. - * - * // Directory site contact ID. - * id: '0', // TODO: Update placeholder value. - * - * auth: authClient, - * }; - * - * dfareporting.directorySiteContacts.get(request, function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); - * }); - * }); - * - * function authorize(callback) { - * // TODO: Change placeholder below to generate authentication credentials. See - * // - * // - * // Authorize using the following scope: - * // 'https://www.googleapis.com/auth/dfatrafficking' - * var authClient = null; - * - * if (authClient == null) { - * console.log('authentication failed'); - * return; - * } - * callback(authClient); - * } - * @alias dfareporting.directorySiteContacts.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.id Directory site contact ID. - * @param {string} params.profileId User profile ID associated with this request. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Directorysitecontacts$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Directorysitecontacts$Get, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Directorysitecontacts$Get, - callback: BodyResponseCallback - ): void; - get(callback: BodyResponseCallback): void; - get( - paramsOrCallback?: - | Params$Resource$Directorysitecontacts$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Directorysitecontacts$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Directorysitecontacts$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/dfareporting/v3.1/userprofiles/{profileId}/directorySiteContacts/{id}' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['profileId', 'id'], - pathParams: ['id', 'profileId'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * dfareporting.directorySiteContacts.list - * @desc Retrieves a list of directory site contacts, possibly filtered. This method supports paging. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the DCM/DFA Reporting And Trafficking API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/dfareporting - * // 2. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var dfareporting = google.dfareporting('v3.1'); - * - * authorize(function(authClient) { - * var request = { - * // User profile ID associated with this request. - * profileId: '0', // TODO: Update placeholder value. - * - * auth: authClient, - * }; - * - * var handlePage = function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * var directorySiteContactsPage = response['directorySiteContacts']; - * if (!directorySiteContactsPage) { - * return; - * } - * for (var i = 0; i < directorySiteContactsPage.length; i++) { - * // TODO: Change code below to process each resource in `directorySiteContactsPage`: - * console.log(JSON.stringify(directorySiteContactsPage[i], null, 2)); - * } - * - * if (response.nextPageToken) { - * request.pageToken = response.nextPageToken; - * dfareporting.directorySiteContacts.list(request, handlePage); - * } - * }; - * - * dfareporting.directorySiteContacts.list(request, handlePage); - * }); - * - * function authorize(callback) { - * // TODO: Change placeholder below to generate authentication credentials. See - * // - * // - * // Authorize using the following scope: - * // 'https://www.googleapis.com/auth/dfatrafficking' - * var authClient = null; - * - * if (authClient == null) { - * console.log('authentication failed'); - * return; - * } - * callback(authClient); - * } - * @alias dfareporting.directorySiteContacts.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.directorySiteIds Select only directory site contacts with these directory site IDs. This is a required field. - * @param {string=} params.ids Select only directory site contacts with these IDs. - * @param {integer=} params.maxResults Maximum number of results to return. - * @param {string=} params.pageToken Value of the nextPageToken from the previous result page. - * @param {string} params.profileId User profile ID associated with this request. - * @param {string=} params.searchString Allows searching for objects by name, ID or email. Wildcards (*) are allowed. For example, "directory site contact*2015" will return objects with names like "directory site contact June 2015", "directory site contact April 2015", or simply "directory site contact 2015". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of "directory site contact" will match objects with name "my directory site contact", "directory site contact 2015", or simply "directory site contact". - * @param {string=} params.sortField Field by which to sort the list. - * @param {string=} params.sortOrder Order of sorted results. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Directorysitecontacts$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Directorysitecontacts$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Directorysitecontacts$List, - callback: BodyResponseCallback - ): void; - list( - callback: BodyResponseCallback - ): void; - list( - paramsOrCallback?: - | Params$Resource$Directorysitecontacts$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Directorysitecontacts$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Directorysitecontacts$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + - '/dfareporting/v3.1/userprofiles/{profileId}/directorySiteContacts' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', - }, - options - ), - params, - requiredParams: ['profileId'], - pathParams: ['profileId'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest( - parameters - ); - } - } - } - - export interface Params$Resource$Directorysitecontacts$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Directory site contact ID. - */ - id?: string; - /** - * User profile ID associated with this request. - */ - profileId?: string; - } - export interface Params$Resource$Directorysitecontacts$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Select only directory site contacts with these directory site IDs. This is a required field. - */ - directorySiteIds?: string[]; - /** - * Select only directory site contacts with these IDs. - */ - ids?: string[]; - /** - * Maximum number of results to return. - */ - maxResults?: number; - /** - * Value of the nextPageToken from the previous result page. - */ - pageToken?: string; - /** - * User profile ID associated with this request. - */ - profileId?: string; - /** - * Allows searching for objects by name, ID or email. Wildcards (*) are allowed. For example, "directory site contact*2015" will return objects with names like "directory site contact June 2015", "directory site contact April 2015", or simply "directory site contact 2015". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of "directory site contact" will match objects with name "my directory site contact", "directory site contact 2015", or simply "directory site contact". - */ - searchString?: string; - /** - * Field by which to sort the list. - */ - sortField?: string; - /** - * Order of sorted results. - */ - sortOrder?: string; - } - export class Resource$Directorysites { context: APIRequestContext; constructor(context: APIRequestContext) { @@ -19767,12 +19307,10 @@ export namespace dfareporting_v3_1 { * @param {boolean=} params.acceptsInterstitialPlacements This search filter is no longer supported and will have no effect on the results returned. * @param {boolean=} params.acceptsPublisherPaidPlacements Select only directory sites that accept publisher paid placements. This field can be left blank. * @param {boolean=} params.active Select only active directory sites. Leave blank to retrieve both active and inactive directory sites. - * @param {string=} params.countryId Select only directory sites with this country ID. * @param {string=} params.dfpNetworkCode Select only directory sites with this Ad Manager network code. * @param {string=} params.ids Select only directory sites with these IDs. * @param {integer=} params.maxResults Maximum number of results to return. * @param {string=} params.pageToken Value of the nextPageToken from the previous result page. - * @param {string=} params.parentId Select only directory sites with this parent ID. * @param {string} params.profileId User profile ID associated with this request. * @param {string=} params.searchString Allows searching for objects by name, ID or URL. Wildcards (*) are allowed. For example, "directory site*2015" will return objects with names like "directory site June 2015", "directory site April 2015", or simply "directory site 2015". Most of the searches also add wildcards implicitly at the start and the end of the search string. For example, a search string of "directory site" will match objects with name "my directory site", "directory site 2015" or simply, "directory site". * @param {string=} params.sortField Field by which to sort the list. @@ -19907,10 +19445,6 @@ export namespace dfareporting_v3_1 { * Select only active directory sites. Leave blank to retrieve both active and inactive directory sites. */ active?: boolean; - /** - * Select only directory sites with this country ID. - */ - countryId?: string; /** * Select only directory sites with this Ad Manager network code. */ @@ -19927,10 +19461,6 @@ export namespace dfareporting_v3_1 { * Value of the nextPageToken from the previous result page. */ pageToken?: string; - /** - * Select only directory sites with this parent ID. - */ - parentId?: string; /** * User profile ID associated with this request. */ diff --git a/src/apis/dialogflow/package.json b/src/apis/dialogflow/package.json index f58c1ef9fb1..981ba7dd982 100644 --- a/src/apis/dialogflow/package.json +++ b/src/apis/dialogflow/package.json @@ -34,10 +34,10 @@ "devDependencies": { "gts": "^1.0.0", "null-loader": "^3.0.0", - "ts-loader": "^6.0.0", - "typedoc": "^0.14.0", + "ts-loader": "^6.0.4", + "typedoc": "^0.15.0", "typescript": "~3.6.0", - "webpack": "^4.28.4", - "webpack-cli": "^3.2.1" + "webpack": "^4.35.3", + "webpack-cli": "^3.3.5" } } diff --git a/src/apis/dialogflow/webpack.config.js b/src/apis/dialogflow/webpack.config.js index 44b6fe38877..147413acc8e 100644 --- a/src/apis/dialogflow/webpack.config.js +++ b/src/apis/dialogflow/webpack.config.js @@ -36,27 +36,27 @@ module.exports = { module: { rules: [ { - test: /node_modules\/google-auth-library\/src\/crypto\/node\/crypto/, + test: /node_modules[\\/]google-auth-library[\\/]src[\\/]crypto[\\/]node[\\/]crypto/, use: 'null-loader', }, { - test: /node_modules\/https-proxy-agent\//, + test: /node_modules[\\/]https-proxy-agent[\\/]/, use: 'null-loader', }, { - test: /node_modules\/gcp-metadata\//, + test: /node_modules[\\/]gcp-metadata[\\/]/, use: 'null-loader', }, { - test: /node_modules\/gtoken\//, + test: /node_modules[\\/]gtoken[\\/]/, use: 'null-loader', }, { - test: /node_modules\/pkginfo\//, + test: /node_modules[\\/]pkginfo[\\/]/, use: 'null-loader', }, { - test: /node_modules\/semver\//, + test: /node_modules[\\/]semver[\\/]/, use: 'null-loader', }, { diff --git a/src/apis/dlp/v2.ts b/src/apis/dlp/v2.ts index 21259e90a50..552a01dfb15 100644 --- a/src/apis/dlp/v2.ts +++ b/src/apis/dlp/v2.ts @@ -106,6 +106,7 @@ export namespace dlp_v2 { export class Dlp { context: APIRequestContext; infoTypes: Resource$Infotypes; + locations: Resource$Locations; organizations: Resource$Organizations; projects: Resource$Projects; @@ -116,6 +117,7 @@ export namespace dlp_v2 { }; this.infoTypes = new Resource$Infotypes(this.context); + this.locations = new Resource$Locations(this.context); this.organizations = new Resource$Organizations(this.context); this.projects = new Resource$Projects(this.context); } @@ -610,7 +612,7 @@ export namespace dlp_v2 { */ cryptoKey?: Schema$GooglePrivacyDlpV2CryptoKey; /** - * The custom info type to annotate the surrogate with. This annotation will be applied to the surrogate by prefixing it with the name of the custom info type followed by the number of characters comprising the surrogate. The following scheme defines the format: <info type name>(<surrogate character count>):<surrogate> For example, if the name of custom info type is 'MY_TOKEN_INFO_TYPE' and the surrogate is 'abc', the full replacement value will be: 'MY_TOKEN_INFO_TYPE(3):abc' This annotation identifies the surrogate when inspecting content using the custom info type 'Surrogate'. This facilitates reversal of the surrogate when it occurs in free text. In order for inspection to work properly, the name of this info type must not occur naturally anywhere in your data; otherwise, inspection may either - reverse a surrogate that does not correspond to an actual identifier - be unable to parse the surrogate and result in an error Therefore, choose your custom info type name carefully after considering what your data looks like. One way to select a name that has a high chance of yielding reliable detection is to include one or more unicode characters that are highly improbable to exist in your data. For example, assuming your data is entered from a regular ASCII keyboard, the symbol with the hex code point 29DD might be used like so: ⧝MY_TOKEN_TYPE + * The custom info type to annotate the surrogate with. This annotation will be applied to the surrogate by prefixing it with the name of the custom info type followed by the number of characters comprising the surrogate. The following scheme defines the format: <info type name>(<surrogate character count>):<surrogate> For example, if the name of custom info type is 'MY_TOKEN_INFO_TYPE' and the surrogate is 'abc', the full replacement value will be: 'MY_TOKEN_INFO_TYPE(3):abc' This annotation identifies the surrogate when inspecting content using the custom info type 'Surrogate'. This facilitates reversal of the surrogate when it occurs in free text. Note: For record transformations where the entire cell in a table is being transformed, surrogates are optional to use. Surrogates are used to denote the location of the token and are necessary for re-identification in free form text. In order for inspection to work properly, the name of this info type must not occur naturally anywhere in your data; otherwise, inspection may either - reverse a surrogate that does not correspond to an actual identifier - be unable to parse the surrogate and result in an error Therefore, choose your custom info type name carefully after considering what your data looks like. One way to select a name that has a high chance of yielding reliable detection is to include one or more unicode characters that are highly improbable to exist in your data. For example, assuming your data is entered from a regular ASCII keyboard, the symbol with the hex code point 29DD might be used like so: ⧝MY_TOKEN_TYPE. */ surrogateInfoType?: Schema$GooglePrivacyDlpV2InfoType; } @@ -1306,6 +1308,10 @@ export namespace dlp_v2 { * The item to inspect. */ item?: Schema$GooglePrivacyDlpV2ContentItem; + /** + * The geographic location to process content inspection. Reserved for future extensions. + */ + location?: string; } /** * Results of inspecting an item. @@ -1445,7 +1451,7 @@ export namespace dlp_v2 { */ lastRunTime?: string; /** - * Unique resource name for the triggeredJob, assigned by the service when the triggeredJob is created, for example `projects/dlp-test-project/triggeredJobs/53234423`. + * Unique resource name for the triggeredJob, assigned by the service when the triggeredJob is created, for example `projects/dlp-test-project/jobTriggers/53234423`. */ name?: string; /** @@ -1747,6 +1753,19 @@ export namespace dlp_v2 { */ nextPageToken?: string; } + /** + * Request for the list of infoTypes. + */ + export interface Schema$GooglePrivacyDlpV2ListInfoTypesRequest { + /** + * Optional filter to only return infoTypes supported by certain parts of the API. Defaults to supported_by=INSPECT. + */ + filter?: string; + /** + * Optional BCP-47 language code for localized infoType friendly names. If omitted, or if localized strings are not available, en-US strings will be returned. + */ + languageCode?: string; + } /** * Response to the ListInfoTypes request. */ @@ -2125,6 +2144,10 @@ export namespace dlp_v2 { * The item to re-identify. Will be treated as text. */ item?: Schema$GooglePrivacyDlpV2ContentItem; + /** + * The geographic location to process content reidentification. Reserved for future extensions. + */ + location?: string; /** * Configuration for the re-identification of the content item. This field shares the same proto message type that is used for de-identification, however its usage here is for the reversal of the previous de-identification. Re-identification is performed by examining the transformations used to de-identify the items and executing the reverse. This requires that only reversible transformations be provided here. The reversible transformations are: - `CryptoReplaceFfxFpeConfig` */ @@ -2649,6 +2672,7 @@ export namespace dlp_v2 { * @param {object} params Parameters for request * @param {string=} params.filter Optional filter to only return infoTypes supported by certain parts of the API. Defaults to supported_by=INSPECT. * @param {string=} params.languageCode Optional BCP-47 language code for localized infoType friendly names. If omitted, or if localized strings are not available, en-US strings will be returned. + * @param {string=} params.location The geographic location to list info types. Reserved for future extensions. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2743,6 +2767,127 @@ export namespace dlp_v2 { * Optional BCP-47 language code for localized infoType friendly names. If omitted, or if localized strings are not available, en-US strings will be returned. */ languageCode?: string; + /** + * The geographic location to list info types. Reserved for future extensions. + */ + location?: string; + } + + export class Resource$Locations { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * dlp.locations.infoTypes + * @desc Returns a list of the sensitive information types that the DLP API supports. See https://cloud.google.com/dlp/docs/infotypes-reference to learn more. + * @alias dlp.locations.infoTypes + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.location The geographic location to list info types. Reserved for future extensions. + * @param {().GooglePrivacyDlpV2ListInfoTypesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + infoTypes( + params?: Params$Resource$Locations$Infotypes, + options?: MethodOptions + ): GaxiosPromise; + infoTypes( + params: Params$Resource$Locations$Infotypes, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback< + Schema$GooglePrivacyDlpV2ListInfoTypesResponse + > + ): void; + infoTypes( + params: Params$Resource$Locations$Infotypes, + callback: BodyResponseCallback< + Schema$GooglePrivacyDlpV2ListInfoTypesResponse + > + ): void; + infoTypes( + callback: BodyResponseCallback< + Schema$GooglePrivacyDlpV2ListInfoTypesResponse + > + ): void; + infoTypes( + paramsOrCallback?: + | Params$Resource$Locations$Infotypes + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback< + Schema$GooglePrivacyDlpV2ListInfoTypesResponse + > + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Locations$Infotypes; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Locations$Infotypes; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://dlp.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v2/locations/{location}/infoTypes').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['location'], + pathParams: ['location'], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest( + parameters + ); + } + } + } + + export interface Params$Resource$Locations$Infotypes + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The geographic location to list info types. Reserved for future extensions. + */ + location?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$GooglePrivacyDlpV2ListInfoTypesRequest; } export class Resource$Organizations { @@ -7057,6 +7202,198 @@ export namespace dlp_v2 { >(parameters); } } + + /** + * dlp.projects.locations.content.inspect + * @desc Finds potentially sensitive info in content. This method has limits on input size, processing time, and output size. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. For how to guides, see https://cloud.google.com/dlp/docs/inspecting-images and https://cloud.google.com/dlp/docs/inspecting-text, + * @alias dlp.projects.locations.content.inspect + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.location The geographic location to process content inspection. Reserved for future extensions. + * @param {string} params.parent The parent resource name, for example projects/my-project-id. + * @param {().GooglePrivacyDlpV2InspectContentRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + inspect( + params?: Params$Resource$Projects$Locations$Content$Inspect, + options?: MethodOptions + ): GaxiosPromise; + inspect( + params: Params$Resource$Projects$Locations$Content$Inspect, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback< + Schema$GooglePrivacyDlpV2InspectContentResponse + > + ): void; + inspect( + params: Params$Resource$Projects$Locations$Content$Inspect, + callback: BodyResponseCallback< + Schema$GooglePrivacyDlpV2InspectContentResponse + > + ): void; + inspect( + callback: BodyResponseCallback< + Schema$GooglePrivacyDlpV2InspectContentResponse + > + ): void; + inspect( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Content$Inspect + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback< + Schema$GooglePrivacyDlpV2InspectContentResponse + > + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Content$Inspect; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Content$Inspect; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://dlp.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + '/v2/{+parent}/locations/{location}/content:inspect' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent', 'location'], + pathParams: ['location', 'parent'], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest< + Schema$GooglePrivacyDlpV2InspectContentResponse + >(parameters); + } + } + + /** + * dlp.projects.locations.content.reidentify + * @desc Re-identifies content that has been de-identified. See https://cloud.google.com/dlp/docs/pseudonymization#re-identification_in_free_text_code_example to learn more. + * @alias dlp.projects.locations.content.reidentify + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.location The geographic location to process content reidentification. Reserved for future extensions. + * @param {string} params.parent The parent resource name. + * @param {().GooglePrivacyDlpV2ReidentifyContentRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + reidentify( + params?: Params$Resource$Projects$Locations$Content$Reidentify, + options?: MethodOptions + ): GaxiosPromise; + reidentify( + params: Params$Resource$Projects$Locations$Content$Reidentify, + options: + | MethodOptions + | BodyResponseCallback< + Schema$GooglePrivacyDlpV2ReidentifyContentResponse + >, + callback: BodyResponseCallback< + Schema$GooglePrivacyDlpV2ReidentifyContentResponse + > + ): void; + reidentify( + params: Params$Resource$Projects$Locations$Content$Reidentify, + callback: BodyResponseCallback< + Schema$GooglePrivacyDlpV2ReidentifyContentResponse + > + ): void; + reidentify( + callback: BodyResponseCallback< + Schema$GooglePrivacyDlpV2ReidentifyContentResponse + > + ): void; + reidentify( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Content$Reidentify + | BodyResponseCallback< + Schema$GooglePrivacyDlpV2ReidentifyContentResponse + >, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback< + Schema$GooglePrivacyDlpV2ReidentifyContentResponse + >, + callback?: BodyResponseCallback< + Schema$GooglePrivacyDlpV2ReidentifyContentResponse + > + ): void | GaxiosPromise< + Schema$GooglePrivacyDlpV2ReidentifyContentResponse + > { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Content$Reidentify; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Content$Reidentify; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://dlp.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + '/v2/{+parent}/locations/{location}/content:reidentify' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent', 'location'], + pathParams: ['location', 'parent'], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest< + Schema$GooglePrivacyDlpV2ReidentifyContentResponse + >(parameters); + } + } } export interface Params$Resource$Projects$Locations$Content$Deidentify @@ -7080,6 +7417,48 @@ export namespace dlp_v2 { */ requestBody?: Schema$GooglePrivacyDlpV2DeidentifyContentRequest; } + export interface Params$Resource$Projects$Locations$Content$Inspect + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The geographic location to process content inspection. Reserved for future extensions. + */ + location?: string; + /** + * The parent resource name, for example projects/my-project-id. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$GooglePrivacyDlpV2InspectContentRequest; + } + export interface Params$Resource$Projects$Locations$Content$Reidentify + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The geographic location to process content reidentification. Reserved for future extensions. + */ + location?: string; + /** + * The parent resource name. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$GooglePrivacyDlpV2ReidentifyContentRequest; + } export class Resource$Projects$Storedinfotypes { context: APIRequestContext; diff --git a/src/apis/docs/v1.ts b/src/apis/docs/v1.ts index f72a44bbb56..fc5147af4ce 100644 --- a/src/apis/docs/v1.ts +++ b/src/apis/docs/v1.ts @@ -495,47 +495,47 @@ export namespace docs_v1 { */ export interface Schema$DocumentStyle { /** - * The background of the document. + * The background of the document. Documents cannot have a transparent background color. */ background?: Schema$Background; /** - * The ID of the default footer. If not set, there is no default footer. + * The ID of the default footer. If not set, there is no default footer. This property is read-only. */ defaultFooterId?: string; /** - * The ID of the default header. If not set, there is no default header. + * The ID of the default header. If not set, there is no default header. This property is read-only. */ defaultHeaderId?: string; /** - * The ID of the footer used only for even pages. The value of use_even_page_header_footer determines whether to use the default_footer_id or this value for the footer on even pages. If not set, there is no even page footer. + * The ID of the footer used only for even pages. The value of use_even_page_header_footer determines whether to use the default_footer_id or this value for the footer on even pages. If not set, there is no even page footer. This property is read-only. */ evenPageFooterId?: string; /** - * The ID of the header used only for even pages. The value of use_even_page_header_footer determines whether to use the default_header_id or this value for the header on even pages. If not set, there is no even page header. + * The ID of the header used only for even pages. The value of use_even_page_header_footer determines whether to use the default_header_id or this value for the header on even pages. If not set, there is no even page header. This property is read-only. */ evenPageHeaderId?: string; /** - * The ID of the footer used only for the first page. If not set then a unique footer for the first page does not exist. The value of use_first_page_header_footer determines whether to use the default_footer_id or this value for the footer on the first page. If not set, there is no first page footer. + * The ID of the footer used only for the first page. If not set then a unique footer for the first page does not exist. The value of use_first_page_header_footer determines whether to use the default_footer_id or this value for the footer on the first page. If not set, there is no first page footer. This property is read-only. */ firstPageFooterId?: string; /** - * The ID of the header used only for the first page. If not set then a unique header for the first page does not exist. The value of use_first_page_header_footer determines whether to use the default_header_id or this value for the header on the first page. If not set, there is no first page header. + * The ID of the header used only for the first page. If not set then a unique header for the first page does not exist. The value of use_first_page_header_footer determines whether to use the default_header_id or this value for the header on the first page. If not set, there is no first page header. This property is read-only. */ firstPageHeaderId?: string; /** - * The bottom page margin. + * The bottom page margin. Updating the bottom page margin on the document style clears the bottom page margin on all section styles. */ marginBottom?: Schema$Dimension; /** - * The left page margin. + * The left page margin. Updating the left page margin on the document style clears the left page margin on all section styles. It may also cause columns to resize in all sections. */ marginLeft?: Schema$Dimension; /** - * The right page margin. + * The right page margin. Updating the right page margin on the document style clears the right page margin on all section styles. It may also cause columns to resize in all sections. */ marginRight?: Schema$Dimension; /** - * The top page margin. + * The top page margin. Updating the top page margin on the document style clears the top page margin on all section styles. */ marginTop?: Schema$Dimension; /** @@ -547,11 +547,11 @@ export namespace docs_v1 { */ pageSize?: Schema$Size; /** - * Indicates whether to use the even page header / footer IDs for the even pages. + * Indicates whether to use the even page header / footer IDs for the even pages. This property is read-only. */ useEvenPageHeaderFooter?: boolean; /** - * Indicates whether to use the first page header / footer IDs for the first page. + * Indicates whether to use the first page header / footer IDs for the first page. This property is read-only. */ useFirstPageHeaderFooter?: boolean; } @@ -1220,6 +1220,15 @@ export namespace docs_v1 { */ segmentId?: string; } + /** + * Merges cells in a Table. + */ + export interface Schema$MergeTableCellsRequest { + /** + * The table range specifying which cells of the table to merge. Any text in the cells being merged will be concatenated and stored in the "head" cell of the range. This is the upper-left cell of the range when the content direction is left to right, and the upper-right cell of the range otherwise. If the range is non-rectangular (which can occur in some cases where the range covers cells that are already merged or where the table is non-rectangular), a 400 bad request error is returned. + */ + tableRange?: Schema$TableRange; + } /** * A collection of Ranges with the same named range ID. Named ranges allow developers to associate parts of a document with an arbitrary user-defined label so their contents can be programmatically read or edited at a later time. A document can contain multiple named ranges with the same name, but every named range has a unique ID. A named range is created with a single Range, and content inserted inside a named range generally expands that range. However, certain document changes can cause the range to be split into multiple ranges. Named ranges are not private. All applications and collaborators that have access to the document can see its named ranges. */ @@ -1553,7 +1562,7 @@ export namespace docs_v1 { */ direction?: string; /** - * The heading ID of the paragraph. If empty, then this paragraph is not a heading. This property is read-only. + * The heading ID of the paragraph. If empty, then this paragraph is not a heading. This property is read-only. */ headingId?: string; /** @@ -1601,7 +1610,7 @@ export namespace docs_v1 { */ spacingMode?: string; /** - * A list of the tab stops for this paragraph. The list of tab stops is not inherited. This property is read-only. + * A list of the tab stops for this paragraph. The list of tab stops is not inherited. This property is read-only. */ tabStops?: Schema$TabStop[]; } @@ -1816,6 +1825,23 @@ export namespace docs_v1 { */ occurrencesChanged?: number; } + /** + * Replaces an existing image with a new image. Replacing an image removes some image effects from the existing image in order to mirror the behavior of the Docs editor. + */ + export interface Schema$ReplaceImageRequest { + /** + * The ID of the existing image that will be replaced. + */ + imageObjectId?: string; + /** + * The replacement method. + */ + imageReplaceMethod?: string; + /** + * The URI of the new image. The image is fetched once at insertion time and a copy is stored for display inside the document. Images must be less than 50MB in size, cannot exceed 25 megapixels, and must be in one of PNG, JPEG, or GIF format. The provided URI can be at most 2 kB in length. The URI itself is saved with the image, and exposed via the ImageProperties.source_uri field. + */ + uri?: string; + } /** * A single update to apply to a document. */ @@ -1876,14 +1902,34 @@ export namespace docs_v1 { * Inserts text at the specified location. */ insertText?: Schema$InsertTextRequest; + /** + * Merges cells in a table. + */ + mergeTableCells?: Schema$MergeTableCellsRequest; /** * Replaces all instances of the specified text. */ replaceAllText?: Schema$ReplaceAllTextRequest; + /** + * Replaces an image in the document. + */ + replaceImage?: Schema$ReplaceImageRequest; + /** + * Unmerges cells in a table. + */ + unmergeTableCells?: Schema$UnmergeTableCellsRequest; + /** + * Updates the style of the document. + */ + updateDocumentStyle?: Schema$UpdateDocumentStyleRequest; /** * Updates the paragraph style at the specified range. */ updateParagraphStyle?: Schema$UpdateParagraphStyleRequest; + /** + * Updates the style of table cells. + */ + updateTableCellStyle?: Schema$UpdateTableCellStyleRequest; /** * Updates the properties of columns in a table. */ @@ -2289,11 +2335,11 @@ export namespace docs_v1 { tableCellStyle?: Schema$TableCellStyle; } /** - * A border around a table cell. + * A border around a table cell. Table cell borders cannot be transparent. To hide a table cell border, make its width 0. */ export interface Schema$TableCellBorder { /** - * The color of the border. + * The color of the border. This color cannot be transparent. */ color?: Schema$OptionalColor; /** @@ -2347,7 +2393,7 @@ export namespace docs_v1 { */ borderTop?: Schema$TableCellBorder; /** - * The column span of the cell. This property is read-only. + * The column span of the cell. This property is read-only. */ columnSpan?: number; /** @@ -2371,7 +2417,7 @@ export namespace docs_v1 { */ paddingTop?: Schema$Dimension; /** - * The row span of the cell. This property is read-only. + * The row span of the cell. This property is read-only. */ rowSpan?: number; } @@ -2458,6 +2504,23 @@ export namespace docs_v1 { */ suggestedInsertionIds?: string[]; } + /** + * A table range represents a reference to a subset of a table. It's important to note that the cells specified by a table range do not necessarily form a rectangle. For example, let's say we have a 3 x 3 table where all the cells of the last row are merged together. The table looks like this: [ ] A table range with table cell location = (table_start_location, row = 0, column = 0), row span = 3 and column span = 2 specifies the following cells: x x [ x x x ] + */ + export interface Schema$TableRange { + /** + * The column span of the table range. + */ + columnSpan?: number; + /** + * The row span of the table range. + */ + rowSpan?: number; + /** + * The cell location where the table range starts. + */ + tableCellLocation?: Schema$TableCellLocation; + } /** * The contents and style of a row in a Table. */ @@ -2656,6 +2719,28 @@ export namespace docs_v1 { */ weightedFontFamilySuggested?: boolean; } + /** + * Unmerges cells in a Table. + */ + export interface Schema$UnmergeTableCellsRequest { + /** + * The table range specifying which cells of the table to unmerge. All merged cells in this range will be unmerged, and cells that are already unmerged will not be affected. If the range has no merged cells, the request will do nothing. If there is text in any of the merged cells, the text will remain in the "head" cell of the resulting block of unmerged cells. The "head" cell is the upper-left cell when the content direction is from left to right, and the upper-right otherwise. + */ + tableRange?: Schema$TableRange; + } + /** + * Updates the DocumentStyle. + */ + export interface Schema$UpdateDocumentStyleRequest { + /** + * The styles to set on the document. Certain document style changes may cause other changes in order to mirror the behavior of the Docs editor. See the documentation of DocumentStyle for more information. + */ + documentStyle?: Schema$DocumentStyle; + /** + * The fields that should be updated. At least one field must be specified. The root `document_style` is implied and should not be specified. A single `"*"` can be used as short-hand for listing every field. For example to update the background, set `fields` to `"background"`. + */ + fields?: string; + } /** * Update the styling of all paragraphs that overlap with the given range. */ @@ -2673,6 +2758,27 @@ export namespace docs_v1 { */ range?: Schema$Range; } + /** + * Updates the style of a range of table cells. + */ + export interface Schema$UpdateTableCellStyleRequest { + /** + * The fields that should be updated. At least one field must be specified. The root `tableCellStyle` is implied and should not be specified. A single `"*"` can be used as short-hand for listing every field. For example to update the table cell background color, set `fields` to `"backgroundColor"`. To reset a property to its default value, include its field name in the field mask but leave the field itself unset. + */ + fields?: string; + /** + * The style to set on the table cells. When updating borders, if a cell shares a border with an adjacent cell, the corresponding border property of the adjacent cell is updated as well. Borders that are merged and invisible are not updated. Since updating a border shared by adjacent cells in the same request can cause conflicting border updates, border updates are applied in the following order: - `border_right` - `border_left` - `border_bottom` - `border_top` + */ + tableCellStyle?: Schema$TableCellStyle; + /** + * The table range representing the subset of the table to which the updates are applied. + */ + tableRange?: Schema$TableRange; + /** + * The location where the table starts in the document. When specified, the updates are applied to all the cells in the table. + */ + tableStartLocation?: Schema$Location; + } /** * Updates the TableColumnProperties of columns in a table. */ @@ -2724,7 +2830,7 @@ export namespace docs_v1 { */ fields?: string; /** - * The range of text to style. The range may be extended to include adjacent newlines. If the range fully contains a paragraph belonging to a list, the paragraph's bullet is also updated with the matching text style. + * The range of text to style. The range may be extended to include adjacent newlines. If the range fully contains a paragraph belonging to a list, the paragraph's bullet is also updated with the matching text style. Ranges cannot be inserted inside a relative UpdateTextStyleRequest. */ range?: Schema$Range; /** diff --git a/src/apis/domainsrdap/README.md b/src/apis/domainsrdap/README.md new file mode 100644 index 00000000000..46b1c4af3e4 --- /dev/null +++ b/src/apis/domainsrdap/README.md @@ -0,0 +1,47 @@ +Google Inc. logo + +# domainsrdap + +> Read-only public API that lets users search for information about domain names. + +## Installation + +```sh +$ npm install googleapis +``` + +## Usage +All documentation and usage information can be found on [GitHub](https://github.com/googleapis/google-api-nodejs-client). + +## Building a browser bundle + +This library can be used in a browser. To prepare a single file bundle, clone the +[repository](https://github.com/googleapis/google-api-nodejs-client) and run + +```sh +$ cd src/apis/domainsrdap +$ npm install +$ npm run webpack +``` + +The generated bundle will be written to `dist/domainsrdap.min.js`. Use it from your HTML file: + +```html + + +``` + +## License +This library is licensed under Apache 2.0. Full license text is available in [LICENSE](https://github.com/googleapis/google-api-nodejs-client/blob/master/LICENSE). + +## Contributing +We love contributions! Before submitting a Pull Request, it's always good to start with a new issue first. To learn more, see [CONTRIBUTING](https://github.com/google/google-api-nodejs-client/blob/master/.github/CONTRIBUTING.md). + +## Questions/problems? +* Ask your development related questions on [StackOverflow](http://stackoverflow.com/questions/tagged/google-api-nodejs-client). +* If you've found an bug/issue, please [file it on GitHub](https://github.com/googleapis/google-api-nodejs-client/issues). + + +*Crafted with ❤️ by the Google Node.js team* diff --git a/src/apis/domainsrdap/index.ts b/src/apis/domainsrdap/index.ts new file mode 100644 index 00000000000..a9507d48272 --- /dev/null +++ b/src/apis/domainsrdap/index.ts @@ -0,0 +1,35 @@ +// Copyright 2019 Google LLC +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! THIS FILE IS AUTO-GENERATED */ + +import {AuthPlus, getAPI, GoogleConfigurable} from 'googleapis-common'; +import {domainsrdap_v1} from './v1'; + +export const VERSIONS = { + v1: domainsrdap_v1.Domainsrdap, +}; + +export function domainsrdap(version: 'v1'): domainsrdap_v1.Domainsrdap; +export function domainsrdap( + options: domainsrdap_v1.Options +): domainsrdap_v1.Domainsrdap; +export function domainsrdap( + this: GoogleConfigurable, + versionOrOptions: 'v1' | domainsrdap_v1.Options +) { + return getAPI('domainsrdap', versionOrOptions, VERSIONS, this); +} + +const auth = new AuthPlus(); +export {auth}; diff --git a/src/apis/domainsrdap/package.json b/src/apis/domainsrdap/package.json new file mode 100644 index 00000000000..60b5432a4dd --- /dev/null +++ b/src/apis/domainsrdap/package.json @@ -0,0 +1,43 @@ +{ + "name": "@google/domainsrdap", + "version": "0.1.0", + "description": "domainsrdap", + "main": "build/index.js", + "types": "build/index.d.ts", + "keywords": [ + "google" + ], + "author": "Google LLC", + "license": "Apache-2.0", + "homepage": "https://github.com/googleapis/google-api-nodejs-client", + "bugs": { + "url": "https://github.com/googleapis/google-api-nodejs-client/issues" + }, + "repository": { + "type": "git", + "url": "https://github.com/googleapis/google-api-nodejs-client.git" + }, + "engines": { + "node": ">=8.0.0" + }, + "scripts": { + "fix": "gts fix", + "lint": "gts check", + "compile": "tsc -p .", + "prepare": "npm run compile", + "docs": "typedoc --out docs/", + "webpack": "webpack" + }, + "dependencies": { + "googleapis-common": "^3.0.0" + }, + "devDependencies": { + "gts": "^1.0.0", + "null-loader": "^3.0.0", + "ts-loader": "^6.0.4", + "typedoc": "^0.15.0", + "typescript": "~3.6.0", + "webpack": "^4.35.3", + "webpack-cli": "^3.3.5" + } +} diff --git a/src/apis/domainsrdap/tsconfig.json b/src/apis/domainsrdap/tsconfig.json new file mode 100644 index 00000000000..e0810904968 --- /dev/null +++ b/src/apis/domainsrdap/tsconfig.json @@ -0,0 +1,10 @@ +{ + "extends": "./node_modules/gts/tsconfig-google.json", + "compilerOptions": { + "rootDir": ".", + "outDir": "build" + }, + "include": [ + "*.ts", + ] +} diff --git a/src/apis/domainsrdap/v1.ts b/src/apis/domainsrdap/v1.ts new file mode 100644 index 00000000000..d8bbb9a66a5 --- /dev/null +++ b/src/apis/domainsrdap/v1.ts @@ -0,0 +1,1078 @@ +/** + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { + OAuth2Client, + JWT, + Compute, + UserRefreshClient, +} from 'google-auth-library'; +import { + GoogleConfigurable, + createAPIRequest, + MethodOptions, + GlobalOptions, + BodyResponseCallback, + APIRequestContext, +} from 'googleapis-common'; +import {GaxiosPromise} from 'gaxios'; + +// tslint:disable: no-any +// tslint:disable: class-name +// tslint:disable: variable-name +// tslint:disable: jsdoc-format +// tslint:disable: no-namespace + +export namespace domainsrdap_v1 { + export interface Options extends GlobalOptions { + version: 'v1'; + } + + interface StandardParameters { + /** + * V1 error format. + */ + '$.xgafv'?: string; + /** + * OAuth access token. + */ + access_token?: string; + /** + * Data format for response. + */ + alt?: string; + /** + * JSONP + */ + callback?: string; + /** + * Selector specifying which fields to include in a partial response. + */ + fields?: string; + /** + * 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. + */ + key?: string; + /** + * OAuth 2.0 token for the current user. + */ + oauth_token?: string; + /** + * Returns response with indentations and line breaks. + */ + prettyPrint?: boolean; + /** + * 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. + */ + quotaUser?: string; + /** + * Legacy upload protocol for media (e.g. "media", "multipart"). + */ + uploadType?: string; + /** + * Upload protocol for media (e.g. "raw", "multipart"). + */ + upload_protocol?: string; + } + + /** + * Domains RDAP API + * + * Read-only public API that lets users search for information about domain names. + * + * @example + * const {google} = require('googleapis'); + * const domainsrdap = google.domainsrdap('v1'); + * + * @namespace domainsrdap + * @type {Function} + * @version v1 + * @variation v1 + * @param {object=} options Options for Domainsrdap + */ + export class Domainsrdap { + context: APIRequestContext; + autnum: Resource$Autnum; + domain: Resource$Domain; + entity: Resource$Entity; + ip: Resource$Ip; + nameserver: Resource$Nameserver; + v1: Resource$V1; + + constructor(options: GlobalOptions, google?: GoogleConfigurable) { + this.context = { + _options: options || {}, + google, + }; + + this.autnum = new Resource$Autnum(this.context); + this.domain = new Resource$Domain(this.context); + this.entity = new Resource$Entity(this.context); + this.ip = new Resource$Ip(this.context); + this.nameserver = new Resource$Nameserver(this.context); + this.v1 = new Resource$V1(this.context); + } + } + + /** + * Message that represents an arbitrary HTTP body. It should only be used for payload formats that can't be represented as JSON, such as raw binary or an HTML page. This message can be used both in streaming and non-streaming API methods in the request as well as the response. It can be used as a top-level request field, which is convenient if one wants to extract parameters from either the URL or HTTP template into the request fields and also want access to the raw HTTP body. Example: message GetResourceRequest { // A unique request id. string request_id = 1; // The raw HTTP body is bound to this field. google.api.HttpBody http_body = 2; } service ResourceService { rpc GetResource(GetResourceRequest) returns (google.api.HttpBody); rpc UpdateResource(google.api.HttpBody) returns (google.protobuf.Empty); } Example with streaming methods: service CaldavService { rpc GetCalendar(stream google.api.HttpBody) returns (stream google.api.HttpBody); rpc UpdateCalendar(stream google.api.HttpBody) returns (stream google.api.HttpBody); } Use of this type only changes how the request and response bodies are handled, all other features will continue to work unchanged. + */ + export interface Schema$HttpBody { + /** + * The HTTP Content-Type header value specifying the content type of the body. + */ + contentType?: string; + /** + * The HTTP request/response body as raw binary. + */ + data?: string; + /** + * Application specific response metadata. Must be set in the first response for streaming APIs. + */ + extensions?: Array<{[key: string]: any}>; + } + /** + * Links object defined in [section 4.2 of RFC 7483](https://tools.ietf.org/html/rfc7483#section-4.2). + */ + export interface Schema$Link { + /** + * Target URL of a link. Example: "http://example.com/previous". + */ + href?: string; + /** + * Language code of a link. Example: "en". + */ + hreflang?: string; + /** + * Media type of the link destination. Example: "screen". + */ + media?: string; + /** + * Relation type of a link. Example: "previous". + */ + rel?: string; + /** + * Title of this link. Example: "title". + */ + title?: string; + /** + * Content type of the link. Example: "application/json". + */ + type?: string; + /** + * URL giving context for the link. Example: "http://example.com/current". + */ + value?: string; + } + /** + * Notices object defined in [section 4.3 of RFC 7483](https://tools.ietf.org/html/rfc7483#section-4.3). + */ + export interface Schema$Notice { + /** + * Description of the notice. + */ + description?: string[]; + /** + * Link to a document containing more information. + */ + links?: Schema$Link[]; + /** + * Title of a notice. Example: "Terms of Service". + */ + title?: string; + /** + * Type values defined in [section 10.2.1 of RFC 7483](https://tools.ietf.org/html/rfc7483#section-10.2.1) specific to a whole response: "result set truncated due to authorization", "result set truncated due to excessive load", "result set truncated due to unexplainable reasons". + */ + type?: string; + } + /** + * Response to a general RDAP query. + */ + export interface Schema$RdapResponse { + /** + * Error description. + */ + description?: string[]; + /** + * Error HTTP code. Example: "501". + */ + errorCode?: number; + /** + * HTTP response with content type set to "application/json+rdap". + */ + jsonResponse?: Schema$HttpBody; + /** + * Error language code. Error response info fields are defined in [section 6 of RFC 7483](https://tools.ietf.org/html/rfc7483#section-6). + */ + lang?: string; + /** + * Notices applying to this response. + */ + notices?: Schema$Notice[]; + /** + * RDAP conformance level. + */ + rdapConformance?: string[]; + /** + * Error title. + */ + title?: string; + } + + export class Resource$Autnum { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * domainsrdap.autnum.get + * @desc The RDAP API recognizes this command from the RDAP specification but does not support it. The response is a formatted 501 error. + * @alias domainsrdap.autnum.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.autnumId + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Autnum$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Autnum$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Autnum$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Autnum$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Autnum$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Autnum$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://domainsrdap.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/autnum/{autnumId}').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['autnumId'], + pathParams: ['autnumId'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Autnum$Get extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * + */ + autnumId?: string; + } + + export class Resource$Domain { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * domainsrdap.domain.get + * @desc Look up RDAP information for a domain by name. + * @alias domainsrdap.domain.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.domainName Full domain name to look up. Example: "example.com" + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Domain$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Domain$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Domain$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Domain$Get + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Domain$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Domain$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://domainsrdap.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/domain/{+domainName}').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['domainName'], + pathParams: ['domainName'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Domain$Get extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Full domain name to look up. Example: "example.com" + */ + domainName?: string; + } + + export class Resource$Entity { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * domainsrdap.entity.get + * @desc The RDAP API recognizes this command from the RDAP specification but does not support it. The response is a formatted 501 error. + * @alias domainsrdap.entity.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.entityId + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Entity$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Entity$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Entity$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Entity$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Entity$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Entity$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://domainsrdap.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/entity/{entityId}').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['entityId'], + pathParams: ['entityId'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Entity$Get extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * + */ + entityId?: string; + } + + export class Resource$Ip { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * domainsrdap.ip.get + * @desc The RDAP API recognizes this command from the RDAP specification but does not support it. The response is a formatted 501 error. + * @alias domainsrdap.ip.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.ipId + * @param {string} params.ipId1 + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Ip$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Ip$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Ip$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Ip$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Ip$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Ip$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://domainsrdap.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/ip/{ipId}/{ipId1}').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['ipId', 'ipId1'], + pathParams: ['ipId', 'ipId1'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Ip$Get extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * + */ + ipId?: string; + /** + * + */ + ipId1?: string; + } + + export class Resource$Nameserver { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * domainsrdap.nameserver.get + * @desc The RDAP API recognizes this command from the RDAP specification but does not support it. The response is a formatted 501 error. + * @alias domainsrdap.nameserver.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.nameserverId + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Nameserver$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Nameserver$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Nameserver$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Nameserver$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Nameserver$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Nameserver$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://domainsrdap.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/nameserver/{nameserverId}').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['nameserverId'], + pathParams: ['nameserverId'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Nameserver$Get extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * + */ + nameserverId?: string; + } + + export class Resource$V1 { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * domainsrdap.getDomains + * @desc The RDAP API recognizes this command from the RDAP specification but does not support it. The response is a formatted 501 error. + * @alias domainsrdap.getDomains + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + getDomains( + params?: Params$Resource$V1$Getdomains, + options?: MethodOptions + ): GaxiosPromise; + getDomains( + params: Params$Resource$V1$Getdomains, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + getDomains( + params: Params$Resource$V1$Getdomains, + callback: BodyResponseCallback + ): void; + getDomains(callback: BodyResponseCallback): void; + getDomains( + paramsOrCallback?: + | Params$Resource$V1$Getdomains + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$V1$Getdomains; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$V1$Getdomains; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://domainsrdap.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/domains').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * domainsrdap.getEntities + * @desc The RDAP API recognizes this command from the RDAP specification but does not support it. The response is a formatted 501 error. + * @alias domainsrdap.getEntities + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + getEntities( + params?: Params$Resource$V1$Getentities, + options?: MethodOptions + ): GaxiosPromise; + getEntities( + params: Params$Resource$V1$Getentities, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + getEntities( + params: Params$Resource$V1$Getentities, + callback: BodyResponseCallback + ): void; + getEntities(callback: BodyResponseCallback): void; + getEntities( + paramsOrCallback?: + | Params$Resource$V1$Getentities + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$V1$Getentities; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$V1$Getentities; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://domainsrdap.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/entities').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * domainsrdap.getHelp + * @desc Get help information for the RDAP API, including links to documentation. + * @alias domainsrdap.getHelp + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + getHelp( + params?: Params$Resource$V1$Gethelp, + options?: MethodOptions + ): GaxiosPromise; + getHelp( + params: Params$Resource$V1$Gethelp, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + getHelp( + params: Params$Resource$V1$Gethelp, + callback: BodyResponseCallback + ): void; + getHelp(callback: BodyResponseCallback): void; + getHelp( + paramsOrCallback?: + | Params$Resource$V1$Gethelp + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$V1$Gethelp; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$V1$Gethelp; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://domainsrdap.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/help').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * domainsrdap.getIp + * @desc The RDAP API recognizes this command from the RDAP specification but does not support it. The response is a formatted 501 error. + * @alias domainsrdap.getIp + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + getIp( + params?: Params$Resource$V1$Getip, + options?: MethodOptions + ): GaxiosPromise; + getIp( + params: Params$Resource$V1$Getip, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + getIp( + params: Params$Resource$V1$Getip, + callback: BodyResponseCallback + ): void; + getIp(callback: BodyResponseCallback): void; + getIp( + paramsOrCallback?: + | Params$Resource$V1$Getip + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$V1$Getip; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$V1$Getip; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://domainsrdap.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/ip').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * domainsrdap.getNameservers + * @desc The RDAP API recognizes this command from the RDAP specification but does not support it. The response is a formatted 501 error. + * @alias domainsrdap.getNameservers + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + getNameservers( + params?: Params$Resource$V1$Getnameservers, + options?: MethodOptions + ): GaxiosPromise; + getNameservers( + params: Params$Resource$V1$Getnameservers, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + getNameservers( + params: Params$Resource$V1$Getnameservers, + callback: BodyResponseCallback + ): void; + getNameservers(callback: BodyResponseCallback): void; + getNameservers( + paramsOrCallback?: + | Params$Resource$V1$Getnameservers + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$V1$Getnameservers; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$V1$Getnameservers; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://domainsrdap.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/nameservers').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$V1$Getdomains extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + } + export interface Params$Resource$V1$Getentities extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + } + export interface Params$Resource$V1$Gethelp extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + } + export interface Params$Resource$V1$Getip extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + } + export interface Params$Resource$V1$Getnameservers + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + } +} diff --git a/src/apis/domainsrdap/webpack.config.js b/src/apis/domainsrdap/webpack.config.js new file mode 100644 index 00000000000..5a0038754a7 --- /dev/null +++ b/src/apis/domainsrdap/webpack.config.js @@ -0,0 +1,71 @@ +/** + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Use `npm run webpack` to produce Webpack bundle for this library. + +const path = require('path'); + +module.exports = { + entry: './index.ts', + resolve: { + extensions: ['.ts', '.js', '.json'], + }, + output: { + library: 'Domainsrdap', + filename: 'domainsrdap.min.js', + path: path.resolve(__dirname, 'dist'), + }, + node: { + child_process: 'empty', + fs: 'empty', + crypto: 'empty', + }, + module: { + rules: [ + { + test: /node_modules[\\/]google-auth-library[\\/]src[\\/]crypto[\\/]node[\\/]crypto/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]https-proxy-agent[\\/]/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]gcp-metadata[\\/]/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]gtoken[\\/]/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]pkginfo[\\/]/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]semver[\\/]/, + use: 'null-loader', + }, + { + test: /\.ts$/, + use: 'ts-loader', + exclude: /node_modules/, + }, + ], + }, + mode: 'production', + plugins: [], +}; diff --git a/src/apis/doubleclicksearch/v2.ts b/src/apis/doubleclicksearch/v2.ts index 5ffcf4f7183..32dfcb380cf 100644 --- a/src/apis/doubleclicksearch/v2.ts +++ b/src/apis/doubleclicksearch/v2.ts @@ -73,7 +73,7 @@ export namespace doubleclicksearch_v2 { } /** - * DoubleClick Search API + * Search Ads 360 API * * Reports and modifies your advertising data in DoubleClick Search (for example, campaigns, ad groups, keywords, and conversions). * @@ -315,7 +315,7 @@ export namespace doubleclicksearch_v2 { */ export interface Schema$Report { /** - * Asynchronous report only. Contains a list of generated report files once the report has succesfully completed. + * Asynchronous report only. Contains a list of generated report files once the report has successfully completed. */ files?: Array<{byteCount?: string; url?: string}>; /** diff --git a/src/apis/drive/v2.ts b/src/apis/drive/v2.ts index 26ade0ffe5b..8e0607a6dea 100644 --- a/src/apis/drive/v2.ts +++ b/src/apis/drive/v2.ts @@ -857,6 +857,7 @@ export namespace drive_v2 { canDownload?: boolean; canEdit?: boolean; canListChildren?: boolean; + canModifyContent?: boolean; canMoveChildrenOutOfDrive?: boolean; canMoveChildrenOutOfTeamDrive?: boolean; canMoveChildrenWithinDrive?: boolean; diff --git a/src/apis/drive/v3.ts b/src/apis/drive/v3.ts index db3964d4101..c0a0f9d48b1 100644 --- a/src/apis/drive/v3.ts +++ b/src/apis/drive/v3.ts @@ -491,6 +491,7 @@ export namespace drive_v3 { canDownload?: boolean; canEdit?: boolean; canListChildren?: boolean; + canModifyContent?: boolean; canMoveChildrenOutOfDrive?: boolean; canMoveChildrenOutOfTeamDrive?: boolean; canMoveChildrenWithinDrive?: boolean; diff --git a/src/apis/driveactivity/v2.ts b/src/apis/driveactivity/v2.ts index 4ec572e631e..4ea0ec3d49c 100644 --- a/src/apis/driveactivity/v2.ts +++ b/src/apis/driveactivity/v2.ts @@ -409,7 +409,7 @@ export namespace driveactivity_v2 { */ driveFile?: Schema$DriveFile; /** - * The Drive item is a folder. + * The Drive item is a folder. Includes information about the type of folder. */ driveFolder?: Schema$DriveFolder; /** diff --git a/src/apis/factchecktools/v1alpha1.ts b/src/apis/factchecktools/v1alpha1.ts index 1df5516ec03..b9d8bc203d5 100644 --- a/src/apis/factchecktools/v1alpha1.ts +++ b/src/apis/factchecktools/v1alpha1.ts @@ -173,6 +173,10 @@ export namespace factchecktools_v1alpha1 { * Corresponds to `ClaimReview.reviewRating.image`. */ imageUrl?: string; + /** + * Corresponds to `ClaimReview.reviewRating.ratingExplanation`. + */ + ratingExplanation?: string; /** * A numeric rating of this claim, in the range worstRating — bestRating inclusive.<br> Corresponds to `ClaimReview.reviewRating.ratingValue`. */ diff --git a/src/apis/fcm/v1.ts b/src/apis/fcm/v1.ts index 20fc3b0e5dd..26f20e568ae 100644 --- a/src/apis/fcm/v1.ts +++ b/src/apis/fcm/v1.ts @@ -187,6 +187,22 @@ export namespace fcm_v1 { * The notification's icon color, expressed in #rrggbb format. */ color?: string; + /** + * If set to true, use the Android framework's default LED light settings for the notification. Default values are specified in [config.xml](https://android.googlesource.com/platform/frameworks/base/+/master/core/res/res/values/config.xml). If `default_light_settings` is set to true and `light_settings` is also set, the user-specified `light_settings` is used instead of the default value. + */ + defaultLightSettings?: boolean; + /** + * If set to true, use the Android framework's default sound for the notification. Default values are specified in [config.xml](https://android.googlesource.com/platform/frameworks/base/+/master/core/res/res/values/config.xml). + */ + defaultSound?: boolean; + /** + * If set to true, use the Android framework's default vibrate pattern for the notification. Default values are specified in [config.xml](https://android.googlesource.com/platform/frameworks/base/+/master/core/res/res/values/config.xml). If `default_vibrate_timings` is set to true and `vibrate_timings` is also set, the default value is used instead of the user-specified `vibrate_timings`. + */ + defaultVibrateTimings?: boolean; + /** + * Set the time that the event in the notification occurred. Notifications in the panel are sorted by this time. A point in time is represented using [protobuf.Timestamp](https://developers.google.com/protocol-buffers/docs/reference/java/com/google/protobuf/Timestamp). + */ + eventTime?: string; /** * The notification's icon. Sets the notification icon to myicon for drawable resource myicon. If you don't send this key in the request, FCM displays the launcher icon specified in your app manifest. */ @@ -195,14 +211,38 @@ export namespace fcm_v1 { * Contains the URL of an image that is going to be displayed in a notification. If present, it will override google.firebase.fcm.v1.Notification.image. */ image?: string; + /** + * Settings to control the notification's LED blinking rate and color if LED is available on the device. The total blinking time is controlled by the OS. + */ + lightSettings?: Schema$LightSettings; + /** + * Set whether or not this notification is relevant only to the current device. Some notifications can be bridged to other devices for remote display, such as a Wear OS watch. This hint can be set to recommend this notification not be bridged. See [Wear OS guides](https://developer.android.com/training/wearables/notifications/bridger#existing-method-of-preventing-bridging) + */ + localOnly?: boolean; + /** + * Sets the number of items this notification represents. May be displayed as a badge count for launchers that support badging.See [Notification Badge](https://developer.android.com/training/notify-user/badges). For example, this might be useful if you're using just one notification to represent multiple new messages but you want the count here to represent the number of total new messages. If zero or unspecified, systems that support badging use the default, which is to increment a number displayed on the long-press menu each time a new notification arrives. + */ + notificationCount?: number; + /** + * Set the relative priority for this notification. Priority is an indication of how much of the user's attention should be consumed by this notification. Low-priority notifications may be hidden from the user in certain situations, while the user might be interrupted for a higher-priority notification. The effect of setting the same priorities may differ slightly on different platforms. Note this priority differs from `AndroidMessagePriority`. This priority is processed by the client after the message has been delivered, whereas [AndroidMessagePriority](https://firebase.google.com/docs/reference/fcm/rest/v1/projects.messages#androidmessagepriority) is an FCM concept that controls when the message is delivered. + */ + notificationPriority?: string; /** * The sound to play when the device receives the notification. Supports "default" or the filename of a sound resource bundled in the app. Sound files must reside in /res/raw/. */ sound?: string; + /** + * When set to false or unset, the notification is automatically dismissed when the user clicks it in the panel. When set to true, the notification persists even when the user clicks it. + */ + sticky?: boolean; /** * Identifier used to replace existing notifications in the notification drawer. If not specified, each request creates a new notification. If specified and a notification with the same tag is already being shown, the new notification replaces the existing one in the notification drawer. */ tag?: string; + /** + * Sets the "ticker" text, which is sent to accessibility services. Prior to API level 21 (`Lollipop`), sets the text that is displayed in the status bar when the notification first arrives. + */ + ticker?: string; /** * The notification's title. If present, it will override google.firebase.fcm.v1.Notification.title. */ @@ -215,6 +255,14 @@ export namespace fcm_v1 { * The key to the title string in the app's string resources to use to localize the title text to the user's current localization. See [String Resources](https://goo.gl/NdFZGI) for more information. */ titleLocKey?: string; + /** + * Set the vibration pattern to use. Pass in an array of [protobuf.Duration](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Duration) to turn on or off the vibrator. The first value indicates the `Duration` to wait before turning the vibrator on. The next value indicates the `Duration` to keep the vibrator on. Subsequent values alternate between `Duration` to turn the vibrator off and to turn the vibrator on. If `vibrate_timings` is set and `default_vibrate_timings` is set to `true`, the default value is used instead of the user-specified `vibrate_timings`. + */ + vibrateTimings?: string[]; + /** + * Set the [Notification.visibility](https://developer.android.com/reference/android/app/Notification.html#visibility) of the notification. + */ + visibility?: string; } /** * [Apple Push Notification Service](https://goo.gl/MXRTPa) specific options. @@ -246,6 +294,27 @@ export namespace fcm_v1 { */ image?: string; } + /** + * Represents a color in the RGBA color space. This representation is designed for simplicity of conversion to/from color representations in various languages over compactness; for example, the fields of this representation can be trivially provided to the constructor of "java.awt.Color" in Java; it can also be trivially provided to UIColor's "+colorWithRed:green:blue:alpha" method in iOS; and, with just a little work, it can be easily formatted into a CSS "rgba()" string in JavaScript, as well. Note: this proto does not carry information about the absolute color space that should be used to interpret the RGB value (e.g. sRGB, Adobe RGB, DCI-P3, BT.2020, etc.). By default, applications SHOULD assume the sRGB color space. Example (Java): import com.google.type.Color; // ... public static java.awt.Color fromProto(Color protocolor) { float alpha = protocolor.hasAlpha() ? protocolor.getAlpha().getValue() : 1.0; return new java.awt.Color( protocolor.getRed(), protocolor.getGreen(), protocolor.getBlue(), alpha); } public static Color toProto(java.awt.Color color) { float red = (float) color.getRed(); float green = (float) color.getGreen(); float blue = (float) color.getBlue(); float denominator = 255.0; Color.Builder resultBuilder = Color .newBuilder() .setRed(red / denominator) .setGreen(green / denominator) .setBlue(blue / denominator); int alpha = color.getAlpha(); if (alpha != 255) { result.setAlpha( FloatValue .newBuilder() .setValue(((float) alpha) / denominator) .build()); } return resultBuilder.build(); } // ... Example (iOS / Obj-C): // ... static UIColor* fromProto(Color* protocolor) { float red = [protocolor red]; float green = [protocolor green]; float blue = [protocolor blue]; FloatValue* alpha_wrapper = [protocolor alpha]; float alpha = 1.0; if (alpha_wrapper != nil) { alpha = [alpha_wrapper value]; } return [UIColor colorWithRed:red green:green blue:blue alpha:alpha]; } static Color* toProto(UIColor* color) { CGFloat red, green, blue, alpha; if (![color getRed:&red green:&green blue:&blue alpha:&alpha]) { return nil; } Color* result = [[Color alloc] init]; [result setRed:red]; [result setGreen:green]; [result setBlue:blue]; if (alpha <= 0.9999) { [result setAlpha:floatWrapperWithValue(alpha)]; } [result autorelease]; return result; } // ... Example (JavaScript): // ... var protoToCssColor = function(rgb_color) { var redFrac = rgb_color.red || 0.0; var greenFrac = rgb_color.green || 0.0; var blueFrac = rgb_color.blue || 0.0; var red = Math.floor(redFrac * 255); var green = Math.floor(greenFrac * 255); var blue = Math.floor(blueFrac * 255); if (!('alpha' in rgb_color)) { return rgbToCssColor_(red, green, blue); } var alphaFrac = rgb_color.alpha.value || 0.0; var rgbParams = [red, green, blue].join(','); return ['rgba(', rgbParams, ',', alphaFrac, ')'].join(''); }; var rgbToCssColor_ = function(red, green, blue) { var rgbNumber = new Number((red << 16) | (green << 8) | blue); var hexString = rgbNumber.toString(16); var missingZeros = 6 - hexString.length; var resultBuilder = ['#']; for (var i = 0; i < missingZeros; i++) { resultBuilder.push('0'); } resultBuilder.push(hexString); return resultBuilder.join(''); }; // ... + */ + export interface Schema$Color { + /** + * The fraction of this color that should be applied to the pixel. That is, the final pixel color is defined by the equation: pixel color = alpha * (this color) + (1.0 - alpha) * (background color) This means that a value of 1.0 corresponds to a solid color, whereas a value of 0.0 corresponds to a completely transparent color. This uses a wrapper message rather than a simple float scalar so that it is possible to distinguish between a default value and the value being unset. If omitted, this color object is to be rendered as a solid color (as if the alpha value had been explicitly given with a value of 1.0). + */ + alpha?: number; + /** + * The amount of blue in the color as a value in the interval [0, 1]. + */ + blue?: number; + /** + * The amount of green in the color as a value in the interval [0, 1]. + */ + green?: number; + /** + * The amount of red in the color as a value in the interval [0, 1]. + */ + red?: number; + } /** * Platform independent options for features provided by the FCM SDKs. */ @@ -255,6 +324,23 @@ export namespace fcm_v1 { */ analyticsLabel?: string; } + /** + * Settings to control notification LED. + */ + export interface Schema$LightSettings { + /** + * Required. Set `color` of the LED with [google.type.Color](https://github.com/googleapis/googleapis/blob/master/google/type/color.proto). + */ + color?: Schema$Color; + /** + * Required. Along with `light_on_duration `, define the blink rate of LED flashes. Resolution defined by [proto.Duration](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Duration) + */ + lightOffDuration?: string; + /** + * Required. Along with `light_off_duration`, define the blink rate of LED flashes. Resolution defined by [proto.Duration](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Duration) + */ + lightOnDuration?: string; + } /** * Message to send by Firebase Cloud Messaging Service. */ diff --git a/src/apis/file/v1.ts b/src/apis/file/v1.ts index 12eae7b7c5f..82df3292237 100644 --- a/src/apis/file/v1.ts +++ b/src/apis/file/v1.ts @@ -139,9 +139,13 @@ export namespace file_v1 { name?: string; } /** - * Instance represents the interface for SLM services to actuate the state of control plane resources. Example Instance in JSON, where consumer-project=snapchat, producer-project=cloud-sql: ```json Instance: { "name": "projects/snapchat/locations/us-east1/instances/prod-instance", "create_time": { "seconds": 1526406431, }, "labels": { "env": "prod", "foo": "bar" }, "state": READY, "software_versions": { "software_update": "cloud-sql-09-28-2018", }, "maintenance_policy_names": { "UpdatePolicy": "projects/snapchat/locations/us-east1/maintenancePolicies/prod-update-policy", } "rollout_metadata": { "projects/cloud-sql/locations/global/rolloutTypes/software_update": { "release": "projects/cloud-sql/locations/global/releases/cloud-sql-09-28-2018", "rollout": "projects/cloud-sql/locations/us-east1/rollouts/cloud-sql-09-28-2018-canary", }, "projects/cloud-sql/locations/global/rolloutTypes/instance_restart": { "release": "projects/cloud-sql/locations/global/releases/cloud-sql-09-20-repair", "rollout": "projects/cloud-sql/locations/us-east1/rollouts/cloud-sql-09-20-repair-100-percent", } } "tenant_project_id": "cloud-sql-test-tenant", "producer_metadata": { "cloud-sql-tier": "basic", "cloud-sql-instance-size": "1G", }, "provisioned_resources": [ { "resource-type": "compute-instance", "resource-url": "https://www.googleapis.com/compute/v1/projects/cloud-sql/zones/us-east1-b/instances/vm-1", } ], "maintenance_schedules": { "csa_rollout": { "start_time": { "seconds": 1526406431, }, "end_time": { "seconds": 1535406431, }, }, "ncsa_rollout": { "start_time": { "seconds": 1526406431, }, "end_time": { "seconds": 1535406431, }, } } } ``` + * Instance represents the interface for SLM services to actuate the state of control plane resources. Example Instance in JSON, where consumer-project=snapchat, producer-project=cloud-sql: ```json Instance: { "name": "projects/snapchat/locations/us-east1/instances/prod-instance", "create_time": { "seconds": 1526406431, }, "labels": { "env": "prod", "foo": "bar" }, "state": READY, "software_versions": { "software_update": "cloud-sql-09-28-2018", }, "maintenance_policy_names": { "UpdatePolicy": "projects/snapchat/locations/us-east1/maintenancePolicies/prod-update-policy", } "rollout_metadata": { "projects/cloud-sql/locations/global/rolloutTypes/software_update": { "release": "projects/cloud-sql/locations/global/releases/cloud-sql-09-28-2018", "rollout": "projects/cloud-sql/locations/us-east1/rollouts/cloud-sql-09-28-2018-canary", }, "projects/cloud-sql/locations/global/rolloutTypes/instance_restart": { "release": "projects/cloud-sql/locations/global/releases/cloud-sql-09-20-repair", "rollout": "projects/cloud-sql/locations/us-east1/rollouts/cloud-sql-09-20-repair-100-percent", } } "tenant_project_id": "cloud-sql-test-tenant", "producer_metadata": { "cloud-sql-tier": "basic", "cloud-sql-instance-size": "1G", }, "provisioned_resources": [ { "resource-type": "compute-instance", "resource-url": "https://www.googleapis.com/compute/v1/projects/cloud-sql/zones/us-east1-b/instances/vm-1", } ], "maintenance_schedules": { "csa_rollout": { "start_time": { "seconds": 1526406431, }, "end_time": { "seconds": 1535406431, }, }, "ncsa_rollout": { "start_time": { "seconds": 1526406431, }, "end_time": { "seconds": 1535406431, }, } }, "consumer_defined_name": "my-sql-instance1", } ``` */ export interface Schema$GoogleCloudSaasacceleratorManagementProvidersV1Instance { + /** + * consumer_defined_name is the name that is set by the consumer. On the other hand Name field represents system-assigned id of an instance so consumers are not necessarily aware of it. consumer_defined_name is used for notification/UI purposes for consumer to recognize their instances. + */ + consumerDefinedName?: string; /** * Output only. Timestamp when the resource was created. */ diff --git a/src/apis/file/v1beta1.ts b/src/apis/file/v1beta1.ts index 98d8b2e86da..1a2e9fc0868 100644 --- a/src/apis/file/v1beta1.ts +++ b/src/apis/file/v1beta1.ts @@ -139,9 +139,13 @@ export namespace file_v1beta1 { name?: string; } /** - * Instance represents the interface for SLM services to actuate the state of control plane resources. Example Instance in JSON, where consumer-project=snapchat, producer-project=cloud-sql: ```json Instance: { "name": "projects/snapchat/locations/us-east1/instances/prod-instance", "create_time": { "seconds": 1526406431, }, "labels": { "env": "prod", "foo": "bar" }, "state": READY, "software_versions": { "software_update": "cloud-sql-09-28-2018", }, "maintenance_policy_names": { "UpdatePolicy": "projects/snapchat/locations/us-east1/maintenancePolicies/prod-update-policy", } "rollout_metadata": { "projects/cloud-sql/locations/global/rolloutTypes/software_update": { "release": "projects/cloud-sql/locations/global/releases/cloud-sql-09-28-2018", "rollout": "projects/cloud-sql/locations/us-east1/rollouts/cloud-sql-09-28-2018-canary", }, "projects/cloud-sql/locations/global/rolloutTypes/instance_restart": { "release": "projects/cloud-sql/locations/global/releases/cloud-sql-09-20-repair", "rollout": "projects/cloud-sql/locations/us-east1/rollouts/cloud-sql-09-20-repair-100-percent", } } "tenant_project_id": "cloud-sql-test-tenant", "producer_metadata": { "cloud-sql-tier": "basic", "cloud-sql-instance-size": "1G", }, "provisioned_resources": [ { "resource-type": "compute-instance", "resource-url": "https://www.googleapis.com/compute/v1/projects/cloud-sql/zones/us-east1-b/instances/vm-1", } ], "maintenance_schedules": { "csa_rollout": { "start_time": { "seconds": 1526406431, }, "end_time": { "seconds": 1535406431, }, }, "ncsa_rollout": { "start_time": { "seconds": 1526406431, }, "end_time": { "seconds": 1535406431, }, } } } ``` + * Instance represents the interface for SLM services to actuate the state of control plane resources. Example Instance in JSON, where consumer-project=snapchat, producer-project=cloud-sql: ```json Instance: { "name": "projects/snapchat/locations/us-east1/instances/prod-instance", "create_time": { "seconds": 1526406431, }, "labels": { "env": "prod", "foo": "bar" }, "state": READY, "software_versions": { "software_update": "cloud-sql-09-28-2018", }, "maintenance_policy_names": { "UpdatePolicy": "projects/snapchat/locations/us-east1/maintenancePolicies/prod-update-policy", } "rollout_metadata": { "projects/cloud-sql/locations/global/rolloutTypes/software_update": { "release": "projects/cloud-sql/locations/global/releases/cloud-sql-09-28-2018", "rollout": "projects/cloud-sql/locations/us-east1/rollouts/cloud-sql-09-28-2018-canary", }, "projects/cloud-sql/locations/global/rolloutTypes/instance_restart": { "release": "projects/cloud-sql/locations/global/releases/cloud-sql-09-20-repair", "rollout": "projects/cloud-sql/locations/us-east1/rollouts/cloud-sql-09-20-repair-100-percent", } } "tenant_project_id": "cloud-sql-test-tenant", "producer_metadata": { "cloud-sql-tier": "basic", "cloud-sql-instance-size": "1G", }, "provisioned_resources": [ { "resource-type": "compute-instance", "resource-url": "https://www.googleapis.com/compute/v1/projects/cloud-sql/zones/us-east1-b/instances/vm-1", } ], "maintenance_schedules": { "csa_rollout": { "start_time": { "seconds": 1526406431, }, "end_time": { "seconds": 1535406431, }, }, "ncsa_rollout": { "start_time": { "seconds": 1526406431, }, "end_time": { "seconds": 1535406431, }, } }, "consumer_defined_name": "my-sql-instance1", } ``` */ export interface Schema$GoogleCloudSaasacceleratorManagementProvidersV1Instance { + /** + * consumer_defined_name is the name that is set by the consumer. On the other hand Name field represents system-assigned id of an instance so consumers are not necessarily aware of it. consumer_defined_name is used for notification/UI purposes for consumer to recognize their instances. + */ + consumerDefinedName?: string; /** * Output only. Timestamp when the resource was created. */ diff --git a/src/apis/firebase/v1beta1.ts b/src/apis/firebase/v1beta1.ts index 85f52af479e..0f23d54cc45 100644 --- a/src/apis/firebase/v1beta1.ts +++ b/src/apis/firebase/v1beta1.ts @@ -126,18 +126,28 @@ export namespace firebase_v1beta1 { */ export interface Schema$AddFirebaseRequest { /** - * Deprecated. Instead, to set your project's default GCP resource location, call [`FinalizeDefaultLocation`](../projects.defaultLocation/finalize) after you add Firebase services to your project. <br> <br>The ID of the project's default GCP resource location. The location must be one of the available [GCP resource locations](https://firebase.google.com/docs/projects/locations). + * Deprecated. Instead, to set your project's default GCP resource location, call [`FinalizeDefaultLocation`](../projects.defaultLocation/finalize) after you add Firebase resources to your project. <br> <br>The ID of the project's default GCP resource location. The location must be one of the available [GCP resource locations](https://firebase.google.com/docs/projects/locations). */ locationId?: string; /** - * The region code (CLDR) that the account will use for Firebase Analytics data. <br>For example: US, GB, or DE <br> <br>In Java, use `com.google.i18n.identifiers.RegionCode`. + * Deprecated. Instead, to link your Project with a Google Analytics account, call [`AddGoogleAnalytics`](../../v1beta1/projects/addGoogleAnalytics) after you add Firebase resources to your Project. <br> <br>The region code (CLDR) that the account will use for Firebase Analytics data. <br>For example: US, GB, or DE <br> <br>In Java, use `com.google.i18n.identifiers.RegionCode`. */ regionCode?: string; /** - * The time zone that the account will use for Firebase Analytics data. <br>For example: America/Los_Angeles or Africa/Abidjan + * Deprecated. Instead, to link your Project with a Google Analytics account, call [`AddGoogleAnalytics`](../../v1beta1/projects/addGoogleAnalytics) after you add Firebase resources to your Project. <br> <br>The time zone that the account will use for Firebase Analytics data. <br>For example: America/Los_Angeles or Africa/Abidjan */ timeZone?: string; } + export interface Schema$AddGoogleAnalyticsRequest { + /** + * The ID for the existing [Google Analytics account](http://www.google.com/analytics/) that you want to link with your `FirebaseProject`. <br> <br>Specifying this field will provision a new Google Analytics property in your Google Analytics account and associate the new property with your `FirebaseProject`. + */ + analyticsAccountId?: string; + /** + * The ID for the existing Google Analytics property that you want to associate with your `FirebaseProject`. + */ + analyticsPropertyId?: string; + } export interface Schema$AdminSdkConfig { /** * The default Firebase Realtime Database URL. @@ -156,6 +166,29 @@ export namespace firebase_v1beta1 { */ storageBucket?: string; } + export interface Schema$AnalyticsDetails { + /** + * The Analytics Property object associated with the specified `FirebaseProject`. <br> <br>This object contains the details of the Google Analytics property associated with the specified `FirebaseProject`. + */ + analyticsProperty?: Schema$AnalyticsProperty; + /** + * A map of `AppId` to `StreamId` for each Firebase App in the specified `FirebaseProject`. Each `AppId` and `StreamId` appears only once. + */ + streamMappings?: Schema$StreamMapping[]; + } + /** + * Details of a Google Analytics property + */ + export interface Schema$AnalyticsProperty { + /** + * The display name of the Google Analytics property associated with the specified `FirebaseProject`. + */ + displayName?: string; + /** + * The globally unique, Google-assigned identifier of the Google Analytics property associated with the specified `FirebaseProject`. <br> <br>If you called [`AddGoogleAnalytics`](../../v1beta1/projects/addGoogleAnalytics) to link your `FirebaseProject` with a Google Analytics account, the value in this `id` field is the same as the ID of the property either specified or provisioned with that call to `AddGoogleAnalytics`. + */ + id?: string; + } /** * Details of a Firebase App for Android. */ @@ -426,7 +459,7 @@ export namespace firebase_v1beta1 { */ displayName?: string; /** - * The ID of the project's default GCP resource location. The location is one of the available [GCP resource locations](https://firebase.google.com/docs/projects/locations). <br> <br> Not all projects will have this field populated. If it is not populated, it means that the project does not yet have a default GCP resource location. To set your project's default GCP resource location, call [`FinalizeDefaultLocation`](../projects.defaultLocation/finalize) after you add Firebase services to your project. + * The ID of the project's default GCP resource location. The location is one of the available [GCP resource locations](https://firebase.google.com/docs/projects/locations). <br> <br> Not all projects will have this field populated. If it is not populated, it means that the project does not yet have a default GCP resource location. To set your project's default GCP resource location, call [`FinalizeDefaultLocation`](../projects.defaultLocation/finalize) after you add Firebase resources to your project. */ locationId?: string; /** @@ -434,6 +467,12 @@ export namespace firebase_v1beta1 { */ project?: string; } + export interface Schema$RemoveAnalyticsRequest { + /** + * Optional. The ID of the Google Analytics property associated with the specified `FirebaseProject`. <ul> <li>If not set, then the Google Analytics property that is currently associated with the specified `FirebaseProject` is removed.</li> <li>If set, and the specified `FirebaseProject` is currently associated with a <em>different</em> Google Analytics property, then the response is a `412 Precondition Failed` error.</li> </ul> + */ + analyticsPropertyId?: string; + } export interface Schema$SearchFirebaseAppsResponse { /** * One page of results from a call to `SearchFirebaseApps`. @@ -507,6 +546,19 @@ export namespace firebase_v1beta1 { */ space?: string; } + /** + * A mapping of a Firebase App to a Google Analytics data stream + */ + export interface Schema$StreamMapping { + /** + * The fully qualified resource name of the Firebase App associated with the Google Analytics data stream, in the format: <br><code>projects/<var>projectId</var>/iosApps/<var>appId</var></code> or <br><code>projects/<var>projectId</var>/androidApps/<var>appId</var></code> + */ + app?: string; + /** + * The unique Google-assigned identifier of the Google Analytics data stream associated with the Firebase App. <br> <br>Learn more about Google Analytics data streams in the [Analytics documentation](https://support.google.com/analytics/answer/9303323). + */ + streamId?: string; + } /** * Message that groups a protocol type_id (as defined by MessageSet), with an encoded message of that type. Its use is similar to MessageSet, except it represents a single (type, encoded message) instead of a set. To fill for known protocol type: MyProtocolMsg proto; TypedMessage typed_msg; typed_msg.set_type_id(MyProtocolMsg::MESSAGE_TYPE_ID); proto.AppendToCord(typed_msg.mutable_message()); To fill for unknown protocol type: ProtocolMessage proto; TypedMessage typed_msg; typed_msg.set_type_id(proto.GetMapper()->type_id()); proto.AppendToCord(typed_msg.mutable_message()); */ @@ -802,7 +854,7 @@ export namespace firebase_v1beta1 { /** * firebase.projects.addFirebase - * @desc Adds Firebase resources to the specified existing [Google Cloud Platform (GCP) `Project`] (https://cloud.google.com/resource-manager/reference/rest/v1/projects).

                          Since a FirebaseProject is actually also a GCP `Project`, a `FirebaseProject` uses underlying GCP identifiers (most importantly, the `projectId`) as its own for easy interop with GCP APIs.

                          The result of this call is an [`Operation`](../../v1beta1/operations). Poll the `Operation` to track the provisioning process by calling GetOperation until [`done`](../../v1beta1/operations#Operation.FIELDS.done) is `true`. When `done` is `true`, the `Operation` has either succeeded or failed. If the `Operation` succeeded, its [`response`](../../v1beta1/operations#Operation.FIELDS.response) is set to a FirebaseProject; if the `Operation` failed, its [`error`](../../v1beta1/operations#Operation.FIELDS.error) is set to a google.rpc.Status. The `Operation` is automatically deleted after completion, so there is no need to call DeleteOperation.

                          This method does not modify any billing account information on the underlying GCP `Project`.

                          All fields listed in the [request body](#request-body) are required.

                          To call `AddFirebase`, a member must be an Editor or Owner for the existing GCP `Project`. Service accounts cannot call `AddFirebase`. + * @desc Adds Firebase resources to the specified existing [Google Cloud Platform (GCP) `Project`] (https://cloud.google.com/resource-manager/reference/rest/v1/projects).

                          Since a FirebaseProject is actually also a GCP `Project`, a `FirebaseProject` uses underlying GCP identifiers (most importantly, the `projectId`) as its own for easy interop with GCP APIs.

                          The result of this call is an [`Operation`](../../v1beta1/operations). Poll the `Operation` to track the provisioning process by calling GetOperation until [`done`](../../v1beta1/operations#Operation.FIELDS.done) is `true`. When `done` is `true`, the `Operation` has either succeeded or failed. If the `Operation` succeeded, its [`response`](../../v1beta1/operations#Operation.FIELDS.response) is set to a FirebaseProject; if the `Operation` failed, its [`error`](../../v1beta1/operations#Operation.FIELDS.error) is set to a google.rpc.Status. The `Operation` is automatically deleted after completion, so there is no need to call DeleteOperation.

                          This method does not modify any billing account information on the underlying GCP `Project`.

                          To call `AddFirebase`, a member must be an Editor or Owner for the existing GCP `Project`. Service accounts cannot call `AddFirebase`. * @alias firebase.projects.addFirebase * @memberOf! () * @@ -875,6 +927,81 @@ export namespace firebase_v1beta1 { } } + /** + * firebase.projects.addGoogleAnalytics + * @desc Links a FirebaseProject with an existing [Google Analytics account](http://www.google.com/analytics/).

                          Using this call, you can either:
                          • Provision a new Google Analytics property and associate the new property with your `FirebaseProject`.
                          • Associate an existing Google Analytics property with your `FirebaseProject`.

                          Note that when you call `AddGoogleAnalytics`:
                          • Any Firebase Apps already in your `FirebaseProject` are automatically provisioned as new data streams in the Google Analytics property.
                          • Any data streams already in the Google Analytics property are automatically associated with their corresponding Firebase Apps (only applies when an app's `packageName` or `bundleId` match those for an existing data stream).
                          Learn more about the hierarchy and structure of Google Analytics accounts in the [Analytics documentation](https://support.google.com/analytics/answer/9303323).

                          The result of this call is an [`Operation`](../../v1beta1/operations). Poll the `Operation` to track the provisioning process by calling GetOperation until [`done`](../../v1beta1/operations#Operation.FIELDS.done) is `true`. When `done` is `true`, the `Operation` has either succeeded or failed. If the `Operation` succeeded, its [`response`](../../v1beta1/operations#Operation.FIELDS.response) is set to an AnalyticsDetails; if the `Operation` failed, its [`error`](../../v1beta1/operations#Operation.FIELDS.error) is set to a google.rpc.Status.

                          To call `AddGoogleAnalytics`, a member must be an Owner for the existing `FirebaseProject` and have the [`Edit` permission](https://support.google.com/analytics/answer/2884495) for the Google Analytics account.

                          If a `FirebaseProject` already has Google Analytics enabled, and you call `AddGoogleAnalytics` using an `analyticsPropertyId` that's different from the currently associated property, then the call will fail. Analytics may have already been enabled in the Firebase console or by specifying `timeZone` and `regionCode` in the call to [`AddFirebase`](../../v1beta1/projects/addFirebase). + * @alias firebase.projects.addGoogleAnalytics + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent The parent `FirebaseProject` to link to an existing Google Analytics account, in the format:
                          projects/projectId + * @param {().AddGoogleAnalyticsRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + addGoogleAnalytics( + params?: Params$Resource$Projects$Addgoogleanalytics, + options?: MethodOptions + ): GaxiosPromise; + addGoogleAnalytics( + params: Params$Resource$Projects$Addgoogleanalytics, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + addGoogleAnalytics( + params: Params$Resource$Projects$Addgoogleanalytics, + callback: BodyResponseCallback + ): void; + addGoogleAnalytics(callback: BodyResponseCallback): void; + addGoogleAnalytics( + paramsOrCallback?: + | Params$Resource$Projects$Addgoogleanalytics + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Addgoogleanalytics; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Addgoogleanalytics; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://firebase.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1beta1/{+parent}:addGoogleAnalytics').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + /** * firebase.projects.get * @desc Gets the FirebaseProject identified by the specified resource name. @@ -1018,6 +1145,79 @@ export namespace firebase_v1beta1 { } } + /** + * firebase.projects.getAnalyticsDetails + * @desc Gets the Google Analytics details currently associated with a FirebaseProject.

                          If the `FirebaseProject` is not yet linked to Google Analytics, then the response to `GetAnalyticsDetails` is NOT_FOUND. + * @alias firebase.projects.getAnalyticsDetails + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The fully qualified resource name, in the format:
                          projects/projectId/analyticsDetails + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + getAnalyticsDetails( + params?: Params$Resource$Projects$Getanalyticsdetails, + options?: MethodOptions + ): GaxiosPromise; + getAnalyticsDetails( + params: Params$Resource$Projects$Getanalyticsdetails, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + getAnalyticsDetails( + params: Params$Resource$Projects$Getanalyticsdetails, + callback: BodyResponseCallback + ): void; + getAnalyticsDetails( + callback: BodyResponseCallback + ): void; + getAnalyticsDetails( + paramsOrCallback?: + | Params$Resource$Projects$Getanalyticsdetails + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Getanalyticsdetails; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Getanalyticsdetails; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://firebase.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1beta1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + /** * firebase.projects.list * @desc Lists each FirebaseProject accessible to the caller.

                          The elements are returned in no particular order, but they will be a consistent view of the Projects when additional requests are made with a `pageToken`.

                          This method is eventually consistent with Project mutations, which means newly provisioned Projects and recent modifications to existing Projects might not be reflected in the set of Projects. The list will include only ACTIVE Projects.

                          Use GetFirebaseProject for consistent reads as well as for additional Project details. @@ -1170,6 +1370,79 @@ export namespace firebase_v1beta1 { } } + /** + * firebase.projects.removeAnalytics + * @desc Unlinks the specified `FirebaseProject` from its Google Analytics account.

                          This call removes the association of the specified `FirebaseProject` with its current Google Analytics property. However, this call does not delete the Google Analytics resources, such as the Google Analytics property or any data streams.

                          These resources may be re-associated later to the `FirebaseProject` by calling [`AddGoogleAnalytics`](../../v1beta1/projects/addGoogleAnalytics) and specifying the same `analyticsPropertyId`.

                          To call `RemoveAnalytics`, a member must be an Owner for the `FirebaseProject`. + * @alias firebase.projects.removeAnalytics + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent The parent `FirebaseProject` to unlink from its Google Analytics account, in the format:
                          projects/projectId + * @param {().RemoveAnalyticsRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + removeAnalytics( + params?: Params$Resource$Projects$Removeanalytics, + options?: MethodOptions + ): GaxiosPromise; + removeAnalytics( + params: Params$Resource$Projects$Removeanalytics, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + removeAnalytics( + params: Params$Resource$Projects$Removeanalytics, + callback: BodyResponseCallback + ): void; + removeAnalytics(callback: BodyResponseCallback): void; + removeAnalytics( + paramsOrCallback?: + | Params$Resource$Projects$Removeanalytics + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Removeanalytics; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Removeanalytics; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://firebase.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1beta1/{+parent}:removeAnalytics').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + /** * firebase.projects.searchApps * @desc A convenience method that lists all available Apps for the specified FirebaseProject.

                          Typically, interaction with an App should be done using the platform-specific service, but some tool use-cases require a summary of all known Apps (such as for App selector interfaces). @@ -1271,6 +1544,23 @@ export namespace firebase_v1beta1 { */ requestBody?: Schema$AddFirebaseRequest; } + export interface Params$Resource$Projects$Addgoogleanalytics + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The parent `FirebaseProject` to link to an existing Google Analytics account, in the format:
                          projects/projectId + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$AddGoogleAnalyticsRequest; + } export interface Params$Resource$Projects$Get extends StandardParameters { /** * Auth client or API Key for the request @@ -1294,6 +1584,18 @@ export namespace firebase_v1beta1 { */ name?: string; } + export interface Params$Resource$Projects$Getanalyticsdetails + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The fully qualified resource name, in the format:
                          projects/projectId/analyticsDetails + */ + name?: string; + } export interface Params$Resource$Projects$List extends StandardParameters { /** * Auth client or API Key for the request @@ -1329,6 +1631,23 @@ export namespace firebase_v1beta1 { */ requestBody?: Schema$FirebaseProject; } + export interface Params$Resource$Projects$Removeanalytics + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The parent `FirebaseProject` to unlink from its Google Analytics account, in the format:
                          projects/projectId + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$RemoveAnalyticsRequest; + } export interface Params$Resource$Projects$Searchapps extends StandardParameters { /** diff --git a/src/apis/firebasehosting/v1beta1.ts b/src/apis/firebasehosting/v1beta1.ts index 7c95f3351a1..bc60a0fcb6d 100644 --- a/src/apis/firebasehosting/v1beta1.ts +++ b/src/apis/firebasehosting/v1beta1.ts @@ -257,13 +257,17 @@ export namespace firebasehosting_v1beta1 { */ export interface Schema$Header { /** - * Required. The user-supplied [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match against the request URL path. + * The user-supplied [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match against the request URL path. */ glob?: string; /** * Required. The additional headers to add to the response. */ headers?: {[key: string]: string}; + /** + * The user-supplied RE2 regular expression to match against the request URL path. + */ + regex?: string; } export interface Schema$ListDomainsResponse { /** @@ -316,13 +320,17 @@ export namespace firebasehosting_v1beta1 { */ export interface Schema$Redirect { /** - * Required. The user-supplied [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match against the request URL path. + * The user-supplied [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match against the request URL path. */ glob?: string; /** * Required. The value to put in the HTTP location header of the response. <br>The location can contain capture group values from the pattern using a `:` prefix to identify the segment and an optional `*` to capture the rest of the URL. For example: <code>"glob": "/:capture*", <br>"statusCode": 301, <br>"location": "https://example.com/foo/:capture"</code> */ location?: string; + /** + * The user-supplied RE2 regular expression to match against the request URL path. + */ + regex?: string; /** * Required. The status HTTP code to return in the response. It must be a valid 3xx status code. */ @@ -353,7 +361,7 @@ export namespace firebasehosting_v1beta1 { */ type?: string; /** - * Output only. The configuration and content that was released. + * Output only. The configuration and content that was released. */ version?: Schema$Version; } @@ -370,13 +378,17 @@ export namespace firebasehosting_v1beta1 { */ function?: string; /** - * Required. The user-supplied [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match against the request URL path. + * The user-supplied [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match against the request URL path. */ glob?: string; /** * The URL path to rewrite the request to. */ path?: string; + /** + * The user-supplied RE2 regular expression to match against the request URL path. + */ + regex?: string; /** * The request will be forwarded to Cloud Run. */ diff --git a/src/apis/firebaserules/v1.ts b/src/apis/firebaserules/v1.ts index 2b5fb466092..894b15a87b2 100644 --- a/src/apis/firebaserules/v1.ts +++ b/src/apis/firebaserules/v1.ts @@ -342,6 +342,10 @@ export namespace firebaserules_v1 { * Optional function mocks for service-defined functions. If not set, any service defined function is expected to return an error, which may or may not influence the test outcome. */ functionMocks?: Schema$FunctionMock[]; + /** + * Specifies whether paths (such as request.path) are encoded and how. + */ + pathEncoding?: string; /** * Request context. The exact format of the request context is service-dependent. See the appropriate service documentation for information about the supported fields and types on the request. Minimally, all services support the following fields and types: Request field | Type ---------------|----------------- auth.uid | `string` auth.token | `map<string, string>` headers | `map<string, string>` method | `string` params | `map<string, string>` path | `string` time | `google.protobuf.Timestamp` If the request value is not well-formed for the service, the request will be rejected as an invalid argument. */ diff --git a/src/apis/firestore/v1.ts b/src/apis/firestore/v1.ts index bb8bf4b7a77..cc9dff9a509 100644 --- a/src/apis/firestore/v1.ts +++ b/src/apis/firestore/v1.ts @@ -773,7 +773,7 @@ export namespace firestore_v1 { */ metadata?: {[key: string]: any}; /** - * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should have the format of `operations/some/unique/name`. + * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. */ name?: string; /** @@ -1040,7 +1040,7 @@ export namespace firestore_v1 { transaction?: string; } /** - * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). The error model is designed to be: - Simple to use and understand for most users - Flexible enough to meet unexpected needs # Overview The `Status` message contains three pieces of data: error code, error message, and error details. The error code should be an enum value of google.rpc.Code, but it may accept additional error codes if needed. The error message should be a developer-facing English message that helps developers *understand* and *resolve* the error. If a localized user-facing error message is needed, put the localized message in the error details or localize it in the client. The optional error details may contain arbitrary information about the error. There is a predefined set of error detail types in the package `google.rpc` that can be used for common error conditions. # Language mapping The `Status` message is the logical representation of the error model, but it is not necessarily the actual wire format. When the `Status` message is exposed in different client libraries and different wire protocols, it can be mapped differently. For example, it will likely be mapped to some exceptions in Java, but more likely mapped to some error codes in C. # Other uses The error model and the `Status` message can be used in a variety of environments, either with or without APIs, to provide a consistent developer experience across different environments. Example uses of this error model include: - Partial errors. If a service needs to return partial errors to the client, it may embed the `Status` in the normal response to indicate the partial errors. - Workflow errors. A typical workflow has multiple steps. Each step may have a `Status` message for error reporting. - Batch operations. If a client uses batch request and batch response, the `Status` message should be used directly inside batch response, one for each error sub-response. - Asynchronous operations. If an API call embeds asynchronous operation results in its response, the status of those operations should be represented directly using the `Status` message. - Logging. If some API errors are stored in logs, the message `Status` could be used directly after any stripping needed for security/privacy reasons. + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). */ export interface Schema$Status { /** @@ -1118,7 +1118,7 @@ export namespace firestore_v1 { */ resumeToken?: string; /** - * A client provided target ID. If not set, the server will assign an ID for the target. Used for resuming a target without changing IDs. The IDs can either be client-assigned or be server-assigned in a previous stream. All targets with client provided IDs must be added before adding a target that needs a server-assigned id. + * The target ID that identifies the target on the stream. Must be a positive number and non-zero. */ targetId?: number; } @@ -1143,7 +1143,7 @@ export namespace firestore_v1 { */ targetChangeType?: string; /** - * The target IDs of targets that have changed. If empty, the change applies to all targets. For `target_change_type=ADD`, the order of the target IDs matches the order of the requests to add the targets. This allows clients to unambiguously associate server-assigned target IDs with added targets. For other states, the order of the target IDs is not defined. + * The target IDs of targets that have changed. If empty, the change applies to all targets. The order of the target IDs is not defined. */ targetIds?: number[]; } diff --git a/src/apis/firestore/v1beta1.ts b/src/apis/firestore/v1beta1.ts index 73657e448eb..72c82a7a6c1 100644 --- a/src/apis/firestore/v1beta1.ts +++ b/src/apis/firestore/v1beta1.ts @@ -659,7 +659,7 @@ export namespace firestore_v1beta1 { */ metadata?: {[key: string]: any}; /** - * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should have the format of `operations/some/unique/name`. + * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. */ name?: string; /** @@ -888,7 +888,7 @@ export namespace firestore_v1beta1 { transaction?: string; } /** - * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). The error model is designed to be: - Simple to use and understand for most users - Flexible enough to meet unexpected needs # Overview The `Status` message contains three pieces of data: error code, error message, and error details. The error code should be an enum value of google.rpc.Code, but it may accept additional error codes if needed. The error message should be a developer-facing English message that helps developers *understand* and *resolve* the error. If a localized user-facing error message is needed, put the localized message in the error details or localize it in the client. The optional error details may contain arbitrary information about the error. There is a predefined set of error detail types in the package `google.rpc` that can be used for common error conditions. # Language mapping The `Status` message is the logical representation of the error model, but it is not necessarily the actual wire format. When the `Status` message is exposed in different client libraries and different wire protocols, it can be mapped differently. For example, it will likely be mapped to some exceptions in Java, but more likely mapped to some error codes in C. # Other uses The error model and the `Status` message can be used in a variety of environments, either with or without APIs, to provide a consistent developer experience across different environments. Example uses of this error model include: - Partial errors. If a service needs to return partial errors to the client, it may embed the `Status` in the normal response to indicate the partial errors. - Workflow errors. A typical workflow has multiple steps. Each step may have a `Status` message for error reporting. - Batch operations. If a client uses batch request and batch response, the `Status` message should be used directly inside batch response, one for each error sub-response. - Asynchronous operations. If an API call embeds asynchronous operation results in its response, the status of those operations should be represented directly using the `Status` message. - Logging. If some API errors are stored in logs, the message `Status` could be used directly after any stripping needed for security/privacy reasons. + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). */ export interface Schema$Status { /** @@ -966,7 +966,7 @@ export namespace firestore_v1beta1 { */ resumeToken?: string; /** - * A client provided target ID. If not set, the server will assign an ID for the target. Used for resuming a target without changing IDs. The IDs can either be client-assigned or be server-assigned in a previous stream. All targets with client provided IDs must be added before adding a target that needs a server-assigned id. + * The target ID that identifies the target on the stream. Must be a positive number and non-zero. */ targetId?: number; } @@ -991,7 +991,7 @@ export namespace firestore_v1beta1 { */ targetChangeType?: string; /** - * The target IDs of targets that have changed. If empty, the change applies to all targets. For `target_change_type=ADD`, the order of the target IDs matches the order of the requests to add the targets. This allows clients to unambiguously associate server-assigned target IDs with added targets. For other states, the order of the target IDs is not defined. + * The target IDs of targets that have changed. If empty, the change applies to all targets. The order of the target IDs is not defined. */ targetIds?: number[]; } diff --git a/src/apis/firestore/v1beta2.ts b/src/apis/firestore/v1beta2.ts index a7aa4c9a303..a1cf54da0b9 100644 --- a/src/apis/firestore/v1beta2.ts +++ b/src/apis/firestore/v1beta2.ts @@ -425,7 +425,7 @@ export namespace firestore_v1beta2 { */ metadata?: {[key: string]: any}; /** - * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should have the format of `operations/some/unique/name`. + * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. */ name?: string; /** @@ -434,7 +434,7 @@ export namespace firestore_v1beta2 { response?: {[key: string]: any}; } /** - * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). The error model is designed to be: - Simple to use and understand for most users - Flexible enough to meet unexpected needs # Overview The `Status` message contains three pieces of data: error code, error message, and error details. The error code should be an enum value of google.rpc.Code, but it may accept additional error codes if needed. The error message should be a developer-facing English message that helps developers *understand* and *resolve* the error. If a localized user-facing error message is needed, put the localized message in the error details or localize it in the client. The optional error details may contain arbitrary information about the error. There is a predefined set of error detail types in the package `google.rpc` that can be used for common error conditions. # Language mapping The `Status` message is the logical representation of the error model, but it is not necessarily the actual wire format. When the `Status` message is exposed in different client libraries and different wire protocols, it can be mapped differently. For example, it will likely be mapped to some exceptions in Java, but more likely mapped to some error codes in C. # Other uses The error model and the `Status` message can be used in a variety of environments, either with or without APIs, to provide a consistent developer experience across different environments. Example uses of this error model include: - Partial errors. If a service needs to return partial errors to the client, it may embed the `Status` in the normal response to indicate the partial errors. - Workflow errors. A typical workflow has multiple steps. Each step may have a `Status` message for error reporting. - Batch operations. If a client uses batch request and batch response, the `Status` message should be used directly inside batch response, one for each error sub-response. - Asynchronous operations. If an API call embeds asynchronous operation results in its response, the status of those operations should be represented directly using the `Status` message. - Logging. If some API errors are stored in logs, the message `Status` could be used directly after any stripping needed for security/privacy reasons. + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). */ export interface Schema$Status { /** diff --git a/src/apis/games/v1.ts b/src/apis/games/v1.ts index 9373d3f42c8..42ae4493d75 100644 --- a/src/apis/games/v1.ts +++ b/src/apis/games/v1.ts @@ -1522,9 +1522,6 @@ export namespace games_v1 { * Uniquely identifies the type of this resource. Value is always the fixed string games#profileSettings. */ kind?: string; - /** - * The player's current profile visibility. This field is visible to both 1P and 3P APIs. - */ profileVisible?: boolean; } /** diff --git a/src/apis/gamesManagement/v1management.ts b/src/apis/gamesManagement/v1management.ts index 8bf8ed9611c..5a956156947 100644 --- a/src/apis/gamesManagement/v1management.ts +++ b/src/apis/gamesManagement/v1management.ts @@ -351,9 +351,6 @@ export namespace gamesManagement_v1management { * Uniquely identifies the type of this resource. Value is always the fixed string gamesManagement#profileSettings. */ kind?: string; - /** - * The player's current profile visibility. This field is visible to both 1P and 3P APIs. - */ profileVisible?: boolean; } /** diff --git a/src/apis/genomics/v1.ts b/src/apis/genomics/v1.ts index 8b9342620fe..933a9acca8f 100644 --- a/src/apis/genomics/v1.ts +++ b/src/apis/genomics/v1.ts @@ -397,6 +397,10 @@ export namespace genomics_v1 { * The worker's instance name. */ instance?: string; + /** + * The machine type that was assigned for the worker. + */ + machineType?: string; /** * The zone the worker is running in. */ diff --git a/src/apis/genomics/v1alpha2.ts b/src/apis/genomics/v1alpha2.ts index e4332259e44..28a1102588d 100644 --- a/src/apis/genomics/v1alpha2.ts +++ b/src/apis/genomics/v1alpha2.ts @@ -689,6 +689,10 @@ export namespace genomics_v1alpha2 { * The worker's instance name. */ instance?: string; + /** + * The machine type that was assigned for the worker. + */ + machineType?: string; /** * The zone the worker is running in. */ diff --git a/src/apis/genomics/v2alpha1.ts b/src/apis/genomics/v2alpha1.ts index af135b4e802..a1b502d57fb 100644 --- a/src/apis/genomics/v2alpha1.ts +++ b/src/apis/genomics/v2alpha1.ts @@ -151,7 +151,7 @@ export namespace genomics_v2alpha1 { */ entrypoint?: string; /** - * The environment to pass into the container. This environment is merged with any values specified in the `Pipeline` message. These values overwrite any in the `Pipeline` message. In addition to the values passed here, a few other values are automatically injected into the environment. These cannot be hidden or overwritten. `GOOGLE_PIPELINE_FAILED` will be set to "1" if the pipeline failed because an action has exited with a non-zero status (and did not have the `IGNORE_EXIT_STATUS` flag set). This can be used to determine if additional debug or logging actions should execute. `GOOGLE_LAST_EXIT_STATUS` will be set to the exit status of the last non-background action that executed. This can be used by workflow engine authors to determine whether an individual action has succeeded or failed. + * The environment to pass into the container. This environment is merged with values specified in the google.genomics.v2alpha1.Pipeline message, overwriting any duplicate values. In addition to the values passed here, a few other values are automatically injected into the environment. These cannot be hidden or overwritten. `GOOGLE_PIPELINE_FAILED` will be set to "1" if the pipeline failed because an action has exited with a non-zero status (and did not have the `IGNORE_EXIT_STATUS` flag set). This can be used to determine if additional debug or logging actions should execute. `GOOGLE_LAST_EXIT_STATUS` will be set to the exit status of the last non-background action that executed. This can be used by workflow engine authors to determine whether an individual action has succeeded or failed. */ environment?: {[key: string]: string}; /** @@ -159,7 +159,7 @@ export namespace genomics_v2alpha1 { */ flags?: string[]; /** - * The URI to pull the container image from. Note that all images referenced by actions in the pipeline are pulled before the first action runs. If multiple actions reference the same image, it is only pulled once, ensuring that the same image is used for all actions in a single pipeline. + * Required. The URI to pull the container image from. Note that all images referenced by actions in the pipeline are pulled before the first action runs. If multiple actions reference the same image, it is only pulled once, ensuring that the same image is used for all actions in a single pipeline. The image URI can be either a complete host and image specification (e.g., quay.io/biocontainers/samtools), a library and image name (e.g., google/cloud-sdk) or a bare image name ('bash') to pull from the default library. No schema is required in any of these cases. If the specified image is not public, the service account specified for the Virtual Machine must have access to pull the images from GCR, or appropriate credentials must be specified in the google.genomics.v2alpha1.Action.credentials field. */ imageUri?: string; /** @@ -598,7 +598,7 @@ export namespace genomics_v2alpha1 { */ labels?: {[key: string]: string}; /** - * The description of the pipeline to run. + * Required. The description of the pipeline to run. */ pipeline?: Schema$Pipeline; } @@ -637,7 +637,7 @@ export namespace genomics_v2alpha1 { */ email?: string; /** - * List of scopes to be enabled for this service account on the VM, in addition to the Cloud Genomics API scope. + * List of scopes to be enabled for this service account on the VM, in addition to the cloud-platform API scope that will be added by default. */ scopes?: string[]; } @@ -700,11 +700,11 @@ export namespace genomics_v2alpha1 { */ enableStackdriverMonitoring?: boolean; /** - * Optional set of labels to apply to the VM and any attached disk resources. These labels must adhere to the name and value restrictions on VM labels imposed by Compute Engine. Labels keys with the prefix 'google-' are reserved for use by Google. Labels applied at creation time to the VM. Applied on a best-effort basis to attached disk resources shortly after VM creation. + * Optional set of labels to apply to the VM and any attached disk resources. These labels must adhere to the [name and value restrictions](https://cloud.google.com/compute/docs/labeling-resources) on VM labels imposed by Compute Engine. Labels keys with the prefix 'google-' are reserved for use by Google. Labels applied at creation time to the VM. Applied on a best-effort basis to attached disk resources shortly after VM creation. */ labels?: {[key: string]: string}; /** - * The machine type of the virtual machine to create. Must be the short name of a standard machine type (such as "n1-standard-1") or a custom machine type (such as "custom-1-4096", where "1" indicates the number of vCPUs and "4096" indicates the memory in MB). See [Creating an instance with a custom machine type](https://cloud.google.com/compute/docs/instances/creating-instance-with-custom-machine-type#create) for more specifications on creating a custom machine type. + * Required. The machine type of the virtual machine to create. Must be the short name of a standard machine type (such as "n1-standard-1") or a custom machine type (such as "custom-1-4096", where "1" indicates the number of vCPUs and "4096" indicates the memory in MB). See [Creating an instance with a custom machine type](https://cloud.google.com/compute/docs/instances/creating-instance-with-custom-machine-type#create) for more specifications on creating a custom machine type. */ machineType?: string; /** @@ -732,6 +732,10 @@ export namespace genomics_v2alpha1 { * The worker's instance name. */ instance?: string; + /** + * The machine type that was assigned for the worker. + */ + machineType?: string; /** * The zone the worker is running in. */ @@ -784,7 +788,7 @@ export namespace genomics_v2alpha1 { /** * genomics.pipelines.run - * @desc Runs a pipeline. **Note:** Before you can use this method, the Genomics Service Agent must have access to your project. This is done automatically when the Cloud Genomics API is first enabled, but if you delete this permission, or if you enabled the Cloud Genomics API before the v2alpha1 API launch, you must disable and re-enable the API to grant the Genomics Service Agent the required permissions. Authorization requires the following [Google IAM](https://cloud.google.com/iam/) permission: * `genomics.operations.create` [1]: /genomics/gsa + * @desc Runs a pipeline. The returned Operation's metadata field will contain a google.genomics.v2alpha1.Metadata object describing the status of the pipeline execution. The [response] field will contain a google.genomics.v2alpha1.RunPipelineResponse object if the pipeline completes successfully. **Note:** Before you can use this method, the Genomics Service Agent must have access to your project. This is done automatically when the Cloud Genomics API is first enabled, but if you delete this permission, or if you enabled the Cloud Genomics API before the v2alpha1 API launch, you must disable and re-enable the API to grant the Genomics Service Agent the required permissions. Authorization requires the following [Google IAM](https://cloud.google.com/iam/) permission: * `genomics.operations.create` [1]: /genomics/gsa * @example * * // BEFORE RUNNING: * // --------------- diff --git a/src/apis/groupssettings/v1.ts b/src/apis/groupssettings/v1.ts index f7df7c9e7bf..e67dfb57875 100644 --- a/src/apis/groupssettings/v1.ts +++ b/src/apis/groupssettings/v1.ts @@ -106,247 +106,247 @@ export namespace groupssettings_v1 { */ export interface Schema$Groups { /** - * Are external members allowed to join the group. + * Identifies whether members external to your organization can join the group. Possible values are: - true: G Suite users external to your organization can become members of this group. - false: Users not belonging to the organization are not allowed to become members of this group. */ allowExternalMembers?: string; /** - * Is google allowed to contact admins. + * Deprecated. Allows Google to contact administrator of the group. - true: Allow Google to contact managers of this group. Occasionally Google may send updates on the latest features, ask for input on new features, or ask for permission to highlight your group. - false: Google can not contact managers of this group. */ allowGoogleCommunication?: string; /** - * If posting from web is allowed. + * Allows posting from web. Possible values are: - true: Allows any member to post to the group forum. - false: Members only use Gmail to communicate with the group. */ allowWebPosting?: string; /** - * If the group is archive only + * Allows the group to be archived only. Possible values are: - true: Group is archived and the group is inactive. New messages to this group are rejected. The older archived messages are browseable and searchable. - If true, the whoCanPostMessage property is set to NONE_CAN_POST. - If reverted from true to false, whoCanPostMessages is set to ALL_MANAGERS_CAN_POST. - false: The group is active and can receive messages. - When false, updating whoCanPostMessage to NONE_CAN_POST, results in an error. */ archiveOnly?: string; /** - * Custom footer text. + * Set the content of custom footer text. The maximum number of characters is 1,000. */ customFooterText?: string; /** - * Default email to which reply to any message should go. + * An email address used when replying to a message if the replyTo property is set to REPLY_TO_CUSTOM. This address is defined by an account administrator. - When the group's ReplyTo property is set to REPLY_TO_CUSTOM, the customReplyTo property holds a custom email address used when replying to a message. - If the group's ReplyTo property is set to REPLY_TO_CUSTOM, the customReplyTo property must have a text value or an error is returned. */ customReplyTo?: string; /** - * If any of the settings that will be merged have custom roles which is anything other than owners, managers, or group scopes. + * Specifies whether the group has a custom role that's included in one of the settings being merged. This field is read-only and update/patch requests to it are ignored. Possible values are: - true - false */ customRolesEnabledForSettingsToBeMerged?: string; /** - * Default message deny notification message + * When a message is rejected, this is text for the rejection notification sent to the message's author. By default, this property is empty and has no value in the API's response body. The maximum notification text size is 10,000 characters. Note: Requires sendMessageDenyNotification property to be true. */ defaultMessageDenyNotificationText?: string; /** - * Description of the group + * Description of the group. This property value may be an empty string if no group description has been entered. If entered, the maximum group description is no more than 300 characters. */ description?: string; /** - * Email id of the group + * The group's email address. This property can be updated using the Directory API. Note: Only a group owner can change a group's email address. A group manager can't do this. When you change your group's address using the Directory API or the control panel, you are changing the address your subscribers use to send email and the web address people use to access your group. People can't reach your group by visiting the old address. */ email?: string; /** - * If a primary Collab Inbox feature is enabled. + * Specifies whether a collaborative inbox will remain turned on for the group. Possible values are: - true - false */ enableCollaborativeInbox?: string; /** - * If favorite replies should be displayed above other replies. + * Indicates if favorite replies should be displayed above other replies. - true: Favorite replies will be displayed above other replies. - false: Favorite replies will not be displayed above other replies. */ favoriteRepliesOnTop?: string; /** - * Whether to include custom footer. + * Whether to include custom footer. Possible values are: - true - false */ includeCustomFooter?: string; /** - * If this groups should be included in global address list or not. + * Enables the group to be included in the Global Address List. For more information, see the help center. Possible values are: - true: Group is included in the Global Address List. - false: Group is not included in the Global Address List. */ includeInGlobalAddressList?: string; /** - * If the contents of the group are archived. + * Allows the Group contents to be archived. Possible values are: - true: Archive messages sent to the group. - false: Do not keep an archive of messages sent to this group. If false, previously archived messages remain in the archive. */ isArchived?: string; /** - * The type of the resource. + * The type of the resource. It is always groupsSettings#groups. */ kind?: string; /** - * Maximum message size allowed. + * Deprecated. The maximum size of a message is 25Mb. */ maxMessageBytes?: number; /** - * Can members post using the group email address. + * Enables members to post messages as the group. Possible values are: - true: Group member can post messages using the group's email address instead of their own email address. Message appear to originate from the group itself. Note: When true, any message moderation settings on individual users or new members do not apply to posts made on behalf of the group. - false: Members can not post in behalf of the group's email address. */ membersCanPostAsTheGroup?: string; /** - * Default message display font. Possible values are: DEFAULT_FONT FIXED_WIDTH_FONT + * Deprecated. The default message display font always has a value of "DEFAULT_FONT". */ messageDisplayFont?: string; /** - * Moderation level for messages. Possible values are: MODERATE_ALL_MESSAGES MODERATE_NON_MEMBERS MODERATE_NEW_MEMBERS MODERATE_NONE + * Moderation level of incoming messages. Possible values are: - MODERATE_ALL_MESSAGES: All messages are sent to the group owner's email address for approval. If approved, the message is sent to the group. - MODERATE_NON_MEMBERS: All messages from non group members are sent to the group owner's email address for approval. If approved, the message is sent to the group. - MODERATE_NEW_MEMBERS: All messages from new members are sent to the group owner's email address for approval. If approved, the message is sent to the group. - MODERATE_NONE: No moderator approval is required. Messages are delivered directly to the group. Note: When the whoCanPostMessage is set to ANYONE_CAN_POST, we recommend the messageModerationLevel be set to MODERATE_NON_MEMBERS to protect the group from possible spam. When memberCanPostAsTheGroup is true, any message moderation settings on individual users or new members will not apply to posts made on behalf of the group. */ messageModerationLevel?: string; /** - * Name of the Group + * Name of the group, which has a maximum size of 75 characters. */ name?: string; /** - * Primary language for the group. + * The primary language for group. For a group's primary language use the language tags from the G Suite languages found at G Suite Email Settings API Email Language Tags. */ primaryLanguage?: string; /** - * Whome should the default reply to a message go to. Possible values are: REPLY_TO_CUSTOM REPLY_TO_SENDER REPLY_TO_LIST REPLY_TO_OWNER REPLY_TO_IGNORE REPLY_TO_MANAGERS + * Specifies who should the default reply go to. Possible values are: - REPLY_TO_CUSTOM: For replies to messages, use the group's custom email address. When the group's ReplyTo property is set to REPLY_TO_CUSTOM, the customReplyTo property holds the custom email address used when replying to a message. If the group's ReplyTo property is set to REPLY_TO_CUSTOM, the customReplyTo property must have a value. Otherwise an error is returned. - REPLY_TO_SENDER: The reply sent to author of message. - REPLY_TO_LIST: This reply message is sent to the group. - REPLY_TO_OWNER: The reply is sent to the owner(s) of the group. This does not include the group's managers. - REPLY_TO_IGNORE: Group users individually decide where the message reply is sent. - REPLY_TO_MANAGERS: This reply message is sent to the group's managers, which includes all managers and the group owner. */ replyTo?: string; /** - * Should the member be notified if his message is denied by owner. + * Allows a member to be notified if the member's message to the group is denied by the group owner. Possible values are: - true: When a message is rejected, send the deny message notification to the message author. The defaultMessageDenyNotificationText property is dependent on the sendMessageDenyNotification property being true. - false: When a message is rejected, no notification is sent. */ sendMessageDenyNotification?: string; /** - * Is the group listed in groups directory + * Deprecated. This is merged into the new whoCanDiscoverGroup setting. Allows the group to be visible in the Groups Directory. Possible values are: - true: All groups in the account are listed in the Groups directory. - false: All groups in the account are not listed in the directory. */ showInGroupDirectory?: string; /** - * Moderation level for messages detected as spam. Possible values are: ALLOW MODERATE SILENTLY_MODERATE REJECT + * Specifies moderation levels for messages detected as spam. Possible values are: - ALLOW: Post the message to the group. - MODERATE: Send the message to the moderation queue. This is the default. - SILENTLY_MODERATE: Send the message to the moderation queue, but do not send notification to moderators. - REJECT: Immediately reject the message. */ spamModerationLevel?: string; /** - * Permissions to add members. Possible values are: ALL_MANAGERS_CAN_ADD ALL_OWNERS_CAN_ADD ALL_MEMBERS_CAN_ADD NONE_CAN_ADD + * Deprecated. This is merged into the new whoCanModerateMembers setting. Permissions to add members. Possible values are: - ALL_MEMBERS_CAN_ADD: Managers and members can directly add new members. - ALL_MANAGERS_CAN_ADD: Only managers can directly add new members. this includes the group's owner. - ALL_OWNERS_CAN_ADD: Only owners can directly add new members. - NONE_CAN_ADD: No one can directly add new members. */ whoCanAdd?: string; /** - * Permission to add references to a topic. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This functionality is no longer supported in the Google Groups UI. The value is always "NONE". */ whoCanAddReferences?: string; /** - * Permission to approve members. Possible values are: ALL_OWNERS_CAN_APPROVE ALL_MANAGERS_CAN_APPROVE ALL_MEMBERS_CAN_APPROVE NONE_CAN_APPROVE + * Specifies who can approve members who ask to join groups. This permission will be deprecated once it is merged into the new whoCanModerateMembers setting. Possible values are: - ALL_MEMBERS_CAN_APPROVE - ALL_MANAGERS_CAN_APPROVE - ALL_OWNERS_CAN_APPROVE - NONE_CAN_APPROVE */ whoCanApproveMembers?: string; /** - * Permission to approve pending messages in the moderation queue. Possible values are: NONE OWNERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanModerateContent setting. Specifies who can approve pending messages in the moderation queue. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanApproveMessages?: string; /** - * Permission to assign topics in a forum to another user. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanAssistContent setting. Permission to assign topics in a forum to another user. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - MANAGERS_ONLY - OWNERS_ONLY - NONE */ whoCanAssignTopics?: string; /** - * Permission for content assistants. Possible values are: Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Specifies who can moderate metadata. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - MANAGERS_ONLY - OWNERS_ONLY - NONE */ whoCanAssistContent?: string; /** - * Permission to ban users. Possible values are: NONE OWNERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Specifies who can deny membership to users. This permission will be deprecated once it is merged into the new whoCanModerateMembers setting. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanBanUsers?: string; /** - * Permission to contact owner of the group via web UI. Possible values are: ANYONE_CAN_CONTACT ALL_IN_DOMAIN_CAN_CONTACT ALL_MEMBERS_CAN_CONTACT ALL_MANAGERS_CAN_CONTACT + * Permission to contact owner of the group via web UI. Possible values are: - ALL_IN_DOMAIN_CAN_CONTACT - ALL_MANAGERS_CAN_CONTACT - ALL_MEMBERS_CAN_CONTACT - ANYONE_CAN_CONTACT */ whoCanContactOwner?: string; /** - * Permission to delete replies to topics. Possible values are: NONE OWNERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanModerateContent setting. Specifies who can delete replies to topics. (Authors can always delete their own posts). Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanDeleteAnyPost?: string; /** - * Permission to delete topics. Possible values are: NONE OWNERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanModerateContent setting. Specifies who can delete topics. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanDeleteTopics?: string; /** - * Permission for who can discover the group. Possible values are: ALL_MEMBERS_CAN_DISCOVER ALL_IN_DOMAIN_CAN_DISCOVER ANYONE_CAN_DISCOVER + * Specifies the set of users for whom this group is discoverable. Possible values are: - ANYONE_CAN_DISCOVER - ALL_IN_DOMAIN_CAN_DISCOVER - ALL_MEMBERS_CAN_DISCOVER */ whoCanDiscoverGroup?: string; /** - * Permission to enter free form tags for topics in a forum. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanAssistContent setting. Permission to enter free form tags for topics in a forum. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - MANAGERS_ONLY - OWNERS_ONLY - NONE */ whoCanEnterFreeFormTags?: string; /** - * Permission to hide posts by reporting them as abuse. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanModerateContent setting. Specifies who can hide posts by reporting them as abuse. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanHideAbuse?: string; /** - * Permissions to invite members. Possible values are: ALL_MEMBERS_CAN_INVITE ALL_MANAGERS_CAN_INVITE ALL_OWNERS_CAN_INVITE NONE_CAN_INVITE + * Deprecated. This is merged into the new whoCanModerateMembers setting. Permissions to invite new members. Possible values are: - ALL_MEMBERS_CAN_INVITE: Managers and members can invite a new member candidate. - ALL_MANAGERS_CAN_INVITE: Only managers can invite a new member. This includes the group's owner. - ALL_OWNERS_CAN_INVITE: Only owners can invite a new member. - NONE_CAN_INVITE: No one can invite a new member candidate. */ whoCanInvite?: string; /** - * Permissions to join the group. Possible values are: ANYONE_CAN_JOIN ALL_IN_DOMAIN_CAN_JOIN INVITED_CAN_JOIN CAN_REQUEST_TO_JOIN + * Permission to join group. Possible values are: - ANYONE_CAN_JOIN: Anyone in the account domain can join. This includes accounts with multiple domains. - ALL_IN_DOMAIN_CAN_JOIN: Any Internet user who is outside your domain can access your Google Groups service and view the list of groups in your Groups directory. Warning: Group owners can add external addresses, outside of the domain to their groups. They can also allow people outside your domain to join their groups. If you later disable this option, any external addresses already added to users' groups remain in those groups. - INVITED_CAN_JOIN: Candidates for membership can be invited to join. - CAN_REQUEST_TO_JOIN: Non members can request an invitation to join. */ whoCanJoin?: string; /** - * Permission to leave the group. Possible values are: ALL_MANAGERS_CAN_LEAVE ALL_OWNERS_CAN_LEAVE ALL_MEMBERS_CAN_LEAVE NONE_CAN_LEAVE + * Permission to leave the group. Possible values are: - ALL_MANAGERS_CAN_LEAVE - ALL_MEMBERS_CAN_LEAVE - NONE_CAN_LEAVE */ whoCanLeaveGroup?: string; /** - * Permission to lock topics. Possible values are: NONE OWNERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanModerateContent setting. Specifies who can prevent users from posting replies to topics. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanLockTopics?: string; /** - * Permission to make topics appear at the top of the topic list. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanModerateContent setting. Specifies who can make topics appear at the top of the topic list. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanMakeTopicsSticky?: string; /** - * Permission to mark a topic as a duplicate of another topic. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanAssistContent setting. Permission to mark a topic as a duplicate of another topic. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - MANAGERS_ONLY - OWNERS_ONLY - NONE */ whoCanMarkDuplicate?: string; /** - * Permission to mark any other user's post as a favorite reply. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanAssistContent setting. Permission to mark any other user's post as a favorite reply. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - MANAGERS_ONLY - OWNERS_ONLY - NONE */ whoCanMarkFavoriteReplyOnAnyTopic?: string; /** - * Permission to mark a post for a topic they started as a favorite reply. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanAssistContent setting. Permission to mark a post for a topic they started as a favorite reply. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - MANAGERS_ONLY - OWNERS_ONLY - NONE */ whoCanMarkFavoriteReplyOnOwnTopic?: string; /** - * Permission to mark a topic as not needing a response. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanAssistContent setting. Permission to mark a topic as not needing a response. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - MANAGERS_ONLY - OWNERS_ONLY - NONE */ whoCanMarkNoResponseNeeded?: string; /** - * Permission for content moderation. Possible values are: NONE OWNERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Specifies who can moderate content. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanModerateContent?: string; /** - * Permission for membership moderation. Possible values are: NONE OWNERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Specifies who can manage members. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanModerateMembers?: string; /** - * Permission to modify members (change member roles). Possible values are: NONE OWNERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanModerateMembers setting. Specifies who can change group members' roles. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanModifyMembers?: string; /** - * Permission to change tags and categories. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanAssistContent setting. Permission to change tags and categories. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - MANAGERS_ONLY - OWNERS_ONLY - NONE */ whoCanModifyTagsAndCategories?: string; /** - * Permission to move topics into the group or forum. Possible values are: NONE OWNERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanModerateContent setting. Specifies who can move topics into the group or forum. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanMoveTopicsIn?: string; /** - * Permission to move topics out of the group or forum. Possible values are: NONE OWNERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanModerateContent setting. Specifies who can move topics out of the group or forum. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanMoveTopicsOut?: string; /** - * Permission to post announcements, a special topic type. Possible values are: NONE OWNERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanModerateContent setting. Specifies who can post announcements, a special topic type. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - OWNERS_ONLY - NONE */ whoCanPostAnnouncements?: string; /** - * Permissions to post messages to the group. Possible values are: NONE_CAN_POST ALL_MANAGERS_CAN_POST ALL_MEMBERS_CAN_POST ALL_OWNERS_CAN_POST ALL_IN_DOMAIN_CAN_POST ANYONE_CAN_POST + * Permissions to post messages. Possible values are: - NONE_CAN_POST: The group is disabled and archived. No one can post a message to this group. - When archiveOnly is false, updating whoCanPostMessage to NONE_CAN_POST, results in an error. - If archiveOnly is reverted from true to false, whoCanPostMessages is set to ALL_MANAGERS_CAN_POST. - ALL_MANAGERS_CAN_POST: Managers, including group owners, can post messages. - ALL_MEMBERS_CAN_POST: Any group member can post a message. - ALL_OWNERS_CAN_POST: Only group owners can post a message. - ALL_IN_DOMAIN_CAN_POST: Anyone in the account can post a message. - ANYONE_CAN_POST: Any Internet user who outside your account can access your Google Groups service and post a message. Note: When whoCanPostMessage is set to ANYONE_CAN_POST, we recommend the messageModerationLevel be set to MODERATE_NON_MEMBERS to protect the group from possible spam. */ whoCanPostMessage?: string; /** - * Permission to take topics in a forum. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanAssistContent setting. Permission to take topics in a forum. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - MANAGERS_ONLY - OWNERS_ONLY - NONE */ whoCanTakeTopics?: string; /** - * Permission to unassign any topic in a forum. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanAssistContent setting. Permission to unassign any topic in a forum. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - MANAGERS_ONLY - OWNERS_ONLY - NONE */ whoCanUnassignTopic?: string; /** - * Permission to unmark any post from a favorite reply. Possible values are: NONE OWNERS_ONLY MANAGERS_ONLY OWNERS_AND_MANAGERS ALL_MEMBERS + * Deprecated. This is merged into the new whoCanAssistContent setting. Permission to unmark any post from a favorite reply. Possible values are: - ALL_MEMBERS - OWNERS_AND_MANAGERS - MANAGERS_ONLY - OWNERS_ONLY - NONE */ whoCanUnmarkFavoriteReplyOnAnyTopic?: string; /** - * Permissions to view group. Possible values are: ANYONE_CAN_VIEW ALL_IN_DOMAIN_CAN_VIEW ALL_MEMBERS_CAN_VIEW ALL_MANAGERS_CAN_VIEW ALL_OWNERS_CAN_VIEW + * Permissions to view group messages. Possible values are: - ANYONE_CAN_VIEW: Any Internet user can view the group's messages. - ALL_IN_DOMAIN_CAN_VIEW: Anyone in your account can view this group's messages. - ALL_MEMBERS_CAN_VIEW: All group members can view the group's messages. - ALL_MANAGERS_CAN_VIEW: Any group manager can view this group's messages. */ whoCanViewGroup?: string; /** - * Permissions to view membership. Possible values are: ALL_IN_DOMAIN_CAN_VIEW ALL_MEMBERS_CAN_VIEW ALL_MANAGERS_CAN_VIEW ALL_OWNERS_CAN_VIEW + * Permissions to view membership. Possible values are: - ALL_IN_DOMAIN_CAN_VIEW: Anyone in the account can view the group members list. If a group already has external members, those members can still send email to this group. - ALL_MEMBERS_CAN_VIEW: The group members can view the group members list. - ALL_MANAGERS_CAN_VIEW: The group managers can view group members list. */ whoCanViewMembership?: string; } @@ -364,7 +364,7 @@ export namespace groupssettings_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.groupUniqueId The resource ID + * @param {string} params.groupUniqueId The group's email address. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -435,7 +435,7 @@ export namespace groupssettings_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.groupUniqueId The resource ID + * @param {string} params.groupUniqueId The group's email address. * @param {().Groups} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -507,7 +507,7 @@ export namespace groupssettings_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.groupUniqueId The resource ID + * @param {string} params.groupUniqueId The group's email address. * @param {().Groups} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -580,7 +580,7 @@ export namespace groupssettings_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The resource ID + * The group's email address. */ groupUniqueId?: string; } @@ -591,7 +591,7 @@ export namespace groupssettings_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The resource ID + * The group's email address. */ groupUniqueId?: string; @@ -607,7 +607,7 @@ export namespace groupssettings_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The resource ID + * The group's email address. */ groupUniqueId?: string; diff --git a/src/apis/healthcare/v1alpha2.ts b/src/apis/healthcare/v1alpha2.ts index 924b87eb47b..a7f8c5bd862 100644 --- a/src/apis/healthcare/v1alpha2.ts +++ b/src/apis/healthcare/v1alpha2.ts @@ -126,7 +126,7 @@ export namespace healthcare_v1alpha2 { */ annotationSource?: Schema$AnnotationSource; /** - * Annnotations for images, e.g., bounding polygons. + * Annotations for images, e.g., bounding polygons. */ imageAnnotation?: Schema$ImageAnnotation; /** @@ -185,10 +185,6 @@ export namespace healthcare_v1alpha2 { * Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members. */ exemptedMembers?: string[]; - /** - * Specifies whether principals can be exempted for the same LogType in lower-level resource policies. If true, any lower-level exemptions will be ignored. - */ - ignoreChildExemptions?: boolean; /** * The log type that this config enables. */ @@ -250,7 +246,7 @@ export namespace healthcare_v1alpha2 { */ export interface Schema$CryptoHashConfig { /** - * An AES 128/192/256 bit key. Causes the hash to be computed based on this key. A default key is generated for each DeidentifyDataset operation and is used wherever crypto_key is not specified. + * An AES 128/192/256 bit key. Causes the hash to be computed based on this key. A default key is generated for each Deidentify operation and is used wherever crypto_key is not specified. */ cryptoKey?: string; } @@ -272,7 +268,7 @@ export namespace healthcare_v1alpha2 { */ export interface Schema$DateShiftConfig { /** - * An AES 128/192/256 bit key. Causes the shift to be computed based on this key and the patient ID. A default key is generated for each DeidentifyDataset operation and is used wherever crypto_key is not specified. + * An AES 128/192/256 bit key. Causes the shift to be computed based on this key and the patient ID. A default key is generated for each Deidentify operation and is used wherever crypto_key is not specified. */ cryptoKey?: string; } @@ -543,7 +539,7 @@ export namespace healthcare_v1alpha2 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ requestedPolicyVersion?: number; } @@ -1271,10 +1267,6 @@ export namespace healthcare_v1alpha2 { permissions?: string[]; } export interface Schema$TextConfig { - /** - * Experimental de-identification config to use. For internal use only. If not specified, it is ignored and standard DLP is used. - */ - experimentalConfig?: string; /** * The transformations to apply to the detected data. */ @@ -1832,7 +1824,7 @@ export namespace healthcare_v1alpha2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2273,7 +2265,7 @@ export namespace healthcare_v1alpha2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -3882,7 +3874,7 @@ export namespace healthcare_v1alpha2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3950,7 +3942,7 @@ export namespace healthcare_v1alpha2 { /** * healthcare.projects.locations.datasets.dicomStores.import - * @desc Imports data into the DICOM store by copying it from the specified source. For errors, the Operation will be populated with error details (in the form of ImportDicomDataErrorDetails in error.details), which will hold finer-grained error information. The metadata field type is OperationMetadata. + * @desc Imports data into the DICOM store by copying it from the specified source. For errors, the Operation will be populated with error details (in the form of ImportDicomDataErrorDetails in error.details), which will hold finer-grained error information. Errors are also logged to Stackdriver (see [Viewing logs](/healthcare/docs/how-tos/stackdriver-logging)). The metadata field type is OperationMetadata. * @alias healthcare.projects.locations.datasets.dicomStores.import * @memberOf! () * @@ -4401,7 +4393,7 @@ export namespace healthcare_v1alpha2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -6337,15 +6329,11 @@ export namespace healthcare_v1alpha2 { export class Resource$Projects$Locations$Datasets$Fhirstores { context: APIRequestContext; fhir: Resource$Projects$Locations$Datasets$Fhirstores$Fhir; - securityLabels: Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels; constructor(context: APIRequestContext) { this.context = context; this.fhir = new Resource$Projects$Locations$Datasets$Fhirstores$Fhir( this.context ); - this.securityLabels = new Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels( - this.context - ); } /** @@ -6713,12 +6701,12 @@ export namespace healthcare_v1alpha2 { /** * healthcare.projects.locations.datasets.fhirStores.getIamPolicy - * @desc Gets the access control policy for a FHIR store or security label within a FHIR store. Returns NOT_FOUND error if the resource does not exist. Returns an empty policy if the resource exists but does not have a policy set. Authorization requires the Google IAM permission `healthcare.fhirStores.getIamPolicy` for a FHIR store or `healthcare.securityLabels.getIamPolicy` for a security label + * @desc Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set. * @alias healthcare.projects.locations.datasets.fhirStores.getIamPolicy * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -6786,7 +6774,7 @@ export namespace healthcare_v1alpha2 { /** * healthcare.projects.locations.datasets.fhirStores.import - * @desc Import resources to the FHIR store by loading data from the specified sources. Each resource must have a client-supplied ID, which is retained by the server. The import operation is idempotent. Upon retry, the most recent data (matching the client-supplied ID) is overwritten, without creating a new resource version. If partial failures occur during the import, successful changes are not rolled back. If history imports are enabled (enable_history_import is set in the FHIR store's configuration), you can import historical versions of a resource by supplying a bundle of type `history`. The historical versions in the bundle must have `lastUpdated` timestamps. If a current or historical version with the supplied resource ID already exists, the bundle is rejected. This method returns an Operation that can be used to track the status of the import by calling GetOperation. Immediate fatal errors appear in the error field. Otherwise, when the operation finishes, a detailed response of type ImportResourcesResponse is returned in the response field. The metadata field type for this operation is OperationMetadata. + * @desc Import resources to the FHIR store by loading data from the specified sources. This method is optimized to load large quantities of data using import semantics that ignore some FHIR store configuration options and are not suitable for all use cases. It is primarily intended to load data into an empty FHIR store that is not being used by other clients. In cases where this method is not appropriate, consider using ExecuteBundle to load data. Every resource in the input must contain a client-supplied ID, and will be stored using that ID regardless of the enable_update_create setting on the FHIR store. The import process does not enforce referential integrity, regardless of the disable_referential_integrity setting on the FHIR store. This allows the import of resources with arbitrary interdependencies without considering grouping or ordering, but if the input data contains invalid references or if some resources fail to be imported, the FHIR store might be left in a state that violates referential integrity. If a resource with the specified ID already exists, the most recent version of the resource is overwritten without creating a new historical version, regardless of the disable_resource_versioning setting on the FHIR store. If transient failures occur during the import, it is possible that successfully imported resources will be overwritten more than once. The import operation is idempotent unless the input data contains multiple valid resources with the same ID but different contents. In that case, after the import completes, the store will contain exactly one resource with that ID but there is no ordering guarantee on which version of the contents it will have. The operation result counters do not count duplicate IDs as an error and will count one success for each resource in the input, which might result in a success count larger than the number of resources in the FHIR store. This often occurs when importing data organized in bundles produced by Patient-everything where each bundle contains its own copy of a resource such as Practitioner that might be referred to by many patients. If some resources fail to import, for example due to parsing errors, successfully imported resources are not rolled back. The location and format of the input data is specified by the parameters below. Note that if no format is specified, this method assumes the `BUNDLE` format. When using the `BUNDLE` format this method ignores the `Bundle.type` field, except for the special case of `history`, and does not apply any of the bundle processing semantics for batch or transaction bundles. Unlike in ExecuteBundle, transaction bundles are not executed as a single transaction and bundle-internal references are not rewritten. The bundle is treated as a collection of resources to be written as provided in `Bundle.entry.resource`, ignoring `Bundle.entry.request`. As an example, this allows the import of `searchset` bundles produced by a FHIR search or Patient-everything operation. If history imports are enabled by setting enable_history_import in the FHIR store's configuration, this method can import historical versions of a resource by supplying a bundle of type `history` and using the `BUNDLE` format. The historical versions in the bundle must have `lastUpdated` timestamps, and the resulting resource history on the server will appear as if the versions had been created at those timestamps. If a current or historical version with the supplied resource ID already exists, the bundle is rejected to avoid creating an inconsistent sequence of resource versions. This method returns an Operation that can be used to track the status of the import by calling GetOperation. Immediate fatal errors appear in the error field. Otherwise, when the operation finishes, a detailed response of type ImportResourcesResponse is returned in the response field. The metadata field type for this operation is OperationMetadata. * @alias healthcare.projects.locations.datasets.fhirStores.import * @memberOf! () * @@ -7013,7 +7001,7 @@ export namespace healthcare_v1alpha2 { /** * healthcare.projects.locations.datasets.fhirStores.setIamPolicy - * @desc Sets the access control policy for a FHIR store or security label within a FHIR store. Replaces any existing policy. Authorization requires the Google IAM permission `healthcare.fhirStores.setIamPolicy` for a FHIR store or `healthcare.securityLabels.setIamPolicy` for a security label + * @desc Sets the access control policy on the specified resource. Replaces any existing policy. * @alias healthcare.projects.locations.datasets.fhirStores.setIamPolicy * @memberOf! () * @@ -7086,7 +7074,7 @@ export namespace healthcare_v1alpha2 { /** * healthcare.projects.locations.datasets.fhirStores.testIamPermissions - * @desc Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error. There is no permission required to make this API call. + * @desc Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may "fail open" without warning. * @alias healthcare.projects.locations.datasets.fhirStores.testIamPermissions * @memberOf! () * @@ -7249,7 +7237,7 @@ export namespace healthcare_v1alpha2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -8088,14 +8076,16 @@ export namespace healthcare_v1alpha2 { /** * healthcare.projects.locations.datasets.fhirStores.fhir.Patient-everything - * @desc Retrieves all the resources in the patient compartment for a `Patient` resource. Implements the FHIR extended operation [Patient-everything](http://hl7.org/implement/standards/fhir/STU3/patient-operations.html#everything). On success, the response body will contain a JSON-encoded representation of a `Bundle` resource of type `searchset`, containing the results of the operation. Errors generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. + * @desc Retrieves all the resources directly referenced by a patient, as well as all of the resources in the patient compartment. Implements the FHIR extended operation [Patient-everything](http://hl7.org/implement/standards/fhir/STU3/patient-operations.html#everything). On success, the response body will contain a JSON-encoded representation of a `Bundle` resource of type `searchset`, containing the results of the operation. Errors generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. * @alias healthcare.projects.locations.datasets.fhirStores.fhir.Patient-everything * @memberOf! () * * @param {object} params Parameters for request * @param {string=} params.end The response includes records prior to the end date. If no end date is provided, all records subsequent to the start date are in scope. * @param {string} params.name Name of the `Patient` resource for which the information is required. + * @param {string=} params.pageToken Used to retrieve the next or previous page of results when using pagination. Value should be set to the value of page_token set in next or previous page links' url. Next and previous page are returned in the response bundle's links field, where `link.relation` is "previous" or "next". Omit `page_token` if no previous request has been made. * @param {string=} params.start The response includes records subsequent to the start date. If no start date is provided, all records prior to the end date are in scope. + * @param {integer=} params._count Maximum number of resources in a page. Defaults to 100. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -8303,7 +8293,7 @@ export namespace healthcare_v1alpha2 { /** * healthcare.projects.locations.datasets.fhirStores.fhir.search - * @desc Searches for resources in the given FHIR store according to criteria specified as query parameters. Implements the FHIR standard [search interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#search) using the search semantics described in the [FHIR Search specification](http://hl7.org/implement/standards/fhir/STU3/search.html). Supports three methods of search defined by the specification: * `GET [base]?[parameters]` to search across all resources. * `GET [base]/[type]?[parameters]` to search resources of a specified type. * `POST [base]/[type]/_search?[parameters]` as an alternate form having the same semantics as the `GET` method. The `GET` methods do not support compartment searches. The `POST` method does not support `application/x-www-form-urlencoded` search parameters. On success, the response body will contain a JSON-encoded representation of a `Bundle` resource of type `searchset`, containing the results of the search. Errors generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. The server's capability statement, retrieved through capabilities, indicates what search parameters are supported on each FHIR resource. A list of all search parameters defined by the specification can be found in the [FHIR Search Parameter Registry](http://hl7.org/implement/standards/fhir/STU3/searchparameter-registry.html). Supported search modifiers: `:missing`, `:exact`, `:contains`, `:text`, `:in`, `:not-in`, `:above`, `:below`, `:[type]`, `:not`, and `:recurse`. Supported search result parameters: `_sort`, `_count`, `_include`, `_revinclude`, `_summary=text`, `_summary=data`, and `_elements`. The maximum number of search results returned defaults to 100, which can be overridden by the `_count` parameter up to a maximum limit of 1000. If there are additional results, the returned `Bundle` will contain pagination links. + * @desc Searches for resources in the given FHIR store according to criteria specified as query parameters. Implements the FHIR standard [search interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#search) using the search semantics described in the [FHIR Search specification](http://hl7.org/implement/standards/fhir/STU3/search.html). Supports three methods of search defined by the specification: * `GET [base]?[parameters]` to search across all resources. * `GET [base]/[type]?[parameters]` to search resources of a specified type. * `POST [base]/[type]/_search?[parameters]` as an alternate form having the same semantics as the `GET` method. The `GET` methods do not support compartment searches. The `POST` method does not support `application/x-www-form-urlencoded` search parameters. On success, the response body will contain a JSON-encoded representation of a `Bundle` resource of type `searchset`, containing the results of the search. Errors generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. The server's capability statement, retrieved through capabilities, indicates what search parameters are supported on each FHIR resource. A list of all search parameters defined by the specification can be found in the [FHIR Search Parameter Registry](http://hl7.org/implement/standards/fhir/STU3/searchparameter-registry.html). Supported search modifiers: `:missing`, `:exact`, `:contains`, `:text`, `:in`, `:not-in`, `:above`, `:below`, `:[type]`, `:not`, and `:recurse`. Supported search result parameters: `_sort`, `_count`, `_include`, `_revinclude`, `_summary=text`, `_summary=data`, and `_elements`. The maximum number of search results returned defaults to 100, which can be overridden by the `_count` parameter up to a maximum limit of 1000. If there are additional results, the returned `Bundle` will contain pagination links. Resources with a total size larger than 5MB or a field count larger than 50,000 might not be fully searchable as the server might trim its generated search index in those cases. Note: FHIR resources are indexed asynchronously, so there might be a slight delay between the time a resource is created or changes and when the change is reflected in search results. * @alias healthcare.projects.locations.datasets.fhirStores.fhir.search * @memberOf! () * @@ -8706,10 +8696,18 @@ export namespace healthcare_v1alpha2 { * Name of the `Patient` resource for which the information is required. */ name?: string; + /** + * Used to retrieve the next or previous page of results when using pagination. Value should be set to the value of page_token set in next or previous page links' url. Next and previous page are returned in the response bundle's links field, where `link.relation` is "previous" or "next". Omit `page_token` if no previous request has been made. + */ + pageToken?: string; /** * The response includes records subsequent to the start date. If no start date is provided, all records prior to the end date are in scope. */ start?: string; + /** + * Maximum number of resources in a page. Defaults to 100. + */ + _count?: number; } export interface Params$Resource$Projects$Locations$Datasets$Fhirstores$Fhir$Read extends StandardParameters { @@ -8782,193 +8780,6 @@ export namespace healthcare_v1alpha2 { name?: string; } - export class Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * healthcare.projects.locations.datasets.fhirStores.securityLabels.getIamPolicy - * @desc Gets the access control policy for a FHIR store or security label within a FHIR store. Returns NOT_FOUND error if the resource does not exist. Returns an empty policy if the resource exists but does not have a policy set. Authorization requires the Google IAM permission `healthcare.fhirStores.getIamPolicy` for a FHIR store or `healthcare.securityLabels.getIamPolicy` for a security label - * @alias healthcare.projects.locations.datasets.fhirStores.securityLabels.getIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. - * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - getIamPolicy( - params?: Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Getiampolicy, - options?: MethodOptions - ): GaxiosPromise; - getIamPolicy( - params: Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Getiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - getIamPolicy( - params: Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Getiampolicy, - callback: BodyResponseCallback - ): void; - getIamPolicy(callback: BodyResponseCallback): void; - getIamPolicy( - paramsOrCallback?: - | Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Getiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Getiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Getiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://healthcare.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1alpha2/{+resource}:getIamPolicy').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'GET', - }, - options - ), - params, - requiredParams: ['resource'], - pathParams: ['resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * healthcare.projects.locations.datasets.fhirStores.securityLabels.setIamPolicy - * @desc Sets the access control policy for a FHIR store or security label within a FHIR store. Replaces any existing policy. Authorization requires the Google IAM permission `healthcare.fhirStores.setIamPolicy` for a FHIR store or `healthcare.securityLabels.setIamPolicy` for a security label - * @alias healthcare.projects.locations.datasets.fhirStores.securityLabels.setIamPolicy - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.resource_ REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. - * @param {().SetIamPolicyRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - setIamPolicy( - params?: Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Setiampolicy, - options?: MethodOptions - ): GaxiosPromise; - setIamPolicy( - params: Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Setiampolicy, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - setIamPolicy( - params: Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Setiampolicy, - callback: BodyResponseCallback - ): void; - setIamPolicy(callback: BodyResponseCallback): void; - setIamPolicy( - paramsOrCallback?: - | Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Setiampolicy - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Setiampolicy; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Setiampolicy; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://healthcare.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1alpha2/{+resource}:setIamPolicy').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'POST', - }, - options - ), - params, - requiredParams: ['resource'], - pathParams: ['resource'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Getiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. - */ - 'options.requestedPolicyVersion'?: number; - /** - * REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. - */ - resource?: string; - } - export interface Params$Resource$Projects$Locations$Datasets$Fhirstores$Securitylabels$Setiampolicy - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. - */ - resource?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$SetIamPolicyRequest; - } - export class Resource$Projects$Locations$Datasets$Hl7v2stores { context: APIRequestContext; messages: Resource$Projects$Locations$Datasets$Hl7v2stores$Messages; @@ -9202,7 +9013,7 @@ export namespace healthcare_v1alpha2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -9629,7 +9440,7 @@ export namespace healthcare_v1alpha2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -10014,12 +9825,12 @@ export namespace healthcare_v1alpha2 { /** * healthcare.projects.locations.datasets.hl7V2Stores.messages.list - * @desc Lists all the messages in the given HL7v2 store with support for filtering. + * @desc Lists all the messages in the given HL7v2 store with support for filtering. Note: HL7v2 messages are indexed asynchronously, so there might be a slight delay between the time a message is created and when it can be found through a filter. * @alias healthcare.projects.locations.datasets.hl7V2Stores.messages.list * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.filter Restricts messages returned to those matching a filter. Syntax: https://cloud.google.com/appengine/docs/standard/python/search/query_strings Fields/functions available for filtering are: * `message_type`, from the MSH-9 segment; for example `NOT message_type = "ADT"` * `send_date` or `sendDate`, the YYYY-MM-DD date the message was sent in the dataset's time_zone, from the MSH-7 segment; for example `send_date < "2017-01-02"` * `send_time`, the timestamp of when the message was sent, using the RFC3339 time format for comparisons, from the MSH-7 segment; for example `send_time < "2017-01-02T00:00:00-05:00"` * `send_facility`, the care center that the message came from, from the MSH-4 segment; for example `send_facility = "ABC"` * `HL7RegExp(expr)`, which does regular expression matching of `expr` against the message payload using re2 (http://code.google.com/p/re2/) syntax; for example `HL7RegExp("^.*\|.*\|EMERG")` * `PatientId(value, type)`, which matches if the message lists a patient having an ID of the given value and type in the PID-2, PID-3, or PID-4 segments; for example `PatientId("123456", "MRN")` * `labels.x`, a string value of the label with key `x` as set using the Message.labels map, for example `labels."priority"="high"`. The operator `:*` can be used to assert the existence of a label, for example `labels."priority":*`. Limitations on conjunctions: * Negation on the patient ID function or the labels field is not supported, for example these queries are invalid: `NOT PatientId("123456", "MRN")`, `NOT labels."tag1":*`, `NOT labels."tag2"="val2"`. * Conjunction of multiple patient ID functions is not supported, for example this query is invalid: `PatientId("123456", "MRN") AND PatientId("456789", "MRN")`. * Conjunction of multiple labels fields is also not supported, for example this query is invalid: `labels."tag1":* AND labels."tag2"="val2"`. * Conjunction of one patient ID function, one labels field and conditions on other fields is supported, for example this query is valid: `PatientId("123456", "MRN") AND labels."tag1":* AND message_type = "ADT"`. The HasLabel(x) and Label(x) syntax from previous API versions are deprecated; replaced by the `labels.x` syntax. + * @param {string=} params.filter Restricts messages returned to those matching a filter. Syntax: https://cloud.google.com/appengine/docs/standard/python/search/query_strings Fields/functions available for filtering are: * `message_type`, from the MSH-9 segment; for example `NOT message_type = "ADT"` * `send_date` or `sendDate`, the YYYY-MM-DD date the message was sent in the dataset's time_zone, from the MSH-7 segment; for example `send_date < "2017-01-02"` * `send_time`, the timestamp when the message was sent, using the RFC3339 time format for comparisons, from the MSH-7 segment; for example `send_time < "2017-01-02T00:00:00-05:00"` * `send_facility`, the care center that the message came from, from the MSH-4 segment; for example `send_facility = "ABC"` * `HL7RegExp(expr)`, which does regular expression matching of `expr` against the message payload using re2 (http://code.google.com/p/re2/) syntax; for example `HL7RegExp("^.*\|.*\|EMERG")` * `PatientId(value, type)`, which matches if the message lists a patient having an ID of the given value and type in the PID-2, PID-3, or PID-4 segments; for example `PatientId("123456", "MRN")` * `labels.x`, a string value of the label with key `x` as set using the Message.labels map, for example `labels."priority"="high"`. The operator `:*` can be used to assert the existence of a label, for example `labels."priority":*`. Limitations on conjunctions: * Negation on the patient ID function or the labels field is not supported, for example these queries are invalid: `NOT PatientId("123456", "MRN")`, `NOT labels."tag1":*`, `NOT labels."tag2"="val2"`. * Conjunction of multiple patient ID functions is not supported, for example this query is invalid: `PatientId("123456", "MRN") AND PatientId("456789", "MRN")`. * Conjunction of multiple labels fields is also not supported, for example this query is invalid: `labels."tag1":* AND labels."tag2"="val2"`. * Conjunction of one patient ID function, one labels field and conditions on other fields is supported, for example this query is valid: `PatientId("123456", "MRN") AND labels."tag1":* AND message_type = "ADT"`. The HasLabel(x) and Label(x) syntax from previous API versions are deprecated; replaced by the `labels.x` syntax. * @param {string=} params.orderBy Orders messages returned by the specified order_by clause. Syntax: https://cloud.google.com/apis/design/design_patterns#sorting_order Fields available for ordering are: * `send_time` * @param {integer=} params.pageSize Limit on the number of messages to return in a single response. If zero the default page size of 100 is used. * @param {string=} params.pageToken The next_page_token value returned from the previous List request, if any. @@ -10234,7 +10045,7 @@ export namespace healthcare_v1alpha2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Restricts messages returned to those matching a filter. Syntax: https://cloud.google.com/appengine/docs/standard/python/search/query_strings Fields/functions available for filtering are: * `message_type`, from the MSH-9 segment; for example `NOT message_type = "ADT"` * `send_date` or `sendDate`, the YYYY-MM-DD date the message was sent in the dataset's time_zone, from the MSH-7 segment; for example `send_date < "2017-01-02"` * `send_time`, the timestamp of when the message was sent, using the RFC3339 time format for comparisons, from the MSH-7 segment; for example `send_time < "2017-01-02T00:00:00-05:00"` * `send_facility`, the care center that the message came from, from the MSH-4 segment; for example `send_facility = "ABC"` * `HL7RegExp(expr)`, which does regular expression matching of `expr` against the message payload using re2 (http://code.google.com/p/re2/) syntax; for example `HL7RegExp("^.*\|.*\|EMERG")` * `PatientId(value, type)`, which matches if the message lists a patient having an ID of the given value and type in the PID-2, PID-3, or PID-4 segments; for example `PatientId("123456", "MRN")` * `labels.x`, a string value of the label with key `x` as set using the Message.labels map, for example `labels."priority"="high"`. The operator `:*` can be used to assert the existence of a label, for example `labels."priority":*`. Limitations on conjunctions: * Negation on the patient ID function or the labels field is not supported, for example these queries are invalid: `NOT PatientId("123456", "MRN")`, `NOT labels."tag1":*`, `NOT labels."tag2"="val2"`. * Conjunction of multiple patient ID functions is not supported, for example this query is invalid: `PatientId("123456", "MRN") AND PatientId("456789", "MRN")`. * Conjunction of multiple labels fields is also not supported, for example this query is invalid: `labels."tag1":* AND labels."tag2"="val2"`. * Conjunction of one patient ID function, one labels field and conditions on other fields is supported, for example this query is valid: `PatientId("123456", "MRN") AND labels."tag1":* AND message_type = "ADT"`. The HasLabel(x) and Label(x) syntax from previous API versions are deprecated; replaced by the `labels.x` syntax. + * Restricts messages returned to those matching a filter. Syntax: https://cloud.google.com/appengine/docs/standard/python/search/query_strings Fields/functions available for filtering are: * `message_type`, from the MSH-9 segment; for example `NOT message_type = "ADT"` * `send_date` or `sendDate`, the YYYY-MM-DD date the message was sent in the dataset's time_zone, from the MSH-7 segment; for example `send_date < "2017-01-02"` * `send_time`, the timestamp when the message was sent, using the RFC3339 time format for comparisons, from the MSH-7 segment; for example `send_time < "2017-01-02T00:00:00-05:00"` * `send_facility`, the care center that the message came from, from the MSH-4 segment; for example `send_facility = "ABC"` * `HL7RegExp(expr)`, which does regular expression matching of `expr` against the message payload using re2 (http://code.google.com/p/re2/) syntax; for example `HL7RegExp("^.*\|.*\|EMERG")` * `PatientId(value, type)`, which matches if the message lists a patient having an ID of the given value and type in the PID-2, PID-3, or PID-4 segments; for example `PatientId("123456", "MRN")` * `labels.x`, a string value of the label with key `x` as set using the Message.labels map, for example `labels."priority"="high"`. The operator `:*` can be used to assert the existence of a label, for example `labels."priority":*`. Limitations on conjunctions: * Negation on the patient ID function or the labels field is not supported, for example these queries are invalid: `NOT PatientId("123456", "MRN")`, `NOT labels."tag1":*`, `NOT labels."tag2"="val2"`. * Conjunction of multiple patient ID functions is not supported, for example this query is invalid: `PatientId("123456", "MRN") AND PatientId("456789", "MRN")`. * Conjunction of multiple labels fields is also not supported, for example this query is invalid: `labels."tag1":* AND labels."tag2"="val2"`. * Conjunction of one patient ID function, one labels field and conditions on other fields is supported, for example this query is valid: `PatientId("123456", "MRN") AND labels."tag1":* AND message_type = "ADT"`. The HasLabel(x) and Label(x) syntax from previous API versions are deprecated; replaced by the `labels.x` syntax. */ filter?: string; /** diff --git a/src/apis/healthcare/v1beta1.ts b/src/apis/healthcare/v1beta1.ts index c6a622c8606..540b9fe8850 100644 --- a/src/apis/healthcare/v1beta1.ts +++ b/src/apis/healthcare/v1beta1.ts @@ -138,10 +138,6 @@ export namespace healthcare_v1beta1 { * Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members. */ exemptedMembers?: string[]; - /** - * Specifies whether principals can be exempted for the same LogType in lower-level resource policies. If true, any lower-level exemptions will be ignored. - */ - ignoreChildExemptions?: boolean; /** * The log type that this config enables. */ @@ -187,7 +183,7 @@ export namespace healthcare_v1beta1 { */ export interface Schema$CryptoHashConfig { /** - * An AES 128/192/256 bit key. Causes the hash to be computed based on this key. A default key is generated for each DeidentifyDataset operation and is used wherever crypto_key is not specified. + * An AES 128/192/256 bit key. Causes the hash to be computed based on this key. A default key is generated for each Deidentify operation and is used wherever crypto_key is not specified. */ cryptoKey?: string; } @@ -209,7 +205,7 @@ export namespace healthcare_v1beta1 { */ export interface Schema$DateShiftConfig { /** - * An AES 128/192/256 bit key. Causes the shift to be computed based on this key and the patient ID. A default key is generated for each DeidentifyDataset operation and is used wherever crypto_key is not specified. + * An AES 128/192/256 bit key. Causes the shift to be computed based on this key and the patient ID. A default key is generated for each Deidentify operation and is used wherever crypto_key is not specified. */ cryptoKey?: string; } @@ -297,6 +293,10 @@ export namespace healthcare_v1beta1 { * List of tags to remove. Keep all other tags. */ removeList?: Schema$TagFilterList; + /** + * If true, skip replacing StudyInstanceUID, SeriesInstanceUID, SOPInstanceUID, and MediaStorageSOPInstanceUID and leave them untouched. The Cloud Healthcare API regenerates these UIDs by default based on the DICOM Standard's reasoning: "Whilst these UIDs cannot be mapped directly to an individual out of context, given access to the original images, or to a database of the original images containing the UIDs, it would be possible to recover the individual's identity." http://dicom.nema.org/medical/dicom/current/output/chtml/part15/sect_E.3.9.html + */ + skipIdRedaction?: boolean; } /** * Represents a DICOM store. @@ -1932,7 +1932,7 @@ export namespace healthcare_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2587,7 +2587,7 @@ export namespace healthcare_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -3216,7 +3216,7 @@ export namespace healthcare_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3284,7 +3284,7 @@ export namespace healthcare_v1beta1 { /** * healthcare.projects.locations.datasets.dicomStores.import - * @desc Imports data into the DICOM store by copying it from the specified source. For errors, the Operation will be populated with error details (in the form of ImportDicomDataErrorDetails in error.details), which will hold finer-grained error information. The metadata field type is OperationMetadata. + * @desc Imports data into the DICOM store by copying it from the specified source. For errors, the Operation will be populated with error details (in the form of ImportDicomDataErrorDetails in error.details), which will hold finer-grained error information. Errors are also logged to Stackdriver (see [Viewing logs](/healthcare/docs/how-tos/stackdriver-logging)). The metadata field type is OperationMetadata. * @example * * // BEFORE RUNNING: * // --------------- @@ -4496,7 +4496,7 @@ export namespace healthcare_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -7486,7 +7486,7 @@ export namespace healthcare_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -7554,7 +7554,7 @@ export namespace healthcare_v1beta1 { /** * healthcare.projects.locations.datasets.fhirStores.import - * @desc Import resources to the FHIR store by loading data from the specified sources. Each resource must have a client-supplied ID, which is retained by the server. The import operation is idempotent. Upon retry, the most recent data (matching the client-supplied ID) is overwritten, without creating a new resource version. If partial failures occur during the import, successful changes are not rolled back. If history imports are enabled (enable_history_import is set in the FHIR store's configuration), you can import historical versions of a resource by supplying a bundle of type `history`. The historical versions in the bundle must have `lastUpdated` timestamps. If a current or historical version with the supplied resource ID already exists, the bundle is rejected. This method returns an Operation that can be used to track the status of the import by calling GetOperation. Immediate fatal errors appear in the error field. Otherwise, when the operation finishes, a detailed response of type ImportResourcesResponse is returned in the response field. The metadata field type for this operation is OperationMetadata. + * @desc Import resources to the FHIR store by loading data from the specified sources. This method is optimized to load large quantities of data using import semantics that ignore some FHIR store configuration options and are not suitable for all use cases. It is primarily intended to load data into an empty FHIR store that is not being used by other clients. In cases where this method is not appropriate, consider using ExecuteBundle to load data. Every resource in the input must contain a client-supplied ID, and will be stored using that ID regardless of the enable_update_create setting on the FHIR store. The import process does not enforce referential integrity, regardless of the disable_referential_integrity setting on the FHIR store. This allows the import of resources with arbitrary interdependencies without considering grouping or ordering, but if the input data contains invalid references or if some resources fail to be imported, the FHIR store might be left in a state that violates referential integrity. If a resource with the specified ID already exists, the most recent version of the resource is overwritten without creating a new historical version, regardless of the disable_resource_versioning setting on the FHIR store. If transient failures occur during the import, it is possible that successfully imported resources will be overwritten more than once. The import operation is idempotent unless the input data contains multiple valid resources with the same ID but different contents. In that case, after the import completes, the store will contain exactly one resource with that ID but there is no ordering guarantee on which version of the contents it will have. The operation result counters do not count duplicate IDs as an error and will count one success for each resource in the input, which might result in a success count larger than the number of resources in the FHIR store. This often occurs when importing data organized in bundles produced by Patient-everything where each bundle contains its own copy of a resource such as Practitioner that might be referred to by many patients. If some resources fail to import, for example due to parsing errors, successfully imported resources are not rolled back. The location and format of the input data is specified by the parameters below. Note that if no format is specified, this method assumes the `BUNDLE` format. When using the `BUNDLE` format this method ignores the `Bundle.type` field, except for the special case of `history`, and does not apply any of the bundle processing semantics for batch or transaction bundles. Unlike in ExecuteBundle, transaction bundles are not executed as a single transaction and bundle-internal references are not rewritten. The bundle is treated as a collection of resources to be written as provided in `Bundle.entry.resource`, ignoring `Bundle.entry.request`. As an example, this allows the import of `searchset` bundles produced by a FHIR search or Patient-everything operation. If history imports are enabled by setting enable_history_import in the FHIR store's configuration, this method can import historical versions of a resource by supplying a bundle of type `history` and using the `BUNDLE` format. The historical versions in the bundle must have `lastUpdated` timestamps, and the resulting resource history on the server will appear as if the versions had been created at those timestamps. If a current or historical version with the supplied resource ID already exists, the bundle is rejected to avoid creating an inconsistent sequence of resource versions. This method returns an Operation that can be used to track the status of the import by calling GetOperation. Immediate fatal errors appear in the error field. Otherwise, when the operation finishes, a detailed response of type ImportResourcesResponse is returned in the response field. The metadata field type for this operation is OperationMetadata. * @example * * // BEFORE RUNNING: * // --------------- @@ -8270,7 +8270,7 @@ export namespace healthcare_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -9611,7 +9611,7 @@ export namespace healthcare_v1beta1 { /** * healthcare.projects.locations.datasets.fhirStores.fhir.Patient-everything - * @desc Retrieves all the resources in the patient compartment for a `Patient` resource. Implements the FHIR extended operation [Patient-everything](http://hl7.org/implement/standards/fhir/STU3/patient-operations.html#everything). On success, the response body will contain a JSON-encoded representation of a `Bundle` resource of type `searchset`, containing the results of the operation. Errors generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. + * @desc Retrieves all the resources directly referenced by a patient, as well as all of the resources in the patient compartment. Implements the FHIR extended operation [Patient-everything](http://hl7.org/implement/standards/fhir/STU3/patient-operations.html#everything). On success, the response body will contain a JSON-encoded representation of a `Bundle` resource of type `searchset`, containing the results of the operation. Errors generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. * @example * * // BEFORE RUNNING: * // --------------- @@ -9664,7 +9664,9 @@ export namespace healthcare_v1beta1 { * @param {object} params Parameters for request * @param {string=} params.end The response includes records prior to the end date. If no end date is provided, all records subsequent to the start date are in scope. * @param {string} params.name Name of the `Patient` resource for which the information is required. + * @param {string=} params.pageToken Used to retrieve the next or previous page of results when using pagination. Value should be set to the value of page_token set in next or previous page links' urls. Next and previous page are returned in the response bundle's links field, where `link.relation` is "previous" or "next". Omit `page_token` if no previous request has been made. * @param {string=} params.start The response includes records subsequent to the start date. If no start date is provided, all records prior to the end date are in scope. + * @param {integer=} params._count Maximum number of resources in a page. Defaults to 100. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -9961,7 +9963,7 @@ export namespace healthcare_v1beta1 { /** * healthcare.projects.locations.datasets.fhirStores.fhir.search - * @desc Searches for resources in the given FHIR store according to criteria specified as query parameters. Implements the FHIR standard [search interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#search) using the search semantics described in the [FHIR Search specification](http://hl7.org/implement/standards/fhir/STU3/search.html). Supports three methods of search defined by the specification: * `GET [base]?[parameters]` to search across all resources. * `GET [base]/[type]?[parameters]` to search resources of a specified type. * `POST [base]/[type]/_search?[parameters]` as an alternate form having the same semantics as the `GET` method. The `GET` methods do not support compartment searches. The `POST` method does not support `application/x-www-form-urlencoded` search parameters. On success, the response body will contain a JSON-encoded representation of a `Bundle` resource of type `searchset`, containing the results of the search. Errors generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. The server's capability statement, retrieved through capabilities, indicates what search parameters are supported on each FHIR resource. A list of all search parameters defined by the specification can be found in the [FHIR Search Parameter Registry](http://hl7.org/implement/standards/fhir/STU3/searchparameter-registry.html). Supported search modifiers: `:missing`, `:exact`, `:contains`, `:text`, `:in`, `:not-in`, `:above`, `:below`, `:[type]`, `:not`, and `:recurse`. Supported search result parameters: `_sort`, `_count`, `_include`, `_revinclude`, `_summary=text`, `_summary=data`, and `_elements`. The maximum number of search results returned defaults to 100, which can be overridden by the `_count` parameter up to a maximum limit of 1000. If there are additional results, the returned `Bundle` will contain pagination links. + * @desc Searches for resources in the given FHIR store according to criteria specified as query parameters. Implements the FHIR standard [search interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#search) using the search semantics described in the [FHIR Search specification](http://hl7.org/implement/standards/fhir/STU3/search.html). Supports three methods of search defined by the specification: * `GET [base]?[parameters]` to search across all resources. * `GET [base]/[type]?[parameters]` to search resources of a specified type. * `POST [base]/[type]/_search?[parameters]` as an alternate form having the same semantics as the `GET` method. The `GET` methods do not support compartment searches. The `POST` method does not support `application/x-www-form-urlencoded` search parameters. On success, the response body will contain a JSON-encoded representation of a `Bundle` resource of type `searchset`, containing the results of the search. Errors generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. The server's capability statement, retrieved through capabilities, indicates what search parameters are supported on each FHIR resource. A list of all search parameters defined by the specification can be found in the [FHIR Search Parameter Registry](http://hl7.org/implement/standards/fhir/STU3/searchparameter-registry.html). Supported search modifiers: `:missing`, `:exact`, `:contains`, `:text`, `:in`, `:not-in`, `:above`, `:below`, `:[type]`, `:not`, and `:recurse`. Supported search result parameters: `_sort`, `_count`, `_include`, `_revinclude`, `_summary=text`, `_summary=data`, and `_elements`. The maximum number of search results returned defaults to 100, which can be overridden by the `_count` parameter up to a maximum limit of 1000. If there are additional results, the returned `Bundle` will contain pagination links. Resources with a total size larger than 5MB or a field count larger than 50,000 might not be fully searchable as the server might trim its generated search index in those cases. Note: FHIR resources are indexed asynchronously, so there might be a slight delay between the time a resource is created or changes and when the change is reflected in search results. * @example * * // BEFORE RUNNING: * // --------------- @@ -10511,10 +10513,18 @@ export namespace healthcare_v1beta1 { * Name of the `Patient` resource for which the information is required. */ name?: string; + /** + * Used to retrieve the next or previous page of results when using pagination. Value should be set to the value of page_token set in next or previous page links' urls. Next and previous page are returned in the response bundle's links field, where `link.relation` is "previous" or "next". Omit `page_token` if no previous request has been made. + */ + pageToken?: string; /** * The response includes records subsequent to the start date. If no start date is provided, all records prior to the end date are in scope. */ start?: string; + /** + * Maximum number of resources in a page. Defaults to 100. + */ + _count?: number; } export interface Params$Resource$Projects$Locations$Datasets$Fhirstores$Fhir$Read extends StandardParameters { @@ -11006,7 +11016,7 @@ export namespace healthcare_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -11646,7 +11656,7 @@ export namespace healthcare_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -12220,7 +12230,7 @@ export namespace healthcare_v1beta1 { /** * healthcare.projects.locations.datasets.hl7V2Stores.messages.list - * @desc Lists all the messages in the given HL7v2 store with support for filtering. + * @desc Lists all the messages in the given HL7v2 store with support for filtering. Note: HL7v2 messages are indexed asynchronously, so there might be a slight delay between the time a message is created and when it can be found through a filter. * @example * * // BEFORE RUNNING: * // --------------- @@ -12284,7 +12294,7 @@ export namespace healthcare_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.filter Restricts messages returned to those matching a filter. Syntax: https://cloud.google.com/appengine/docs/standard/python/search/query_strings Fields/functions available for filtering are: * `message_type`, from the MSH-9 segment; for example `NOT message_type = "ADT"` * `send_date` or `sendDate`, the YYYY-MM-DD date the message was sent in the dataset's time_zone, from the MSH-7 segment; for example `send_date < "2017-01-02"` * `send_time`, the timestamp of when the message was sent, using the RFC3339 time format for comparisons, from the MSH-7 segment; for example `send_time < "2017-01-02T00:00:00-05:00"` * `send_facility`, the care center that the message came from, from the MSH-4 segment; for example `send_facility = "ABC"` * `HL7RegExp(expr)`, which does regular expression matching of `expr` against the message payload using re2 (http://code.google.com/p/re2/) syntax; for example `HL7RegExp("^.*\|.*\|EMERG")` * `PatientId(value, type)`, which matches if the message lists a patient having an ID of the given value and type in the PID-2, PID-3, or PID-4 segments; for example `PatientId("123456", "MRN")` * `labels.x`, a string value of the label with key `x` as set using the Message.labels map, for example `labels."priority"="high"`. The operator `:*` can be used to assert the existence of a label, for example `labels."priority":*`. Limitations on conjunctions: * Negation on the patient ID function or the labels field is not supported, for example these queries are invalid: `NOT PatientId("123456", "MRN")`, `NOT labels."tag1":*`, `NOT labels."tag2"="val2"`. * Conjunction of multiple patient ID functions is not supported, for example this query is invalid: `PatientId("123456", "MRN") AND PatientId("456789", "MRN")`. * Conjunction of multiple labels fields is also not supported, for example this query is invalid: `labels."tag1":* AND labels."tag2"="val2"`. * Conjunction of one patient ID function, one labels field and conditions on other fields is supported, for example this query is valid: `PatientId("123456", "MRN") AND labels."tag1":* AND message_type = "ADT"`. + * @param {string=} params.filter Restricts messages returned to those matching a filter. Syntax: https://cloud.google.com/appengine/docs/standard/python/search/query_strings Fields/functions available for filtering are: * `message_type`, from the MSH-9 segment; for example `NOT message_type = "ADT"` * `send_date` or `sendDate`, the YYYY-MM-DD date the message was sent in the dataset's time_zone, from the MSH-7 segment; for example `send_date < "2017-01-02"` * `send_time`, the timestamp when the message was sent, using the RFC3339 time format for comparisons, from the MSH-7 segment; for example `send_time < "2017-01-02T00:00:00-05:00"` * `send_facility`, the care center that the message came from, from the MSH-4 segment; for example `send_facility = "ABC"` * `HL7RegExp(expr)`, which does regular expression matching of `expr` against the message payload using re2 (http://code.google.com/p/re2/) syntax; for example `HL7RegExp("^.*\|.*\|EMERG")` * `PatientId(value, type)`, which matches if the message lists a patient having an ID of the given value and type in the PID-2, PID-3, or PID-4 segments; for example `PatientId("123456", "MRN")` * `labels.x`, a string value of the label with key `x` as set using the Message.labels map, for example `labels."priority"="high"`. The operator `:*` can be used to assert the existence of a label, for example `labels."priority":*`. Limitations on conjunctions: * Negation on the patient ID function or the labels field is not supported, for example these queries are invalid: `NOT PatientId("123456", "MRN")`, `NOT labels."tag1":*`, `NOT labels."tag2"="val2"`. * Conjunction of multiple patient ID functions is not supported, for example this query is invalid: `PatientId("123456", "MRN") AND PatientId("456789", "MRN")`. * Conjunction of multiple labels fields is also not supported, for example this query is invalid: `labels."tag1":* AND labels."tag2"="val2"`. * Conjunction of one patient ID function, one labels field and conditions on other fields is supported, for example this query is valid: `PatientId("123456", "MRN") AND labels."tag1":* AND message_type = "ADT"`. * @param {string=} params.orderBy Orders messages returned by the specified order_by clause. Syntax: https://cloud.google.com/apis/design/design_patterns#sorting_order Fields available for ordering are: * `send_time` * @param {integer=} params.pageSize Limit on the number of messages to return in a single response. If zero the default page size of 100 is used. * @param {string=} params.pageToken The next_page_token value returned from the previous List request, if any. @@ -12552,7 +12562,7 @@ export namespace healthcare_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Restricts messages returned to those matching a filter. Syntax: https://cloud.google.com/appengine/docs/standard/python/search/query_strings Fields/functions available for filtering are: * `message_type`, from the MSH-9 segment; for example `NOT message_type = "ADT"` * `send_date` or `sendDate`, the YYYY-MM-DD date the message was sent in the dataset's time_zone, from the MSH-7 segment; for example `send_date < "2017-01-02"` * `send_time`, the timestamp of when the message was sent, using the RFC3339 time format for comparisons, from the MSH-7 segment; for example `send_time < "2017-01-02T00:00:00-05:00"` * `send_facility`, the care center that the message came from, from the MSH-4 segment; for example `send_facility = "ABC"` * `HL7RegExp(expr)`, which does regular expression matching of `expr` against the message payload using re2 (http://code.google.com/p/re2/) syntax; for example `HL7RegExp("^.*\|.*\|EMERG")` * `PatientId(value, type)`, which matches if the message lists a patient having an ID of the given value and type in the PID-2, PID-3, or PID-4 segments; for example `PatientId("123456", "MRN")` * `labels.x`, a string value of the label with key `x` as set using the Message.labels map, for example `labels."priority"="high"`. The operator `:*` can be used to assert the existence of a label, for example `labels."priority":*`. Limitations on conjunctions: * Negation on the patient ID function or the labels field is not supported, for example these queries are invalid: `NOT PatientId("123456", "MRN")`, `NOT labels."tag1":*`, `NOT labels."tag2"="val2"`. * Conjunction of multiple patient ID functions is not supported, for example this query is invalid: `PatientId("123456", "MRN") AND PatientId("456789", "MRN")`. * Conjunction of multiple labels fields is also not supported, for example this query is invalid: `labels."tag1":* AND labels."tag2"="val2"`. * Conjunction of one patient ID function, one labels field and conditions on other fields is supported, for example this query is valid: `PatientId("123456", "MRN") AND labels."tag1":* AND message_type = "ADT"`. + * Restricts messages returned to those matching a filter. Syntax: https://cloud.google.com/appengine/docs/standard/python/search/query_strings Fields/functions available for filtering are: * `message_type`, from the MSH-9 segment; for example `NOT message_type = "ADT"` * `send_date` or `sendDate`, the YYYY-MM-DD date the message was sent in the dataset's time_zone, from the MSH-7 segment; for example `send_date < "2017-01-02"` * `send_time`, the timestamp when the message was sent, using the RFC3339 time format for comparisons, from the MSH-7 segment; for example `send_time < "2017-01-02T00:00:00-05:00"` * `send_facility`, the care center that the message came from, from the MSH-4 segment; for example `send_facility = "ABC"` * `HL7RegExp(expr)`, which does regular expression matching of `expr` against the message payload using re2 (http://code.google.com/p/re2/) syntax; for example `HL7RegExp("^.*\|.*\|EMERG")` * `PatientId(value, type)`, which matches if the message lists a patient having an ID of the given value and type in the PID-2, PID-3, or PID-4 segments; for example `PatientId("123456", "MRN")` * `labels.x`, a string value of the label with key `x` as set using the Message.labels map, for example `labels."priority"="high"`. The operator `:*` can be used to assert the existence of a label, for example `labels."priority":*`. Limitations on conjunctions: * Negation on the patient ID function or the labels field is not supported, for example these queries are invalid: `NOT PatientId("123456", "MRN")`, `NOT labels."tag1":*`, `NOT labels."tag2"="val2"`. * Conjunction of multiple patient ID functions is not supported, for example this query is invalid: `PatientId("123456", "MRN") AND PatientId("456789", "MRN")`. * Conjunction of multiple labels fields is also not supported, for example this query is invalid: `labels."tag1":* AND labels."tag2"="val2"`. * Conjunction of one patient ID function, one labels field and conditions on other fields is supported, for example this query is valid: `PatientId("123456", "MRN") AND labels."tag1":* AND message_type = "ADT"`. */ filter?: string; /** diff --git a/src/apis/appstate/README.md b/src/apis/homegraph/README.md similarity index 84% rename from src/apis/appstate/README.md rename to src/apis/homegraph/README.md index 1f0fce86d8b..e09164fc7ec 100644 --- a/src/apis/appstate/README.md +++ b/src/apis/homegraph/README.md @@ -1,8 +1,8 @@ Google Inc. logo -# appstate +# homegraph -> The Google App State API. +> ## Installation @@ -19,17 +19,17 @@ This library can be used in a browser. To prepare a single file bundle, clone th [repository](https://github.com/googleapis/google-api-nodejs-client) and run ```sh -$ cd src/apis/appstate +$ cd src/apis/homegraph $ npm install $ npm run webpack ``` -The generated bundle will be written to `dist/appstate.min.js`. Use it from your HTML file: +The generated bundle will be written to `dist/homegraph.min.js`. Use it from your HTML file: ```html - + ``` diff --git a/src/apis/appstate/index.ts b/src/apis/homegraph/index.ts similarity index 67% rename from src/apis/appstate/index.ts rename to src/apis/homegraph/index.ts index 18b17bf18e8..e10f34c1007 100644 --- a/src/apis/appstate/index.ts +++ b/src/apis/homegraph/index.ts @@ -14,19 +14,21 @@ /*! THIS FILE IS AUTO-GENERATED */ import {AuthPlus, getAPI, GoogleConfigurable} from 'googleapis-common'; -import {appstate_v1} from './v1'; +import {homegraph_v1} from './v1'; export const VERSIONS = { - v1: appstate_v1.Appstate, + v1: homegraph_v1.Homegraph, }; -export function appstate(version: 'v1'): appstate_v1.Appstate; -export function appstate(options: appstate_v1.Options): appstate_v1.Appstate; -export function appstate( +export function homegraph(version: 'v1'): homegraph_v1.Homegraph; +export function homegraph( + options: homegraph_v1.Options +): homegraph_v1.Homegraph; +export function homegraph( this: GoogleConfigurable, - versionOrOptions: 'v1' | appstate_v1.Options + versionOrOptions: 'v1' | homegraph_v1.Options ) { - return getAPI('appstate', versionOrOptions, VERSIONS, this); + return getAPI('homegraph', versionOrOptions, VERSIONS, this); } const auth = new AuthPlus(); diff --git a/src/apis/appstate/package.json b/src/apis/homegraph/package.json similarity index 93% rename from src/apis/appstate/package.json rename to src/apis/homegraph/package.json index bd15df5b5b3..2dce0affb36 100644 --- a/src/apis/appstate/package.json +++ b/src/apis/homegraph/package.json @@ -1,7 +1,7 @@ { - "name": "@google/appstate", + "name": "@google/homegraph", "version": "0.1.0", - "description": "appstate", + "description": "homegraph", "main": "build/index.js", "types": "build/index.d.ts", "keywords": [ diff --git a/src/apis/homegraph/tsconfig.json b/src/apis/homegraph/tsconfig.json new file mode 100644 index 00000000000..e0810904968 --- /dev/null +++ b/src/apis/homegraph/tsconfig.json @@ -0,0 +1,10 @@ +{ + "extends": "./node_modules/gts/tsconfig-google.json", + "compilerOptions": { + "rootDir": ".", + "outDir": "build" + }, + "include": [ + "*.ts", + ] +} diff --git a/src/apis/homegraph/v1.ts b/src/apis/homegraph/v1.ts new file mode 100644 index 00000000000..aee7dd533d7 --- /dev/null +++ b/src/apis/homegraph/v1.ts @@ -0,0 +1,856 @@ +/** + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { + OAuth2Client, + JWT, + Compute, + UserRefreshClient, +} from 'google-auth-library'; +import { + GoogleConfigurable, + createAPIRequest, + MethodOptions, + GlobalOptions, + BodyResponseCallback, + APIRequestContext, +} from 'googleapis-common'; +import {GaxiosPromise} from 'gaxios'; + +// tslint:disable: no-any +// tslint:disable: class-name +// tslint:disable: variable-name +// tslint:disable: jsdoc-format +// tslint:disable: no-namespace + +export namespace homegraph_v1 { + export interface Options extends GlobalOptions { + version: 'v1'; + } + + interface StandardParameters { + /** + * V1 error format. + */ + '$.xgafv'?: string; + /** + * OAuth access token. + */ + access_token?: string; + /** + * Data format for response. + */ + alt?: string; + /** + * JSONP + */ + callback?: string; + /** + * Selector specifying which fields to include in a partial response. + */ + fields?: string; + /** + * 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. + */ + key?: string; + /** + * OAuth 2.0 token for the current user. + */ + oauth_token?: string; + /** + * Returns response with indentations and line breaks. + */ + prettyPrint?: boolean; + /** + * 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. + */ + quotaUser?: string; + /** + * Legacy upload protocol for media (e.g. "media", "multipart"). + */ + uploadType?: string; + /** + * Upload protocol for media (e.g. "raw", "multipart"). + */ + upload_protocol?: string; + } + + /** + * HomeGraph API + * + * + * + * @example + * const {google} = require('googleapis'); + * const homegraph = google.homegraph('v1'); + * + * @namespace homegraph + * @type {Function} + * @version v1 + * @variation v1 + * @param {object=} options Options for Homegraph + */ + export class Homegraph { + context: APIRequestContext; + agentUsers: Resource$Agentusers; + devices: Resource$Devices; + + constructor(options: GlobalOptions, google?: GoogleConfigurable) { + this.context = { + _options: options || {}, + google, + }; + + this.agentUsers = new Resource$Agentusers(this.context); + this.devices = new Resource$Devices(this.context); + } + } + + /** + * Third-party partner's device ID for one device. + */ + export interface Schema$AgentDeviceId { + /** + * Third-party partner's device ID. + */ + id?: string; + } + /** + * Identifies a device in the third party or first party system. + */ + export interface Schema$AgentOtherDeviceId { + /** + * The agent's ID. Generally it is the agent's AoG project id. + */ + agentId?: string; + /** + * Device ID defined by the agent. The device_id must be unique. + */ + deviceId?: string; + } + /** + * Third-party partner's device definition. + */ + export interface Schema$Device { + /** + * Attributes for the traits supported by the device. + */ + attributes?: {[key: string]: any}; + /** + * Custom JSON data provided by the manufacturer and attached to QUERY and EXECUTE requests in AoG. + */ + customData?: string; + /** + * Device manufacturer, model, hardware version, and software version. + */ + deviceInfo?: Schema$DeviceInfo; + /** + * Third-party partner's device ID. + */ + id?: string; + /** + * Name of the device given by the third party. This includes names given to the device via third party device manufacturer's app, model names for the device, etc. + */ + name?: Schema$DeviceNames; + /** + * IDs of other devices associated with this device. This is used to represent a device group (e.g. bonded zone) or "facets" synced through different flows (e.g. Google Nest Hub Max with a Nest Camera). This may also be used to pass in alternate IDs used to identify a cloud synced device for local execution (i.e. local verification). If used for local verification, this field is synced from the cloud. + */ + otherDeviceIds?: Schema$AgentOtherDeviceId[]; + /** + * If the third-party partner's cloud configuration includes placing devices in rooms, the name of the room can be provided here. + */ + roomHint?: string; + /** + * As in roomHint, for structures that users set up in the partner's system. + */ + structureHint?: string; + /** + * Traits supported by the device. + */ + traits?: string[]; + /** + * Hardware type of the device (e.g. light, outlet, etc). + */ + type?: string; + /** + * Indicates whether the state of this device is being reported to Google through ReportStateAndNotification call. + */ + willReportState?: boolean; + } + /** + * Device information. + */ + export interface Schema$DeviceInfo { + /** + * Device hardware version. + */ + hwVersion?: string; + /** + * Device manufacturer. + */ + manufacturer?: string; + /** + * Device model. + */ + model?: string; + /** + * Device software version. + */ + swVersion?: string; + } + /** + * Different names for the device. + */ + export interface Schema$DeviceNames { + /** + * List of names provided by the partner rather than the user, often manufacturer names, SKUs, etc. + */ + defaultNames?: string[]; + /** + * Primary name of the device, generally provided by the user. + */ + name?: string; + /** + * Additional names provided by the user for the device. + */ + nicknames?: string[]; + } + /** + * A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`. + */ + export interface Schema$Empty {} + /** + * Request type for the [`Query`](#google.home.graph.v1.HomeGraphApiService.Query) call. This should be the same format as the Actions on Google `action.devices.QUERY` [request](/actions/smarthome/create-app#actiondevicesquery) with the exception of the extra `agent_user_id` and no `intent` and `customData` fields. + */ + export interface Schema$QueryRequest { + /** + * Required. Third-party user ID. + */ + agentUserId?: string; + /** + * Required. Inputs containing third-party partner's device IDs for which to get the device states. + */ + inputs?: Schema$QueryRequestInput[]; + /** + * Request ID used for debugging. + */ + requestId?: string; + } + /** + * Device ID inputs to QueryRequest. + */ + export interface Schema$QueryRequestInput { + /** + * Payload containing third-party partner's device IDs. + */ + payload?: Schema$QueryRequestPayload; + } + /** + * Payload containing device IDs. + */ + export interface Schema$QueryRequestPayload { + /** + * Third-party partner's device IDs for which to get the device states. + */ + devices?: Schema$AgentDeviceId[]; + } + /** + * Response type for the [`Query`](#google.home.graph.v1.HomeGraphApiService.Query) call. This should follow the same format as the Actions on Google `action.devices.QUERY` [response](/actions/smarthome/create-app#actiondevicesquery). # Example ```json { "requestId": "ff36a3cc-ec34-11e6-b1a0-64510650abcf", "payload": { "devices": { "123": { "on": true, "online": true }, "456": { "on": true, "online": true, "brightness": 80, "color": { "name": "cerulean", "spectrumRGB": 31655 } } } } } ``` + */ + export interface Schema$QueryResponse { + /** + * Device states for the devices given in the request. + */ + payload?: Schema$QueryResponsePayload; + /** + * Request ID used for debugging. Copied from the request. + */ + requestId?: string; + } + /** + * Payload containing device states information. + */ + export interface Schema$QueryResponsePayload { + /** + * States of the devices. Map of third-party device ID to struct of device states. + */ + devices?: {[key: string]: {[key: string]: any}}; + } + /** + * The states and notifications specific to a device. + */ + export interface Schema$ReportStateAndNotificationDevice { + /** + * Notifications metadata for devices. + */ + notifications?: {[key: string]: any}; + /** + * States of devices to update. + */ + states?: {[key: string]: any}; + } + /** + * Request type for the [`ReportStateAndNotification`](#google.home.graph.v1.HomeGraphApiService.ReportStateAndNotification) call. It may include States, Notifications, or both. This request uses globally unique flattened state names instead of namespaces based on traits to align with the existing QUERY and EXECUTE APIs implemented by 90+ Smart Home partners. States and notifications are defined per `device_id` (for example, "123" and "456" in the following example). # Example ```json { "requestId": "ff36a3cc-ec34-11e6-b1a0-64510650abcf", "agentUserId": "1234", "payload": { "devices": { "states": { "123": { "on": true }, "456": { "on": true, "brightness": 10 } }, } } } ``` + */ + export interface Schema$ReportStateAndNotificationRequest { + /** + * Required. Third-party user ID. + */ + agentUserId?: string; + /** + * Unique identifier per event (for example, a doorbell press). + */ + eventId?: string; + /** + * Token to maintain state in the follow up notification response. + */ + followUpToken?: string; + /** + * State of devices to update and notification metadata for devices. For example, if a user turns a light on manually, a state update should be sent so that the information is always the current status of the device. Notifications are independent from the state and its piece of the payload should contain everything necessary to notify the user. Although it may be related to a state change, it does not need to be. For example, if a device can turn on/off and change temperature, the states reported would include both "on" and "70 degrees" but the 3p may choose not to send any notification for that, or to only say that the "the room is heating up", keeping state and notification independent. + */ + payload?: Schema$StateAndNotificationPayload; + /** + * Request ID used for debugging. + */ + requestId?: string; + } + /** + * Response type for the [`ReportStateAndNotification`](#google.home.graph.v1.HomeGraphApiService.ReportStateAndNotification) call. + */ + export interface Schema$ReportStateAndNotificationResponse { + /** + * Request ID copied from ReportStateAndNotificationRequest. + */ + requestId?: string; + } + /** + * Request type for the [`RequestSyncDevices`](#google.home.graph.v1.HomeGraphApiService.RequestSyncDevices) call. + */ + export interface Schema$RequestSyncDevicesRequest { + /** + * Required. Third-party user ID issued by agent's third-party identity provider. + */ + agentUserId?: string; + /** + * Optional. If set, the request will be added to a queue and a response will be returned immediately. The queue allows for de-duplication of simultaneous requests. + */ + async?: boolean; + } + /** + * Response type for the [`RequestSyncDevices`](#google.home.graph.v1.HomeGraphApiService.RequestSyncDevices) call. Intentionally empty upon success. An HTTP response code is returned with more details upon failure. + */ + export interface Schema$RequestSyncDevicesResponse {} + /** + * Payload containing the state and notification information for devices. + */ + export interface Schema$StateAndNotificationPayload { + /** + * The devices for updating state and sending notifications. + */ + devices?: Schema$ReportStateAndNotificationDevice; + } + /** + * Request type for the [`Sync`](#google.home.graph.v1.HomeGraphApiService.Sync) call. This should follow the same format as the Actions on Google `action.devices.SYNC` [request](/actions/smarthome/create-app#actiondevicessync) with the exception of the extra `agent_user_id` and no `intent` field. + */ + export interface Schema$SyncRequest { + /** + * Required. Third-party user ID. + */ + agentUserId?: string; + /** + * Request ID used for debugging. + */ + requestId?: string; + } + /** + * Response type for the [`Sync`](#google.home.graph.v1.HomeGraphApiService.Sync) call. This should follow the same format as the Actions on Google `action.devices.SYNC` [response](/actions/smarthome/create-app#actiondevicessync). # Example ```json { "requestId": "ff36a3cc-ec34-11e6-b1a0-64510650abcf", "payload": { "agentUserId": "1836.15267389", "devices": [{ "id": "123", "type": "action.devices.types.OUTLET", "traits": [ "action.devices.traits.OnOff" ], "name": { "defaultNames": ["My Outlet 1234"], "name": "Night light", "nicknames": ["wall plug"] }, "willReportState": false, "deviceInfo": { "manufacturer": "lights-out-inc", "model": "hs1234", "hwVersion": "3.2", "swVersion": "11.4" }, "customData": { "fooValue": 74, "barValue": true, "bazValue": "foo" } }] } } ``` + */ + export interface Schema$SyncResponse { + /** + * Devices associated with the third-party user. + */ + payload?: Schema$SyncResponsePayload; + /** + * Request ID used for debugging. Copied from the request. + */ + requestId?: string; + } + /** + * Payload containing device information. + */ + export interface Schema$SyncResponsePayload { + /** + * Third-party user ID + */ + agentUserId?: string; + /** + * Devices associated with the third-party user. + */ + devices?: Schema$Device[]; + } + + export class Resource$Agentusers { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * homegraph.agentUsers.delete + * @desc Unlinks an agent user from Google. As a result, all data related to this user will be deleted. Here is how the agent user is created in Google: 1. When a user opens their Google Home App, they can begin linking a 3p partner. 2. User is guided through the OAuth process. 3. After entering the 3p credentials, Google gets the 3p OAuth token and uses it to make a Sync call to the 3p partner and gets back all of the user's data, including `agent_user_id` and devices. 4. Google creates the agent user and stores a mapping from the `agent_user_id` -> Google ID mapping. Google also stores all of the user's devices under that Google ID. The mapping from `agent_user_id` to Google ID is many to many, since one Google user can have multiple 3p accounts, and multiple Google users can map to one `agent_user_id` (e.g., a husband and wife share one Nest account username/password). The third-party user's identity is passed in as `agent_user_id`. The agent is identified by the JWT signed by the partner's service account. Note: Special characters (except "/") in `agent_user_id` must be URL-encoded. + * @alias homegraph.agentUsers.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.agentUserId Required. Third-party user ID. + * @param {string=} params.requestId Request ID used for debugging. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + delete( + params?: Params$Resource$Agentusers$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Agentusers$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Agentusers$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Agentusers$Delete + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Agentusers$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Agentusers$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://homegraph.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+agentUserId}').replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['agentUserId'], + pathParams: ['agentUserId'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Agentusers$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. Third-party user ID. + */ + agentUserId?: string; + /** + * Request ID used for debugging. + */ + requestId?: string; + } + + export class Resource$Devices { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * homegraph.devices.query + * @desc Gets the device states for the devices in QueryRequest. The third-party user's identity is passed in as `agent_user_id`. The agent is identified by the JWT signed by the third-party partner's service account. + * @alias homegraph.devices.query + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().QueryRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + query( + params?: Params$Resource$Devices$Query, + options?: MethodOptions + ): GaxiosPromise; + query( + params: Params$Resource$Devices$Query, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + query( + params: Params$Resource$Devices$Query, + callback: BodyResponseCallback + ): void; + query(callback: BodyResponseCallback): void; + query( + paramsOrCallback?: + | Params$Resource$Devices$Query + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Devices$Query; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Devices$Query; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://homegraph.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/devices:query').replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * homegraph.devices.reportStateAndNotification + * @desc Reports device state and optionally sends device notifications. Called by an agent when the device state of a third-party changes or the agent wants to send a notification about the device. See [Implement Report State](/actions/smarthome/report-state) for more information. This method updates a predefined set of states for a device, which all devices have according to their prescribed traits (for example, a light will have the [OnOff](/actions/smarthome/traits/onoff) trait that reports the state `on` as a boolean value). A new state may not be created and an INVALID_ARGUMENT code will be thrown if so. It also optionally takes in a list of Notifications that may be created, which are associated to this state change. The third-party user's identity is passed in as `agent_user_id`. The agent is identified by the JWT signed by the partner's service account. + * @alias homegraph.devices.reportStateAndNotification + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().ReportStateAndNotificationRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + reportStateAndNotification( + params?: Params$Resource$Devices$Reportstateandnotification, + options?: MethodOptions + ): GaxiosPromise; + reportStateAndNotification( + params: Params$Resource$Devices$Reportstateandnotification, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + reportStateAndNotification( + params: Params$Resource$Devices$Reportstateandnotification, + callback: BodyResponseCallback + ): void; + reportStateAndNotification( + callback: BodyResponseCallback + ): void; + reportStateAndNotification( + paramsOrCallback?: + | Params$Resource$Devices$Reportstateandnotification + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Devices$Reportstateandnotification; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Devices$Reportstateandnotification; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://homegraph.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/devices:reportStateAndNotification').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest( + parameters + ); + } + } + + /** + * homegraph.devices.requestSync + * @desc Requests a `SYNC` call from Google to a 3p partner's home control agent for a user. The third-party user's identity is passed in as `agent_user_id` (see RequestSyncDevicesRequest) and forwarded back to the agent. The agent is identified by the API key or JWT signed by the partner's service account. + * @alias homegraph.devices.requestSync + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().RequestSyncDevicesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + requestSync( + params?: Params$Resource$Devices$Requestsync, + options?: MethodOptions + ): GaxiosPromise; + requestSync( + params: Params$Resource$Devices$Requestsync, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + requestSync( + params: Params$Resource$Devices$Requestsync, + callback: BodyResponseCallback + ): void; + requestSync( + callback: BodyResponseCallback + ): void; + requestSync( + paramsOrCallback?: + | Params$Resource$Devices$Requestsync + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Devices$Requestsync; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Devices$Requestsync; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://homegraph.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/devices:requestSync').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest(parameters); + } + } + + /** + * homegraph.devices.sync + * @desc Gets all the devices associated with the given third-party user. The third-party user's identity is passed in as `agent_user_id`. The agent is identified by the JWT signed by the third-party partner's service account. + * @alias homegraph.devices.sync + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().SyncRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + sync( + params?: Params$Resource$Devices$Sync, + options?: MethodOptions + ): GaxiosPromise; + sync( + params: Params$Resource$Devices$Sync, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + sync( + params: Params$Resource$Devices$Sync, + callback: BodyResponseCallback + ): void; + sync(callback: BodyResponseCallback): void; + sync( + paramsOrCallback?: + | Params$Resource$Devices$Sync + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Devices$Sync; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Devices$Sync; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://homegraph.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/devices:sync').replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Devices$Query extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Request body metadata + */ + requestBody?: Schema$QueryRequest; + } + export interface Params$Resource$Devices$Reportstateandnotification + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Request body metadata + */ + requestBody?: Schema$ReportStateAndNotificationRequest; + } + export interface Params$Resource$Devices$Requestsync + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Request body metadata + */ + requestBody?: Schema$RequestSyncDevicesRequest; + } + export interface Params$Resource$Devices$Sync extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Request body metadata + */ + requestBody?: Schema$SyncRequest; + } +} diff --git a/src/apis/appstate/webpack.config.js b/src/apis/homegraph/webpack.config.js similarity index 96% rename from src/apis/appstate/webpack.config.js rename to src/apis/homegraph/webpack.config.js index 3e56d65c897..46fd8c73331 100644 --- a/src/apis/appstate/webpack.config.js +++ b/src/apis/homegraph/webpack.config.js @@ -24,8 +24,8 @@ module.exports = { extensions: ['.ts', '.js', '.json'], }, output: { - library: 'Appstate', - filename: 'appstate.min.js', + library: 'Homegraph', + filename: 'homegraph.min.js', path: path.resolve(__dirname, 'dist'), }, node: { diff --git a/src/apis/iam/v1.ts b/src/apis/iam/v1.ts index c6d03422dd8..bb374cdf208 100644 --- a/src/apis/iam/v1.ts +++ b/src/apis/iam/v1.ts @@ -204,7 +204,7 @@ export namespace iam_v1 { */ action?: string; /** - * Unimplemented. The condition that is associated with this binding. This field is logged only for Cloud Audit Logging. + * The condition that is associated with this binding. This field is logged only for Cloud Audit Logging. */ condition?: Schema$Expr; /** @@ -421,6 +421,10 @@ export namespace iam_v1 { * This permission can ONLY be used in predefined roles. */ onlyInPredefinedRoles?: boolean; + /** + * The preferred name for this permission. If present, then this permission is an alias of, and equivalent to, the listed primary_permission. + */ + primaryPermission?: string; /** * The current launch stage of the permission. */ @@ -573,7 +577,7 @@ export namespace iam_v1 { */ includedPermissions?: string[]; /** - * The name of the role. When Role is used in CreateRole, the role name must not be set. When Role is used in output and other input such as UpdateRole, the role name is the complete path, e.g., roles/logging.viewer for curated roles and organizations/{ORGANIZATION_ID}/roles/logging.viewer for custom roles. + * The name of the role. When Role is used in CreateRole, the role name must not be set. When Role is used in output and other input such as UpdateRole, the role name is the complete path, e.g., roles/logging.viewer for predefined roles and organizations/{ORGANIZATION_ID}/roles/logging.viewer for custom roles. */ name?: string; /** @@ -757,6 +761,15 @@ export namespace iam_v1 { */ restoredAccount?: Schema$ServiceAccount; } + /** + * The service account key upload request. + */ + export interface Schema$UploadServiceAccountKeyRequest { + /** + * A field that allows clients to upload their own public key. If set, use this public key data to create a service account key for given service account. Please note, the expected format for this field is X509_PEM. + */ + publicKeyData?: string; + } export class Resource$Iampolicies { context: APIRequestContext; @@ -3397,7 +3410,7 @@ export namespace iam_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name The resource name of the service account in the following format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_UNIQUE_ID}'. Using `-` as a wildcard for the `PROJECT_ID` will infer the project from the account. + * @param {string} params.name The resource name of the service account in the following format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. Using `-` as a wildcard for the `PROJECT_ID` will infer the project from the account. The `ACCOUNT` value can be the `email` address or the `unique_id` of the service account. * @param {().EnableServiceAccountRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3635,7 +3648,7 @@ export namespace iam_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -4548,7 +4561,7 @@ export namespace iam_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name The resource name of the service account in the following format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_UNIQUE_ID}'. Using `-` as a wildcard for the `PROJECT_ID` will infer the project from the account. + * @param {string} params.name The resource name of the service account in the following format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_UNIQUE_ID}`. Using `-` as a wildcard for the `PROJECT_ID` will infer the project from the account. * @param {().UndeleteServiceAccountRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -4809,7 +4822,7 @@ export namespace iam_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The resource name of the service account in the following format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_UNIQUE_ID}'. Using `-` as a wildcard for the `PROJECT_ID` will infer the project from the account. + * The resource name of the service account in the following format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. Using `-` as a wildcard for the `PROJECT_ID` will infer the project from the account. The `ACCOUNT` value can be the `email` address or the `unique_id` of the service account. */ name?: string; @@ -4838,7 +4851,7 @@ export namespace iam_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** @@ -4959,7 +4972,7 @@ export namespace iam_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The resource name of the service account in the following format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_UNIQUE_ID}'. Using `-` as a wildcard for the `PROJECT_ID` will infer the project from the account. + * The resource name of the service account in the following format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_UNIQUE_ID}`. Using `-` as a wildcard for the `PROJECT_ID` will infer the project from the account. */ name?: string; @@ -5486,6 +5499,81 @@ export namespace iam_v1 { ); } } + + /** + * iam.projects.serviceAccounts.keys.upload + * @desc Upload public key for a given service account. This rpc will create a ServiceAccountKey that has the provided public key and returns it. + * @alias iam.projects.serviceAccounts.keys.upload + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The resource name of the service account in the following format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. Using `-` as a wildcard for the `PROJECT_ID` will infer the project from the account. The `ACCOUNT` value can be the `email` address or the `unique_id` of the service account. + * @param {().UploadServiceAccountKeyRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + upload( + params?: Params$Resource$Projects$Serviceaccounts$Keys$Upload, + options?: MethodOptions + ): GaxiosPromise; + upload( + params: Params$Resource$Projects$Serviceaccounts$Keys$Upload, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + upload( + params: Params$Resource$Projects$Serviceaccounts$Keys$Upload, + callback: BodyResponseCallback + ): void; + upload(callback: BodyResponseCallback): void; + upload( + paramsOrCallback?: + | Params$Resource$Projects$Serviceaccounts$Keys$Upload + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Serviceaccounts$Keys$Upload; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Serviceaccounts$Keys$Upload; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://iam.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}/keys:upload').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } export interface Params$Resource$Projects$Serviceaccounts$Keys$Create @@ -5549,6 +5637,23 @@ export namespace iam_v1 { */ name?: string; } + export interface Params$Resource$Projects$Serviceaccounts$Keys$Upload + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The resource name of the service account in the following format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. Using `-` as a wildcard for the `PROJECT_ID` will infer the project from the account. The `ACCOUNT` value can be the `email` address or the `unique_id` of the service account. + */ + name?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$UploadServiceAccountKeyRequest; + } export class Resource$Roles { context: APIRequestContext; diff --git a/src/apis/iamcredentials/v1.ts b/src/apis/iamcredentials/v1.ts index f5258c4e87b..db2646afdf2 100644 --- a/src/apis/iamcredentials/v1.ts +++ b/src/apis/iamcredentials/v1.ts @@ -141,26 +141,6 @@ export namespace iamcredentials_v1 { */ expireTime?: string; } - export interface Schema$GenerateIdentityBindingAccessTokenRequest { - /** - * Required. Input token. Must be in JWT format according to RFC7523 (https://tools.ietf.org/html/rfc7523) and must have 'kid' field in the header. Supported signing algorithms: RS256 (RS512, ES256, ES512 coming soon). Mandatory payload fields (along the lines of RFC 7523, section 3): - iss: issuer of the token. Must provide a discovery document at $iss/.well-known/openid-configuration . The document needs to be formatted according to section 4.2 of the OpenID Connect Discovery 1.0 specification. - iat: Issue time in seconds since epoch. Must be in the past. - exp: Expiration time in seconds since epoch. Must be less than 48 hours after iat. We recommend to create tokens that last shorter than 6 hours to improve security unless business reasons mandate longer expiration times. Shorter token lifetimes are generally more secure since tokens that have been exfiltrated by attackers can be used for a shorter time. you can configure the maximum lifetime of the incoming token in the configuration of the mapper. The resulting Google token will expire within an hour or at "exp", whichever is earlier. - sub: JWT subject, identity asserted in the JWT. - aud: Configured in the mapper policy. By default the service account email. Claims from the incoming token can be transferred into the output token accoding to the mapper configuration. The outgoing claim size is limited. Outgoing claims size must be less than 4kB serialized as JSON without whitespace. Example header: { "alg": "RS256", "kid": "92a4265e14ab04d4d228a48d10d4ca31610936f8" } Example payload: { "iss": "https://accounts.google.com", "iat": 1517963104, "exp": 1517966704, "aud": "https://iamcredentials.googleapis.com/google.iam.credentials.v1.CloudGaia", "sub": "113475438248934895348", "my_claims": { "additional_claim": "value" } } - */ - jwt?: string; - /** - * Code to identify the scopes to be included in the OAuth 2.0 access token. See https://developers.google.com/identity/protocols/googlescopes for more information. At least one value required. - */ - scope?: string[]; - } - export interface Schema$GenerateIdentityBindingAccessTokenResponse { - /** - * The OAuth 2.0 access token. - */ - accessToken?: string; - /** - * Token expiration time. The expiration time is always set. - */ - expireTime?: string; - } export interface Schema$GenerateIdTokenRequest { /** * The audience for the token, such as the API or account that this token grants access to. @@ -322,103 +302,6 @@ export namespace iamcredentials_v1 { } } - /** - * iamcredentials.projects.serviceAccounts.generateIdentityBindingAccessToken - * @alias iamcredentials.projects.serviceAccounts.generateIdentityBindingAccessToken - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.name The resource name of the service account for which the credentials are requested, in the following format: `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard character is required; replacing it with a project ID is invalid. - * @param {().GenerateIdentityBindingAccessTokenRequest} params.resource Request body data - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - generateIdentityBindingAccessToken( - params?: Params$Resource$Projects$Serviceaccounts$Generateidentitybindingaccesstoken, - options?: MethodOptions - ): GaxiosPromise; - generateIdentityBindingAccessToken( - params: Params$Resource$Projects$Serviceaccounts$Generateidentitybindingaccesstoken, - options: - | MethodOptions - | BodyResponseCallback< - Schema$GenerateIdentityBindingAccessTokenResponse - >, - callback: BodyResponseCallback< - Schema$GenerateIdentityBindingAccessTokenResponse - > - ): void; - generateIdentityBindingAccessToken( - params: Params$Resource$Projects$Serviceaccounts$Generateidentitybindingaccesstoken, - callback: BodyResponseCallback< - Schema$GenerateIdentityBindingAccessTokenResponse - > - ): void; - generateIdentityBindingAccessToken( - callback: BodyResponseCallback< - Schema$GenerateIdentityBindingAccessTokenResponse - > - ): void; - generateIdentityBindingAccessToken( - paramsOrCallback?: - | Params$Resource$Projects$Serviceaccounts$Generateidentitybindingaccesstoken - | BodyResponseCallback< - Schema$GenerateIdentityBindingAccessTokenResponse - >, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback< - Schema$GenerateIdentityBindingAccessTokenResponse - >, - callback?: BodyResponseCallback< - Schema$GenerateIdentityBindingAccessTokenResponse - > - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Serviceaccounts$Generateidentitybindingaccesstoken; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Serviceaccounts$Generateidentitybindingaccesstoken; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = - options.rootUrl || 'https://iamcredentials.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: ( - rootUrl + '/v1/{+name}:generateIdentityBindingAccessToken' - ).replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', - }, - options - ), - params, - requiredParams: ['name'], - pathParams: ['name'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest< - Schema$GenerateIdentityBindingAccessTokenResponse - >(parameters); - } - } - /** * iamcredentials.projects.serviceAccounts.generateIdToken * @desc Generates an OpenID Connect ID token for a service account. @@ -669,23 +552,6 @@ export namespace iamcredentials_v1 { */ requestBody?: Schema$GenerateAccessTokenRequest; } - export interface Params$Resource$Projects$Serviceaccounts$Generateidentitybindingaccesstoken - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The resource name of the service account for which the credentials are requested, in the following format: `projects/-/serviceAccounts/{ACCOUNT_EMAIL_OR_UNIQUEID}`. The `-` wildcard character is required; replacing it with a project ID is invalid. - */ - name?: string; - - /** - * Request body metadata - */ - requestBody?: Schema$GenerateIdentityBindingAccessTokenRequest; - } export interface Params$Resource$Projects$Serviceaccounts$Generateidtoken extends StandardParameters { /** diff --git a/src/apis/iap/v1.ts b/src/apis/iap/v1.ts index 9518de83736..896060b764c 100644 --- a/src/apis/iap/v1.ts +++ b/src/apis/iap/v1.ts @@ -169,7 +169,7 @@ export namespace iap_v1 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ requestedPolicyVersion?: number; } diff --git a/src/apis/iap/v1beta1.ts b/src/apis/iap/v1beta1.ts index 89fcc3d414a..94f66876184 100644 --- a/src/apis/iap/v1beta1.ts +++ b/src/apis/iap/v1beta1.ts @@ -169,7 +169,7 @@ export namespace iap_v1beta1 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ requestedPolicyVersion?: number; } diff --git a/src/apis/index.ts b/src/apis/index.ts index c9e3eec36b1..9dcff723d44 100644 --- a/src/apis/index.ts +++ b/src/apis/index.ts @@ -32,9 +32,9 @@ import * as androidmanagement from './androidmanagement'; import * as androidpublisher from './androidpublisher'; import * as appengine from './appengine'; import * as appsactivity from './appsactivity'; -import * as appstate from './appstate'; import * as bigquery from './bigquery'; import * as bigquerydatatransfer from './bigquerydatatransfer'; +import * as bigqueryreservation from './bigqueryreservation'; import * as bigtableadmin from './bigtableadmin'; import * as binaryauthorization from './binaryauthorization'; import * as blogger from './blogger'; @@ -80,6 +80,7 @@ import * as discovery from './discovery'; import * as dlp from './dlp'; import * as dns from './dns'; import * as docs from './docs'; +import * as domainsrdap from './domainsrdap'; import * as doubleclickbidmanager from './doubleclickbidmanager'; import * as doubleclicksearch from './doubleclicksearch'; import * as drive from './drive'; @@ -102,6 +103,7 @@ import * as gmail from './gmail'; import * as groupsmigration from './groupsmigration'; import * as groupssettings from './groupssettings'; import * as healthcare from './healthcare'; +import * as homegraph from './homegraph'; import * as iam from './iam'; import * as iamcredentials from './iamcredentials'; import * as iap from './iap'; @@ -163,6 +165,7 @@ import * as tpu from './tpu'; import * as translate from './translate'; import * as urlshortener from './urlshortener'; import * as vault from './vault'; +import * as verifiedaccess from './verifiedaccess'; import * as videointelligence from './videointelligence'; import * as vision from './vision'; import * as webfonts from './webfonts'; @@ -197,9 +200,9 @@ export const APIS: APIList = { androidpublisher: androidpublisher.VERSIONS, appengine: appengine.VERSIONS, appsactivity: appsactivity.VERSIONS, - appstate: appstate.VERSIONS, bigquery: bigquery.VERSIONS, bigquerydatatransfer: bigquerydatatransfer.VERSIONS, + bigqueryreservation: bigqueryreservation.VERSIONS, bigtableadmin: bigtableadmin.VERSIONS, binaryauthorization: binaryauthorization.VERSIONS, blogger: blogger.VERSIONS, @@ -245,6 +248,7 @@ export const APIS: APIList = { dlp: dlp.VERSIONS, dns: dns.VERSIONS, docs: docs.VERSIONS, + domainsrdap: domainsrdap.VERSIONS, doubleclickbidmanager: doubleclickbidmanager.VERSIONS, doubleclicksearch: doubleclicksearch.VERSIONS, drive: drive.VERSIONS, @@ -267,6 +271,7 @@ export const APIS: APIList = { groupsmigration: groupsmigration.VERSIONS, groupssettings: groupssettings.VERSIONS, healthcare: healthcare.VERSIONS, + homegraph: homegraph.VERSIONS, iam: iam.VERSIONS, iamcredentials: iamcredentials.VERSIONS, iap: iap.VERSIONS, @@ -328,6 +333,7 @@ export const APIS: APIList = { translate: translate.VERSIONS, urlshortener: urlshortener.VERSIONS, vault: vault.VERSIONS, + verifiedaccess: verifiedaccess.VERSIONS, videointelligence: videointelligence.VERSIONS, vision: vision.VERSIONS, webfonts: webfonts.VERSIONS, @@ -359,9 +365,9 @@ export class GeneratedAPIs { androidpublisher = androidpublisher.androidpublisher; appengine = appengine.appengine; appsactivity = appsactivity.appsactivity; - appstate = appstate.appstate; bigquery = bigquery.bigquery; bigquerydatatransfer = bigquerydatatransfer.bigquerydatatransfer; + bigqueryreservation = bigqueryreservation.bigqueryreservation; bigtableadmin = bigtableadmin.bigtableadmin; binaryauthorization = binaryauthorization.binaryauthorization; blogger = blogger.blogger; @@ -408,6 +414,7 @@ export class GeneratedAPIs { dlp = dlp.dlp; dns = dns.dns; docs = docs.docs; + domainsrdap = domainsrdap.domainsrdap; doubleclickbidmanager = doubleclickbidmanager.doubleclickbidmanager; doubleclicksearch = doubleclicksearch.doubleclicksearch; drive = drive.drive; @@ -430,6 +437,7 @@ export class GeneratedAPIs { groupsmigration = groupsmigration.groupsmigration; groupssettings = groupssettings.groupssettings; healthcare = healthcare.healthcare; + homegraph = homegraph.homegraph; iam = iam.iam; iamcredentials = iamcredentials.iamcredentials; iap = iap.iap; @@ -492,6 +500,7 @@ export class GeneratedAPIs { translate = translate.translate; urlshortener = urlshortener.urlshortener; vault = vault.vault; + verifiedaccess = verifiedaccess.verifiedaccess; videointelligence = videointelligence.videointelligence; vision = vision.vision; webfonts = webfonts.webfonts; diff --git a/src/apis/jobs/v2.ts b/src/apis/jobs/v2.ts index bd30add6412..28a06927cea 100644 --- a/src/apis/jobs/v2.ts +++ b/src/apis/jobs/v2.ts @@ -126,7 +126,7 @@ export namespace jobs_v2 { */ export interface Schema$BatchDeleteJobsRequest { /** - * Required. The filter string specifies the jobs to be deleted. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Required) Sample Query: companyName = "companies/123" AND requisitionId = "req-1" + * Required. The filter string specifies the jobs to be deleted. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Required) Sample Query: companyName = "companies/123" AND requisitionId = "req-1" */ filter?: string; } @@ -178,23 +178,23 @@ export namespace jobs_v2 { */ allowNonStreetLevelAddress?: boolean; /** - * Optional. The departure hour to use to calculate traffic impact. Accepts an integer between 0 and 23, representing the hour in the time zone of the start_location. Must not be present if road_traffic is specified. + * Optional. The departure hour to use to calculate traffic impact. Accepts an integer between 0 and 23, representing the hour in the time zone of the start_location. Must not be present if road_traffic is specified. */ departureHourLocal?: number; /** - * Required. The method of transportation for which to calculate the commute time. + * Required. The method of transportation for which to calculate the commute time. */ method?: string; /** - * Optional. Specifies the traffic density to use when calculating commute time. Must not be present if departure_hour_local is specified. + * Optional. Specifies the traffic density to use when calculating commute time. Must not be present if departure_hour_local is specified. */ roadTraffic?: string; /** - * Required. The latitude and longitude of the location from which to calculate the commute time. + * Required. The latitude and longitude of the location from which to calculate the commute time. */ startLocation?: Schema$LatLng; /** - * Required. The maximum travel time in seconds. The maximum allowed value is `3600s` (one hour). Format is `123s`. + * Required. The maximum travel time in seconds. The maximum allowed value is `3600s` (one hour). Format is `123s`. */ travelTime?: string; } @@ -203,15 +203,15 @@ export namespace jobs_v2 { */ export interface Schema$Company { /** - * Optional. The URL to employer's career site or careers page on the employer's web site. + * Optional. The URL to employer's career site or careers page on the employer's web site. */ careerPageLink?: string; /** - * Optional. Identifiers external to the application that help to further identify the employer. + * Optional. Identifiers external to the application that help to further identify the employer. */ companyInfoSources?: Schema$CompanyInfoSource[]; /** - * Optional. The employer's company size. + * Optional. The employer's company size. */ companySize?: string; /** @@ -219,35 +219,35 @@ export namespace jobs_v2 { */ disableLocationOptimization?: boolean; /** - * Required. The name of the employer to be displayed with the job, for example, "Google, LLC.". + * Required. The name of the employer to be displayed with the job, for example, "Google, LLC.". */ displayName?: string; /** - * Optional. The unique company identifier provided by the client to identify an employer for billing purposes. Recommended practice is to use the distributor_company_id. Defaults to same value as distributor_company_id when a value is not provided. + * Optional. The unique company identifier provided by the client to identify an employer for billing purposes. Recommended practice is to use the distributor_company_id. Defaults to same value as distributor_company_id when a value is not provided. */ distributorBillingCompanyId?: string; /** - * Required. A client's company identifier, used to uniquely identify the company. If an employer has a subsidiary or sub-brand, such as "Alphabet" and "Google", which the client wishes to use as the company displayed on the job. Best practice is to create a distinct company identifier for each distinct brand displayed. The maximum number of allowed characters is 255. + * Required. A client's company identifier, used to uniquely identify the company. If an employer has a subsidiary or sub-brand, such as "Alphabet" and "Google", which the client wishes to use as the company displayed on the job. Best practice is to create a distinct company identifier for each distinct brand displayed. The maximum number of allowed characters is 255. */ distributorCompanyId?: string; /** - * Optional. Equal Employment Opportunity legal disclaimer text to be associated with all jobs, and typically to be displayed in all roles. The maximum number of allowed characters is 500. + * Optional. Equal Employment Opportunity legal disclaimer text to be associated with all jobs, and typically to be displayed in all roles. The maximum number of allowed characters is 500. */ eeoText?: string; /** - * Optional. Set to true if it is the hiring agency that post jobs for other employers. Defaults to false if not provided. + * Optional. Set to true if it is the hiring agency that post jobs for other employers. Defaults to false if not provided. */ hiringAgency?: boolean; /** - * Optional. The street address of the company's main headquarters, which may be different from the job location. The service attempts to geolocate the provided address, and populates a more specific location wherever possible in structured_company_hq_location. + * Optional. The street address of the company's main headquarters, which may be different from the job location. The service attempts to geolocate the provided address, and populates a more specific location wherever possible in structured_company_hq_location. */ hqLocation?: string; /** - * Optional. A URL that hosts the employer's company logo. If provided, the logo image should be squared at 80x80 pixels. The url must be a Google Photos or Google Album url. Only images in these Google sub-domains are accepted. + * Optional. A URL that hosts the employer's company logo. If provided, the logo image should be squared at 80x80 pixels. The url must be a Google Photos or Google Album url. Only images in these Google sub-domains are accepted. */ imageUrl?: string; /** - * Optional. A list of keys of filterable Job.custom_attributes, whose corresponding `string_values` are used in keyword search. Jobs with `string_values` under these specified field keys are returned if any of the values matches the search keyword. Custom field values with parenthesis, brackets and special symbols might not be properly searchable, and those keyword queries need to be surrounded by quotes. + * Optional. A list of keys of filterable Job.custom_attributes, whose corresponding `string_values` are used in keyword search. Jobs with `string_values` under these specified field keys are returned if any of the values matches the search keyword. Custom field values with parenthesis, brackets and special symbols might not be properly searchable, and those keyword queries need to be surrounded by quotes. */ keywordSearchableCustomAttributes?: string[]; /** @@ -259,11 +259,11 @@ export namespace jobs_v2 { */ name?: string; /** - * Output only. A structured headquarters location of the company, resolved from hq_location if possible. + * Output only. A structured headquarters location of the company, resolved from hq_location if possible. */ structuredCompanyHqLocation?: Schema$JobLocation; /** - * Output only. Indicates whether a company is flagged to be suspended from public availability by the service when job content appears suspicious, abusive, or spammy. + * Output only. Indicates whether a company is flagged to be suspended from public availability by the service when job content appears suspicious, abusive, or spammy. */ suspended?: boolean; /** @@ -271,7 +271,7 @@ export namespace jobs_v2 { */ title?: string; /** - * Optional. The URL representing the company's primary web site or home page, such as, "www.google.com". + * Optional. The URL representing the company's primary web site or home page, such as, "www.google.com". */ website?: string; } @@ -280,19 +280,19 @@ export namespace jobs_v2 { */ export interface Schema$CompanyInfoSource { /** - * Optional. The Google's Knowledge Graph value for the employer's company. + * Optional. The Google's Knowledge Graph value for the employer's company. */ freebaseMid?: string; /** - * Optional. The numeric identifier for the employer's Google+ business page. + * Optional. The numeric identifier for the employer's Google+ business page. */ gplusId?: string; /** - * Optional. The numeric identifier for the employer's headquarters on Google Maps, namely, the Google Maps CID (cell id). + * Optional. The numeric identifier for the employer's headquarters on Google Maps, namely, the Google Maps CID (cell id). */ mapsCid?: string; /** - * Optional. A Google identifier that does not match any of the other types. + * Optional. A Google identifier that does not match any of the other types. */ unknownTypeId?: string; } @@ -301,27 +301,27 @@ export namespace jobs_v2 { */ export interface Schema$CompensationEntry { /** - * Optional. Compensation amount. + * Optional. Compensation amount. */ amount?: Schema$Money; /** - * Optional. Compensation description. For example, could indicate equity terms or provide additional context to an estimated bonus. + * Optional. Compensation description. For example, could indicate equity terms or provide additional context to an estimated bonus. */ description?: string; /** - * Optional. Expected number of units paid each year. If not specified, when Job.employment_types is FULLTIME, a default value is inferred based on unit. Default values: - HOURLY: 2080 - DAILY: 260 - WEEKLY: 52 - MONTHLY: 12 - ANNUAL: 1 + * Optional. Expected number of units paid each year. If not specified, when Job.employment_types is FULLTIME, a default value is inferred based on unit. Default values: - HOURLY: 2080 - DAILY: 260 - WEEKLY: 52 - MONTHLY: 12 - ANNUAL: 1 */ expectedUnitsPerYear?: number; /** - * Optional. Compensation range. + * Optional. Compensation range. */ range?: Schema$CompensationRange; /** - * Required. Compensation type. + * Required. Compensation type. */ type?: string; /** - * Optional. Frequency of the specified amount. Default is CompensationUnit.COMPENSATION_UNIT_UNSPECIFIED. + * Optional. Frequency of the specified amount. Default is CompensationUnit.COMPENSATION_UNIT_UNSPECIFIED. */ unit?: string; } @@ -330,19 +330,19 @@ export namespace jobs_v2 { */ export interface Schema$CompensationFilter { /** - * Optional. Whether to include jobs whose compensation range is unspecified. + * Optional. Whether to include jobs whose compensation range is unspecified. */ includeJobsWithUnspecifiedCompensationRange?: boolean; /** - * Optional. Compensation range. + * Optional. Compensation range. */ range?: Schema$CompensationRange; /** - * Required. Type of filter. + * Required. Type of filter. */ type?: string; /** - * Required. Specify desired `base compensation entry's` CompensationInfo.CompensationUnit. + * Required. Specify desired `base compensation entry's` CompensationInfo.CompensationUnit. */ units?: string[]; } @@ -351,11 +351,11 @@ export namespace jobs_v2 { */ export interface Schema$CompensationHistogramRequest { /** - * Required. Numeric histogram options, like buckets, whether include min or max value. + * Required. Numeric histogram options, like buckets, whether include min or max value. */ bucketingOption?: Schema$NumericBucketingOption; /** - * Required. Type of the request, representing which field the histogramming should be performed over. A single request can only specify one histogram of each `CompensationHistogramRequestType`. + * Required. Type of the request, representing which field the histogramming should be performed over. A single request can only specify one histogram of each `CompensationHistogramRequestType`. */ type?: string; } @@ -381,15 +381,15 @@ export namespace jobs_v2 { */ amount?: Schema$Money; /** - * Output only. Annualized base compensation range. Computed as base compensation entry's CompensationEntry.compensation times CompensationEntry.expected_units_per_year. See CompensationEntry for explanation on compensation annualization. + * Output only. Annualized base compensation range. Computed as base compensation entry's CompensationEntry.compensation times CompensationEntry.expected_units_per_year. See CompensationEntry for explanation on compensation annualization. */ annualizedBaseCompensationRange?: Schema$CompensationRange; /** - * Output only. Annualized total compensation range. Computed as all compensation entries' CompensationEntry.compensation times CompensationEntry.expected_units_per_year. See CompensationEntry for explanation on compensation annualization. + * Output only. Annualized total compensation range. Computed as all compensation entries' CompensationEntry.compensation times CompensationEntry.expected_units_per_year. See CompensationEntry for explanation on compensation annualization. */ annualizedTotalCompensationRange?: Schema$CompensationRange; /** - * Optional. Job compensation information. At most one entry can be of type CompensationInfo.CompensationType.BASE, which is referred as ** base compensation entry ** for the job. + * Optional. Job compensation information. At most one entry can be of type CompensationInfo.CompensationType.BASE, which is referred as ** base compensation entry ** for the job. */ entries?: Schema$CompensationEntry[]; /** @@ -410,11 +410,11 @@ export namespace jobs_v2 { */ export interface Schema$CompensationRange { /** - * Optional. The maximum amount of compensation. If left empty, the value is set to a maximal compensation value and the currency code is set to match the currency code of min_compensation. + * Optional. The maximum amount of compensation. If left empty, the value is set to a maximal compensation value and the currency code is set to match the currency code of min_compensation. */ max?: Schema$Money; /** - * Optional. The minimum amount of compensation. If left empty, the value is set to zero and the currency code is set to match the currency code of max_compensation. + * Optional. The minimum amount of compensation. If left empty, the value is set to zero and the currency code is set to match the currency code of max_compensation. */ min?: Schema$Money; } @@ -457,11 +457,11 @@ export namespace jobs_v2 { */ disableStreetAddressResolution?: boolean; /** - * Required. The Job to be created. + * Required. The Job to be created. */ job?: Schema$Job; /** - * Optional. Options for job processing. + * Optional. Options for job processing. */ processingOptions?: Schema$JobProcessingOptions; } @@ -470,7 +470,7 @@ export namespace jobs_v2 { */ export interface Schema$CustomAttribute { /** - * Optional. If the `filterable` flag is true, custom field values are searchable. If false, values are not searchable. Default is false. + * Optional. If the `filterable` flag is true, custom field values are searchable. If false, values are not searchable. Default is false. */ filterable?: boolean; /** @@ -487,11 +487,11 @@ export namespace jobs_v2 { */ export interface Schema$CustomAttributeHistogramRequest { /** - * Required. Specifies the custom field key to perform a histogram on. If specified without `long_value_histogram_bucketing_option`, histogram on string values of the given `key` is triggered, otherwise histogram is performed on long values. + * Required. Specifies the custom field key to perform a histogram on. If specified without `long_value_histogram_bucketing_option`, histogram on string values of the given `key` is triggered, otherwise histogram is performed on long values. */ key?: string; /** - * Optional. Specifies buckets used to perform a range histogram on Job's filterable long custom field values, or min/max value requirements. + * Optional. Specifies buckets used to perform a range histogram on Job's filterable long custom field values, or min/max value requirements. */ longValueHistogramBucketingOption?: Schema$NumericBucketingOption; /** @@ -521,7 +521,7 @@ export namespace jobs_v2 { */ export interface Schema$CustomField { /** - * Optional. The values of the custom data. + * Optional. The values of the custom data. */ values?: string[]; } @@ -530,11 +530,11 @@ export namespace jobs_v2 { */ export interface Schema$CustomFieldFilter { /** - * Required. The query strings for the filter. + * Required. The query strings for the filter. */ queries?: string[]; /** - * Optional. The type of filter. Defaults to FilterType.OR. + * Optional. The type of filter. Defaults to FilterType.OR. */ type?: string; } @@ -560,11 +560,11 @@ export namespace jobs_v2 { */ export interface Schema$DeleteJobsByFilterRequest { /** - * Optional. If set to true, this call waits for all processing steps to complete before the job is cleaned up. Otherwise, the call returns while some steps are still taking place asynchronously, hence faster. + * Optional. If set to true, this call waits for all processing steps to complete before the job is cleaned up. Otherwise, the call returns while some steps are still taking place asynchronously, hence faster. */ disableFastProcess?: boolean; /** - * Required. Restrictions on the scope of the delete request. + * Required. Restrictions on the scope of the delete request. */ filter?: Schema$Filter; } @@ -573,11 +573,11 @@ export namespace jobs_v2 { */ export interface Schema$DeviceInfo { /** - * Optional. Type of the device. + * Optional. Type of the device. */ deviceType?: string; /** - * Optional. A device-specific ID. The ID must be a unique identifier that distinguishes the device from other devices. + * Optional. A device-specific ID. The ID must be a unique identifier that distinguishes the device from other devices. */ id?: string; } @@ -590,23 +590,23 @@ export namespace jobs_v2 { */ export interface Schema$ExtendedCompensationFilter { /** - * Optional. Compensation range. + * Optional. Compensation range. */ compensationRange?: Schema$ExtendedCompensationInfoCompensationRange; /** - * Required. Specify desired `base compensation entry's` ExtendedCompensationInfo.CompensationUnit. + * Required. Specify desired `base compensation entry's` ExtendedCompensationInfo.CompensationUnit. */ compensationUnits?: string[]; /** - * Optional. Specify currency in 3-letter [ISO 4217](https://www.iso.org/iso-4217-currency-codes.html) format. If unspecified, jobs are returned regardless of currency. + * Optional. Specify currency in 3-letter [ISO 4217](https://www.iso.org/iso-4217-currency-codes.html) format. If unspecified, jobs are returned regardless of currency. */ currency?: string; /** - * Optional. Whether to include jobs whose compensation range is unspecified. + * Optional. Whether to include jobs whose compensation range is unspecified. */ includeJobWithUnspecifiedCompensationRange?: boolean; /** - * Required. Type of filter. + * Required. Type of filter. */ type?: string; } @@ -615,27 +615,27 @@ export namespace jobs_v2 { */ export interface Schema$ExtendedCompensationInfo { /** - * Output only. Annualized base compensation range. + * Output only. Annualized base compensation range. */ annualizedBaseCompensationRange?: Schema$ExtendedCompensationInfoCompensationRange; /** - * Output only. Indicates annualized base compensation range cannot be derived, due to the job's base compensation entry cannot be annualized. See CompensationEntry for explanation on annualization and base compensation entry. + * Output only. Indicates annualized base compensation range cannot be derived, due to the job's base compensation entry cannot be annualized. See CompensationEntry for explanation on annualization and base compensation entry. */ annualizedBaseCompensationUnspecified?: boolean; /** - * Output only. Annualized total compensation range. + * Output only. Annualized total compensation range. */ annualizedTotalCompensationRange?: Schema$ExtendedCompensationInfoCompensationRange; /** - * Output only. Indicates annualized total compensation range cannot be derived, due to the job's all CompensationEntry cannot be annualized. See CompensationEntry for explanation on annualization and base compensation entry. + * Output only. Indicates annualized total compensation range cannot be derived, due to the job's all CompensationEntry cannot be annualized. See CompensationEntry for explanation on annualization and base compensation entry. */ annualizedTotalCompensationUnspecified?: boolean; /** - * Optional. A 3-letter [ISO 4217](https://www.iso.org/iso-4217-currency-codes.html) currency code. + * Optional. A 3-letter [ISO 4217](https://www.iso.org/iso-4217-currency-codes.html) currency code. */ currency?: string; /** - * Optional. Job compensation information. At most one entry can be of type ExtendedCompensationInfo.CompensationType.BASE, which is referred as ** base compensation entry ** for the job. + * Optional. Job compensation information. At most one entry can be of type ExtendedCompensationInfo.CompensationType.BASE, which is referred as ** base compensation entry ** for the job. */ entries?: Schema$ExtendedCompensationInfoCompensationEntry[]; } @@ -644,31 +644,31 @@ export namespace jobs_v2 { */ export interface Schema$ExtendedCompensationInfoCompensationEntry { /** - * Optional. Monetary amount. + * Optional. Monetary amount. */ amount?: Schema$ExtendedCompensationInfoDecimal; /** - * Optional. Compensation description. + * Optional. Compensation description. */ description?: string; /** - * Optional. Expected number of units paid each year. If not specified, when Job.employment_types is FULLTIME, a default value is inferred based on unit. Default values: - HOURLY: 2080 - DAILY: 260 - WEEKLY: 52 - MONTHLY: 12 - ANNUAL: 1 + * Optional. Expected number of units paid each year. If not specified, when Job.employment_types is FULLTIME, a default value is inferred based on unit. Default values: - HOURLY: 2080 - DAILY: 260 - WEEKLY: 52 - MONTHLY: 12 - ANNUAL: 1 */ expectedUnitsPerYear?: Schema$ExtendedCompensationInfoDecimal; /** - * Optional. Compensation range. + * Optional. Compensation range. */ range?: Schema$ExtendedCompensationInfoCompensationRange; /** - * Required. Compensation type. + * Required. Compensation type. */ type?: string; /** - * Optional. Frequency of the specified amount. Default is CompensationUnit.COMPENSATION_UNIT_UNSPECIFIED. + * Optional. Frequency of the specified amount. Default is CompensationUnit.COMPENSATION_UNIT_UNSPECIFIED. */ unit?: string; /** - * Optional. Indicates compensation amount and range are unset. + * Optional. Indicates compensation amount and range are unset. */ unspecified?: boolean; } @@ -677,11 +677,11 @@ export namespace jobs_v2 { */ export interface Schema$ExtendedCompensationInfoCompensationRange { /** - * Required. Maximum value. + * Required. Maximum value. */ max?: Schema$ExtendedCompensationInfoDecimal; /** - * Required. Minimum value. + * Required. Minimum value. */ min?: Schema$ExtendedCompensationInfoDecimal; } @@ -703,7 +703,7 @@ export namespace jobs_v2 { */ export interface Schema$Filter { /** - * Required. The requisition ID (or posting ID) assigned by the client to identify a job. This is intended for client identification and tracking of listings. name takes precedence over this field The maximum number of allowed characters is 225. + * Required. The requisition ID (or posting ID) assigned by the client to identify a job. This is intended for client identification and tracking of listings. name takes precedence over this field The maximum number of allowed characters is 225. */ requisitionId?: string; } @@ -712,7 +712,7 @@ export namespace jobs_v2 { */ export interface Schema$GetHistogramRequest { /** - * Optional. Controls whether to broaden the search to avoid too few results for a given query in instances where a search has sparse results. Results from a broadened query is a superset of the results from the original query. Defaults to false. + * Optional. Controls whether to broaden the search to avoid too few results for a given query in instances where a search has sparse results. Results from a broadened query is a superset of the results from the original query. Defaults to false. */ allowBroadening?: boolean; /** @@ -720,7 +720,7 @@ export namespace jobs_v2 { */ filters?: Schema$JobFilters; /** - * Optional. Query used to search against jobs, such as keyword, location filters, etc. + * Optional. Query used to search against jobs, such as keyword, location filters, etc. */ query?: Schema$JobQuery; /** @@ -728,7 +728,7 @@ export namespace jobs_v2 { */ requestMetadata?: Schema$RequestMetadata; /** - * Required. A list of facets that specify the histogram data to be calculated against and returned. Histogram response times can be slow, and counts can be approximations. This call may be temporarily or permanently removed prior to the production release of Cloud Talent Solution. + * Required. A list of facets that specify the histogram data to be calculated against and returned. Histogram response times can be slow, and counts can be approximations. This call may be temporarily or permanently removed prior to the production release of Cloud Talent Solution. */ searchTypes?: string[]; } @@ -750,11 +750,11 @@ export namespace jobs_v2 { */ export interface Schema$HistogramFacets { /** - * Optional. Specifies compensation field-based histogram requests. Duplicate values of CompensationHistogramRequest.type are not allowed. + * Optional. Specifies compensation field-based histogram requests. Duplicate values of CompensationHistogramRequest.type are not allowed. */ compensationHistogramFacets?: Schema$CompensationHistogramRequest[]; /** - * Optional. Specifies the custom attributes histogram requests. Duplicate values of CustomAttributeHistogramRequest.key are not allowed. + * Optional. Specifies the custom attributes histogram requests. Duplicate values of CustomAttributeHistogramRequest.key are not allowed. */ customAttributeHistogramFacets?: Schema$CustomAttributeHistogramRequest[]; /** @@ -809,11 +809,11 @@ export namespace jobs_v2 { */ applicationUrls?: string[]; /** - * Optional. The benefits included with the job. + * Optional. The benefits included with the job. */ benefits?: string[]; /** - * Output only. The name of the company listing the job. + * Output only. The name of the company listing the job. */ companyDisplayName?: string; /** @@ -825,23 +825,23 @@ export namespace jobs_v2 { */ companyTitle?: string; /** - * Optional. Job compensation information. + * Optional. Job compensation information. */ compensationInfo?: Schema$CompensationInfo; /** - * Output only. The timestamp when this job was created. + * Output only. The timestamp when this job was created. */ createTime?: string; /** - * Optional. A map of fields to hold both filterable and non-filterable custom job attributes that are not covered by the provided structured fields. This field is a more general combination of the deprecated id-based filterable_custom_fields and string-based non_filterable_custom_fields. The keys of the map are strings up to 64 bytes and must match the pattern: a-zA-Z*. At most 100 filterable and at most 100 unfilterable keys are supported. For filterable `string_values`, across all keys at most 200 values are allowed, with each string no more than 255 characters. For unfilterable `string_values`, the maximum total size of `string_values` across all keys is 50KB. + * Optional. A map of fields to hold both filterable and non-filterable custom job attributes that are not covered by the provided structured fields. This field is a more general combination of the deprecated id-based filterable_custom_fields and string-based non_filterable_custom_fields. The keys of the map are strings up to 64 bytes and must match the pattern: a-zA-Z*. At most 100 filterable and at most 100 unfilterable keys are supported. For filterable `string_values`, across all keys at most 200 values are allowed, with each string no more than 255 characters. For unfilterable `string_values`, the maximum total size of `string_values` across all keys is 50KB. */ customAttributes?: {[key: string]: Schema$CustomAttribute}; /** - * Optional. The department or functional area within the company with the open position. The maximum number of allowed characters is 255. + * Optional. The department or functional area within the company with the open position. The maximum number of allowed characters is 255. */ department?: string; /** - * Required. The description of the job, which typically includes a multi-paragraph description of the company and related information. Separate fields are provided on the job object for responsibilities, qualifications, and other job characteristics. Use of these separate job fields is recommended. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 100,000. + * Required. The description of the job, which typically includes a multi-paragraph description of the company and related information. Separate fields are provided on the job object for responsibilities, qualifications, and other job characteristics. Use of these separate job fields is recommended. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 100,000. */ description?: string; /** @@ -849,15 +849,15 @@ export namespace jobs_v2 { */ distributorCompanyId?: string; /** - * Optional. The desired education level for the job, such as "Bachelors", "Masters", "Doctorate". + * Optional. The desired education level for the job, such as "Bachelors", "Masters", "Doctorate". */ educationLevels?: string[]; /** - * Optional. The employment type(s) of a job, for example, full time or part time. + * Optional. The employment type(s) of a job, for example, full time or part time. */ employmentTypes?: string[]; /** - * Optional. The end date of the job in UTC time zone. Typically this field is used for contracting engagements. Dates prior to 1970/1/1 and invalid date formats are ignored. + * Optional. The end date of the job in UTC time zone. Typically this field is used for contracting engagements. Dates prior to 1970/1/1 and invalid date formats are ignored. */ endDate?: Schema$Date; /** @@ -877,23 +877,23 @@ export namespace jobs_v2 { */ filterableCustomFields?: {[key: string]: Schema$CustomField}; /** - * Optional. A description of bonus, commission, and other compensation incentives associated with the job not including salary or pay. The maximum number of allowed characters is 10,000. + * Optional. A description of bonus, commission, and other compensation incentives associated with the job not including salary or pay. The maximum number of allowed characters is 10,000. */ incentives?: string; /** - * Output only. Structured locations of the job, resolved from locations. + * Output only. Structured locations of the job, resolved from locations. */ jobLocations?: Schema$JobLocation[]; /** - * Required. The title of the job, such as "Software Engineer" The maximum number of allowed characters is 500. + * Required. The title of the job, such as "Software Engineer" The maximum number of allowed characters is 500. */ jobTitle?: string; /** - * Optional. The language of the posting. This field is distinct from any requirements for fluency that are associated with the job. Language codes must be in BCP-47 format, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47){: class="external" target="_blank" }. If this field is unspecified and Job.description is present, detected language code based on Job.description is assigned, otherwise defaults to 'en_US'. + * Optional. The language of the posting. This field is distinct from any requirements for fluency that are associated with the job. Language codes must be in BCP-47 format, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47){: class="external" target="_blank" }. If this field is unspecified and Job.description is present, detected language code based on Job.description is assigned, otherwise defaults to 'en_US'. */ languageCode?: string; /** - * Optional. The experience level associated with the job, such as "Entry Level". + * Optional. The experience level associated with the job, such as "Entry Level". */ level?: string; /** @@ -905,35 +905,35 @@ export namespace jobs_v2 { */ name?: string; /** - * Optional. A promotion value of the job, as determined by the client. The value determines the sort order of the jobs returned when searching for jobs using the featured jobs search call, with higher promotional values being returned first and ties being resolved by relevance sort. Only the jobs with a promotionValue >0 are returned in a FEATURED_JOB_SEARCH. Default value is 0, and negative values are treated as 0. + * Optional. A promotion value of the job, as determined by the client. The value determines the sort order of the jobs returned when searching for jobs using the featured jobs search call, with higher promotional values being returned first and ties being resolved by relevance sort. Only the jobs with a promotionValue >0 are returned in a FEATURED_JOB_SEARCH. Default value is 0, and negative values are treated as 0. */ promotionValue?: number; /** - * Optional. The date this job was most recently published in UTC format. The default value is the time the request arrives at the server. + * Optional. The date this job was most recently published in UTC format. The default value is the time the request arrives at the server. */ publishDate?: Schema$Date; /** - * Optional. A description of the qualifications required to perform the job. The use of this field is recommended as an alternative to using the more general description field. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 10,000. + * Optional. A description of the qualifications required to perform the job. The use of this field is recommended as an alternative to using the more general description field. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 10,000. */ qualifications?: string; /** - * Output only. The URL of a web page that displays job details. + * Output only. The URL of a web page that displays job details. */ referenceUrl?: string; /** - * Optional. The job Region (for example, state, country) throughout which the job is available. If this field is set, a LocationFilter in a search query within the job region finds this job if an exact location match is not specified. If this field is set, setting job locations to the same location level as this field is strongly recommended. + * Optional. The job Region (for example, state, country) throughout which the job is available. If this field is set, a LocationFilter in a search query within the job region finds this job if an exact location match is not specified. If this field is set, setting job locations to the same location level as this field is strongly recommended. */ region?: string; /** - * Required. The requisition ID, also referred to as the posting ID, assigned by the client to identify a job. This field is intended to be used by clients for client identification and tracking of listings. A job is not allowed to be created if there is another job with the same requisition_id, company_name and language_code. The maximum number of allowed characters is 255. + * Required. The requisition ID, also referred to as the posting ID, assigned by the client to identify a job. This field is intended to be used by clients for client identification and tracking of listings. A job is not allowed to be created if there is another job with the same requisition_id, company_name and language_code. The maximum number of allowed characters is 255. */ requisitionId?: string; /** - * Optional. A description of job responsibilities. The use of this field is recommended as an alternative to using the more general description field. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 10,000. + * Optional. A description of job responsibilities. The use of this field is recommended as an alternative to using the more general description field. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 10,000. */ responsibilities?: string; /** - * Optional. The start date of the job in UTC time zone. Typically this field is used for contracting engagements. Dates prior to 1970/1/1 and invalid date formats are ignored. + * Optional. The start date of the job in UTC time zone. Typically this field is used for contracting engagements. Dates prior to 1970/1/1 and invalid date formats are ignored. */ startDate?: Schema$Date; /** @@ -941,11 +941,11 @@ export namespace jobs_v2 { */ unindexedCustomFields?: {[key: string]: Schema$CustomField}; /** - * Output only. The timestamp when this job was last updated. + * Output only. The timestamp when this job was last updated. */ updateTime?: string; /** - * Optional. The visibility of the job. Defaults to JobVisibility.PRIVATE if not specified. Currently only JobVisibility.PRIVATE is supported. + * Optional. The visibility of the job. Defaults to JobVisibility.PRIVATE if not specified. Currently only JobVisibility.PRIVATE is supported. */ visibility?: string; } @@ -954,27 +954,27 @@ export namespace jobs_v2 { */ export interface Schema$JobFilters { /** - * Optional. The category filter specifies the categories of jobs to search against. See Category for more information. If a value is not specified, jobs from any category are searched against. If multiple values are specified, jobs from any of the specified categories are searched against. + * Optional. The category filter specifies the categories of jobs to search against. See Category for more information. If a value is not specified, jobs from any category are searched against. If multiple values are specified, jobs from any of the specified categories are searched against. */ categories?: string[]; /** - * Optional. Allows filtering jobs by commute time with different travel methods (e.g. driving or public transit). Note: this only works with COMMUTE MODE. When specified, [JobFilters.location_filters] will be ignored. Currently we do not support sorting by commute time. + * Optional. Allows filtering jobs by commute time with different travel methods (e.g. driving or public transit). Note: this only works with COMMUTE MODE. When specified, [JobFilters.location_filters] will be ignored. Currently we do not support sorting by commute time. */ commuteFilter?: Schema$CommutePreference; /** - * Optional. The company names filter specifies the company entities to search against. If a value is not specified, jobs are searched for against all companies. If multiple values are specified, jobs are searched against the specified companies. At most 20 company filters are allowed. + * Optional. The company names filter specifies the company entities to search against. If a value is not specified, jobs are searched for against all companies. If multiple values are specified, jobs are searched against the specified companies. At most 20 company filters are allowed. */ companyNames?: string[]; /** - * Optional. This filter specifies the exact company titles of jobs to search against. If a value is not specified, jobs within the search results can be associated with any company. If multiple values are specified, jobs within the search results may be associated with any of the specified companies. At most 20 company title filters are allowed. + * Optional. This filter specifies the exact company titles of jobs to search against. If a value is not specified, jobs within the search results can be associated with any company. If multiple values are specified, jobs within the search results may be associated with any of the specified companies. At most 20 company title filters are allowed. */ companyTitles?: string[]; /** - * Optional. This search filter is applied only to Job.compensation_info. For example, if the filter is specified as "Hourly job with per-hour compensation > $15", only jobs that meet this criteria are searched. If a filter is not defined, all open jobs are searched. + * Optional. This search filter is applied only to Job.compensation_info. For example, if the filter is specified as "Hourly job with per-hour compensation > $15", only jobs that meet this criteria are searched. If a filter is not defined, all open jobs are searched. */ compensationFilter?: Schema$CompensationFilter; /** - * Optional. This filter specifies a structured syntax to match against the Job.custom_attributes that are marked as `filterable`. The syntax for this expression is a subset of Google SQL syntax. Supported operators are: =, !=, <, <=, >, >= where the left of the operator is a custom field key and the right of the operator is a number or string (surrounded by quotes) value. Supported functions are LOWER(<field_name>) to perform case insensitive match and EMPTY(<field_name>) to filter on the existence of a key. Boolean expressions (AND/OR/NOT) are supported up to 3 levels of nesting (For example, "((A AND B AND C) OR NOT D) AND E"), and there can be a maximum of 100 comparisons/functions in the expression. The expression must be < 3000 bytes in length. Sample Query: (key1 = "TEST" OR LOWER(key1)="test" OR NOT EMPTY(key1)) AND key2 > 100 + * Optional. This filter specifies a structured syntax to match against the Job.custom_attributes that are marked as `filterable`. The syntax for this expression is a subset of Google SQL syntax. Supported operators are: =, !=, <, <=, >, >= where the left of the operator is a custom field key and the right of the operator is a number or string (surrounded by quotes) value. Supported functions are LOWER(<field_name>) to perform case insensitive match and EMPTY(<field_name>) to filter on the existence of a key. Boolean expressions (AND/OR/NOT) are supported up to 3 levels of nesting (For example, "((A AND B AND C) OR NOT D) AND E"), and there can be a maximum of 100 comparisons/functions in the expression. The expression must be < 3000 bytes in length. Sample Query: (key1 = "TEST" OR LOWER(key1)="test" OR NOT EMPTY(key1)) AND key2 > 100 */ customAttributeFilter?: string; /** @@ -982,11 +982,11 @@ export namespace jobs_v2 { */ customFieldFilters?: {[key: string]: Schema$CustomFieldFilter}; /** - * Optional. This flag controls the spell-check feature. If false, the service attempts to correct a misspelled query, for example, "enginee" is corrected to "engineer". Defaults to false: a spell check is performed. + * Optional. This flag controls the spell-check feature. If false, the service attempts to correct a misspelled query, for example, "enginee" is corrected to "engineer". Defaults to false: a spell check is performed. */ disableSpellCheck?: boolean; /** - * Optional. The employment type filter specifies the employment type of jobs to search against, such as EmploymentType.FULL_TIME. If a value is not specified, jobs in the search results include any employment type. If multiple values are specified, jobs in the search results include any of the specified employment types. + * Optional. The employment type filter specifies the employment type of jobs to search against, such as EmploymentType.FULL_TIME. If a value is not specified, jobs in the search results include any employment type. If multiple values are specified, jobs in the search results include any of the specified employment types. */ employmentTypes?: string[]; /** @@ -994,19 +994,19 @@ export namespace jobs_v2 { */ extendedCompensationFilter?: Schema$ExtendedCompensationFilter; /** - * Optional. This filter specifies the locale of jobs to search against, for example, "en-US". If a value is not specified, the search results may contain jobs in any locale. Language codes should be in BCP-47 format, for example, "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). At most 10 language code filters are allowed. + * Optional. This filter specifies the locale of jobs to search against, for example, "en-US". If a value is not specified, the search results may contain jobs in any locale. Language codes should be in BCP-47 format, for example, "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). At most 10 language code filters are allowed. */ languageCodes?: string[]; /** - * Optional. The location filter specifies geo-regions containing the jobs to search against. See LocationFilter for more information. If a location value is not specified, jobs are retrieved from all locations. If multiple values are specified, jobs are retrieved from any of the specified locations. If different values are specified for the LocationFilter.distance_in_miles parameter, the maximum provided distance is used for all locations. At most 5 location filters are allowed. + * Optional. The location filter specifies geo-regions containing the jobs to search against. See LocationFilter for more information. If a location value is not specified, jobs are retrieved from all locations. If multiple values are specified, jobs are retrieved from any of the specified locations. If different values are specified for the LocationFilter.distance_in_miles parameter, the maximum provided distance is used for all locations. At most 5 location filters are allowed. */ locationFilters?: Schema$LocationFilter[]; /** - * Optional. Jobs published within a range specified by this filter are searched against, for example, DateRange.PAST_MONTH. If a value is not specified, all open jobs are searched against regardless of the date they were published. + * Optional. Jobs published within a range specified by this filter are searched against, for example, DateRange.PAST_MONTH. If a value is not specified, all open jobs are searched against regardless of the date they were published. */ publishDateRange?: string; /** - * Optional. The query filter contains the keywords that match against the job title, description, and location fields. The maximum query size is 255 bytes/characters. + * Optional. The query filter contains the keywords that match against the job title, description, and location fields. The maximum query size is 255 bytes/characters. */ query?: string; /** @@ -1040,11 +1040,11 @@ export namespace jobs_v2 { */ export interface Schema$JobProcessingOptions { /** - * Optional. If set to `true`, the service does not attempt to resolve a more precise address for the job. + * Optional. If set to `true`, the service does not attempt to resolve a more precise address for the job. */ disableStreetAddressResolution?: boolean; /** - * Optional. Option for job HTML content sanitization. Applied fields are: * description * applicationInstruction * incentives * qualifications * responsibilities HTML tags in these fields may be stripped if sanitiazation is not disabled. Defaults to HtmlSanitization.SIMPLE_FORMATTING_ONLY. + * Optional. Option for job HTML content sanitization. Applied fields are: * description * applicationInstruction * incentives * qualifications * responsibilities HTML tags in these fields may be stripped if sanitiazation is not disabled. Defaults to HtmlSanitization.SIMPLE_FORMATTING_ONLY. */ htmlSanitization?: string; } @@ -1053,51 +1053,51 @@ export namespace jobs_v2 { */ export interface Schema$JobQuery { /** - * Optional. The category filter specifies the categories of jobs to search against. See Category for more information. If a value is not specified, jobs from any category are searched against. If multiple values are specified, jobs from any of the specified categories are searched against. + * Optional. The category filter specifies the categories of jobs to search against. See Category for more information. If a value is not specified, jobs from any category are searched against. If multiple values are specified, jobs from any of the specified categories are searched against. */ categories?: string[]; /** - * Optional. Allows filtering jobs by commute time with different travel methods (for example, driving or public transit). Note: This only works with COMMUTE MODE. When specified, [JobQuery.location_filters] is ignored. Currently we don't support sorting by commute time. + * Optional. Allows filtering jobs by commute time with different travel methods (for example, driving or public transit). Note: This only works with COMMUTE MODE. When specified, [JobQuery.location_filters] is ignored. Currently we don't support sorting by commute time. */ commuteFilter?: Schema$CommutePreference; /** - * Optional. This filter specifies the exact company display name of the jobs to search against. If a value isn't specified, jobs within the search results are associated with any company. If multiple values are specified, jobs within the search results may be associated with any of the specified companies. At most 20 company display name filters are allowed. + * Optional. This filter specifies the exact company display name of the jobs to search against. If a value isn't specified, jobs within the search results are associated with any company. If multiple values are specified, jobs within the search results may be associated with any of the specified companies. At most 20 company display name filters are allowed. */ companyDisplayNames?: string[]; /** - * Optional. This filter specifies the company entities to search against. If a value isn't specified, jobs are searched for against all companies. If multiple values are specified, jobs are searched against the companies specified. At most 20 company filters are allowed. + * Optional. This filter specifies the company entities to search against. If a value isn't specified, jobs are searched for against all companies. If multiple values are specified, jobs are searched against the companies specified. At most 20 company filters are allowed. */ companyNames?: string[]; /** - * Optional. This search filter is applied only to Job.compensation_info. For example, if the filter is specified as "Hourly job with per-hour compensation > $15", only jobs meeting these criteria are searched. If a filter isn't defined, all open jobs are searched. + * Optional. This search filter is applied only to Job.compensation_info. For example, if the filter is specified as "Hourly job with per-hour compensation > $15", only jobs meeting these criteria are searched. If a filter isn't defined, all open jobs are searched. */ compensationFilter?: Schema$CompensationFilter; /** - * Optional. This filter specifies a structured syntax to match against the Job.custom_attributes marked as `filterable`. The syntax for this expression is a subset of Google SQL syntax. Supported operators are: =, !=, <, <=, >, >= where the left of the operator is a custom field key and the right of the operator is a number or string (surrounded by quotes) value. Supported functions are LOWER(<field_name>) to perform case insensitive match and EMPTY(<field_name>) to filter on the existence of a key. Boolean expressions (AND/OR/NOT) are supported up to 3 levels of nesting (for example, "((A AND B AND C) OR NOT D) AND E"), a maximum of 50 comparisons/functions are allowed in the expression. The expression must be < 2000 characters in length. Sample Query: (key1 = "TEST" OR LOWER(key1)="test" OR NOT EMPTY(key1)) AND key2 > 100 + * Optional. This filter specifies a structured syntax to match against the Job.custom_attributes marked as `filterable`. The syntax for this expression is a subset of Google SQL syntax. Supported operators are: =, !=, <, <=, >, >= where the left of the operator is a custom field key and the right of the operator is a number or string (surrounded by quotes) value. Supported functions are LOWER(<field_name>) to perform case insensitive match and EMPTY(<field_name>) to filter on the existence of a key. Boolean expressions (AND/OR/NOT) are supported up to 3 levels of nesting (for example, "((A AND B AND C) OR NOT D) AND E"), a maximum of 50 comparisons/functions are allowed in the expression. The expression must be < 2000 characters in length. Sample Query: (key1 = "TEST" OR LOWER(key1)="test" OR NOT EMPTY(key1)) AND key2 > 100 */ customAttributeFilter?: string; /** - * Optional. This flag controls the spell-check feature. If false, the service attempts to correct a misspelled query, for example, "enginee" is corrected to "engineer". Defaults to false: a spell check is performed. + * Optional. This flag controls the spell-check feature. If false, the service attempts to correct a misspelled query, for example, "enginee" is corrected to "engineer". Defaults to false: a spell check is performed. */ disableSpellCheck?: boolean; /** - * Optional. The employment type filter specifies the employment type of jobs to search against, such as EmploymentType.FULL_TIME. If a value is not specified, jobs in the search results include any employment type. If multiple values are specified, jobs in the search results include any of the specified employment types. + * Optional. The employment type filter specifies the employment type of jobs to search against, such as EmploymentType.FULL_TIME. If a value is not specified, jobs in the search results include any employment type. If multiple values are specified, jobs in the search results include any of the specified employment types. */ employmentTypes?: string[]; /** - * Optional. This filter specifies the locale of jobs to search against, for example, "en-US". If a value isn't specified, the search results can contain jobs in any locale. Language codes should be in BCP-47 format, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). At most 10 language code filters are allowed. + * Optional. This filter specifies the locale of jobs to search against, for example, "en-US". If a value isn't specified, the search results can contain jobs in any locale. Language codes should be in BCP-47 format, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). At most 10 language code filters are allowed. */ languageCodes?: string[]; /** - * Optional. The location filter specifies geo-regions containing the jobs to search against. See LocationFilter for more information. If a location value isn't specified, jobs fitting the other search criteria are retrieved regardless of where they're located. If multiple values are specified, jobs are retrieved from any of the specified locations. If different values are specified for the LocationFilter.distance_in_miles parameter, the maximum provided distance is used for all locations. At most 5 location filters are allowed. + * Optional. The location filter specifies geo-regions containing the jobs to search against. See LocationFilter for more information. If a location value isn't specified, jobs fitting the other search criteria are retrieved regardless of where they're located. If multiple values are specified, jobs are retrieved from any of the specified locations. If different values are specified for the LocationFilter.distance_in_miles parameter, the maximum provided distance is used for all locations. At most 5 location filters are allowed. */ locationFilters?: Schema$LocationFilter[]; /** - * Optional. Jobs published within a range specified by this filter are searched against, for example, DateRange.PAST_MONTH. If a value isn't specified, all open jobs are searched against regardless of their published date. + * Optional. Jobs published within a range specified by this filter are searched against, for example, DateRange.PAST_MONTH. If a value isn't specified, all open jobs are searched against regardless of their published date. */ publishDateRange?: string; /** - * Optional. The query string that matches against the job title, description, and location fields. The maximum query size is 255 bytes. + * Optional. The query string that matches against the job title, description, and location fields. The maximum query size is 255 bytes. */ query?: string; } @@ -1174,23 +1174,23 @@ export namespace jobs_v2 { */ export interface Schema$LocationFilter { /** - * Optional. The distance_in_miles is applied when the location being searched for is identified as a city or smaller. When the location being searched for is a state or larger, this field is ignored. + * Optional. The distance_in_miles is applied when the location being searched for is identified as a city or smaller. When the location being searched for is a state or larger, this field is ignored. */ distanceInMiles?: number; /** - * Optional. Allows the client to return jobs without a set location, specifically, telecommuting jobs (telecomuting is considered by the service as a special location. Job.allow_telecommute indicates if a job permits telecommuting. If this field is true, telecommuting jobs are searched, and name and lat_lng are ignored. This filter can be used by itself to search exclusively for telecommuting jobs, or it can be combined with another location filter to search for a combination of job locations, such as "Mountain View" or "telecommuting" jobs. However, when used in combination with other location filters, telecommuting jobs can be treated as less relevant than other jobs in the search response. + * Optional. Allows the client to return jobs without a set location, specifically, telecommuting jobs (telecomuting is considered by the service as a special location. Job.allow_telecommute indicates if a job permits telecommuting. If this field is true, telecommuting jobs are searched, and name and lat_lng are ignored. This filter can be used by itself to search exclusively for telecommuting jobs, or it can be combined with another location filter to search for a combination of job locations, such as "Mountain View" or "telecommuting" jobs. However, when used in combination with other location filters, telecommuting jobs can be treated as less relevant than other jobs in the search response. */ isTelecommute?: boolean; /** - * Optional. The latitude and longitude of the geographic center from which to search. This field is ignored if `location_name` is provided. + * Optional. The latitude and longitude of the geographic center from which to search. This field is ignored if `location_name` is provided. */ latLng?: Schema$LatLng; /** - * Optional. The address name, such as "Mountain View" or "Bay Area". + * Optional. The address name, such as "Mountain View" or "Bay Area". */ name?: string; /** - * Optional. CLDR region code of the country/region of the address. This will be used to address ambiguity of the user-input location, e.g. "Liverpool" against "Liverpool, NY, US" or "Liverpool, UK". Set this field if all the jobs to search against are from a same region, or jobs are world-wide but the job seeker is from a specific region. See http://cldr.unicode.org/ and http://www.unicode.org/cldr/charts/30/supplemental/territory_information.html for details. Example: "CH" for Switzerland. + * Optional. CLDR region code of the country/region of the address. This will be used to address ambiguity of the user-input location, e.g. "Liverpool" against "Liverpool, NY, US" or "Liverpool, UK". Set this field if all the jobs to search against are from a same region, or jobs are world-wide but the job seeker is from a specific region. See http://cldr.unicode.org/ and http://www.unicode.org/cldr/charts/30/supplemental/territory_information.html for details. Example: "CH" for Switzerland. */ regionCode?: string; } @@ -1241,11 +1241,11 @@ export namespace jobs_v2 { */ export interface Schema$NumericBucketingOption { /** - * Required. Two adjacent values form a histogram bucket. Values should be in ascending order. For example, if [5, 10, 15] are provided, four buckets are created: (-inf, 5), 5, 10), [10, 15), [15, inf). At most 20 [buckets_bound is supported. + * Required. Two adjacent values form a histogram bucket. Values should be in ascending order. For example, if [5, 10, 15] are provided, four buckets are created: (-inf, 5), 5, 10), [10, 15), [15, inf). At most 20 [buckets_bound is supported. */ bucketBounds?: number[]; /** - * Optional. If set to true, the histogram result includes minimum/maximum value of the numeric field. + * Optional. If set to true, the histogram result includes minimum/maximum value of the numeric field. */ requiresMinMax?: boolean; } @@ -1267,7 +1267,7 @@ export namespace jobs_v2 { minValue?: number; } /** - * Represents a postal address, e.g. for postal delivery or payments addresses. Given a postal address, a postal service can deliver items to a premise, P.O. Box or similar. It is not intended to model geographical locations (roads, towns, mountains). In typical usage an address would be created via user input or from importing existing data, depending on the type of process. Advice on address input / editing: - Use an i18n-ready address widget such as https://github.com/googlei18n/libaddressinput) - Users should not be presented with UI elements for input or editing of fields outside countries where that field is used. For more guidance on how to use this schema, please see: https://support.google.com/business/answer/6397478 + * Represents a postal address, e.g. for postal delivery or payments addresses. Given a postal address, a postal service can deliver items to a premise, P.O. Box or similar. It is not intended to model geographical locations (roads, towns, mountains). In typical usage an address would be created via user input or from importing existing data, depending on the type of process. Advice on address input / editing: - Use an i18n-ready address widget such as https://github.com/google/libaddressinput) - Users should not be presented with UI elements for input or editing of fields outside countries where that field is used. For more guidance on how to use this schema, please see: https://support.google.com/business/answer/6397478 */ export interface Schema$PostalAddress { /** @@ -1320,19 +1320,19 @@ export namespace jobs_v2 { */ export interface Schema$RequestMetadata { /** - * Optional. The type of device used by the job seeker at the time of the call to the service. + * Optional. The type of device used by the job seeker at the time of the call to the service. */ deviceInfo?: Schema$DeviceInfo; /** - * Required. The client-defined scope or source of the service call, which typically is the domain on which the service has been implemented and is currently being run. For example, if the service is being run by client <em>Foo, Inc.</em>, on job board www.foo.com and career site www.bar.com, then this field is set to "foo.com" for use on the job board, and "bar.com" for use on the career site. If this field is not available for some reason, send "UNKNOWN". Note that any improvements to the service model for a particular tenant site rely on this field being set correctly to some domain. + * Required. The client-defined scope or source of the service call, which typically is the domain on which the service has been implemented and is currently being run. For example, if the service is being run by client <em>Foo, Inc.</em>, on job board www.foo.com and career site www.bar.com, then this field is set to "foo.com" for use on the job board, and "bar.com" for use on the career site. If this field is not available for some reason, send "UNKNOWN". Note that any improvements to the service model for a particular tenant site rely on this field being set correctly to some domain. */ domain?: string; /** - * Required. A unique session identification string. A session is defined as the duration of an end user's interaction with the service over a period. Obfuscate this field for privacy concerns before providing it to the API. If this field is not available for some reason, please send "UNKNOWN". Note that any improvements to the service model for a particular tenant site, rely on this field being set correctly to some unique session_id. + * Required. A unique session identification string. A session is defined as the duration of an end user's interaction with the service over a period. Obfuscate this field for privacy concerns before providing it to the API. If this field is not available for some reason, please send "UNKNOWN". Note that any improvements to the service model for a particular tenant site, rely on this field being set correctly to some unique session_id. */ sessionId?: string; /** - * Required. A unique user identification string, as determined by the client. The client is responsible for ensuring client-level uniqueness of this value in order to have the strongest positive impact on search quality. Obfuscate this field for privacy concerns before providing it to the service. If this field is not available for some reason, please send "UNKNOWN". Note that any improvements to the service model for a particular tenant site, rely on this field being set correctly to some unique user_id. + * Required. A unique user identification string, as determined by the client. The client is responsible for ensuring client-level uniqueness of this value in order to have the strongest positive impact on search quality. Obfuscate this field for privacy concerns before providing it to the service. If this field is not available for some reason, please send "UNKNOWN". Note that any improvements to the service model for a particular tenant site, rely on this field being set correctly to some unique user_id. */ userId?: string; } @@ -1358,15 +1358,15 @@ export namespace jobs_v2 { */ export interface Schema$SearchJobsRequest { /** - * Optional. Controls whether to disable relevance thresholding. Relevance thresholding removes jobs that have low relevance in search results, for example, removing "Assistant to the CEO" positions from the search results of a search for "CEO". Disabling relevance thresholding improves the accuracy of subsequent search requests. Defaults to false. + * Optional. Controls whether to disable relevance thresholding. Relevance thresholding removes jobs that have low relevance in search results, for example, removing "Assistant to the CEO" positions from the search results of a search for "CEO". Disabling relevance thresholding improves the accuracy of subsequent search requests. Defaults to false. */ disableRelevanceThresholding?: boolean; /** - * Optional. Controls whether to broaden the search when it produces sparse results. Broadened queries append results to the end of the matching results list. Defaults to false. + * Optional. Controls whether to broaden the search when it produces sparse results. Broadened queries append results to the end of the matching results list. Defaults to false. */ enableBroadening?: boolean; /** - * Optional. Controls if the search job request requires the return of a precise count of the first 300 results. Setting this to `true` ensures consistency in the number of results per page. Best practice is to set this value to true if a client allows users to jump directly to a non-sequential search results page. Enabling this flag may adversely impact performance. Defaults to false. + * Optional. Controls if the search job request requires the return of a precise count of the first 300 results. Setting this to `true` ensures consistency in the number of results per page. Best practice is to set this value to true if a client allows users to jump directly to a non-sequential search results page. Enabling this flag may adversely impact performance. Defaults to false. */ enablePreciseResultSize?: boolean; /** @@ -1374,19 +1374,19 @@ export namespace jobs_v2 { */ filters?: Schema$JobFilters; /** - * Optional. Restrictions on what fields to perform histogram on, such as `COMPANY_SIZE` etc. + * Optional. Restrictions on what fields to perform histogram on, such as `COMPANY_SIZE` etc. */ histogramFacets?: Schema$HistogramFacets; /** - * Optional. The number of job attributes returned for jobs in the search response. Defaults to JobView.SMALL if no value is specified. + * Optional. The number of job attributes returned for jobs in the search response. Defaults to JobView.SMALL if no value is specified. */ jobView?: string; /** - * Required. Mode of a search. + * Required. Mode of a search. */ mode?: string; /** - * Optional. An integer that specifies the current offset (that is, starting result location, amongst the jobs deemed by the API as relevant) in search results. This field is only considered if page_token is unset. For example, 0 means to return results starting from the first matching job, and 10 means to return from the 11th job. This can be used for pagination, (for example, pageSize = 10 and offset = 10 means to return from the second page). + * Optional. An integer that specifies the current offset (that is, starting result location, amongst the jobs deemed by the API as relevant) in search results. This field is only considered if page_token is unset. For example, 0 means to return results starting from the first matching job, and 10 means to return from the 11th job. This can be used for pagination, (for example, pageSize = 10 and offset = 10 means to return from the second page). */ offset?: number; /** @@ -1394,23 +1394,23 @@ export namespace jobs_v2 { */ orderBy?: string; /** - * Optional. A limit on the number of jobs returned in the search results. Increasing this value above the default value of 10 can increase search response time. The value can be between 1 and 100. + * Optional. A limit on the number of jobs returned in the search results. Increasing this value above the default value of 10 can increase search response time. The value can be between 1 and 100. */ pageSize?: number; /** - * Optional. The token specifying the current offset within search results. See SearchJobsResponse.next_page_token for an explanation of how to obtain the next set of query results. + * Optional. The token specifying the current offset within search results. See SearchJobsResponse.next_page_token for an explanation of how to obtain the next set of query results. */ pageToken?: string; /** - * Optional. Query used to search against jobs, such as keyword, location filters, etc. + * Optional. Query used to search against jobs, such as keyword, location filters, etc. */ query?: Schema$JobQuery; /** - * Required. The meta information collected about the job searcher, used to improve the search quality of the service. The identifiers, (such as `user_id`) are provided by users, and must be unique and consistent. + * Required. The meta information collected about the job searcher, used to improve the search quality of the service. The identifiers, (such as `user_id`) are provided by users, and must be unique and consistent. */ requestMetadata?: Schema$RequestMetadata; /** - * Optional. The criteria determining how search results are sorted. Defaults to SortBy.RELEVANCE_DESC if no value is specified. + * Optional. The criteria determining how search results are sorted. Defaults to SortBy.RELEVANCE_DESC if no value is specified. */ sortBy?: string; } @@ -1481,7 +1481,7 @@ export namespace jobs_v2 { */ export interface Schema$StringValues { /** - * Required. String values. + * Required. String values. */ values?: string[]; } @@ -1494,11 +1494,11 @@ export namespace jobs_v2 { */ disableStreetAddressResolution?: boolean; /** - * Required. The Job to be updated. + * Required. The Job to be updated. */ job?: Schema$Job; /** - * Optional. Options for job processing. UpdateJobRequest.disable_street_address_resolution is ignored if this flag is set. + * Optional. Options for job processing. UpdateJobRequest.disable_street_address_resolution is ignored if this flag is set. */ processingOptions?: Schema$JobProcessingOptions; /** @@ -1590,7 +1590,7 @@ export namespace jobs_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the company to be deleted, such as, "companies/0000aaaa-1111-bbbb-2222-cccc3333dddd". + * @param {string} params.name Required. The resource name of the company to be deleted, such as, "companies/0000aaaa-1111-bbbb-2222-cccc3333dddd". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1658,7 +1658,7 @@ export namespace jobs_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. Resource name of the company to retrieve, such as "companies/0000aaaa-1111-bbbb-2222-cccc3333dddd". + * @param {string} params.name Required. Resource name of the company to retrieve, such as "companies/0000aaaa-1111-bbbb-2222-cccc3333dddd". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1726,9 +1726,9 @@ export namespace jobs_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {boolean=} params.mustHaveOpenJobs Optional. Set to true if the companies request must have open jobs. Defaults to false. If true, at most page_size of companies are fetched, among which only those with open jobs are returned. - * @param {integer=} params.pageSize Optional. The maximum number of companies to be returned, at most 100. Default is 100 if a non-positive number is provided. - * @param {string=} params.pageToken Optional. The starting indicator from which to return results. + * @param {boolean=} params.mustHaveOpenJobs Optional. Set to true if the companies request must have open jobs. Defaults to false. If true, at most page_size of companies are fetched, among which only those with open jobs are returned. + * @param {integer=} params.pageSize Optional. The maximum number of companies to be returned, at most 100. Default is 100 if a non-positive number is provided. + * @param {string=} params.pageToken Optional. The starting indicator from which to return results. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1882,7 +1882,7 @@ export namespace jobs_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the company to be deleted, such as, "companies/0000aaaa-1111-bbbb-2222-cccc3333dddd". + * Required. The resource name of the company to be deleted, such as, "companies/0000aaaa-1111-bbbb-2222-cccc3333dddd". */ name?: string; } @@ -1893,7 +1893,7 @@ export namespace jobs_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. Resource name of the company to retrieve, such as "companies/0000aaaa-1111-bbbb-2222-cccc3333dddd". + * Required. Resource name of the company to retrieve, such as "companies/0000aaaa-1111-bbbb-2222-cccc3333dddd". */ name?: string; } @@ -1904,15 +1904,15 @@ export namespace jobs_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. Set to true if the companies request must have open jobs. Defaults to false. If true, at most page_size of companies are fetched, among which only those with open jobs are returned. + * Optional. Set to true if the companies request must have open jobs. Defaults to false. If true, at most page_size of companies are fetched, among which only those with open jobs are returned. */ mustHaveOpenJobs?: boolean; /** - * Optional. The maximum number of companies to be returned, at most 100. Default is 100 if a non-positive number is provided. + * Optional. The maximum number of companies to be returned, at most 100. Default is 100 if a non-positive number is provided. */ pageSize?: number; /** - * Optional. The starting indicator from which to return results. + * Optional. The starting indicator from which to return results. */ pageToken?: string; } @@ -1950,12 +1950,12 @@ export namespace jobs_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.companyName Required. The resource name of the company that owns the jobs to be listed, such as, "companies/0000aaaa-1111-bbbb-2222-cccc3333dddd". - * @param {boolean=} params.idsOnly Optional. If set to `true`, only job ID, job requisition ID and language code will be returned. A typical use is to synchronize job repositories. Defaults to false. + * @param {string} params.companyName Required. The resource name of the company that owns the jobs to be listed, such as, "companies/0000aaaa-1111-bbbb-2222-cccc3333dddd". + * @param {boolean=} params.idsOnly Optional. If set to `true`, only job ID, job requisition ID and language code will be returned. A typical use is to synchronize job repositories. Defaults to false. * @param {boolean=} params.includeJobsCount Deprecated. Please DO NOT use this field except for small companies. Suggest counting jobs page by page instead. Optional. Set to true if the total number of open jobs is to be returned. Defaults to false. - * @param {string=} params.jobRequisitionId Optional. The requisition ID, also known as posting ID, assigned by the company to the job. The maximum number of allowable characters is 225. - * @param {integer=} params.pageSize Optional. The maximum number of jobs to be returned per page of results. If ids_only is set to true, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. - * @param {string=} params.pageToken Optional. The starting point of a query result. + * @param {string=} params.jobRequisitionId Optional. The requisition ID, also known as posting ID, assigned by the company to the job. The maximum number of allowable characters is 225. + * @param {integer=} params.pageSize Optional. The maximum number of jobs to be returned per page of results. If ids_only is set to true, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. + * @param {string=} params.pageToken Optional. The starting point of a query result. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2033,11 +2033,11 @@ export namespace jobs_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the company that owns the jobs to be listed, such as, "companies/0000aaaa-1111-bbbb-2222-cccc3333dddd". + * Required. The resource name of the company that owns the jobs to be listed, such as, "companies/0000aaaa-1111-bbbb-2222-cccc3333dddd". */ companyName?: string; /** - * Optional. If set to `true`, only job ID, job requisition ID and language code will be returned. A typical use is to synchronize job repositories. Defaults to false. + * Optional. If set to `true`, only job ID, job requisition ID and language code will be returned. A typical use is to synchronize job repositories. Defaults to false. */ idsOnly?: boolean; /** @@ -2045,15 +2045,15 @@ export namespace jobs_v2 { */ includeJobsCount?: boolean; /** - * Optional. The requisition ID, also known as posting ID, assigned by the company to the job. The maximum number of allowable characters is 225. + * Optional. The requisition ID, also known as posting ID, assigned by the company to the job. The maximum number of allowable characters is 225. */ jobRequisitionId?: string; /** - * Optional. The maximum number of jobs to be returned per page of results. If ids_only is set to true, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. + * Optional. The maximum number of jobs to be returned per page of results. If ids_only is set to true, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. */ pageSize?: number; /** - * Optional. The starting point of a query result. + * Optional. The starting point of a query result. */ pageToken?: string; } @@ -2211,7 +2211,7 @@ export namespace jobs_v2 { * * @param {object} params Parameters for request * @param {boolean=} params.disableFastProcess Deprecated. This field is not working anymore. Optional. If set to true, this call waits for all processing steps to complete before the job is cleaned up. Otherwise, the call returns while some steps are still taking place asynchronously, hence faster. - * @param {string} params.name Required. The resource name of the job to be deleted, such as "jobs/11111111". + * @param {string} params.name Required. The resource name of the job to be deleted, such as "jobs/11111111". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2351,7 +2351,7 @@ export namespace jobs_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the job to retrieve, such as "jobs/11111111". + * @param {string} params.name Required. The resource name of the job to retrieve, such as "jobs/11111111". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2493,10 +2493,10 @@ export namespace jobs_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.filter Required. The filter string specifies the jobs to be enumerated. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Optional) Sample Query: * companyName = "companies/123" * companyName = "companies/123" AND requisitionId = "req-1" - * @param {boolean=} params.idsOnly Optional. If set to `true`, only Job.name, Job.requisition_id and Job.language_code will be returned. A typical use case is to synchronize job repositories. Defaults to false. - * @param {integer=} params.pageSize Optional. The maximum number of jobs to be returned per page of results. If ids_only is set to true, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. - * @param {string=} params.pageToken Optional. The starting point of a query result. + * @param {string=} params.filter Required. The filter string specifies the jobs to be enumerated. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Optional) Sample Query: * companyName = "companies/123" * companyName = "companies/123" AND requisitionId = "req-1" + * @param {boolean=} params.idsOnly Optional. If set to `true`, only Job.name, Job.requisition_id and Job.language_code will be returned. A typical use case is to synchronize job repositories. Defaults to false. + * @param {integer=} params.pageSize Optional. The maximum number of jobs to be returned per page of results. If ids_only is set to true, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. + * @param {string=} params.pageToken Optional. The starting point of a query result. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2808,7 +2808,7 @@ export namespace jobs_v2 { */ disableFastProcess?: boolean; /** - * Required. The resource name of the job to be deleted, such as "jobs/11111111". + * Required. The resource name of the job to be deleted, such as "jobs/11111111". */ name?: string; } @@ -2831,7 +2831,7 @@ export namespace jobs_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the job to retrieve, such as "jobs/11111111". + * Required. The resource name of the job to retrieve, such as "jobs/11111111". */ name?: string; } @@ -2853,19 +2853,19 @@ export namespace jobs_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The filter string specifies the jobs to be enumerated. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Optional) Sample Query: * companyName = "companies/123" * companyName = "companies/123" AND requisitionId = "req-1" + * Required. The filter string specifies the jobs to be enumerated. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Optional) Sample Query: * companyName = "companies/123" * companyName = "companies/123" AND requisitionId = "req-1" */ filter?: string; /** - * Optional. If set to `true`, only Job.name, Job.requisition_id and Job.language_code will be returned. A typical use case is to synchronize job repositories. Defaults to false. + * Optional. If set to `true`, only Job.name, Job.requisition_id and Job.language_code will be returned. A typical use case is to synchronize job repositories. Defaults to false. */ idsOnly?: boolean; /** - * Optional. The maximum number of jobs to be returned per page of results. If ids_only is set to true, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. + * Optional. The maximum number of jobs to be returned per page of results. If ids_only is set to true, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. */ pageSize?: number; /** - * Optional. The starting point of a query result. + * Optional. The starting point of a query result. */ pageToken?: string; } @@ -2922,12 +2922,12 @@ export namespace jobs_v2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.companyName Optional. If provided, restricts completion to the specified company. - * @param {string=} params.languageCode Required. The language of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with same language_code are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with same language_code are returned. For CompletionType.COMBINED type, only open jobs with same language_code or companies having open jobs with same language_code are returned. - * @param {integer=} params.pageSize Required. Completion result count. The maximum allowed page size is 10. - * @param {string=} params.query Required. The query used to generate suggestions. - * @param {string=} params.scope Optional. The scope of the completion. The defaults is CompletionScope.PUBLIC. - * @param {string=} params.type Optional. The completion topic. The default is CompletionType.COMBINED. + * @param {string=} params.companyName Optional. If provided, restricts completion to the specified company. + * @param {string=} params.languageCode Required. The language of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with same language_code are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with same language_code are returned. For CompletionType.COMBINED type, only open jobs with same language_code or companies having open jobs with same language_code are returned. + * @param {integer=} params.pageSize Required. Completion result count. The maximum allowed page size is 10. + * @param {string=} params.query Required. The query used to generate suggestions. + * @param {string=} params.scope Optional. The scope of the completion. The defaults is CompletionScope.PUBLIC. + * @param {string=} params.type Optional. The completion topic. The default is CompletionType.COMBINED. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -3002,27 +3002,27 @@ export namespace jobs_v2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. If provided, restricts completion to the specified company. + * Optional. If provided, restricts completion to the specified company. */ companyName?: string; /** - * Required. The language of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with same language_code are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with same language_code are returned. For CompletionType.COMBINED type, only open jobs with same language_code or companies having open jobs with same language_code are returned. + * Required. The language of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with same language_code are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with same language_code are returned. For CompletionType.COMBINED type, only open jobs with same language_code or companies having open jobs with same language_code are returned. */ languageCode?: string; /** - * Required. Completion result count. The maximum allowed page size is 10. + * Required. Completion result count. The maximum allowed page size is 10. */ pageSize?: number; /** - * Required. The query used to generate suggestions. + * Required. The query used to generate suggestions. */ query?: string; /** - * Optional. The scope of the completion. The defaults is CompletionScope.PUBLIC. + * Optional. The scope of the completion. The defaults is CompletionScope.PUBLIC. */ scope?: string; /** - * Optional. The completion topic. The default is CompletionType.COMBINED. + * Optional. The completion topic. The default is CompletionType.COMBINED. */ type?: string; } diff --git a/src/apis/jobs/v3.ts b/src/apis/jobs/v3.ts index e5a874f0cac..ecca84c1bae 100644 --- a/src/apis/jobs/v3.ts +++ b/src/apis/jobs/v3.ts @@ -139,7 +139,7 @@ export namespace jobs_v3 { */ export interface Schema$BatchDeleteJobsRequest { /** - * Required. The filter string specifies the jobs to be deleted. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Required) Sample Query: companyName = "projects/api-test-project/companies/123" AND requisitionId = "req-1" + * Required. The filter string specifies the jobs to be deleted. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Required) Sample Query: companyName = "projects/api-test-project/companies/123" AND requisitionId = "req-1" */ filter?: string; } @@ -174,15 +174,15 @@ export namespace jobs_v3 { */ export interface Schema$ClientEvent { /** - * Required. The timestamp of the event. + * Required. The timestamp of the event. */ createTime?: string; /** - * Required. A unique identifier, generated by the client application. This `event_id` is used to establish the relationship between different events (see parent_event_id). + * Required. A unique identifier, generated by the client application. This `event_id` is used to establish the relationship between different events (see parent_event_id). */ eventId?: string; /** - * Optional. Extra information about this event. Used for storing information with no matching field in event payload, for example, user application specific context or details. At most 20 keys are supported. The maximum total size of all keys and values is 2 KB. + * Optional. Extra information about this event. Used for storing information with no matching field in event payload, for example, user application specific context or details. At most 20 keys are supported. The maximum total size of all keys and values is 2 KB. */ extraInfo?: {[key: string]: string}; /** @@ -190,11 +190,11 @@ export namespace jobs_v3 { */ jobEvent?: Schema$JobEvent; /** - * Optional. The event_id of an event that resulted in the current event. For example, a Job view event usually follows a parent impression event: A job seeker first does a search where a list of jobs appears (impression). The job seeker then selects a result and views the description of a particular job (Job view). + * Optional. The event_id of an event that resulted in the current event. For example, a Job view event usually follows a parent impression event: A job seeker first does a search where a list of jobs appears (impression). The job seeker then selects a result and views the description of a particular job (Job view). */ parentEventId?: string; /** - * Required. A unique ID generated in the API responses. It can be found in ResponseMetadata.request_id. + * Required. A unique ID generated in the API responses. It can be found in ResponseMetadata.request_id. */ requestId?: string; } @@ -207,23 +207,23 @@ export namespace jobs_v3 { */ allowImpreciseAddresses?: boolean; /** - * Required. The method of transportation for which to calculate the commute time. + * Required. The method of transportation for which to calculate the commute time. */ commuteMethod?: string; /** - * Optional. The departure time used to calculate traffic impact, represented as google.type.TimeOfDay in local time zone. Currently traffic model is restricted to hour level resolution. + * Optional. The departure time used to calculate traffic impact, represented as google.type.TimeOfDay in local time zone. Currently traffic model is restricted to hour level resolution. */ departureTime?: Schema$TimeOfDay; /** - * Optional. Specifies the traffic density to use when calculating commute time. + * Optional. Specifies the traffic density to use when calculating commute time. */ roadTraffic?: string; /** - * Required. The latitude and longitude of the location from which to calculate the commute time. + * Required. The latitude and longitude of the location from which to calculate the commute time. */ startCoordinates?: Schema$LatLng; /** - * Required. The maximum travel time in seconds. The maximum allowed value is `3600s` (one hour). Format is `123s`. + * Required. The maximum travel time in seconds. The maximum allowed value is `3600s` (one hour). Format is `123s`. */ travelDuration?: string; } @@ -245,7 +245,7 @@ export namespace jobs_v3 { */ export interface Schema$Company { /** - * Optional. The URI to employer's career site or careers page on the employer's web site, for example, "https://careers.google.com". + * Optional. The URI to employer's career site or careers page on the employer's web site, for example, "https://careers.google.com". */ careerSiteUri?: string; /** @@ -253,31 +253,31 @@ export namespace jobs_v3 { */ derivedInfo?: Schema$CompanyDerivedInfo; /** - * Required. The display name of the company, for example, "Google, LLC". + * Required. The display name of the company, for example, "Google LLC". */ displayName?: string; /** - * Optional. Equal Employment Opportunity legal disclaimer text to be associated with all jobs, and typically to be displayed in all roles. The maximum number of allowed characters is 500. + * Optional. Equal Employment Opportunity legal disclaimer text to be associated with all jobs, and typically to be displayed in all roles. The maximum number of allowed characters is 500. */ eeoText?: string; /** - * Required. Client side company identifier, used to uniquely identify the company. The maximum number of allowed characters is 255. + * Required. Client side company identifier, used to uniquely identify the company. The maximum number of allowed characters is 255. */ externalId?: string; /** - * Optional. The street address of the company's main headquarters, which may be different from the job location. The service attempts to geolocate the provided address, and populates a more specific location wherever possible in DerivedInfo.headquarters_location. + * Optional. The street address of the company's main headquarters, which may be different from the job location. The service attempts to geolocate the provided address, and populates a more specific location wherever possible in DerivedInfo.headquarters_location. */ headquartersAddress?: string; /** - * Optional. Set to true if it is the hiring agency that post jobs for other employers. Defaults to false if not provided. + * Optional. Set to true if it is the hiring agency that post jobs for other employers. Defaults to false if not provided. */ hiringAgency?: boolean; /** - * Optional. A URI that hosts the employer's company logo. + * Optional. A URI that hosts the employer's company logo. */ imageUri?: string; /** - * Optional. A list of keys of filterable Job.custom_attributes, whose corresponding `string_values` are used in keyword search. Jobs with `string_values` under these specified field keys are returned if any of the values matches the search keyword. Custom field values with parenthesis, brackets and special symbols won't be properly searchable, and those keyword queries need to be surrounded by quotes. + * Optional. A list of keys of filterable Job.custom_attributes, whose corresponding `string_values` are used in keyword search. Jobs with `string_values` under these specified field keys are returned if any of the values matches the search keyword. Custom field values with parenthesis, brackets and special symbols won't be properly searchable, and those keyword queries need to be surrounded by quotes. */ keywordSearchableJobCustomAttributes?: string[]; /** @@ -285,7 +285,7 @@ export namespace jobs_v3 { */ name?: string; /** - * Optional. The employer's company size. + * Optional. The employer's company size. */ size?: string; /** @@ -293,7 +293,7 @@ export namespace jobs_v3 { */ suspended?: boolean; /** - * Optional. The URI representing the company's primary web site or home page, for example, "https://www.google.com". The maximum number of allowed characters is 255. + * Optional. The URI representing the company's primary web site or home page, for example, "https://www.google.com". The maximum number of allowed characters is 255. */ websiteUri?: string; } @@ -311,27 +311,27 @@ export namespace jobs_v3 { */ export interface Schema$CompensationEntry { /** - * Optional. Compensation amount. + * Optional. Compensation amount. */ amount?: Schema$Money; /** - * Optional. Compensation description. For example, could indicate equity terms or provide additional context to an estimated bonus. + * Optional. Compensation description. For example, could indicate equity terms or provide additional context to an estimated bonus. */ description?: string; /** - * Optional. Expected number of units paid each year. If not specified, when Job.employment_types is FULLTIME, a default value is inferred based on unit. Default values: - HOURLY: 2080 - DAILY: 260 - WEEKLY: 52 - MONTHLY: 12 - ANNUAL: 1 + * Optional. Expected number of units paid each year. If not specified, when Job.employment_types is FULLTIME, a default value is inferred based on unit. Default values: - HOURLY: 2080 - DAILY: 260 - WEEKLY: 52 - MONTHLY: 12 - ANNUAL: 1 */ expectedUnitsPerYear?: number; /** - * Optional. Compensation range. + * Optional. Compensation range. */ range?: Schema$CompensationRange; /** - * Optional. Compensation type. Default is CompensationUnit.COMPENSATION_TYPE_UNSPECIFIED. + * Optional. Compensation type. Default is CompensationUnit.COMPENSATION_TYPE_UNSPECIFIED. */ type?: string; /** - * Optional. Frequency of the specified amount. Default is CompensationUnit.COMPENSATION_UNIT_UNSPECIFIED. + * Optional. Frequency of the specified amount. Default is CompensationUnit.COMPENSATION_UNIT_UNSPECIFIED. */ unit?: string; } @@ -340,19 +340,19 @@ export namespace jobs_v3 { */ export interface Schema$CompensationFilter { /** - * Optional. If set to true, jobs with unspecified compensation range fields are included. + * Optional. If set to true, jobs with unspecified compensation range fields are included. */ includeJobsWithUnspecifiedCompensationRange?: boolean; /** - * Optional. Compensation range. + * Optional. Compensation range. */ range?: Schema$CompensationRange; /** - * Required. Type of filter. + * Required. Type of filter. */ type?: string; /** - * Required. Specify desired `base compensation entry's` CompensationInfo.CompensationUnit. + * Required. Specify desired `base compensation entry's` CompensationInfo.CompensationUnit. */ units?: string[]; } @@ -361,11 +361,11 @@ export namespace jobs_v3 { */ export interface Schema$CompensationHistogramRequest { /** - * Required. Numeric histogram options, like buckets, whether include min or max value. + * Required. Numeric histogram options, like buckets, whether include min or max value. */ bucketingOption?: Schema$NumericBucketingOption; /** - * Required. Type of the request, representing which field the histogramming should be performed over. A single request can only specify one histogram of each `CompensationHistogramRequestType`. + * Required. Type of the request, representing which field the histogramming should be performed over. A single request can only specify one histogram of each `CompensationHistogramRequestType`. */ type?: string; } @@ -395,7 +395,7 @@ export namespace jobs_v3 { */ annualizedTotalCompensationRange?: Schema$CompensationRange; /** - * Optional. Job compensation information. At most one entry can be of type CompensationInfo.CompensationType.BASE, which is referred as ** base compensation entry ** for the job. + * Optional. Job compensation information. At most one entry can be of type CompensationInfo.CompensationType.BASE, which is referred as ** base compensation entry ** for the job. */ entries?: Schema$CompensationEntry[]; } @@ -404,11 +404,11 @@ export namespace jobs_v3 { */ export interface Schema$CompensationRange { /** - * Optional. The maximum amount of compensation. If left empty, the value is set to a maximal compensation value and the currency code is set to match the currency code of min_compensation. + * Optional. The maximum amount of compensation. If left empty, the value is set to a maximal compensation value and the currency code is set to match the currency code of min_compensation. */ maxCompensation?: Schema$Money; /** - * Optional. The minimum amount of compensation. If left empty, the value is set to zero and the currency code is set to match the currency code of max_compensation. + * Optional. The minimum amount of compensation. If left empty, the value is set to zero and the currency code is set to match the currency code of max_compensation. */ minCompensation?: Schema$Money; } @@ -447,7 +447,7 @@ export namespace jobs_v3 { */ export interface Schema$CreateClientEventRequest { /** - * Required. Events issued when end user interacts with customer's application that uses Cloud Talent Solution. + * Required. Events issued when end user interacts with customer's application that uses Cloud Talent Solution. */ clientEvent?: Schema$ClientEvent; } @@ -456,7 +456,7 @@ export namespace jobs_v3 { */ export interface Schema$CreateCompanyRequest { /** - * Required. The company to be created. + * Required. The company to be created. */ company?: Schema$Company; } @@ -465,7 +465,7 @@ export namespace jobs_v3 { */ export interface Schema$CreateJobRequest { /** - * Required. The Job to be created. + * Required. The Job to be created. */ job?: Schema$Job; } @@ -474,7 +474,7 @@ export namespace jobs_v3 { */ export interface Schema$CustomAttribute { /** - * Optional. If the `filterable` flag is true, custom field values are searchable. If false, values are not searchable. Default is false. + * Optional. If the `filterable` flag is true, custom field values are searchable. If false, values are not searchable. Default is false. */ filterable?: boolean; /** @@ -482,7 +482,7 @@ export namespace jobs_v3 { */ longValues?: string[]; /** - * Optional but exactly one of string_values or long_values must be specified. This field is used to perform a string match (`CASE_SENSITIVE_MATCH` or `CASE_INSENSITIVE_MATCH`) search. For filterable `string_value`s, a maximum total number of 200 values is allowed, with each `string_value` has a byte size of no more than 255B. For unfilterable `string_values`, the maximum total byte size of unfilterable `string_values` is 50KB. Empty string is not allowed. + * Optional but exactly one of string_values or long_values must be specified. This field is used to perform a string match (`CASE_SENSITIVE_MATCH` or `CASE_INSENSITIVE_MATCH`) search. For filterable `string_value`s, a maximum total number of 200 values is allowed, with each `string_value` has a byte size of no more than 500B. For unfilterable `string_values`, the maximum total byte size of unfilterable `string_values` is 50KB. Empty string is not allowed. */ stringValues?: string[]; } @@ -491,11 +491,11 @@ export namespace jobs_v3 { */ export interface Schema$CustomAttributeHistogramRequest { /** - * Required. Specifies the custom field key to perform a histogram on. If specified without `long_value_histogram_bucketing_option`, histogram on string values of the given `key` is triggered, otherwise histogram is performed on long values. + * Required. Specifies the custom field key to perform a histogram on. If specified without `long_value_histogram_bucketing_option`, histogram on string values of the given `key` is triggered, otherwise histogram is performed on long values. */ key?: string; /** - * Optional. Specifies buckets used to perform a range histogram on Job's filterable long custom field values, or min/max value requirements. + * Optional. Specifies buckets used to perform a range histogram on Job's filterable long custom field values, or min/max value requirements. */ longValueHistogramBucketingOption?: Schema$NumericBucketingOption; /** @@ -525,11 +525,11 @@ export namespace jobs_v3 { */ export interface Schema$DeviceInfo { /** - * Optional. Type of the device. + * Optional. Type of the device. */ deviceType?: string; /** - * Optional. A device-specific ID. The ID must be a unique identifier that distinguishes the device from other devices. + * Optional. A device-specific ID. The ID must be a unique identifier that distinguishes the device from other devices. */ id?: string; } @@ -542,15 +542,15 @@ export namespace jobs_v3 { */ export interface Schema$HistogramFacets { /** - * Optional. Specifies compensation field-based histogram requests. Duplicate values of CompensationHistogramRequest.type are not allowed. + * Optional. Specifies compensation field-based histogram requests. Duplicate values of CompensationHistogramRequest.type are not allowed. */ compensationHistogramFacets?: Schema$CompensationHistogramRequest[]; /** - * Optional. Specifies the custom attributes histogram requests. Duplicate values of CustomAttributeHistogramRequest.key are not allowed. + * Optional. Specifies the custom attributes histogram requests. Duplicate values of CustomAttributeHistogramRequest.key are not allowed. */ customAttributeHistogramFacets?: Schema$CustomAttributeHistogramRequest[]; /** - * Optional. Specifies the simple type of histogram facets, for example, `COMPANY_SIZE`, `EMPLOYMENT_TYPE` etc. + * Optional. Specifies the simple type of histogram facets, for example, `COMPANY_SIZE`, `EMPLOYMENT_TYPE` etc. */ simpleHistogramFacets?: string[]; } @@ -601,23 +601,23 @@ export namespace jobs_v3 { */ companyDisplayName?: string; /** - * Required. The resource name of the company listing the job, such as "projects/api-test-project/companies/foo". + * Required. The resource name of the company listing the job, such as "projects/api-test-project/companies/foo". */ companyName?: string; /** - * Optional. Job compensation information. + * Optional. Job compensation information. */ compensationInfo?: Schema$CompensationInfo; /** - * Optional. A map of fields to hold both filterable and non-filterable custom job attributes that are not covered by the provided structured fields. The keys of the map are strings up to 64 bytes and must match the pattern: a-zA-Z*. For example, key0LikeThis or KEY_1_LIKE_THIS. At most 100 filterable and at most 100 unfilterable keys are supported. For filterable `string_values`, across all keys at most 200 values are allowed, with each string no more than 255 characters. For unfilterable `string_values`, the maximum total size of `string_values` across all keys is 50KB. + * Optional. A map of fields to hold both filterable and non-filterable custom job attributes that are not covered by the provided structured fields. The keys of the map are strings up to 64 bytes and must match the pattern: a-zA-Z*. For example, key0LikeThis or KEY_1_LIKE_THIS. At most 100 filterable and at most 100 unfilterable keys are supported. For filterable `string_values`, across all keys at most 200 values are allowed, with each string no more than 255 characters. For unfilterable `string_values`, the maximum total size of `string_values` across all keys is 50KB. */ customAttributes?: {[key: string]: Schema$CustomAttribute}; /** - * Optional. The desired education degrees for the job, such as Bachelors, Masters. + * Optional. The desired education degrees for the job, such as Bachelors, Masters. */ degreeTypes?: string[]; /** - * Optional. The department or functional area within the company with the open position. The maximum number of allowed characters is 255. + * Optional. The department or functional area within the company with the open position. The maximum number of allowed characters is 255. */ department?: string; /** @@ -625,35 +625,35 @@ export namespace jobs_v3 { */ derivedInfo?: Schema$JobDerivedInfo; /** - * Required. The description of the job, which typically includes a multi-paragraph description of the company and related information. Separate fields are provided on the job object for responsibilities, qualifications, and other job characteristics. Use of these separate job fields is recommended. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 100,000. + * Required. The description of the job, which typically includes a multi-paragraph description of the company and related information. Separate fields are provided on the job object for responsibilities, qualifications, and other job characteristics. Use of these separate job fields is recommended. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 100,000. */ description?: string; /** - * Optional. The employment type(s) of a job, for example, full time or part time. + * Optional. The employment type(s) of a job, for example, full time or part time. */ employmentTypes?: string[]; /** - * Optional. A description of bonus, commission, and other compensation incentives associated with the job not including salary or pay. The maximum number of allowed characters is 10,000. + * Optional. A description of bonus, commission, and other compensation incentives associated with the job not including salary or pay. The maximum number of allowed characters is 10,000. */ incentives?: string; /** - * Optional. The benefits included with the job. + * Optional. The benefits included with the job. */ jobBenefits?: string[]; /** - * Optional. The end timestamp of the job. Typically this field is used for contracting engagements. Invalid timestamps are ignored. + * Optional. The end timestamp of the job. Typically this field is used for contracting engagements. Invalid timestamps are ignored. */ jobEndTime?: string; /** - * Optional. The experience level associated with the job, such as "Entry Level". + * Optional. The experience level associated with the job, such as "Entry Level". */ jobLevel?: string; /** - * Optional. The start timestamp of the job in UTC time zone. Typically this field is used for contracting engagements. Invalid timestamps are ignored. + * Optional. The start timestamp of the job in UTC time zone. Typically this field is used for contracting engagements. Invalid timestamps are ignored. */ jobStartTime?: string; /** - * Optional. The language of the posting. This field is distinct from any requirements for fluency that are associated with the job. Language codes must be in BCP-47 format, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47){: class="external" target="_blank" }. If this field is unspecified and Job.description is present, detected language code based on Job.description is assigned, otherwise defaults to 'en_US'. + * Optional. The language of the posting. This field is distinct from any requirements for fluency that are associated with the job. Language codes must be in BCP-47 format, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47){: class="external" target="_blank" }. If this field is unspecified and Job.description is present, detected language code based on Job.description is assigned, otherwise defaults to 'en_US'. */ languageCode?: string; /** @@ -669,11 +669,11 @@ export namespace jobs_v3 { */ postingExpireTime?: string; /** - * Optional. The timestamp this job posting was most recently published. The default value is the time the request arrives at the server. Invalid timestamps are ignored. + * Optional. The timestamp this job posting was most recently published. The default value is the time the request arrives at the server. Invalid timestamps are ignored. */ postingPublishTime?: string; /** - * Optional. The job PostingRegion (for example, state, country) throughout which the job is available. If this field is set, a LocationFilter in a search query within the job region finds this job posting if an exact location match isn't specified. If this field is set to PostingRegion.NATION or PostingRegion.ADMINISTRATIVE_AREA, setting job Job.addresses to the same location level as this field is strongly recommended. + * Optional. The job PostingRegion (for example, state, country) throughout which the job is available. If this field is set, a LocationFilter in a search query within the job region finds this job posting if an exact location match isn't specified. If this field is set to PostingRegion.NATION or PostingRegion.ADMINISTRATIVE_AREA, setting job Job.addresses to the same location level as this field is strongly recommended. */ postingRegion?: string; /** @@ -681,31 +681,31 @@ export namespace jobs_v3 { */ postingUpdateTime?: string; /** - * Optional. Options for job processing. + * Optional. Options for job processing. */ processingOptions?: Schema$ProcessingOptions; /** - * Optional. A promotion value of the job, as determined by the client. The value determines the sort order of the jobs returned when searching for jobs using the featured jobs search call, with higher promotional values being returned first and ties being resolved by relevance sort. Only the jobs with a promotionValue >0 are returned in a FEATURED_JOB_SEARCH. Default value is 0, and negative values are treated as 0. + * Optional. A promotion value of the job, as determined by the client. The value determines the sort order of the jobs returned when searching for jobs using the featured jobs search call, with higher promotional values being returned first and ties being resolved by relevance sort. Only the jobs with a promotionValue >0 are returned in a FEATURED_JOB_SEARCH. Default value is 0, and negative values are treated as 0. */ promotionValue?: number; /** - * Optional. A description of the qualifications required to perform the job. The use of this field is recommended as an alternative to using the more general description field. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 10,000. + * Optional. A description of the qualifications required to perform the job. The use of this field is recommended as an alternative to using the more general description field. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 10,000. */ qualifications?: string; /** - * Required. The requisition ID, also referred to as the posting ID, assigned by the client to identify a job. This field is intended to be used by clients for client identification and tracking of postings. A job is not allowed to be created if there is another job with the same [company_name], language_code and requisition_id. The maximum number of allowed characters is 255. + * Required. The requisition ID, also referred to as the posting ID, assigned by the client to identify a job. This field is intended to be used by clients for client identification and tracking of postings. A job is not allowed to be created if there is another job with the same [company_name], language_code and requisition_id. The maximum number of allowed characters is 255. */ requisitionId?: string; /** - * Optional. A description of job responsibilities. The use of this field is recommended as an alternative to using the more general description field. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 10,000. + * Optional. A description of job responsibilities. The use of this field is recommended as an alternative to using the more general description field. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 10,000. */ responsibilities?: string; /** - * Required. The title of the job, such as "Software Engineer" The maximum number of allowed characters is 500. + * Required. The title of the job, such as "Software Engineer" The maximum number of allowed characters is 500. */ title?: string; /** - * Optional. The visibility of the job. Defaults to Visibility.ACCOUNT_ONLY if not specified. + * Deprecated. The job is only visible to the owner. The visibility of the job. Defaults to Visibility.ACCOUNT_ONLY if not specified. */ visibility?: string; } @@ -727,11 +727,11 @@ export namespace jobs_v3 { */ export interface Schema$JobEvent { /** - * Required. The job name(s) associated with this event. For example, if this is an impression event, this field contains the identifiers of all jobs shown to the job seeker. If this was a view event, this field contains the identifier of the viewed job. + * Required. The job name(s) associated with this event. For example, if this is an impression event, this field contains the identifiers of all jobs shown to the job seeker. If this was a view event, this field contains the identifier of the viewed job. */ jobs?: string[]; /** - * Required. The type of the event (see JobEventType). + * Required. The type of the event (see JobEventType). */ type?: string; } @@ -740,51 +740,51 @@ export namespace jobs_v3 { */ export interface Schema$JobQuery { /** - * Optional. Allows filtering jobs by commute time with different travel methods (for example, driving or public transit). Note: This only works with COMMUTE MODE. When specified, [JobQuery.location_filters] is ignored. Currently we don't support sorting by commute time. + * Optional. Allows filtering jobs by commute time with different travel methods (for example, driving or public transit). Note: This only works with COMMUTE MODE. When specified, [JobQuery.location_filters] is ignored. Currently we don't support sorting by commute time. */ commuteFilter?: Schema$CommuteFilter; /** - * Optional. This filter specifies the exact company display name of the jobs to search against. If a value isn't specified, jobs within the search results are associated with any company. If multiple values are specified, jobs within the search results may be associated with any of the specified companies. At most 20 company display name filters are allowed. + * Optional. This filter specifies the exact company display name of the jobs to search against. If a value isn't specified, jobs within the search results are associated with any company. If multiple values are specified, jobs within the search results may be associated with any of the specified companies. At most 20 company display name filters are allowed. */ companyDisplayNames?: string[]; /** - * Optional. This filter specifies the company entities to search against. If a value isn't specified, jobs are searched for against all companies. If multiple values are specified, jobs are searched against the companies specified. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". At most 20 company filters are allowed. + * Optional. This filter specifies the company entities to search against. If a value isn't specified, jobs are searched for against all companies. If multiple values are specified, jobs are searched against the companies specified. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". At most 20 company filters are allowed. */ companyNames?: string[]; /** - * Optional. This search filter is applied only to Job.compensation_info. For example, if the filter is specified as "Hourly job with per-hour compensation > $15", only jobs meeting these criteria are searched. If a filter isn't defined, all open jobs are searched. + * Optional. This search filter is applied only to Job.compensation_info. For example, if the filter is specified as "Hourly job with per-hour compensation > $15", only jobs meeting these criteria are searched. If a filter isn't defined, all open jobs are searched. */ compensationFilter?: Schema$CompensationFilter; /** - * Optional. This filter specifies a structured syntax to match against the Job.custom_attributes marked as `filterable`. The syntax for this expression is a subset of SQL syntax. Supported operators are: `=`, `!=`, `<`, `<=`, `>`, and `>=` where the left of the operator is a custom field key and the right of the operator is a number or a quoted string. You must escape backslash (\\) and quote (\") characters. Supported functions are `LOWER([field_name])` to perform a case insensitive match and `EMPTY([field_name])` to filter on the existence of a key. Boolean expressions (AND/OR/NOT) are supported up to 3 levels of nesting (for example, "((A AND B AND C) OR NOT D) AND E"), a maximum of 100 comparisons or functions are allowed in the expression. The expression must be < 3000 bytes in length. Sample Query: `(LOWER(driving_license)="class \"a\"" OR EMPTY(driving_license)) AND driving_years > 10` + * Optional. This filter specifies a structured syntax to match against the Job.custom_attributes marked as `filterable`. The syntax for this expression is a subset of SQL syntax. Supported operators are: `=`, `!=`, `<`, `<=`, `>`, and `>=` where the left of the operator is a custom field key and the right of the operator is a number or a quoted string. You must escape backslash (\\) and quote (\") characters. Supported functions are `LOWER([field_name])` to perform a case insensitive match and `EMPTY([field_name])` to filter on the existence of a key. Boolean expressions (AND/OR/NOT) are supported up to 3 levels of nesting (for example, "((A AND B AND C) OR NOT D) AND E"), a maximum of 100 comparisons or functions are allowed in the expression. The expression must be < 6000 bytes in length. Sample Query: `(LOWER(driving_license)="class \"a\"" OR EMPTY(driving_license)) AND driving_years > 10` */ customAttributeFilter?: string; /** - * Optional. This flag controls the spell-check feature. If false, the service attempts to correct a misspelled query, for example, "enginee" is corrected to "engineer". Defaults to false: a spell check is performed. + * Optional. This flag controls the spell-check feature. If false, the service attempts to correct a misspelled query, for example, "enginee" is corrected to "engineer". Defaults to false: a spell check is performed. */ disableSpellCheck?: boolean; /** - * Optional. The employment type filter specifies the employment type of jobs to search against, such as EmploymentType.FULL_TIME. If a value is not specified, jobs in the search results includes any employment type. If multiple values are specified, jobs in the search results include any of the specified employment types. + * Optional. The employment type filter specifies the employment type of jobs to search against, such as EmploymentType.FULL_TIME. If a value is not specified, jobs in the search results includes any employment type. If multiple values are specified, jobs in the search results include any of the specified employment types. */ employmentTypes?: string[]; /** - * Optional. The category filter specifies the categories of jobs to search against. See Category for more information. If a value is not specified, jobs from any category are searched against. If multiple values are specified, jobs from any of the specified categories are searched against. + * Optional. The category filter specifies the categories of jobs to search against. See Category for more information. If a value is not specified, jobs from any category are searched against. If multiple values are specified, jobs from any of the specified categories are searched against. */ jobCategories?: string[]; /** - * Optional. This filter specifies the locale of jobs to search against, for example, "en-US". If a value isn't specified, the search results can contain jobs in any locale. Language codes should be in BCP-47 format, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). At most 10 language code filters are allowed. + * Optional. This filter specifies the locale of jobs to search against, for example, "en-US". If a value isn't specified, the search results can contain jobs in any locale. Language codes should be in BCP-47 format, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). At most 10 language code filters are allowed. */ languageCodes?: string[]; /** - * Optional. The location filter specifies geo-regions containing the jobs to search against. See LocationFilter for more information. If a location value isn't specified, jobs fitting the other search criteria are retrieved regardless of where they're located. If multiple values are specified, jobs are retrieved from any of the specified locations. If different values are specified for the LocationFilter.distance_in_miles parameter, the maximum provided distance is used for all locations. At most 5 location filters are allowed. + * Optional. The location filter specifies geo-regions containing the jobs to search against. See LocationFilter for more information. If a location value isn't specified, jobs fitting the other search criteria are retrieved regardless of where they're located. If multiple values are specified, jobs are retrieved from any of the specified locations. If different values are specified for the LocationFilter.distance_in_miles parameter, the maximum provided distance is used for all locations. At most 5 location filters are allowed. */ locationFilters?: Schema$LocationFilter[]; /** - * Optional. Jobs published within a range specified by this filter are searched against. + * Optional. Jobs published within a range specified by this filter are searched against. */ publishTimeRange?: Schema$TimestampRange; /** - * Optional. The query string that matches against the job title, description, and location fields. The maximum number of allowed characters is 255. + * Optional. The query string that matches against the job title, description, and location fields. The maximum number of allowed characters is 255. */ query?: string; } @@ -861,23 +861,23 @@ export namespace jobs_v3 { */ export interface Schema$LocationFilter { /** - * Optional. The address name, such as "Mountain View" or "Bay Area". + * Optional. The address name, such as "Mountain View" or "Bay Area". */ address?: string; /** - * Optional. The distance_in_miles is applied when the location being searched for is identified as a city or smaller. When the location being searched for is a state or larger, this field is ignored. + * Optional. The distance_in_miles is applied when the location being searched for is identified as a city or smaller. When the location being searched for is a state or larger, this field is ignored. */ distanceInMiles?: number; /** - * Optional. The latitude and longitude of the geographic center from which to search. This field's ignored if `address` is provided. + * Optional. The latitude and longitude of the geographic center from which to search. This field's ignored if `address` is provided. */ latLng?: Schema$LatLng; /** - * Optional. CLDR region code of the country/region of the address. This is used to address ambiguity of the user-input location, for example, "Liverpool" against "Liverpool, NY, US" or "Liverpool, UK". Set this field if all the jobs to search against are from a same region, or jobs are world-wide, but the job seeker is from a specific region. See http://cldr.unicode.org/ and http://www.unicode.org/cldr/charts/30/supplemental/territory_information.html for details. Example: "CH" for Switzerland. + * Optional. CLDR region code of the country/region of the address. This is used to address ambiguity of the user-input location, for example, "Liverpool" against "Liverpool, NY, US" or "Liverpool, UK". Set this field if all the jobs to search against are from a same region, or jobs are world-wide, but the job seeker is from a specific region. See http://cldr.unicode.org/ and http://www.unicode.org/cldr/charts/30/supplemental/territory_information.html for details. Example: "CH" for Switzerland. */ regionCode?: string; /** - * Optional. Allows the client to return jobs without a set location, specifically, telecommuting jobs (telecommuting is considered by the service as a special location. Job.posting_region indicates if a job permits telecommuting. If this field is set to TelecommutePreference.TELECOMMUTE_ALLOWED, telecommuting jobs are searched, and address and lat_lng are ignored. If not set or set to TelecommutePreference.TELECOMMUTE_EXCLUDED, telecommute job are not searched. This filter can be used by itself to search exclusively for telecommuting jobs, or it can be combined with another location filter to search for a combination of job locations, such as "Mountain View" or "telecommuting" jobs. However, when used in combination with other location filters, telecommuting jobs can be treated as less relevant than other jobs in the search response. + * Optional. Allows the client to return jobs without a set location, specifically, telecommuting jobs (telecommuting is considered by the service as a special location. Job.posting_region indicates if a job permits telecommuting. If this field is set to TelecommutePreference.TELECOMMUTE_ALLOWED, telecommuting jobs are searched, and address and lat_lng are ignored. If not set or set to TelecommutePreference.TELECOMMUTE_EXCLUDED, telecommute job are not searched. This filter can be used by itself to search exclusively for telecommuting jobs, or it can be combined with another location filter to search for a combination of job locations, such as "Mountain View" or "telecommuting" jobs. However, when used in combination with other location filters, telecommuting jobs can be treated as less relevant than other jobs in the search response. */ telecommutePreference?: string; } @@ -928,11 +928,11 @@ export namespace jobs_v3 { */ export interface Schema$NumericBucketingOption { /** - * Required. Two adjacent values form a histogram bucket. Values should be in ascending order. For example, if [5, 10, 15] are provided, four buckets are created: (-inf, 5), 5, 10), [10, 15), [15, inf). At most 20 [buckets_bound is supported. + * Required. Two adjacent values form a histogram bucket. Values should be in ascending order. For example, if [5, 10, 15] are provided, four buckets are created: (-inf, 5), 5, 10), [10, 15), [15, inf). At most 20 [buckets_bound is supported. */ bucketBounds?: number[]; /** - * Optional. If set to true, the histogram result includes minimum/maximum value of the numeric field. + * Optional. If set to true, the histogram result includes minimum/maximum value of the numeric field. */ requiresMinMax?: boolean; } @@ -954,7 +954,7 @@ export namespace jobs_v3 { minValue?: number; } /** - * Represents a postal address, e.g. for postal delivery or payments addresses. Given a postal address, a postal service can deliver items to a premise, P.O. Box or similar. It is not intended to model geographical locations (roads, towns, mountains). In typical usage an address would be created via user input or from importing existing data, depending on the type of process. Advice on address input / editing: - Use an i18n-ready address widget such as https://github.com/googlei18n/libaddressinput) - Users should not be presented with UI elements for input or editing of fields outside countries where that field is used. For more guidance on how to use this schema, please see: https://support.google.com/business/answer/6397478 + * Represents a postal address, e.g. for postal delivery or payments addresses. Given a postal address, a postal service can deliver items to a premise, P.O. Box or similar. It is not intended to model geographical locations (roads, towns, mountains). In typical usage an address would be created via user input or from importing existing data, depending on the type of process. Advice on address input / editing: - Use an i18n-ready address widget such as https://github.com/google/libaddressinput) - Users should not be presented with UI elements for input or editing of fields outside countries where that field is used. For more guidance on how to use this schema, please see: https://support.google.com/business/answer/6397478 */ export interface Schema$PostalAddress { /** @@ -1007,11 +1007,11 @@ export namespace jobs_v3 { */ export interface Schema$ProcessingOptions { /** - * Optional. If set to `true`, the service does not attempt to resolve a more precise address for the job. + * Optional. If set to `true`, the service does not attempt to resolve a more precise address for the job. */ disableStreetAddressResolution?: boolean; /** - * Optional. Option for job HTML content sanitization. Applied fields are: * description * applicationInfo.instruction * incentives * qualifications * responsibilities HTML tags in these fields may be stripped if sanitiazation is not disabled. Defaults to HtmlSanitization.SIMPLE_FORMATTING_ONLY. + * Optional. Option for job HTML content sanitization. Applied fields are: * description * applicationInfo.instruction * incentives * qualifications * responsibilities HTML tags in these fields may be stripped if sanitiazation is not disabled. Defaults to HtmlSanitization.SIMPLE_FORMATTING_ONLY. */ htmlSanitization?: string; } @@ -1020,19 +1020,19 @@ export namespace jobs_v3 { */ export interface Schema$RequestMetadata { /** - * Optional. The type of device used by the job seeker at the time of the call to the service. + * Optional. The type of device used by the job seeker at the time of the call to the service. */ deviceInfo?: Schema$DeviceInfo; /** - * Required. The client-defined scope or source of the service call, which typically is the domain on which the service has been implemented and is currently being run. For example, if the service is being run by client <em>Foo, Inc.</em>, on job board www.foo.com and career site www.bar.com, then this field is set to "foo.com" for use on the job board, and "bar.com" for use on the career site. If this field isn't available for some reason, send "UNKNOWN". Any improvements to the model for a particular tenant site rely on this field being set correctly to a domain. The maximum number of allowed characters is 255. + * Required. The client-defined scope or source of the service call, which typically is the domain on which the service has been implemented and is currently being run. For example, if the service is being run by client <em>Foo, Inc.</em>, on job board www.foo.com and career site www.bar.com, then this field is set to "foo.com" for use on the job board, and "bar.com" for use on the career site. If this field isn't available for some reason, send "UNKNOWN". Any improvements to the model for a particular tenant site rely on this field being set correctly to a domain. The maximum number of allowed characters is 255. */ domain?: string; /** - * Required. A unique session identification string. A session is defined as the duration of an end user's interaction with the service over a certain period. Obfuscate this field for privacy concerns before providing it to the service. If this field is not available for some reason, send "UNKNOWN". Note that any improvements to the model for a particular tenant site, rely on this field being set correctly to some unique session_id. The maximum number of allowed characters is 255. + * Required. A unique session identification string. A session is defined as the duration of an end user's interaction with the service over a certain period. Obfuscate this field for privacy concerns before providing it to the service. If this field is not available for some reason, send "UNKNOWN". Note that any improvements to the model for a particular tenant site, rely on this field being set correctly to some unique session_id. The maximum number of allowed characters is 255. */ sessionId?: string; /** - * Required. A unique user identification string, as determined by the client. To have the strongest positive impact on search quality make sure the client-level is unique. Obfuscate this field for privacy concerns before providing it to the service. If this field is not available for some reason, send "UNKNOWN". Note that any improvements to the model for a particular tenant site, rely on this field being set correctly to a unique user_id. The maximum number of allowed characters is 255. + * Required. A unique user identification string, as determined by the client. To have the strongest positive impact on search quality make sure the client-level is unique. Obfuscate this field for privacy concerns before providing it to the service. If this field is not available for some reason, send "UNKNOWN". Note that any improvements to the model for a particular tenant site, rely on this field being set correctly to a unique user_id. The maximum number of allowed characters is 255. */ userId?: string; } @@ -1050,55 +1050,55 @@ export namespace jobs_v3 { */ export interface Schema$SearchJobsRequest { /** - * Optional. Controls whether to disable exact keyword match on Job.job_title, Job.description, Job.company_display_name, Job.locations, Job.qualifications. When disable keyword match is turned off, a keyword match returns jobs that do not match given category filters when there are matching keywords. For example, the query "program manager," a result is returned even if the job posting has the title "software developer," which does not fall into "program manager" ontology, but does have "program manager" appearing in its description. For queries like "cloud" that does not contain title or location specific ontology, jobs with "cloud" keyword matches are returned regardless of this flag's value. Please use Company.keyword_searchable_custom_fields or Company.keyword_searchable_custom_attributes if company specific globally matched custom field/attribute string values is needed. Enabling keyword match improves recall of subsequent search requests. Defaults to false. + * Optional. Controls whether to disable exact keyword match on Job.job_title, Job.description, Job.company_display_name, Job.locations, Job.qualifications. When disable keyword match is turned off, a keyword match returns jobs that do not match given category filters when there are matching keywords. For example, the query "program manager," a result is returned even if the job posting has the title "software developer," which does not fall into "program manager" ontology, but does have "program manager" appearing in its description. For queries like "cloud" that does not contain title or location specific ontology, jobs with "cloud" keyword matches are returned regardless of this flag's value. Please use Company.keyword_searchable_custom_fields or Company.keyword_searchable_custom_attributes if company specific globally matched custom field/attribute string values is needed. Enabling keyword match improves recall of subsequent search requests. Defaults to false. */ disableKeywordMatch?: boolean; /** - * Optional. Controls whether highly similar jobs are returned next to each other in the search results. Jobs are identified as highly similar based on their titles, job categories, and locations. Highly similar results are clustered so that only one representative job of the cluster is displayed to the job seeker higher up in the results, with the other jobs being displayed lower down in the results. Defaults to DiversificationLevel.SIMPLE if no value is specified. + * Optional. Controls whether highly similar jobs are returned next to each other in the search results. Jobs are identified as highly similar based on their titles, job categories, and locations. Highly similar results are clustered so that only one representative job of the cluster is displayed to the job seeker higher up in the results, with the other jobs being displayed lower down in the results. Defaults to DiversificationLevel.SIMPLE if no value is specified. */ diversificationLevel?: string; /** - * Optional. Controls whether to broaden the search when it produces sparse results. Broadened queries append results to the end of the matching results list. Defaults to false. + * Optional. Controls whether to broaden the search when it produces sparse results. Broadened queries append results to the end of the matching results list. Defaults to false. */ enableBroadening?: boolean; /** - * Optional. Histogram requests for jobs matching JobQuery. + * Optional. Histogram requests for jobs matching JobQuery. */ histogramFacets?: Schema$HistogramFacets; /** - * Optional. Query used to search against jobs, such as keyword, location filters, etc. + * Optional. Query used to search against jobs, such as keyword, location filters, etc. */ jobQuery?: Schema$JobQuery; /** - * Optional. The desired job attributes returned for jobs in the search response. Defaults to JobView.SMALL if no value is specified. + * Optional. The desired job attributes returned for jobs in the search response. Defaults to JobView.SMALL if no value is specified. */ jobView?: string; /** - * Optional. An integer that specifies the current offset (that is, starting result location, amongst the jobs deemed by the API as relevant) in search results. This field is only considered if page_token is unset. For example, 0 means to return results starting from the first matching job, and 10 means to return from the 11th job. This can be used for pagination, (for example, pageSize = 10 and offset = 10 means to return from the second page). + * Optional. An integer that specifies the current offset (that is, starting result location, amongst the jobs deemed by the API as relevant) in search results. This field is only considered if page_token is unset. For example, 0 means to return results starting from the first matching job, and 10 means to return from the 11th job. This can be used for pagination, (for example, pageSize = 10 and offset = 10 means to return from the second page). */ offset?: number; /** - * Optional. The criteria determining how search results are sorted. Default is "relevance desc". Supported options are: * `"relevance desc"`: By relevance descending, as determined by the API algorithms. Relevance thresholding of query results is only available with this ordering. * `"posting_publish_time desc"`: By Job.posting_publish_time descending. * `"posting_update_time desc"`: By Job.posting_update_time descending. * `"title"`: By Job.title ascending. * `"title desc"`: By Job.title descending. * `"annualized_base_compensation"`: By job's CompensationInfo.annualized_base_compensation_range ascending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"annualized_base_compensation desc"`: By job's CompensationInfo.annualized_base_compensation_range descending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"annualized_total_compensation"`: By job's CompensationInfo.annualized_total_compensation_range ascending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"annualized_total_compensation desc"`: By job's CompensationInfo.annualized_total_compensation_range descending. Jobs whose annualized base compensation is unspecified are put at the end of search results. + * Optional. The criteria determining how search results are sorted. Default is "relevance desc". Supported options are: * `"relevance desc"`: By relevance descending, as determined by the API algorithms. Relevance thresholding of query results is only available with this ordering. * `"posting_publish_time desc"`: By Job.posting_publish_time descending. * `"posting_update_time desc"`: By Job.posting_update_time descending. * `"title"`: By Job.title ascending. * `"title desc"`: By Job.title descending. * `"annualized_base_compensation"`: By job's CompensationInfo.annualized_base_compensation_range ascending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"annualized_base_compensation desc"`: By job's CompensationInfo.annualized_base_compensation_range descending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"annualized_total_compensation"`: By job's CompensationInfo.annualized_total_compensation_range ascending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"annualized_total_compensation desc"`: By job's CompensationInfo.annualized_total_compensation_range descending. Jobs whose annualized base compensation is unspecified are put at the end of search results. */ orderBy?: string; /** - * Optional. A limit on the number of jobs returned in the search results. Increasing this value above the default value of 10 can increase search response time. The value can be between 1 and 100. + * Optional. A limit on the number of jobs returned in the search results. Increasing this value above the default value of 10 can increase search response time. The value can be between 1 and 100. */ pageSize?: number; /** - * Optional. The token specifying the current offset within search results. See SearchJobsResponse.next_page_token for an explanation of how to obtain the next set of query results. + * Optional. The token specifying the current offset within search results. See SearchJobsResponse.next_page_token for an explanation of how to obtain the next set of query results. */ pageToken?: string; /** - * Required. The meta information collected about the job searcher, used to improve the search quality of the service. The identifiers (such as `user_id`) are provided by users, and must be unique and consistent. + * Required. The meta information collected about the job searcher, used to improve the search quality of the service. The identifiers (such as `user_id`) are provided by users, and must be unique and consistent. */ requestMetadata?: Schema$RequestMetadata; /** - * Optional. Controls if the search job request requires the return of a precise count of the first 300 results. Setting this to `true` ensures consistency in the number of results per page. Best practice is to set this value to true if a client allows users to jump directly to a non-sequential search results page. Enabling this flag may adversely impact performance. Defaults to false. + * Optional. Controls if the search job request requires the return of a precise count of the first 300 results. Setting this to `true` ensures consistency in the number of results per page. Best practice is to set this value to true if a client allows users to jump directly to a non-sequential search results page. Enabling this flag may adversely impact performance. Defaults to false. */ requirePreciseResultSize?: boolean; /** - * Optional. Mode of a search. Defaults to SearchMode.JOB_SEARCH. + * Optional. Mode of a search. Defaults to SearchMode.JOB_SEARCH. */ searchMode?: string; } @@ -1195,7 +1195,7 @@ export namespace jobs_v3 { */ export interface Schema$UpdateCompanyRequest { /** - * Required. The company resource to replace the current resource in the system. + * Required. The company resource to replace the current resource in the system. */ company?: Schema$Company; /** @@ -1208,7 +1208,7 @@ export namespace jobs_v3 { */ export interface Schema$UpdateJobRequest { /** - * Required. The Job to be updated. + * Required. The Job to be updated. */ job?: Schema$Job; /** @@ -1236,14 +1236,14 @@ export namespace jobs_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.companyName Optional. If provided, restricts completion to specified company. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". + * @param {string=} params.companyName Optional. If provided, restricts completion to specified company. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". * @param {string=} params.languageCode Deprecated. Use language_codes instead. Optional. The language of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with the same language_code are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with the same language_code are returned. For CompletionType.COMBINED type, only open jobs with the same language_code or companies having open jobs with the same language_code are returned. The maximum number of allowed characters is 255. - * @param {string=} params.languageCodes Optional. The list of languages of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with the same language_codes are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with the same language_codes are returned. For CompletionType.COMBINED type, only open jobs with the same language_codes or companies having open jobs with the same language_codes are returned. The maximum number of allowed characters is 255. - * @param {string} params.name Required. Resource name of project the completion is performed within. The format is "projects/{project_id}", for example, "projects/api-test-project". - * @param {integer=} params.pageSize Required. Completion result count. The maximum allowed page size is 10. - * @param {string=} params.query Required. The query used to generate suggestions. The maximum number of allowed characters is 255. - * @param {string=} params.scope Optional. The scope of the completion. The defaults is CompletionScope.PUBLIC. - * @param {string=} params.type Optional. The completion topic. The default is CompletionType.COMBINED. + * @param {string=} params.languageCodes Optional. The list of languages of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with the same language_codes are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with the same language_codes are returned. For CompletionType.COMBINED type, only open jobs with the same language_codes or companies having open jobs with the same language_codes are returned. The maximum number of allowed characters is 255. + * @param {string} params.name Required. Resource name of project the completion is performed within. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {integer=} params.pageSize Required. Completion result count. The maximum allowed page size is 10. + * @param {string=} params.query Required. The query used to generate suggestions. The maximum number of allowed characters is 255. + * @param {string=} params.scope Optional. The scope of the completion. The defaults is CompletionScope.PUBLIC. + * @param {string=} params.type Optional. The completion topic. The default is CompletionType.COMBINED. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1323,7 +1323,7 @@ export namespace jobs_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. If provided, restricts completion to specified company. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". + * Optional. If provided, restricts completion to specified company. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". */ companyName?: string; /** @@ -1331,27 +1331,27 @@ export namespace jobs_v3 { */ languageCode?: string; /** - * Optional. The list of languages of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with the same language_codes are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with the same language_codes are returned. For CompletionType.COMBINED type, only open jobs with the same language_codes or companies having open jobs with the same language_codes are returned. The maximum number of allowed characters is 255. + * Optional. The list of languages of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with the same language_codes are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with the same language_codes are returned. For CompletionType.COMBINED type, only open jobs with the same language_codes or companies having open jobs with the same language_codes are returned. The maximum number of allowed characters is 255. */ languageCodes?: string[]; /** - * Required. Resource name of project the completion is performed within. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. Resource name of project the completion is performed within. The format is "projects/{project_id}", for example, "projects/api-test-project". */ name?: string; /** - * Required. Completion result count. The maximum allowed page size is 10. + * Required. Completion result count. The maximum allowed page size is 10. */ pageSize?: number; /** - * Required. The query used to generate suggestions. The maximum number of allowed characters is 255. + * Required. The query used to generate suggestions. The maximum number of allowed characters is 255. */ query?: string; /** - * Optional. The scope of the completion. The defaults is CompletionScope.PUBLIC. + * Optional. The scope of the completion. The defaults is CompletionScope.PUBLIC. */ scope?: string; /** - * Optional. The completion topic. The default is CompletionType.COMBINED. + * Optional. The completion topic. The default is CompletionType.COMBINED. */ type?: string; } @@ -1469,7 +1469,7 @@ export namespace jobs_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {string} params.parent Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". * @param {().CreateCompanyRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1542,7 +1542,7 @@ export namespace jobs_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the company to be deleted. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". + * @param {string} params.name Required. The resource name of the company to be deleted. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1611,7 +1611,7 @@ export namespace jobs_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the company to be retrieved. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". + * @param {string} params.name Required. The resource name of the company to be retrieved. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1680,10 +1680,10 @@ export namespace jobs_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.pageSize Optional. The maximum number of companies to be returned, at most 100. Default is 100 if a non-positive number is provided. - * @param {string=} params.pageToken Optional. The starting indicator from which to return results. - * @param {string} params.parent Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". - * @param {boolean=} params.requireOpenJobs Optional. Set to true if the companies requested must have open jobs. Defaults to false. If true, at most page_size of companies are fetched, among which only those with open jobs are returned. + * @param {integer=} params.pageSize Optional. The maximum number of companies to be returned, at most 100. Default is 100 if a non-positive number is provided. + * @param {string=} params.pageToken Optional. The starting indicator from which to return results. + * @param {string} params.parent Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {boolean=} params.requireOpenJobs Optional. Set to true if the companies requested must have open jobs. Defaults to false. If true, at most page_size of companies are fetched, among which only those with open jobs are returned. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1831,7 +1831,7 @@ export namespace jobs_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; @@ -1848,7 +1848,7 @@ export namespace jobs_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the company to be deleted. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". + * Required. The resource name of the company to be deleted. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". */ name?: string; } @@ -1860,7 +1860,7 @@ export namespace jobs_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the company to be retrieved. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". + * Required. The resource name of the company to be retrieved. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". */ name?: string; } @@ -1872,19 +1872,19 @@ export namespace jobs_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The maximum number of companies to be returned, at most 100. Default is 100 if a non-positive number is provided. + * Optional. The maximum number of companies to be returned, at most 100. Default is 100 if a non-positive number is provided. */ pageSize?: number; /** - * Optional. The starting indicator from which to return results. + * Optional. The starting indicator from which to return results. */ pageToken?: string; /** - * Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; /** - * Optional. Set to true if the companies requested must have open jobs. Defaults to false. If true, at most page_size of companies are fetched, among which only those with open jobs are returned. + * Optional. Set to true if the companies requested must have open jobs. Defaults to false. If true, at most page_size of companies are fetched, among which only those with open jobs are returned. */ requireOpenJobs?: boolean; } @@ -1919,7 +1919,7 @@ export namespace jobs_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {string} params.parent Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". * @param {().BatchDeleteJobsRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1992,7 +1992,7 @@ export namespace jobs_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {string} params.parent Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". * @param {().CreateJobRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2062,7 +2062,7 @@ export namespace jobs_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the job to be deleted. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". + * @param {string} params.name Required. The resource name of the job to be deleted. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2131,7 +2131,7 @@ export namespace jobs_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the job to retrieve. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". + * @param {string} params.name Required. The resource name of the job to retrieve. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2200,11 +2200,11 @@ export namespace jobs_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.filter Required. The filter string specifies the jobs to be enumerated. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Optional) Sample Query: * companyName = "projects/api-test-project/companies/123" * companyName = "projects/api-test-project/companies/123" AND requisitionId = "req-1" - * @param {string=} params.jobView Optional. The desired job attributes returned for jobs in the search response. Defaults to JobView.JOB_VIEW_FULL if no value is specified. - * @param {integer=} params.pageSize Optional. The maximum number of jobs to be returned per page of results. If job_view is set to JobView.JOB_VIEW_ID_ONLY, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. - * @param {string=} params.pageToken Optional. The starting point of a query result. - * @param {string} params.parent Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {string=} params.filter Required. The filter string specifies the jobs to be enumerated. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Optional) Sample Query: * companyName = "projects/api-test-project/companies/123" * companyName = "projects/api-test-project/companies/123" AND requisitionId = "req-1" + * @param {string=} params.jobView Optional. The desired job attributes returned for jobs in the search response. Defaults to JobView.JOB_VIEW_FULL if no value is specified. + * @param {integer=} params.pageSize Optional. The maximum number of jobs to be returned per page of results. If job_view is set to JobView.JOB_VIEW_ID_ONLY, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. + * @param {string=} params.pageToken Optional. The starting point of a query result. + * @param {string} params.parent Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2345,7 +2345,7 @@ export namespace jobs_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {string} params.parent Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". * @param {().SearchJobsRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2420,7 +2420,7 @@ export namespace jobs_v3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {string} params.parent Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". * @param {().SearchJobsRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2499,7 +2499,7 @@ export namespace jobs_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; @@ -2516,7 +2516,7 @@ export namespace jobs_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; @@ -2533,7 +2533,7 @@ export namespace jobs_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the job to be deleted. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". + * Required. The resource name of the job to be deleted. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". */ name?: string; } @@ -2545,7 +2545,7 @@ export namespace jobs_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the job to retrieve. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". + * Required. The resource name of the job to retrieve. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". */ name?: string; } @@ -2557,23 +2557,23 @@ export namespace jobs_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The filter string specifies the jobs to be enumerated. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Optional) Sample Query: * companyName = "projects/api-test-project/companies/123" * companyName = "projects/api-test-project/companies/123" AND requisitionId = "req-1" + * Required. The filter string specifies the jobs to be enumerated. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Optional) Sample Query: * companyName = "projects/api-test-project/companies/123" * companyName = "projects/api-test-project/companies/123" AND requisitionId = "req-1" */ filter?: string; /** - * Optional. The desired job attributes returned for jobs in the search response. Defaults to JobView.JOB_VIEW_FULL if no value is specified. + * Optional. The desired job attributes returned for jobs in the search response. Defaults to JobView.JOB_VIEW_FULL if no value is specified. */ jobView?: string; /** - * Optional. The maximum number of jobs to be returned per page of results. If job_view is set to JobView.JOB_VIEW_ID_ONLY, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. + * Optional. The maximum number of jobs to be returned per page of results. If job_view is set to JobView.JOB_VIEW_ID_ONLY, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. */ pageSize?: number; /** - * Optional. The starting point of a query result. + * Optional. The starting point of a query result. */ pageToken?: string; /** - * Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; } @@ -2602,7 +2602,7 @@ export namespace jobs_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; @@ -2619,7 +2619,7 @@ export namespace jobs_v3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; diff --git a/src/apis/jobs/v3p1beta1.ts b/src/apis/jobs/v3p1beta1.ts index 2de4211f56c..4ee849a38d5 100644 --- a/src/apis/jobs/v3p1beta1.ts +++ b/src/apis/jobs/v3p1beta1.ts @@ -139,7 +139,7 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$BatchDeleteJobsRequest { /** - * Required. The filter string specifies the jobs to be deleted. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Required) Sample Query: companyName = "projects/api-test-project/companies/123" AND requisitionId = "req-1" + * Required. The filter string specifies the jobs to be deleted. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Required) Sample Query: companyName = "projects/api-test-project/companies/123" AND requisitionId = "req-1" */ filter?: string; } @@ -174,15 +174,15 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$ClientEvent { /** - * Required. The timestamp of the event. + * Required. The timestamp of the event. */ createTime?: string; /** - * Required. A unique identifier, generated by the client application. This `event_id` is used to establish the relationship between different events (see parent_event_id). + * Required. A unique identifier, generated by the client application. This `event_id` is used to establish the relationship between different events (see parent_event_id). */ eventId?: string; /** - * Optional. Extra information about this event. Used for storing information with no matching field in event payload, for example, user application specific context or details. At most 20 keys are supported. The maximum total size of all keys and values is 2 KB. + * Optional. Extra information about this event. Used for storing information with no matching field in event payload, for example, user application specific context or details. At most 20 keys are supported. The maximum total size of all keys and values is 2 KB. */ extraInfo?: {[key: string]: string}; /** @@ -190,11 +190,11 @@ export namespace jobs_v3p1beta1 { */ jobEvent?: Schema$JobEvent; /** - * Optional. The event_id of an event that resulted in the current event. For example, a Job view event usually follows a parent impression event: A job seeker first does a search where a list of jobs appears (impression). The job seeker then selects a result and views the description of a particular job (Job view). + * Optional. The event_id of an event that resulted in the current event. For example, a Job view event usually follows a parent impression event: A job seeker first does a search where a list of jobs appears (impression). The job seeker then selects a result and views the description of a particular job (Job view). */ parentEventId?: string; /** - * Required. A unique ID generated in the API responses. It can be found in ResponseMetadata.request_id. + * Required. A unique ID generated in the API responses. It can be found in ResponseMetadata.request_id. */ requestId?: string; } @@ -207,23 +207,23 @@ export namespace jobs_v3p1beta1 { */ allowImpreciseAddresses?: boolean; /** - * Required. The method of transportation for which to calculate the commute time. + * Required. The method of transportation for which to calculate the commute time. */ commuteMethod?: string; /** - * Optional. The departure time used to calculate traffic impact, represented as google.type.TimeOfDay in local time zone. Currently traffic model is restricted to hour level resolution. + * Optional. The departure time used to calculate traffic impact, represented as google.type.TimeOfDay in local time zone. Currently traffic model is restricted to hour level resolution. */ departureTime?: Schema$TimeOfDay; /** - * Optional. Specifies the traffic density to use when calculating commute time. + * Optional. Specifies the traffic density to use when calculating commute time. */ roadTraffic?: string; /** - * Required. The latitude and longitude of the location from which to calculate the commute time. + * Required. The latitude and longitude of the location from which to calculate the commute time. */ startCoordinates?: Schema$LatLng; /** - * Required. The maximum travel time in seconds. The maximum allowed value is `3600s` (one hour). Format is `123s`. + * Required. The maximum travel time in seconds. The maximum allowed value is `3600s` (one hour). Format is `123s`. */ travelDuration?: string; } @@ -245,7 +245,7 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$Company { /** - * Optional. The URI to employer's career site or careers page on the employer's web site, for example, "https://careers.google.com". + * Optional. The URI to employer's career site or careers page on the employer's web site, for example, "https://careers.google.com". */ careerSiteUri?: string; /** @@ -253,31 +253,31 @@ export namespace jobs_v3p1beta1 { */ derivedInfo?: Schema$CompanyDerivedInfo; /** - * Required. The display name of the company, for example, "Google, LLC". + * Required. The display name of the company, for example, "Google LLC". */ displayName?: string; /** - * Optional. Equal Employment Opportunity legal disclaimer text to be associated with all jobs, and typically to be displayed in all roles. The maximum number of allowed characters is 500. + * Optional. Equal Employment Opportunity legal disclaimer text to be associated with all jobs, and typically to be displayed in all roles. The maximum number of allowed characters is 500. */ eeoText?: string; /** - * Required. Client side company identifier, used to uniquely identify the company. The maximum number of allowed characters is 255. + * Required. Client side company identifier, used to uniquely identify the company. The maximum number of allowed characters is 255. */ externalId?: string; /** - * Optional. The street address of the company's main headquarters, which may be different from the job location. The service attempts to geolocate the provided address, and populates a more specific location wherever possible in DerivedInfo.headquarters_location. + * Optional. The street address of the company's main headquarters, which may be different from the job location. The service attempts to geolocate the provided address, and populates a more specific location wherever possible in DerivedInfo.headquarters_location. */ headquartersAddress?: string; /** - * Optional. Set to true if it is the hiring agency that post jobs for other employers. Defaults to false if not provided. + * Optional. Set to true if it is the hiring agency that post jobs for other employers. Defaults to false if not provided. */ hiringAgency?: boolean; /** - * Optional. A URI that hosts the employer's company logo. + * Optional. A URI that hosts the employer's company logo. */ imageUri?: string; /** - * Optional. A list of keys of filterable Job.custom_attributes, whose corresponding `string_values` are used in keyword search. Jobs with `string_values` under these specified field keys are returned if any of the values matches the search keyword. Custom field values with parenthesis, brackets and special symbols won't be properly searchable, and those keyword queries need to be surrounded by quotes. + * Optional. A list of keys of filterable Job.custom_attributes, whose corresponding `string_values` are used in keyword search. Jobs with `string_values` under these specified field keys are returned if any of the values matches the search keyword. Custom field values with parenthesis, brackets and special symbols won't be properly searchable, and those keyword queries need to be surrounded by quotes. */ keywordSearchableJobCustomAttributes?: string[]; /** @@ -285,7 +285,7 @@ export namespace jobs_v3p1beta1 { */ name?: string; /** - * Optional. The employer's company size. + * Optional. The employer's company size. */ size?: string; /** @@ -293,7 +293,7 @@ export namespace jobs_v3p1beta1 { */ suspended?: boolean; /** - * Optional. The URI representing the company's primary web site or home page, for example, "https://www.google.com". The maximum number of allowed characters is 255. + * Optional. The URI representing the company's primary web site or home page, for example, "https://www.google.com". The maximum number of allowed characters is 255. */ websiteUri?: string; } @@ -311,27 +311,27 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$CompensationEntry { /** - * Optional. Compensation amount. + * Optional. Compensation amount. */ amount?: Schema$Money; /** - * Optional. Compensation description. For example, could indicate equity terms or provide additional context to an estimated bonus. + * Optional. Compensation description. For example, could indicate equity terms or provide additional context to an estimated bonus. */ description?: string; /** - * Optional. Expected number of units paid each year. If not specified, when Job.employment_types is FULLTIME, a default value is inferred based on unit. Default values: - HOURLY: 2080 - DAILY: 260 - WEEKLY: 52 - MONTHLY: 12 - ANNUAL: 1 + * Optional. Expected number of units paid each year. If not specified, when Job.employment_types is FULLTIME, a default value is inferred based on unit. Default values: - HOURLY: 2080 - DAILY: 260 - WEEKLY: 52 - MONTHLY: 12 - ANNUAL: 1 */ expectedUnitsPerYear?: number; /** - * Optional. Compensation range. + * Optional. Compensation range. */ range?: Schema$CompensationRange; /** - * Optional. Compensation type. Default is CompensationUnit.COMPENSATION_TYPE_UNSPECIFIED. + * Optional. Compensation type. Default is CompensationUnit.COMPENSATION_TYPE_UNSPECIFIED. */ type?: string; /** - * Optional. Frequency of the specified amount. Default is CompensationUnit.COMPENSATION_UNIT_UNSPECIFIED. + * Optional. Frequency of the specified amount. Default is CompensationUnit.COMPENSATION_UNIT_UNSPECIFIED. */ unit?: string; } @@ -340,19 +340,19 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$CompensationFilter { /** - * Optional. If set to true, jobs with unspecified compensation range fields are included. + * Optional. If set to true, jobs with unspecified compensation range fields are included. */ includeJobsWithUnspecifiedCompensationRange?: boolean; /** - * Optional. Compensation range. + * Optional. Compensation range. */ range?: Schema$CompensationRange; /** - * Required. Type of filter. + * Required. Type of filter. */ type?: string; /** - * Required. Specify desired `base compensation entry's` CompensationInfo.CompensationUnit. + * Required. Specify desired `base compensation entry's` CompensationInfo.CompensationUnit. */ units?: string[]; } @@ -361,11 +361,11 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$CompensationHistogramRequest { /** - * Required. Numeric histogram options, like buckets, whether include min or max value. + * Required. Numeric histogram options, like buckets, whether include min or max value. */ bucketingOption?: Schema$NumericBucketingOption; /** - * Required. Type of the request, representing which field the histogramming should be performed over. A single request can only specify one histogram of each `CompensationHistogramRequestType`. + * Required. Type of the request, representing which field the histogramming should be performed over. A single request can only specify one histogram of each `CompensationHistogramRequestType`. */ type?: string; } @@ -395,7 +395,7 @@ export namespace jobs_v3p1beta1 { */ annualizedTotalCompensationRange?: Schema$CompensationRange; /** - * Optional. Job compensation information. At most one entry can be of type CompensationInfo.CompensationType.BASE, which is referred as ** base compensation entry ** for the job. + * Optional. Job compensation information. At most one entry can be of type CompensationInfo.CompensationType.BASE, which is referred as ** base compensation entry ** for the job. */ entries?: Schema$CompensationEntry[]; } @@ -404,11 +404,11 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$CompensationRange { /** - * Optional. The maximum amount of compensation. If left empty, the value is set to a maximal compensation value and the currency code is set to match the currency code of min_compensation. + * Optional. The maximum amount of compensation. If left empty, the value is set to a maximal compensation value and the currency code is set to match the currency code of min_compensation. */ maxCompensation?: Schema$Money; /** - * Optional. The minimum amount of compensation. If left empty, the value is set to zero and the currency code is set to match the currency code of max_compensation. + * Optional. The minimum amount of compensation. If left empty, the value is set to zero and the currency code is set to match the currency code of max_compensation. */ minCompensation?: Schema$Money; } @@ -447,7 +447,7 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$CreateClientEventRequest { /** - * Required. Events issued when end user interacts with customer's application that uses Cloud Talent Solution. + * Required. Events issued when end user interacts with customer's application that uses Cloud Talent Solution. */ clientEvent?: Schema$ClientEvent; } @@ -456,7 +456,7 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$CreateCompanyRequest { /** - * Required. The company to be created. + * Required. The company to be created. */ company?: Schema$Company; } @@ -465,7 +465,7 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$CreateJobRequest { /** - * Required. The Job to be created. + * Required. The Job to be created. */ job?: Schema$Job; } @@ -474,7 +474,7 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$CustomAttribute { /** - * Optional. If the `filterable` flag is true, custom field values are searchable. If false, values are not searchable. Default is false. + * Optional. If the `filterable` flag is true, custom field values are searchable. If false, values are not searchable. Default is false. */ filterable?: boolean; /** @@ -482,7 +482,7 @@ export namespace jobs_v3p1beta1 { */ longValues?: string[]; /** - * Optional but exactly one of string_values or long_values must be specified. This field is used to perform a string match (`CASE_SENSITIVE_MATCH` or `CASE_INSENSITIVE_MATCH`) search. For filterable `string_value`s, a maximum total number of 200 values is allowed, with each `string_value` has a byte size of no more than 255B. For unfilterable `string_values`, the maximum total byte size of unfilterable `string_values` is 50KB. Empty string is not allowed. + * Optional but exactly one of string_values or long_values must be specified. This field is used to perform a string match (`CASE_SENSITIVE_MATCH` or `CASE_INSENSITIVE_MATCH`) search. For filterable `string_value`s, a maximum total number of 200 values is allowed, with each `string_value` has a byte size of no more than 500B. For unfilterable `string_values`, the maximum total byte size of unfilterable `string_values` is 50KB. Empty string is not allowed. */ stringValues?: string[]; } @@ -491,11 +491,11 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$CustomAttributeHistogramRequest { /** - * Required. Specifies the custom field key to perform a histogram on. If specified without `long_value_histogram_bucketing_option`, histogram on string values of the given `key` is triggered, otherwise histogram is performed on long values. + * Required. Specifies the custom field key to perform a histogram on. If specified without `long_value_histogram_bucketing_option`, histogram on string values of the given `key` is triggered, otherwise histogram is performed on long values. */ key?: string; /** - * Optional. Specifies buckets used to perform a range histogram on Job's filterable long custom field values, or min/max value requirements. + * Optional. Specifies buckets used to perform a range histogram on Job's filterable long custom field values, or min/max value requirements. */ longValueHistogramBucketingOption?: Schema$NumericBucketingOption; /** @@ -525,11 +525,11 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$CustomRankingInfo { /** - * Required. Controls over how important the score of CustomRankingInfo.ranking_expression gets applied to job's final ranking position. An error is thrown if not specified. + * Required. Controls over how important the score of CustomRankingInfo.ranking_expression gets applied to job's final ranking position. An error is thrown if not specified. */ importanceLevel?: string; /** - * Required. Controls over how job documents get ranked on top of existing relevance score (determined by API algorithm). The product of ranking expression and relevance score is used to determine job's final ranking position. The syntax for this expression is a subset of Google SQL syntax. Supported operators are: +, -, *, /, where the left and right side of the operator is either a numeric Job.custom_attributes key, integer/double value or an expression that can be evaluated to a number. Parenthesis are supported to adjust calculation precedence. The expression must be < 100 characters in length. Sample ranking expression (year + 25) * 0.25 - (freshness / 0.5) + * Required. Controls over how job documents get ranked on top of existing relevance score (determined by API algorithm). The product of ranking expression and relevance score is used to determine job's final ranking position. The syntax for this expression is a subset of Google SQL syntax. Supported operators are: +, -, *, /, where the left and right side of the operator is either a numeric Job.custom_attributes key, integer/double value or an expression that can be evaluated to a number. Parenthesis are supported to adjust calculation precedence. The expression must be < 100 characters in length. Sample ranking expression (year + 25) * 0.25 - (freshness / 0.5) */ rankingExpression?: string; } @@ -538,11 +538,11 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$DeviceInfo { /** - * Optional. Type of the device. + * Optional. Type of the device. */ deviceType?: string; /** - * Optional. A device-specific ID. The ID must be a unique identifier that distinguishes the device from other devices. + * Optional. A device-specific ID. The ID must be a unique identifier that distinguishes the device from other devices. */ id?: string; } @@ -555,15 +555,15 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$HistogramFacets { /** - * Optional. Specifies compensation field-based histogram requests. Duplicate values of CompensationHistogramRequest.type are not allowed. + * Optional. Specifies compensation field-based histogram requests. Duplicate values of CompensationHistogramRequest.type are not allowed. */ compensationHistogramFacets?: Schema$CompensationHistogramRequest[]; /** - * Optional. Specifies the custom attributes histogram requests. Duplicate values of CustomAttributeHistogramRequest.key are not allowed. + * Optional. Specifies the custom attributes histogram requests. Duplicate values of CustomAttributeHistogramRequest.key are not allowed. */ customAttributeHistogramFacets?: Schema$CustomAttributeHistogramRequest[]; /** - * Optional. Specifies the simple type of histogram facets, for example, `COMPANY_SIZE`, `EMPLOYMENT_TYPE` etc. + * Optional. Specifies the simple type of histogram facets, for example, `COMPANY_SIZE`, `EMPLOYMENT_TYPE` etc. */ simpleHistogramFacets?: string[]; } @@ -636,23 +636,23 @@ export namespace jobs_v3p1beta1 { */ companyDisplayName?: string; /** - * Required. The resource name of the company listing the job, such as "projects/api-test-project/companies/foo". + * Required. The resource name of the company listing the job, such as "projects/api-test-project/companies/foo". */ companyName?: string; /** - * Optional. Job compensation information. + * Optional. Job compensation information. */ compensationInfo?: Schema$CompensationInfo; /** - * Optional. A map of fields to hold both filterable and non-filterable custom job attributes that are not covered by the provided structured fields. The keys of the map are strings up to 64 bytes and must match the pattern: a-zA-Z*. For example, key0LikeThis or KEY_1_LIKE_THIS. At most 100 filterable and at most 100 unfilterable keys are supported. For filterable `string_values`, across all keys at most 200 values are allowed, with each string no more than 255 characters. For unfilterable `string_values`, the maximum total size of `string_values` across all keys is 50KB. + * Optional. A map of fields to hold both filterable and non-filterable custom job attributes that are not covered by the provided structured fields. The keys of the map are strings up to 64 bytes and must match the pattern: a-zA-Z*. For example, key0LikeThis or KEY_1_LIKE_THIS. At most 100 filterable and at most 100 unfilterable keys are supported. For filterable `string_values`, across all keys at most 200 values are allowed, with each string no more than 255 characters. For unfilterable `string_values`, the maximum total size of `string_values` across all keys is 50KB. */ customAttributes?: {[key: string]: Schema$CustomAttribute}; /** - * Optional. The desired education degrees for the job, such as Bachelors, Masters. + * Optional. The desired education degrees for the job, such as Bachelors, Masters. */ degreeTypes?: string[]; /** - * Optional. The department or functional area within the company with the open position. The maximum number of allowed characters is 255. + * Optional. The department or functional area within the company with the open position. The maximum number of allowed characters is 255. */ department?: string; /** @@ -660,35 +660,35 @@ export namespace jobs_v3p1beta1 { */ derivedInfo?: Schema$JobDerivedInfo; /** - * Required. The description of the job, which typically includes a multi-paragraph description of the company and related information. Separate fields are provided on the job object for responsibilities, qualifications, and other job characteristics. Use of these separate job fields is recommended. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 100,000. + * Required. The description of the job, which typically includes a multi-paragraph description of the company and related information. Separate fields are provided on the job object for responsibilities, qualifications, and other job characteristics. Use of these separate job fields is recommended. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 100,000. */ description?: string; /** - * Optional. The employment type(s) of a job, for example, full time or part time. + * Optional. The employment type(s) of a job, for example, full time or part time. */ employmentTypes?: string[]; /** - * Optional. A description of bonus, commission, and other compensation incentives associated with the job not including salary or pay. The maximum number of allowed characters is 10,000. + * Optional. A description of bonus, commission, and other compensation incentives associated with the job not including salary or pay. The maximum number of allowed characters is 10,000. */ incentives?: string; /** - * Optional. The benefits included with the job. + * Optional. The benefits included with the job. */ jobBenefits?: string[]; /** - * Optional. The end timestamp of the job. Typically this field is used for contracting engagements. Invalid timestamps are ignored. + * Optional. The end timestamp of the job. Typically this field is used for contracting engagements. Invalid timestamps are ignored. */ jobEndTime?: string; /** - * Optional. The experience level associated with the job, such as "Entry Level". + * Optional. The experience level associated with the job, such as "Entry Level". */ jobLevel?: string; /** - * Optional. The start timestamp of the job in UTC time zone. Typically this field is used for contracting engagements. Invalid timestamps are ignored. + * Optional. The start timestamp of the job in UTC time zone. Typically this field is used for contracting engagements. Invalid timestamps are ignored. */ jobStartTime?: string; /** - * Optional. The language of the posting. This field is distinct from any requirements for fluency that are associated with the job. Language codes must be in BCP-47 format, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47){: class="external" target="_blank" }. If this field is unspecified and Job.description is present, detected language code based on Job.description is assigned, otherwise defaults to 'en_US'. + * Optional. The language of the posting. This field is distinct from any requirements for fluency that are associated with the job. Language codes must be in BCP-47 format, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47){: class="external" target="_blank" }. If this field is unspecified and Job.description is present, detected language code based on Job.description is assigned, otherwise defaults to 'en_US'. */ languageCode?: string; /** @@ -704,11 +704,11 @@ export namespace jobs_v3p1beta1 { */ postingExpireTime?: string; /** - * Optional. The timestamp this job posting was most recently published. The default value is the time the request arrives at the server. Invalid timestamps are ignored. + * Optional. The timestamp this job posting was most recently published. The default value is the time the request arrives at the server. Invalid timestamps are ignored. */ postingPublishTime?: string; /** - * Optional. The job PostingRegion (for example, state, country) throughout which the job is available. If this field is set, a LocationFilter in a search query within the job region finds this job posting if an exact location match isn't specified. If this field is set to PostingRegion.NATION or PostingRegion.ADMINISTRATIVE_AREA, setting job Job.addresses to the same location level as this field is strongly recommended. + * Optional. The job PostingRegion (for example, state, country) throughout which the job is available. If this field is set, a LocationFilter in a search query within the job region finds this job posting if an exact location match isn't specified. If this field is set to PostingRegion.NATION or PostingRegion.ADMINISTRATIVE_AREA, setting job Job.addresses to the same location level as this field is strongly recommended. */ postingRegion?: string; /** @@ -716,31 +716,31 @@ export namespace jobs_v3p1beta1 { */ postingUpdateTime?: string; /** - * Optional. Options for job processing. + * Optional. Options for job processing. */ processingOptions?: Schema$ProcessingOptions; /** - * Optional. A promotion value of the job, as determined by the client. The value determines the sort order of the jobs returned when searching for jobs using the featured jobs search call, with higher promotional values being returned first and ties being resolved by relevance sort. Only the jobs with a promotionValue >0 are returned in a FEATURED_JOB_SEARCH. Default value is 0, and negative values are treated as 0. + * Optional. A promotion value of the job, as determined by the client. The value determines the sort order of the jobs returned when searching for jobs using the featured jobs search call, with higher promotional values being returned first and ties being resolved by relevance sort. Only the jobs with a promotionValue >0 are returned in a FEATURED_JOB_SEARCH. Default value is 0, and negative values are treated as 0. */ promotionValue?: number; /** - * Optional. A description of the qualifications required to perform the job. The use of this field is recommended as an alternative to using the more general description field. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 10,000. + * Optional. A description of the qualifications required to perform the job. The use of this field is recommended as an alternative to using the more general description field. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 10,000. */ qualifications?: string; /** - * Required. The requisition ID, also referred to as the posting ID, assigned by the client to identify a job. This field is intended to be used by clients for client identification and tracking of postings. A job is not allowed to be created if there is another job with the same [company_name], language_code and requisition_id. The maximum number of allowed characters is 255. + * Required. The requisition ID, also referred to as the posting ID, assigned by the client to identify a job. This field is intended to be used by clients for client identification and tracking of postings. A job is not allowed to be created if there is another job with the same [company_name], language_code and requisition_id. The maximum number of allowed characters is 255. */ requisitionId?: string; /** - * Optional. A description of job responsibilities. The use of this field is recommended as an alternative to using the more general description field. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 10,000. + * Optional. A description of job responsibilities. The use of this field is recommended as an alternative to using the more general description field. This field accepts and sanitizes HTML input, and also accepts bold, italic, ordered list, and unordered list markup tags. The maximum number of allowed characters is 10,000. */ responsibilities?: string; /** - * Required. The title of the job, such as "Software Engineer" The maximum number of allowed characters is 500. + * Required. The title of the job, such as "Software Engineer" The maximum number of allowed characters is 500. */ title?: string; /** - * Optional. The visibility of the job. Defaults to Visibility.ACCOUNT_ONLY if not specified. + * Deprecated. The job is only visible to the owner. The visibility of the job. Defaults to Visibility.ACCOUNT_ONLY if not specified. */ visibility?: string; } @@ -762,11 +762,11 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$JobEvent { /** - * Required. The job name(s) associated with this event. For example, if this is an impression event, this field contains the identifiers of all jobs shown to the job seeker. If this was a view event, this field contains the identifier of the viewed job. + * Required. The job name(s) associated with this event. For example, if this is an impression event, this field contains the identifiers of all jobs shown to the job seeker. If this was a view event, this field contains the identifier of the viewed job. */ jobs?: string[]; /** - * Required. The type of the event (see JobEventType). + * Required. The type of the event (see JobEventType). */ type?: string; } @@ -775,55 +775,55 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$JobQuery { /** - * Optional. Allows filtering jobs by commute time with different travel methods (for example, driving or public transit). Note: This only works with COMMUTE MODE. When specified, [JobQuery.location_filters] is ignored. Currently we don't support sorting by commute time. + * Optional. Allows filtering jobs by commute time with different travel methods (for example, driving or public transit). Note: This only works with COMMUTE MODE. When specified, [JobQuery.location_filters] is ignored. Currently we don't support sorting by commute time. */ commuteFilter?: Schema$CommuteFilter; /** - * Optional. This filter specifies the exact company display name of the jobs to search against. If a value isn't specified, jobs within the search results are associated with any company. If multiple values are specified, jobs within the search results may be associated with any of the specified companies. At most 20 company display name filters are allowed. + * Optional. This filter specifies the exact company display name of the jobs to search against. If a value isn't specified, jobs within the search results are associated with any company. If multiple values are specified, jobs within the search results may be associated with any of the specified companies. At most 20 company display name filters are allowed. */ companyDisplayNames?: string[]; /** - * Optional. This filter specifies the company entities to search against. If a value isn't specified, jobs are searched for against all companies. If multiple values are specified, jobs are searched against the companies specified. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". At most 20 company filters are allowed. + * Optional. This filter specifies the company entities to search against. If a value isn't specified, jobs are searched for against all companies. If multiple values are specified, jobs are searched against the companies specified. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". At most 20 company filters are allowed. */ companyNames?: string[]; /** - * Optional. This search filter is applied only to Job.compensation_info. For example, if the filter is specified as "Hourly job with per-hour compensation > $15", only jobs meeting these criteria are searched. If a filter isn't defined, all open jobs are searched. + * Optional. This search filter is applied only to Job.compensation_info. For example, if the filter is specified as "Hourly job with per-hour compensation > $15", only jobs meeting these criteria are searched. If a filter isn't defined, all open jobs are searched. */ compensationFilter?: Schema$CompensationFilter; /** - * Optional. This filter specifies a structured syntax to match against the Job.custom_attributes marked as `filterable`. The syntax for this expression is a subset of SQL syntax. Supported operators are: `=`, `!=`, `<`, `<=`, `>`, and `>=` where the left of the operator is a custom field key and the right of the operator is a number or a quoted string. You must escape backslash (\\) and quote (\") characters. Supported functions are `LOWER([field_name])` to perform a case insensitive match and `EMPTY([field_name])` to filter on the existence of a key. Boolean expressions (AND/OR/NOT) are supported up to 3 levels of nesting (for example, "((A AND B AND C) OR NOT D) AND E"), a maximum of 100 comparisons or functions are allowed in the expression. The expression must be < 3000 bytes in length. Sample Query: `(LOWER(driving_license)="class \"a\"" OR EMPTY(driving_license)) AND driving_years > 10` + * Optional. This filter specifies a structured syntax to match against the Job.custom_attributes marked as `filterable`. The syntax for this expression is a subset of SQL syntax. Supported operators are: `=`, `!=`, `<`, `<=`, `>`, and `>=` where the left of the operator is a custom field key and the right of the operator is a number or a quoted string. You must escape backslash (\\) and quote (\") characters. Supported functions are `LOWER([field_name])` to perform a case insensitive match and `EMPTY([field_name])` to filter on the existence of a key. Boolean expressions (AND/OR/NOT) are supported up to 3 levels of nesting (for example, "((A AND B AND C) OR NOT D) AND E"), a maximum of 100 comparisons or functions are allowed in the expression. The expression must be < 6000 bytes in length. Sample Query: `(LOWER(driving_license)="class \"a\"" OR EMPTY(driving_license)) AND driving_years > 10` */ customAttributeFilter?: string; /** - * Optional. This flag controls the spell-check feature. If false, the service attempts to correct a misspelled query, for example, "enginee" is corrected to "engineer". Defaults to false: a spell check is performed. + * Optional. This flag controls the spell-check feature. If false, the service attempts to correct a misspelled query, for example, "enginee" is corrected to "engineer". Defaults to false: a spell check is performed. */ disableSpellCheck?: boolean; /** - * Optional. The employment type filter specifies the employment type of jobs to search against, such as EmploymentType.FULL_TIME. If a value is not specified, jobs in the search results includes any employment type. If multiple values are specified, jobs in the search results include any of the specified employment types. + * Optional. The employment type filter specifies the employment type of jobs to search against, such as EmploymentType.FULL_TIME. If a value is not specified, jobs in the search results includes any employment type. If multiple values are specified, jobs in the search results include any of the specified employment types. */ employmentTypes?: string[]; /** - * Optional. This filter specifies a list of job names to be excluded during search. At most 400 excluded job names are allowed. + * Optional. This filter specifies a list of job names to be excluded during search. At most 400 excluded job names are allowed. */ excludedJobs?: string[]; /** - * Optional. The category filter specifies the categories of jobs to search against. See Category for more information. If a value is not specified, jobs from any category are searched against. If multiple values are specified, jobs from any of the specified categories are searched against. + * Optional. The category filter specifies the categories of jobs to search against. See Category for more information. If a value is not specified, jobs from any category are searched against. If multiple values are specified, jobs from any of the specified categories are searched against. */ jobCategories?: string[]; /** - * Optional. This filter specifies the locale of jobs to search against, for example, "en-US". If a value isn't specified, the search results can contain jobs in any locale. Language codes should be in BCP-47 format, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). At most 10 language code filters are allowed. + * Optional. This filter specifies the locale of jobs to search against, for example, "en-US". If a value isn't specified, the search results can contain jobs in any locale. Language codes should be in BCP-47 format, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). At most 10 language code filters are allowed. */ languageCodes?: string[]; /** - * Optional. The location filter specifies geo-regions containing the jobs to search against. See LocationFilter for more information. If a location value isn't specified, jobs fitting the other search criteria are retrieved regardless of where they're located. If multiple values are specified, jobs are retrieved from any of the specified locations. If different values are specified for the LocationFilter.distance_in_miles parameter, the maximum provided distance is used for all locations. At most 5 location filters are allowed. + * Optional. The location filter specifies geo-regions containing the jobs to search against. See LocationFilter for more information. If a location value isn't specified, jobs fitting the other search criteria are retrieved regardless of where they're located. If multiple values are specified, jobs are retrieved from any of the specified locations. If different values are specified for the LocationFilter.distance_in_miles parameter, the maximum provided distance is used for all locations. At most 5 location filters are allowed. */ locationFilters?: Schema$LocationFilter[]; /** - * Optional. Jobs published within a range specified by this filter are searched against. + * Optional. Jobs published within a range specified by this filter are searched against. */ publishTimeRange?: Schema$TimestampRange; /** - * Optional. The query string that matches against the job title, description, and location fields. The maximum number of allowed characters is 255. + * Optional. The query string that matches against the job title, description, and location fields. The maximum number of allowed characters is 255. */ query?: string; } @@ -900,23 +900,23 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$LocationFilter { /** - * Optional. The address name, such as "Mountain View" or "Bay Area". + * Optional. The address name, such as "Mountain View" or "Bay Area". */ address?: string; /** - * Optional. The distance_in_miles is applied when the location being searched for is identified as a city or smaller. When the location being searched for is a state or larger, this field is ignored. + * Optional. The distance_in_miles is applied when the location being searched for is identified as a city or smaller. When the location being searched for is a state or larger, this field is ignored. */ distanceInMiles?: number; /** - * Optional. The latitude and longitude of the geographic center from which to search. This field's ignored if `address` is provided. + * Optional. The latitude and longitude of the geographic center from which to search. This field's ignored if `address` is provided. */ latLng?: Schema$LatLng; /** - * Optional. CLDR region code of the country/region of the address. This is used to address ambiguity of the user-input location, for example, "Liverpool" against "Liverpool, NY, US" or "Liverpool, UK". Set this field if all the jobs to search against are from a same region, or jobs are world-wide, but the job seeker is from a specific region. See http://cldr.unicode.org/ and http://www.unicode.org/cldr/charts/30/supplemental/territory_information.html for details. Example: "CH" for Switzerland. + * Optional. CLDR region code of the country/region of the address. This is used to address ambiguity of the user-input location, for example, "Liverpool" against "Liverpool, NY, US" or "Liverpool, UK". Set this field if all the jobs to search against are from a same region, or jobs are world-wide, but the job seeker is from a specific region. See http://cldr.unicode.org/ and http://www.unicode.org/cldr/charts/30/supplemental/territory_information.html for details. Example: "CH" for Switzerland. */ regionCode?: string; /** - * Optional. Allows the client to return jobs without a set location, specifically, telecommuting jobs (telecommuting is considered by the service as a special location. Job.posting_region indicates if a job permits telecommuting. If this field is set to TelecommutePreference.TELECOMMUTE_ALLOWED, telecommuting jobs are searched, and address and lat_lng are ignored. If not set or set to TelecommutePreference.TELECOMMUTE_EXCLUDED, telecommute job are not searched. This filter can be used by itself to search exclusively for telecommuting jobs, or it can be combined with another location filter to search for a combination of job locations, such as "Mountain View" or "telecommuting" jobs. However, when used in combination with other location filters, telecommuting jobs can be treated as less relevant than other jobs in the search response. + * Optional. Allows the client to return jobs without a set location, specifically, telecommuting jobs (telecommuting is considered by the service as a special location. Job.posting_region indicates if a job permits telecommuting. If this field is set to TelecommutePreference.TELECOMMUTE_ALLOWED, telecommuting jobs are searched, and address and lat_lng are ignored. If not set or set to TelecommutePreference.TELECOMMUTE_EXCLUDED, telecommute job are not searched. This filter can be used by itself to search exclusively for telecommuting jobs, or it can be combined with another location filter to search for a combination of job locations, such as "Mountain View" or "telecommuting" jobs. However, when used in combination with other location filters, telecommuting jobs can be treated as less relevant than other jobs in the search response. */ telecommutePreference?: string; } @@ -967,11 +967,11 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$NumericBucketingOption { /** - * Required. Two adjacent values form a histogram bucket. Values should be in ascending order. For example, if [5, 10, 15] are provided, four buckets are created: (-inf, 5), 5, 10), [10, 15), [15, inf). At most 20 [buckets_bound is supported. + * Required. Two adjacent values form a histogram bucket. Values should be in ascending order. For example, if [5, 10, 15] are provided, four buckets are created: (-inf, 5), 5, 10), [10, 15), [15, inf). At most 20 [buckets_bound is supported. */ bucketBounds?: number[]; /** - * Optional. If set to true, the histogram result includes minimum/maximum value of the numeric field. + * Optional. If set to true, the histogram result includes minimum/maximum value of the numeric field. */ requiresMinMax?: boolean; } @@ -1018,7 +1018,7 @@ export namespace jobs_v3p1beta1 { response?: {[key: string]: any}; } /** - * Represents a postal address, e.g. for postal delivery or payments addresses. Given a postal address, a postal service can deliver items to a premise, P.O. Box or similar. It is not intended to model geographical locations (roads, towns, mountains). In typical usage an address would be created via user input or from importing existing data, depending on the type of process. Advice on address input / editing: - Use an i18n-ready address widget such as https://github.com/googlei18n/libaddressinput) - Users should not be presented with UI elements for input or editing of fields outside countries where that field is used. For more guidance on how to use this schema, please see: https://support.google.com/business/answer/6397478 + * Represents a postal address, e.g. for postal delivery or payments addresses. Given a postal address, a postal service can deliver items to a premise, P.O. Box or similar. It is not intended to model geographical locations (roads, towns, mountains). In typical usage an address would be created via user input or from importing existing data, depending on the type of process. Advice on address input / editing: - Use an i18n-ready address widget such as https://github.com/google/libaddressinput) - Users should not be presented with UI elements for input or editing of fields outside countries where that field is used. For more guidance on how to use this schema, please see: https://support.google.com/business/answer/6397478 */ export interface Schema$PostalAddress { /** @@ -1071,11 +1071,11 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$ProcessingOptions { /** - * Optional. If set to `true`, the service does not attempt to resolve a more precise address for the job. + * Optional. If set to `true`, the service does not attempt to resolve a more precise address for the job. */ disableStreetAddressResolution?: boolean; /** - * Optional. Option for job HTML content sanitization. Applied fields are: * description * applicationInfo.instruction * incentives * qualifications * responsibilities HTML tags in these fields may be stripped if sanitiazation is not disabled. Defaults to HtmlSanitization.SIMPLE_FORMATTING_ONLY. + * Optional. Option for job HTML content sanitization. Applied fields are: * description * applicationInfo.instruction * incentives * qualifications * responsibilities HTML tags in these fields may be stripped if sanitiazation is not disabled. Defaults to HtmlSanitization.SIMPLE_FORMATTING_ONLY. */ htmlSanitization?: string; } @@ -1084,19 +1084,19 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$RequestMetadata { /** - * Optional. The type of device used by the job seeker at the time of the call to the service. + * Optional. The type of device used by the job seeker at the time of the call to the service. */ deviceInfo?: Schema$DeviceInfo; /** - * Required. The client-defined scope or source of the service call, which typically is the domain on which the service has been implemented and is currently being run. For example, if the service is being run by client <em>Foo, Inc.</em>, on job board www.foo.com and career site www.bar.com, then this field is set to "foo.com" for use on the job board, and "bar.com" for use on the career site. If this field isn't available for some reason, send "UNKNOWN". Any improvements to the model for a particular tenant site rely on this field being set correctly to a domain. The maximum number of allowed characters is 255. + * Required. The client-defined scope or source of the service call, which typically is the domain on which the service has been implemented and is currently being run. For example, if the service is being run by client <em>Foo, Inc.</em>, on job board www.foo.com and career site www.bar.com, then this field is set to "foo.com" for use on the job board, and "bar.com" for use on the career site. If this field isn't available for some reason, send "UNKNOWN". Any improvements to the model for a particular tenant site rely on this field being set correctly to a domain. The maximum number of allowed characters is 255. */ domain?: string; /** - * Required. A unique session identification string. A session is defined as the duration of an end user's interaction with the service over a certain period. Obfuscate this field for privacy concerns before providing it to the service. If this field is not available for some reason, send "UNKNOWN". Note that any improvements to the model for a particular tenant site, rely on this field being set correctly to some unique session_id. The maximum number of allowed characters is 255. + * Required. A unique session identification string. A session is defined as the duration of an end user's interaction with the service over a certain period. Obfuscate this field for privacy concerns before providing it to the service. If this field is not available for some reason, send "UNKNOWN". Note that any improvements to the model for a particular tenant site, rely on this field being set correctly to some unique session_id. The maximum number of allowed characters is 255. */ sessionId?: string; /** - * Required. A unique user identification string, as determined by the client. To have the strongest positive impact on search quality make sure the client-level is unique. Obfuscate this field for privacy concerns before providing it to the service. If this field is not available for some reason, send "UNKNOWN". Note that any improvements to the model for a particular tenant site, rely on this field being set correctly to a unique user_id. The maximum number of allowed characters is 255. + * Required. A unique user identification string, as determined by the client. To have the strongest positive impact on search quality make sure the client-level is unique. Obfuscate this field for privacy concerns before providing it to the service. If this field is not available for some reason, send "UNKNOWN". Note that any improvements to the model for a particular tenant site, rely on this field being set correctly to a unique user_id. The maximum number of allowed characters is 255. */ userId?: string; } @@ -1114,63 +1114,63 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$SearchJobsRequest { /** - * Optional. Controls over how job documents get ranked on top of existing relevance score (determined by API algorithm). + * Optional. Controls over how job documents get ranked on top of existing relevance score (determined by API algorithm). */ customRankingInfo?: Schema$CustomRankingInfo; /** - * Optional. Controls whether to disable exact keyword match on Job.job_title, Job.description, Job.company_display_name, Job.locations, Job.qualifications. When disable keyword match is turned off, a keyword match returns jobs that do not match given category filters when there are matching keywords. For example, the query "program manager," a result is returned even if the job posting has the title "software developer," which does not fall into "program manager" ontology, but does have "program manager" appearing in its description. For queries like "cloud" that does not contain title or location specific ontology, jobs with "cloud" keyword matches are returned regardless of this flag's value. Please use Company.keyword_searchable_custom_fields or Company.keyword_searchable_custom_attributes if company specific globally matched custom field/attribute string values is needed. Enabling keyword match improves recall of subsequent search requests. Defaults to false. + * Optional. Controls whether to disable exact keyword match on Job.job_title, Job.description, Job.company_display_name, Job.locations, Job.qualifications. When disable keyword match is turned off, a keyword match returns jobs that do not match given category filters when there are matching keywords. For example, the query "program manager," a result is returned even if the job posting has the title "software developer," which does not fall into "program manager" ontology, but does have "program manager" appearing in its description. For queries like "cloud" that does not contain title or location specific ontology, jobs with "cloud" keyword matches are returned regardless of this flag's value. Please use Company.keyword_searchable_custom_fields or Company.keyword_searchable_custom_attributes if company specific globally matched custom field/attribute string values is needed. Enabling keyword match improves recall of subsequent search requests. Defaults to false. */ disableKeywordMatch?: boolean; /** - * Optional. Controls whether highly similar jobs are returned next to each other in the search results. Jobs are identified as highly similar based on their titles, job categories, and locations. Highly similar results are clustered so that only one representative job of the cluster is displayed to the job seeker higher up in the results, with the other jobs being displayed lower down in the results. Defaults to DiversificationLevel.SIMPLE if no value is specified. + * Optional. Controls whether highly similar jobs are returned next to each other in the search results. Jobs are identified as highly similar based on their titles, job categories, and locations. Highly similar results are clustered so that only one representative job of the cluster is displayed to the job seeker higher up in the results, with the other jobs being displayed lower down in the results. Defaults to DiversificationLevel.SIMPLE if no value is specified. */ diversificationLevel?: string; /** - * Optional. Controls whether to broaden the search when it produces sparse results. Broadened queries append results to the end of the matching results list. Defaults to false. + * Optional. Controls whether to broaden the search when it produces sparse results. Broadened queries append results to the end of the matching results list. Defaults to false. */ enableBroadening?: boolean; /** - * Optional. Histogram requests for jobs matching JobQuery. + * Optional. Histogram requests for jobs matching JobQuery. */ histogramFacets?: Schema$HistogramFacets; /** - * Optional. Expression based histogram requests for jobs matching JobQuery. + * Optional. Expression based histogram requests for jobs matching JobQuery. */ histogramQueries?: Schema$HistogramQuery[]; /** - * Optional. Query used to search against jobs, such as keyword, location filters, etc. + * Optional. Query used to search against jobs, such as keyword, location filters, etc. */ jobQuery?: Schema$JobQuery; /** - * Optional. The desired job attributes returned for jobs in the search response. Defaults to JobView.SMALL if no value is specified. + * Optional. The desired job attributes returned for jobs in the search response. Defaults to JobView.SMALL if no value is specified. */ jobView?: string; /** - * Optional. An integer that specifies the current offset (that is, starting result location, amongst the jobs deemed by the API as relevant) in search results. This field is only considered if page_token is unset. For example, 0 means to return results starting from the first matching job, and 10 means to return from the 11th job. This can be used for pagination, (for example, pageSize = 10 and offset = 10 means to return from the second page). + * Optional. An integer that specifies the current offset (that is, starting result location, amongst the jobs deemed by the API as relevant) in search results. This field is only considered if page_token is unset. For example, 0 means to return results starting from the first matching job, and 10 means to return from the 11th job. This can be used for pagination, (for example, pageSize = 10 and offset = 10 means to return from the second page). */ offset?: number; /** - * Optional. The criteria determining how search results are sorted. Default is "relevance desc". Supported options are: * `"relevance desc"`: By relevance descending, as determined by the API algorithms. Relevance thresholding of query results is only available with this ordering. * `"posting_publish_time desc"`: By Job.posting_publish_time descending. * `"posting_update_time desc"`: By Job.posting_update_time descending. * `"title"`: By Job.title ascending. * `"title desc"`: By Job.title descending. * `"annualized_base_compensation"`: By job's CompensationInfo.annualized_base_compensation_range ascending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"annualized_base_compensation desc"`: By job's CompensationInfo.annualized_base_compensation_range descending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"annualized_total_compensation"`: By job's CompensationInfo.annualized_total_compensation_range ascending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"annualized_total_compensation desc"`: By job's CompensationInfo.annualized_total_compensation_range descending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"custom_ranking desc"`: By the relevance score adjusted to the SearchJobsRequest.custom_ranking_info.ranking_expression with weight factor assigned by SearchJobsRequest.custom_ranking_info.importance_level in descending order. * Location sorting: Use the special syntax to order jobs by distance:<br> "`distance_from('Hawaii')`": Order by distance from Hawaii.<br> "`distance_from(19.89, 155.5)`": Order by distance from a coordinate.<br> "`distance_from('Hawaii'), distance_from('Puerto Rico')`": Order by multiple locations. See details below.<br> "`distance_from('Hawaii'), distance_from(19.89, 155.5)`": Order by multiple locations. See details below.<br> The string can have a maximum of 256 characters. When multiple distance centers are provided, a job that is close to any of the distance centers would have a high rank. When a job has multiple locations, the job location closest to one of the distance centers will be used. Jobs that don't have locations will be ranked at the bottom. Distance is calculated with a precision of 11.3 meters (37.4 feet). Diversification strategy is still applied unless explicitly disabled in diversification_level. + * Optional. The criteria determining how search results are sorted. Default is "relevance desc". Supported options are: * `"relevance desc"`: By relevance descending, as determined by the API algorithms. Relevance thresholding of query results is only available with this ordering. * `"posting_publish_time desc"`: By Job.posting_publish_time descending. * `"posting_update_time desc"`: By Job.posting_update_time descending. * `"title"`: By Job.title ascending. * `"title desc"`: By Job.title descending. * `"annualized_base_compensation"`: By job's CompensationInfo.annualized_base_compensation_range ascending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"annualized_base_compensation desc"`: By job's CompensationInfo.annualized_base_compensation_range descending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"annualized_total_compensation"`: By job's CompensationInfo.annualized_total_compensation_range ascending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"annualized_total_compensation desc"`: By job's CompensationInfo.annualized_total_compensation_range descending. Jobs whose annualized base compensation is unspecified are put at the end of search results. * `"custom_ranking desc"`: By the relevance score adjusted to the SearchJobsRequest.custom_ranking_info.ranking_expression with weight factor assigned by SearchJobsRequest.custom_ranking_info.importance_level in descending order. * Location sorting: Use the special syntax to order jobs by distance:<br> "`distance_from('Hawaii')`": Order by distance from Hawaii.<br> "`distance_from(19.89, 155.5)`": Order by distance from a coordinate.<br> "`distance_from('Hawaii'), distance_from('Puerto Rico')`": Order by multiple locations. See details below.<br> "`distance_from('Hawaii'), distance_from(19.89, 155.5)`": Order by multiple locations. See details below.<br> The string can have a maximum of 256 characters. When multiple distance centers are provided, a job that is close to any of the distance centers would have a high rank. When a job has multiple locations, the job location closest to one of the distance centers will be used. Jobs that don't have locations will be ranked at the bottom. Distance is calculated with a precision of 11.3 meters (37.4 feet). Diversification strategy is still applied unless explicitly disabled in diversification_level. */ orderBy?: string; /** - * Optional. A limit on the number of jobs returned in the search results. Increasing this value above the default value of 10 can increase search response time. The value can be between 1 and 100. + * Optional. A limit on the number of jobs returned in the search results. Increasing this value above the default value of 10 can increase search response time. The value can be between 1 and 100. */ pageSize?: number; /** - * Optional. The token specifying the current offset within search results. See SearchJobsResponse.next_page_token for an explanation of how to obtain the next set of query results. + * Optional. The token specifying the current offset within search results. See SearchJobsResponse.next_page_token for an explanation of how to obtain the next set of query results. */ pageToken?: string; /** - * Required. The meta information collected about the job searcher, used to improve the search quality of the service. The identifiers (such as `user_id`) are provided by users, and must be unique and consistent. + * Required. The meta information collected about the job searcher, used to improve the search quality of the service. The identifiers (such as `user_id`) are provided by users, and must be unique and consistent. */ requestMetadata?: Schema$RequestMetadata; /** - * Optional. Controls if the search job request requires the return of a precise count of the first 300 results. Setting this to `true` ensures consistency in the number of results per page. Best practice is to set this value to true if a client allows users to jump directly to a non-sequential search results page. Enabling this flag may adversely impact performance. Defaults to false. + * Optional. Controls if the search job request requires the return of a precise count of the first 300 results. Setting this to `true` ensures consistency in the number of results per page. Best practice is to set this value to true if a client allows users to jump directly to a non-sequential search results page. Enabling this flag may adversely impact performance. Defaults to false. */ requirePreciseResultSize?: boolean; /** - * Optional. Mode of a search. Defaults to SearchMode.JOB_SEARCH. + * Optional. Mode of a search. Defaults to SearchMode.JOB_SEARCH. */ searchMode?: string; } @@ -1288,7 +1288,7 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$UpdateCompanyRequest { /** - * Required. The company resource to replace the current resource in the system. + * Required. The company resource to replace the current resource in the system. */ company?: Schema$Company; /** @@ -1301,7 +1301,7 @@ export namespace jobs_v3p1beta1 { */ export interface Schema$UpdateJobRequest { /** - * Required. The Job to be updated. + * Required. The Job to be updated. */ job?: Schema$Job; /** @@ -1331,14 +1331,14 @@ export namespace jobs_v3p1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.companyName Optional. If provided, restricts completion to specified company. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". + * @param {string=} params.companyName Optional. If provided, restricts completion to specified company. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". * @param {string=} params.languageCode Deprecated. Use language_codes instead. Optional. The language of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with the same language_code are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with the same language_code are returned. For CompletionType.COMBINED type, only open jobs with the same language_code or companies having open jobs with the same language_code are returned. The maximum number of allowed characters is 255. - * @param {string=} params.languageCodes Optional. The list of languages of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with the same language_codes are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with the same language_codes are returned. For CompletionType.COMBINED type, only open jobs with the same language_codes or companies having open jobs with the same language_codes are returned. The maximum number of allowed characters is 255. - * @param {string} params.name Required. Resource name of project the completion is performed within. The format is "projects/{project_id}", for example, "projects/api-test-project". - * @param {integer=} params.pageSize Required. Completion result count. The maximum allowed page size is 10. - * @param {string=} params.query Required. The query used to generate suggestions. The maximum number of allowed characters is 255. - * @param {string=} params.scope Optional. The scope of the completion. The defaults is CompletionScope.PUBLIC. - * @param {string=} params.type Optional. The completion topic. The default is CompletionType.COMBINED. + * @param {string=} params.languageCodes Optional. The list of languages of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with the same language_codes are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with the same language_codes are returned. For CompletionType.COMBINED type, only open jobs with the same language_codes or companies having open jobs with the same language_codes are returned. The maximum number of allowed characters is 255. + * @param {string} params.name Required. Resource name of project the completion is performed within. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {integer=} params.pageSize Required. Completion result count. The maximum allowed page size is 10. + * @param {string=} params.query Required. The query used to generate suggestions. The maximum number of allowed characters is 255. + * @param {string=} params.scope Optional. The scope of the completion. The defaults is CompletionScope.PUBLIC. + * @param {string=} params.type Optional. The completion topic. The default is CompletionType.COMBINED. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1418,7 +1418,7 @@ export namespace jobs_v3p1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. If provided, restricts completion to specified company. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". + * Optional. If provided, restricts completion to specified company. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". */ companyName?: string; /** @@ -1426,27 +1426,27 @@ export namespace jobs_v3p1beta1 { */ languageCode?: string; /** - * Optional. The list of languages of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with the same language_codes are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with the same language_codes are returned. For CompletionType.COMBINED type, only open jobs with the same language_codes or companies having open jobs with the same language_codes are returned. The maximum number of allowed characters is 255. + * Optional. The list of languages of the query. This is the BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see [Tags for Identifying Languages](https://tools.ietf.org/html/bcp47). For CompletionType.JOB_TITLE type, only open jobs with the same language_codes are returned. For CompletionType.COMPANY_NAME type, only companies having open jobs with the same language_codes are returned. For CompletionType.COMBINED type, only open jobs with the same language_codes or companies having open jobs with the same language_codes are returned. The maximum number of allowed characters is 255. */ languageCodes?: string[]; /** - * Required. Resource name of project the completion is performed within. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. Resource name of project the completion is performed within. The format is "projects/{project_id}", for example, "projects/api-test-project". */ name?: string; /** - * Required. Completion result count. The maximum allowed page size is 10. + * Required. Completion result count. The maximum allowed page size is 10. */ pageSize?: number; /** - * Required. The query used to generate suggestions. The maximum number of allowed characters is 255. + * Required. The query used to generate suggestions. The maximum number of allowed characters is 255. */ query?: string; /** - * Optional. The scope of the completion. The defaults is CompletionScope.PUBLIC. + * Optional. The scope of the completion. The defaults is CompletionScope.PUBLIC. */ scope?: string; /** - * Optional. The completion topic. The default is CompletionType.COMBINED. + * Optional. The completion topic. The default is CompletionType.COMBINED. */ type?: string; } @@ -1564,7 +1564,7 @@ export namespace jobs_v3p1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {string} params.parent Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". * @param {().CreateCompanyRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1637,7 +1637,7 @@ export namespace jobs_v3p1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the company to be deleted. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". + * @param {string} params.name Required. The resource name of the company to be deleted. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1706,7 +1706,7 @@ export namespace jobs_v3p1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the company to be retrieved. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". + * @param {string} params.name Required. The resource name of the company to be retrieved. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1775,10 +1775,10 @@ export namespace jobs_v3p1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.pageSize Optional. The maximum number of companies to be returned, at most 100. Default is 100 if a non-positive number is provided. - * @param {string=} params.pageToken Optional. The starting indicator from which to return results. - * @param {string} params.parent Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". - * @param {boolean=} params.requireOpenJobs Optional. Set to true if the companies requested must have open jobs. Defaults to false. If true, at most page_size of companies are fetched, among which only those with open jobs are returned. + * @param {integer=} params.pageSize Optional. The maximum number of companies to be returned, at most 100. Default is 100 if a non-positive number is provided. + * @param {string=} params.pageToken Optional. The starting indicator from which to return results. + * @param {string} params.parent Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {boolean=} params.requireOpenJobs Optional. Set to true if the companies requested must have open jobs. Defaults to false. If true, at most page_size of companies are fetched, among which only those with open jobs are returned. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -1926,7 +1926,7 @@ export namespace jobs_v3p1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; @@ -1943,7 +1943,7 @@ export namespace jobs_v3p1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the company to be deleted. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". + * Required. The resource name of the company to be deleted. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". */ name?: string; } @@ -1955,7 +1955,7 @@ export namespace jobs_v3p1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the company to be retrieved. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". + * Required. The resource name of the company to be retrieved. The format is "projects/{project_id}/companies/{company_id}", for example, "projects/api-test-project/companies/foo". */ name?: string; } @@ -1967,19 +1967,19 @@ export namespace jobs_v3p1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The maximum number of companies to be returned, at most 100. Default is 100 if a non-positive number is provided. + * Optional. The maximum number of companies to be returned, at most 100. Default is 100 if a non-positive number is provided. */ pageSize?: number; /** - * Optional. The starting indicator from which to return results. + * Optional. The starting indicator from which to return results. */ pageToken?: string; /** - * Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. Resource name of the project under which the company is created. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; /** - * Optional. Set to true if the companies requested must have open jobs. Defaults to false. If true, at most page_size of companies are fetched, among which only those with open jobs are returned. + * Optional. Set to true if the companies requested must have open jobs. Defaults to false. If true, at most page_size of companies are fetched, among which only those with open jobs are returned. */ requireOpenJobs?: boolean; } @@ -2014,7 +2014,7 @@ export namespace jobs_v3p1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {string} params.parent Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". * @param {().BatchDeleteJobsRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2087,7 +2087,7 @@ export namespace jobs_v3p1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {string} params.parent Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". * @param {().CreateJobRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2160,7 +2160,7 @@ export namespace jobs_v3p1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the job to be deleted. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". + * @param {string} params.name Required. The resource name of the job to be deleted. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2229,7 +2229,7 @@ export namespace jobs_v3p1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name Required. The resource name of the job to retrieve. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". + * @param {string} params.name Required. The resource name of the job to retrieve. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2298,11 +2298,11 @@ export namespace jobs_v3p1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.filter Required. The filter string specifies the jobs to be enumerated. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Optional) Sample Query: * companyName = "projects/api-test-project/companies/123" * companyName = "projects/api-test-project/companies/123" AND requisitionId = "req-1" - * @param {string=} params.jobView Optional. The desired job attributes returned for jobs in the search response. Defaults to JobView.JOB_VIEW_FULL if no value is specified. - * @param {integer=} params.pageSize Optional. The maximum number of jobs to be returned per page of results. If job_view is set to JobView.JOB_VIEW_ID_ONLY, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. - * @param {string=} params.pageToken Optional. The starting point of a query result. - * @param {string} params.parent Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {string=} params.filter Required. The filter string specifies the jobs to be enumerated. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Optional) Sample Query: * companyName = "projects/api-test-project/companies/123" * companyName = "projects/api-test-project/companies/123" AND requisitionId = "req-1" + * @param {string=} params.jobView Optional. The desired job attributes returned for jobs in the search response. Defaults to JobView.JOB_VIEW_FULL if no value is specified. + * @param {integer=} params.pageSize Optional. The maximum number of jobs to be returned per page of results. If job_view is set to JobView.JOB_VIEW_ID_ONLY, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. + * @param {string=} params.pageToken Optional. The starting point of a query result. + * @param {string} params.parent Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -2446,7 +2446,7 @@ export namespace jobs_v3p1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {string} params.parent Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". * @param {().SearchJobsRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2521,7 +2521,7 @@ export namespace jobs_v3p1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.parent Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". + * @param {string} params.parent Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". * @param {().SearchJobsRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2600,7 +2600,7 @@ export namespace jobs_v3p1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; @@ -2617,7 +2617,7 @@ export namespace jobs_v3p1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; @@ -2634,7 +2634,7 @@ export namespace jobs_v3p1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the job to be deleted. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". + * Required. The resource name of the job to be deleted. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". */ name?: string; } @@ -2646,7 +2646,7 @@ export namespace jobs_v3p1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the job to retrieve. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". + * Required. The resource name of the job to retrieve. The format is "projects/{project_id}/jobs/{job_id}", for example, "projects/api-test-project/jobs/1234". */ name?: string; } @@ -2658,23 +2658,23 @@ export namespace jobs_v3p1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The filter string specifies the jobs to be enumerated. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Optional) Sample Query: * companyName = "projects/api-test-project/companies/123" * companyName = "projects/api-test-project/companies/123" AND requisitionId = "req-1" + * Required. The filter string specifies the jobs to be enumerated. Supported operator: =, AND The fields eligible for filtering are: * `companyName` (Required) * `requisitionId` (Optional) Sample Query: * companyName = "projects/api-test-project/companies/123" * companyName = "projects/api-test-project/companies/123" AND requisitionId = "req-1" */ filter?: string; /** - * Optional. The desired job attributes returned for jobs in the search response. Defaults to JobView.JOB_VIEW_FULL if no value is specified. + * Optional. The desired job attributes returned for jobs in the search response. Defaults to JobView.JOB_VIEW_FULL if no value is specified. */ jobView?: string; /** - * Optional. The maximum number of jobs to be returned per page of results. If job_view is set to JobView.JOB_VIEW_ID_ONLY, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. + * Optional. The maximum number of jobs to be returned per page of results. If job_view is set to JobView.JOB_VIEW_ID_ONLY, the maximum allowed page size is 1000. Otherwise, the maximum allowed page size is 100. Default is 100 if empty or a number < 1 is specified. */ pageSize?: number; /** - * Optional. The starting point of a query result. + * Optional. The starting point of a query result. */ pageToken?: string; /** - * Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. The resource name of the project under which the job is created. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; } @@ -2703,7 +2703,7 @@ export namespace jobs_v3p1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; @@ -2720,7 +2720,7 @@ export namespace jobs_v3p1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". + * Required. The resource name of the project to search within. The format is "projects/{project_id}", for example, "projects/api-test-project". */ parent?: string; diff --git a/src/apis/language/v1.ts b/src/apis/language/v1.ts index 9e174b34c62..00593958161 100644 --- a/src/apis/language/v1.ts +++ b/src/apis/language/v1.ts @@ -122,7 +122,7 @@ export namespace language_v1 { */ export interface Schema$AnalyzeEntitiesRequest { /** - * Input document. + * Required. Input document. */ document?: Schema$Document; /** @@ -148,7 +148,7 @@ export namespace language_v1 { */ export interface Schema$AnalyzeEntitySentimentRequest { /** - * Input document. + * Required. Input document. */ document?: Schema$Document; /** @@ -174,7 +174,7 @@ export namespace language_v1 { */ export interface Schema$AnalyzeSentimentRequest { /** - * Input document. + * Required. Input document. */ document?: Schema$Document; /** @@ -204,7 +204,7 @@ export namespace language_v1 { */ export interface Schema$AnalyzeSyntaxRequest { /** - * Input document. + * Required. Input document. */ document?: Schema$Document; /** @@ -234,7 +234,7 @@ export namespace language_v1 { */ export interface Schema$AnnotateTextRequest { /** - * Input document. + * Required. Input document. */ document?: Schema$Document; /** @@ -242,7 +242,7 @@ export namespace language_v1 { */ encodingType?: string; /** - * The enabled features. + * Required. The enabled features. */ features?: Schema$Features; } @@ -293,7 +293,7 @@ export namespace language_v1 { */ export interface Schema$ClassifyTextRequest { /** - * Input document. + * Required. Input document. */ document?: Schema$Document; } diff --git a/src/apis/language/v1beta2.ts b/src/apis/language/v1beta2.ts index d2b2c1f3cc8..8d9a6f0d0b4 100644 --- a/src/apis/language/v1beta2.ts +++ b/src/apis/language/v1beta2.ts @@ -122,7 +122,7 @@ export namespace language_v1beta2 { */ export interface Schema$AnalyzeEntitiesRequest { /** - * Input document. + * Required. Input document. */ document?: Schema$Document; /** @@ -148,7 +148,7 @@ export namespace language_v1beta2 { */ export interface Schema$AnalyzeEntitySentimentRequest { /** - * Input document. + * Required. Input document. */ document?: Schema$Document; /** @@ -174,7 +174,7 @@ export namespace language_v1beta2 { */ export interface Schema$AnalyzeSentimentRequest { /** - * Input document. + * Required. Input document. */ document?: Schema$Document; /** @@ -204,7 +204,7 @@ export namespace language_v1beta2 { */ export interface Schema$AnalyzeSyntaxRequest { /** - * Input document. + * Required. Input document. */ document?: Schema$Document; /** @@ -234,7 +234,7 @@ export namespace language_v1beta2 { */ export interface Schema$AnnotateTextRequest { /** - * Input document. + * Required. Input document. */ document?: Schema$Document; /** @@ -242,7 +242,7 @@ export namespace language_v1beta2 { */ encodingType?: string; /** - * The enabled features. + * Required. The enabled features. */ features?: Schema$Features; } @@ -293,7 +293,7 @@ export namespace language_v1beta2 { */ export interface Schema$ClassifyTextRequest { /** - * Input document. + * Required. Input document. */ document?: Schema$Document; } diff --git a/src/apis/libraryagent/v1.ts b/src/apis/libraryagent/v1.ts index 9fce8da8077..b10231e6c37 100644 --- a/src/apis/libraryagent/v1.ts +++ b/src/apis/libraryagent/v1.ts @@ -193,7 +193,7 @@ export namespace libraryagent_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name The name of the shelf to retrieve. + * @param {string} params.name Required. The name of the shelf to retrieve. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -369,7 +369,7 @@ export namespace libraryagent_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The name of the shelf to retrieve. + * Required. The name of the shelf to retrieve. */ name?: string; } @@ -402,7 +402,7 @@ export namespace libraryagent_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name The name of the book to borrow. + * @param {string} params.name Required. The name of the book to borrow. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -482,7 +482,7 @@ export namespace libraryagent_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name The name of the book to retrieve. + * @param {string} params.name Required. The name of the book to retrieve. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -564,7 +564,7 @@ export namespace libraryagent_v1 { * @param {object} params Parameters for request * @param {integer=} params.pageSize Requested page size. Server may return fewer books than requested. If unspecified, server will pick an appropriate default. * @param {string=} params.pageToken A token identifying a page of results the server should return. Typically, this is the value of ListBooksResponse.next_page_token. returned from the previous call to `ListBooks` method. - * @param {string} params.parent The name of the shelf whose books we'd like to list. + * @param {string} params.parent Required. The name of the shelf whose books we'd like to list. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -663,7 +663,7 @@ export namespace libraryagent_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name The name of the book to return. + * @param {string} params.name Required. The name of the book to return. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object @@ -745,7 +745,7 @@ export namespace libraryagent_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The name of the book to borrow. + * Required. The name of the book to borrow. */ name?: string; } @@ -757,7 +757,7 @@ export namespace libraryagent_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The name of the book to retrieve. + * Required. The name of the book to retrieve. */ name?: string; } @@ -777,7 +777,7 @@ export namespace libraryagent_v1 { */ pageToken?: string; /** - * The name of the shelf whose books we'd like to list. + * Required. The name of the shelf whose books we'd like to list. */ parent?: string; } @@ -789,7 +789,7 @@ export namespace libraryagent_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The name of the book to return. + * Required. The name of the book to return. */ name?: string; } diff --git a/src/apis/ml/v1.ts b/src/apis/ml/v1.ts index 39d1b74b0fd..c2c0ca19937 100644 --- a/src/apis/ml/v1.ts +++ b/src/apis/ml/v1.ts @@ -628,10 +628,23 @@ export namespace ml_v1 { */ imageUri?: string; /** - * TensorFlow version used in the custom container. This field is required if the replica is a TPU worker that uses a custom container. Otherwise, do not specify this field. + * The AI Platform runtime version that includes a TensorFlow version matching the one used in the custom container. This field is required if the replica is a TPU worker that uses a custom container. Otherwise, do not specify this field. This must be a [runtime version that currently supports training with TPUs](/ml-engine/docs/tensorflow/runtime-version-list#tpu-support). Note that the version of TensorFlow included in a runtime version may differ from the numbering of the runtime version itself, because it may have a different [patch version](https://www.tensorflow.org/guide/version_compat#semantic_versioning_20). In this field, you must specify the runtime version (TensorFlow minor version). For example, if your custom container runs TensorFlow `1.x.y`, specify `1.x`. */ tpuTfVersion?: string; } + /** + * Configurations for logging request-response pairs. Currently only BigQuery logging is supported. The request and response will be converted to raw string and stored within the specified BigQuery table. The schema is: model: STRING version: STRING time: Timestamp raw_data: STRING raw_prediction: STRING ground_truth: STRING + */ + export interface Schema$GoogleCloudMlV1__RequestLoggingConfig { + /** + * Fully qualified BigQuery table name in the format of "[project_id].[dataset_name].[table_name]". + */ + bigqueryTableName?: string; + /** + * Percentage of the request being logged. The sampling window is the lifetime of the Version. Defaults to 0. + */ + samplingPercentage?: number; + } /** * Request message for the SetDefaultVersion request. */ @@ -660,10 +673,6 @@ export namespace ml_v1 { * Optional. Specifies the type of virtual machine to use for your training job's master worker. The following types are supported: <dl> <dt>standard</dt> <dd> A basic machine configuration suitable for training simple models with small to moderate datasets. </dd> <dt>large_model</dt> <dd> A machine with a lot of memory, specially suited for parameter servers when your model is large (having many hidden layers or layers with very large numbers of nodes). </dd> <dt>complex_model_s</dt> <dd> A machine suitable for the master and workers of the cluster when your model requires more computation than the standard machine can handle satisfactorily. </dd> <dt>complex_model_m</dt> <dd> A machine with roughly twice the number of cores and roughly double the memory of <i>complex_model_s</i>. </dd> <dt>complex_model_l</dt> <dd> A machine with roughly twice the number of cores and roughly double the memory of <i>complex_model_m</i>. </dd> <dt>standard_gpu</dt> <dd> A machine equivalent to <i>standard</i> that also includes a single NVIDIA Tesla K80 GPU. See more about <a href="/ml-engine/docs/tensorflow/using-gpus">using GPUs to train your model</a>. </dd> <dt>complex_model_m_gpu</dt> <dd> A machine equivalent to <i>complex_model_m</i> that also includes four NVIDIA Tesla K80 GPUs. </dd> <dt>complex_model_l_gpu</dt> <dd> A machine equivalent to <i>complex_model_l</i> that also includes eight NVIDIA Tesla K80 GPUs. </dd> <dt>standard_p100</dt> <dd> A machine equivalent to <i>standard</i> that also includes a single NVIDIA Tesla P100 GPU. </dd> <dt>complex_model_m_p100</dt> <dd> A machine equivalent to <i>complex_model_m</i> that also includes four NVIDIA Tesla P100 GPUs. </dd> <dt>standard_v100</dt> <dd> A machine equivalent to <i>standard</i> that also includes a single NVIDIA Tesla V100 GPU. </dd> <dt>large_model_v100</dt> <dd> A machine equivalent to <i>large_model</i> that also includes a single NVIDIA Tesla V100 GPU. </dd> <dt>complex_model_m_v100</dt> <dd> A machine equivalent to <i>complex_model_m</i> that also includes four NVIDIA Tesla V100 GPUs. </dd> <dt>complex_model_l_v100</dt> <dd> A machine equivalent to <i>complex_model_l</i> that also includes eight NVIDIA Tesla V100 GPUs. </dd> <dt>cloud_tpu</dt> <dd> A TPU VM including one Cloud TPU. See more about <a href="/ml-engine/docs/tensorflow/using-tpus">using TPUs to train your model</a>. </dd> </dl> You may also use certain Compute Engine machine types directly in this field. The following types are supported: - `n1-standard-4` - `n1-standard-8` - `n1-standard-16` - `n1-standard-32` - `n1-standard-64` - `n1-standard-96` - `n1-highmem-2` - `n1-highmem-4` - `n1-highmem-8` - `n1-highmem-16` - `n1-highmem-32` - `n1-highmem-64` - `n1-highmem-96` - `n1-highcpu-16` - `n1-highcpu-32` - `n1-highcpu-64` - `n1-highcpu-96` See more about [using Compute Engine machine types](/ml-engine/docs/tensorflow/machine-types#compute-engine-machine-types). You must set this value when `scaleTier` is set to `CUSTOM`. */ masterType?: string; - /** - * Optional. The maximum job running time. The default is 7 days. - */ - maxRunningTime?: string; /** * Required. The Google Cloud Storage location of the packages with the training program and any additional dependencies. The maximum number of package URIs is 100. */ @@ -814,6 +823,10 @@ export namespace ml_v1 { * Optional. The version of Python used in prediction. If not set, the default version is '2.7'. Python '3.5' is available when `runtime_version` is set to '1.4' and above. Python '2.7' works with all supported runtime versions. */ pythonVersion?: string; + /** + * Optional. Configures the request-response pair logging on predictions from this Version. + */ + requestLoggingConfig?: Schema$GoogleCloudMlV1__RequestLoggingConfig; /** * Optional. The AI Platform runtime version to use for this deployment. If not set, AI Platform uses the default stable version, 1.0. For more information, see the [runtime version list](/ml-engine/docs/runtime-version-list) and [how to manage runtime versions](/ml-engine/docs/versioning). */ @@ -887,7 +900,7 @@ export namespace ml_v1 { */ etag?: string; /** - * Deprecated. + * Specifies the format of the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ version?: number; } @@ -1438,7 +1451,7 @@ export namespace ml_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1890,7 +1903,7 @@ export namespace ml_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ 'options.requestedPolicyVersion'?: number; /** @@ -2432,7 +2445,7 @@ export namespace ml_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2891,7 +2904,7 @@ export namespace ml_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ 'options.requestedPolicyVersion'?: number; /** diff --git a/src/apis/monitoring/v3.ts b/src/apis/monitoring/v3.ts index 7d8ca9c0529..192feec4601 100644 --- a/src/apis/monitoring/v3.ts +++ b/src/apis/monitoring/v3.ts @@ -184,6 +184,10 @@ export namespace monitoring_v3 { * User-supplied key/value data to be used for organizing and identifying the AlertPolicy objects.The field can contain up to 64 entries. Each key and value is limited to 63 Unicode characters or 128 bytes, whichever is smaller. Labels and values can contain only lowercase letters, numerals, underscores, and dashes. Keys must begin with a letter. */ userLabels?: {[key: string]: string}; + /** + * Read-only description of how the alert policy is invalid. OK if the alert policy is valid. If not OK, the alert policy will not generate incidents. + */ + validity?: Schema$Status; } /** * A type of authentication to perform against the specified resource or URL that uses username and password. Currently, only Basic authentication is supported in Uptime Monitoring. @@ -328,6 +332,10 @@ export namespace monitoring_v3 { * String or regex content to match (max 1024 bytes) */ content?: string; + /** + * The matcher representing content match options which the check will run with. If the field is not specified (in previous versions), the option is set to be CONTAINS_STRING which performs content substring matching. + */ + matcher?: string; } /** * The CreateCollectdTimeSeries request. @@ -586,6 +594,10 @@ export namespace monitoring_v3 { * If true, use HTTPS instead of HTTP to run the check. */ useSsl?: boolean; + /** + * Boolean specifying whether to validate SSL certificates. Only applies to uptime_url checks. If use_ssl is false, setting this to true has no effect. + */ + validateSsl?: boolean; } /** * An internal checker allows uptime checks to run on private/internal GCP resources. @@ -1160,7 +1172,7 @@ export namespace monitoring_v3 { port?: number; } /** - * A closed time interval. It extends from the start time to the end time, and includes both: [startTime, endTime]. Valid time intervals depend on the MetricKind of the metric value. In no case can the end time be earlier than the start time. For a GAUGE metric, the startTime value is technically optional; if no value is specified, the start time defaults to the value of the end time, and the interval represents a single point in time. Such an interval is valid only for GAUGE metrics, which are point-in-time measurements. For DELTA and CUMULATIVE metrics, the start time must be later than the end time. In all cases, the start time of the next interval must be at least a microsecond after the end time of the previous interval. Because the interval is closed, if the start time of a new interval is the same as the end time of the previous interval, data written at the new start time could overwrite data written at the previous end time. + * A closed time interval. It extends from the start time to the end time, and includes both: [startTime, endTime]. Valid time intervals depend on the MetricKind of the metric value. In no case can the end time be earlier than the start time. For a GAUGE metric, the startTime value is technically optional; if no value is specified, the start time defaults to the value of the end time, and the interval represents a single point in time. Such an interval is valid only for GAUGE metrics, which are point-in-time measurements. For DELTA and CUMULATIVE metrics, the start time must be earlier than the end time. In all cases, the start time of the next interval must be at least a microsecond after the end time of the previous interval. Because the interval is closed, if the start time of a new interval is the same as the end time of the previous interval, data written at the new start time could overwrite data written at the previous end time. */ export interface Schema$TimeInterval { /** diff --git a/src/apis/pagespeedonline/v5.ts b/src/apis/pagespeedonline/v5.ts index 6bb51695d47..266c7b527ea 100644 --- a/src/apis/pagespeedonline/v5.ts +++ b/src/apis/pagespeedonline/v5.ts @@ -101,6 +101,7 @@ export namespace pagespeedonline_v5 { } } + export interface Schema$GoogleprotobufListValue {} export interface Schema$GoogleprotobufValue {} export interface Schema$LighthouseAuditResultV5 { /** @@ -242,7 +243,7 @@ export namespace pagespeedonline_v5 { /** * List of all run warnings in the LHR. Will always output to at least `[]`. */ - runWarnings?: any[]; + runWarnings?: Schema$GoogleprotobufListValue; /** * The Stack Pack advice strings. */ diff --git a/src/apis/people/v1.ts b/src/apis/people/v1.ts index 0e402043dde..6516c513d41 100644 --- a/src/apis/people/v1.ts +++ b/src/apis/people/v1.ts @@ -364,6 +364,15 @@ export namespace people_v1 { */ year?: number; } + /** + * The response for deleteing a contact's photo. + */ + export interface Schema$DeleteContactPhotoResponse { + /** + * The updated person, if person_fields is set in the DeleteContactPhotoRequest; otherwise this will be unset. + */ + person?: Schema$Person; + } /** * A read-only G Suite Domain membership. */ @@ -595,6 +604,10 @@ export namespace people_v1 { * The response to a modify contact group members request. */ export interface Schema$ModifyContactGroupMembersResponse { + /** + * The contact people resource names that cannot be removed from their last contact group. + */ + canNotRemoveLastContactGroupResourceNames?: string[]; /** * The contact people resource names that were not found. */ @@ -1156,6 +1169,28 @@ export namespace people_v1 { */ contactGroup?: Schema$ContactGroup; } + /** + * A request to update an existing contact's photo. All requests must have a valid photo format: JPEG or PNG. + */ + export interface Schema$UpdateContactPhotoRequest { + /** + * **Optional.** Not specifying any fields will skip the post mutate read. A field mask to restrict which fields on the person are returned. Multiple fields can be specified by separating them with commas. Valid values are: * addresses * ageRanges * biographies * birthdays * braggingRights * coverPhotos * emailAddresses * events * genders * imClients * interests * locales * memberships * metadata * names * nicknames * occupations * organizations * phoneNumbers * photos * relations * relationshipInterests * relationshipStatuses * residences * sipAddresses * skills * taglines * urls * userDefined + */ + personFields?: string; + /** + * Raw photo bytes + */ + photoBytes?: string; + } + /** + * The response for updating a contact's photo. + */ + export interface Schema$UpdateContactPhotoResponse { + /** + * The updated person, if person_fields is set in the UpdateContactPhotoRequest; otherwise this will be unset. + */ + person?: Schema$Person; + } /** * A person's associated URLs. */ @@ -2022,6 +2057,88 @@ export namespace people_v1 { } } + /** + * people.people.deleteContactPhoto + * @desc Delete a contact's photo. + * @alias people.people.deleteContactPhoto + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.personFields **Optional.** Not specifying any fields will skip the post mutate read. A field mask to restrict which fields on the person are returned. Multiple fields can be specified by separating them with commas. Valid values are: * addresses * ageRanges * biographies * birthdays * braggingRights * coverPhotos * emailAddresses * events * genders * imClients * interests * locales * memberships * metadata * names * nicknames * occupations * organizations * phoneNumbers * photos * relations * relationshipInterests * relationshipStatuses * residences * sipAddresses * skills * taglines * urls * userDefined + * @param {string} params.resourceName The resource name of the contact whose photo will be deleted. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + deleteContactPhoto( + params?: Params$Resource$People$Deletecontactphoto, + options?: MethodOptions + ): GaxiosPromise; + deleteContactPhoto( + params: Params$Resource$People$Deletecontactphoto, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + deleteContactPhoto( + params: Params$Resource$People$Deletecontactphoto, + callback: BodyResponseCallback + ): void; + deleteContactPhoto( + callback: BodyResponseCallback + ): void; + deleteContactPhoto( + paramsOrCallback?: + | Params$Resource$People$Deletecontactphoto + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$People$Deletecontactphoto; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$People$Deletecontactphoto; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://people.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+resourceName}:deleteContactPhoto').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['resourceName'], + pathParams: ['resourceName'], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest(parameters); + } + } + /** * people.people.get * @desc Provides information about a person by specifying a resource name. Use `people/me` to indicate the authenticated user.
                          The request throws a 400 error if 'personFields' is not specified. @@ -2173,7 +2290,7 @@ export namespace people_v1 { /** * people.people.updateContact - * @desc Update contact data for an existing contact person. Any non-contact data will not be modified. The request throws a 400 error if `updatePersonFields` is not specified.
                          The request throws a 400 error if `person.metadata.sources` is not specified for the contact to be updated.
                          The request throws a 412 error if `person.metadata.sources.etag` is different than the contact's etag, which indicates the contact has changed since its data was read. Clients should get the latest person and re-apply their updates to the latest person. + * @desc Update contact data for an existing contact person. Any non-contact data will not be modified. The request throws a 400 error if `updatePersonFields` is not specified.
                          The request throws a 400 error if `person.metadata.sources` is not specified for the contact to be updated.
                          The request throws a 400 error with an error with reason `"failedPrecondition"` if `person.metadata.sources.etag` is different than the contact's etag, which indicates the contact has changed since its data was read. Clients should get the latest person and re-apply their updates to the latest person. * @alias people.people.updateContact * @memberOf! () * @@ -2244,6 +2361,88 @@ export namespace people_v1 { return createAPIRequest(parameters); } } + + /** + * people.people.updateContactPhoto + * @desc Update a contact's photo. + * @alias people.people.updateContactPhoto + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.resourceName Person resource name + * @param {().UpdateContactPhotoRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + updateContactPhoto( + params?: Params$Resource$People$Updatecontactphoto, + options?: MethodOptions + ): GaxiosPromise; + updateContactPhoto( + params: Params$Resource$People$Updatecontactphoto, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + updateContactPhoto( + params: Params$Resource$People$Updatecontactphoto, + callback: BodyResponseCallback + ): void; + updateContactPhoto( + callback: BodyResponseCallback + ): void; + updateContactPhoto( + paramsOrCallback?: + | Params$Resource$People$Updatecontactphoto + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$People$Updatecontactphoto; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$People$Updatecontactphoto; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://people.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+resourceName}:updateContactPhoto').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'PATCH', + }, + options + ), + params, + requiredParams: ['resourceName'], + pathParams: ['resourceName'], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest(parameters); + } + } } export interface Params$Resource$People$Createcontact @@ -2275,6 +2474,22 @@ export namespace people_v1 { */ resourceName?: string; } + export interface Params$Resource$People$Deletecontactphoto + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * **Optional.** Not specifying any fields will skip the post mutate read. A field mask to restrict which fields on the person are returned. Multiple fields can be specified by separating them with commas. Valid values are: * addresses * ageRanges * biographies * birthdays * braggingRights * coverPhotos * emailAddresses * events * genders * imClients * interests * locales * memberships * metadata * names * nicknames * occupations * organizations * phoneNumbers * photos * relations * relationshipInterests * relationshipStatuses * residences * sipAddresses * skills * taglines * urls * userDefined + */ + personFields?: string; + /** + * The resource name of the contact whose photo will be deleted. + */ + resourceName?: string; + } export interface Params$Resource$People$Get extends StandardParameters { /** * Auth client or API Key for the request @@ -2335,6 +2550,23 @@ export namespace people_v1 { */ requestBody?: Schema$Person; } + export interface Params$Resource$People$Updatecontactphoto + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Person resource name + */ + resourceName?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$UpdateContactPhotoRequest; + } export class Resource$People$Connections { context: APIRequestContext; diff --git a/src/apis/pubsub/v1.ts b/src/apis/pubsub/v1.ts index cbc7c5e3574..e247fae983c 100644 --- a/src/apis/pubsub/v1.ts +++ b/src/apis/pubsub/v1.ts @@ -135,7 +135,7 @@ export namespace pubsub_v1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -305,11 +305,11 @@ export namespace pubsub_v1 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** - * Deprecated. + * Specifies the format of the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ version?: number; } @@ -357,7 +357,7 @@ export namespace pubsub_v1 { */ export interface Schema$PullRequest { /** - * The maximum number of messages returned for this request. The Pub/Sub system may return fewer than the number specified. + * The maximum number of messages to return for this request. Must be a positive integer. The Pub/Sub system may return fewer than the number specified. */ maxMessages?: number; /** @@ -379,7 +379,7 @@ export namespace pubsub_v1 { */ export interface Schema$PushConfig { /** - * Endpoint configuration attributes. Every endpoint has a set of API supported attributes that can be used to control different aspects of the message delivery. The currently supported attribute is `x-goog-version`, which you can use to change the format of the pushed message. This attribute indicates the version of the data expected by the endpoint. This controls the shape of the pushed message (i.e., its fields and metadata). The endpoint version is based on the version of the Pub/Sub API. If not present during the `CreateSubscription` call, it will default to the version of the API used to make such call. If not present during a `ModifyPushConfig` call, its value will not be changed. `GetSubscription` calls will always return a valid version, even if the subscription was created without this attribute. The possible values for this attribute are: * `v1beta1`: uses the push format defined in the v1beta1 Pub/Sub API. * `v1` or `v1beta2`: uses the push format defined in the v1 Pub/Sub API. + * Endpoint configuration attributes that can be used to control different aspects of the message delivery. The only currently supported attribute is `x-goog-version`, which you can use to change the format of the pushed message. This attribute indicates the version of the data expected by the endpoint. This controls the shape of the pushed message (i.e., its fields and metadata). If not present during the `CreateSubscription` call, it will default to the version of the Pub/Sub API used to make such call. If not present in a `ModifyPushConfig` call, its value will not be changed. `GetSubscription` calls will always return a valid version, even if the subscription was created without this attribute. The only supported values for the `x-goog-version` attribute are: * `v1beta1`: uses the push format defined in the v1beta1 Pub/Sub API. * `v1` or `v1beta2`: uses the push format defined in the v1 Pub/Sub API. For example: <pre><code>attributes { "x-goog-version": "v1" } </code></pre> */ attributes?: {[key: string]: string}; /** @@ -996,7 +996,7 @@ export namespace pubsub_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1628,7 +1628,7 @@ export namespace pubsub_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ 'options.requestedPolicyVersion'?: number; /** @@ -2254,7 +2254,7 @@ export namespace pubsub_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3408,7 +3408,7 @@ export namespace pubsub_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ 'options.requestedPolicyVersion'?: number; /** @@ -3977,7 +3977,7 @@ export namespace pubsub_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -4738,7 +4738,7 @@ export namespace pubsub_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ 'options.requestedPolicyVersion'?: number; /** diff --git a/src/apis/pubsub/v1beta2.ts b/src/apis/pubsub/v1beta2.ts index 2c477a406cc..9e7c1a7ca12 100644 --- a/src/apis/pubsub/v1beta2.ts +++ b/src/apis/pubsub/v1beta2.ts @@ -135,7 +135,7 @@ export namespace pubsub_v1beta2 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -255,11 +255,11 @@ export namespace pubsub_v1beta2 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** - * Deprecated. + * Specifies the format of the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ version?: number; } @@ -727,7 +727,7 @@ export namespace pubsub_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1317,7 +1317,7 @@ export namespace pubsub_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ 'options.requestedPolicyVersion'?: number; /** @@ -1656,7 +1656,7 @@ export namespace pubsub_v1beta2 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2078,7 +2078,7 @@ export namespace pubsub_v1beta2 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ 'options.requestedPolicyVersion'?: number; /** diff --git a/src/apis/remotebuildexecution/v1.ts b/src/apis/remotebuildexecution/v1.ts index b845ca929da..9c5f0dd9d04 100644 --- a/src/apis/remotebuildexecution/v1.ts +++ b/src/apis/remotebuildexecution/v1.ts @@ -600,6 +600,19 @@ export namespace remotebuildexecution_v1 { */ message?: string; } + /** + * AcceleratorConfig defines the accelerator cards to attach to the VM. + */ + export interface Schema$GoogleDevtoolsRemotebuildexecutionAdminV1alphaAcceleratorConfig { + /** + * The number of the guest accelerator cards exposed to this VM. + */ + acceleratorCount?: string; + /** + * The type of accelerator to attach to this VM, e.g. "nvidia-tesla-k80" for nVidia Tesla K80. + */ + acceleratorType?: string; + } /** * The request used for `CreateInstance`. */ @@ -705,7 +718,7 @@ export namespace remotebuildexecution_v1 { } export interface Schema$GoogleDevtoolsRemotebuildexecutionAdminV1alphaListWorkerPoolsRequest { /** - * Optional. A filter to constrain the pools returned. Filters have the form: <field> <operator> <value> [[AND|OR] <field> <operator> <value>]... <field> is the path for a field or map key in the Pool proto message. e.g. "configuration.disk_size_gb" or "configuration.labels.key". <operator> can be one of "<", "<=", ">=", ">", "=", "!=", ":". ":" is a HAS operation for strings and repeated primitive fields. <value> is the value to test, case-insensitive for strings. "*" stands for any value and can be used to test for key presence. Parenthesis determine AND/OR precedence. In space separated restrictions, AND is implicit, e.g. "a = b x = y" is equivalent to "a = b AND x = y". Example filter: configuration.labels.key1 = * AND (state = RUNNING OR state = UPDATING) + * Optional. A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. String values are case-insensitive. The comparison operator must be either `:`, `=`, `!=`, `>`, `>=`, `<=` or `<`. The `:` operator can be used with string fields to match substrings. For non-string fields it is equivalent to the `=` operator. The `:*` comparison can be used to test whether a key has been defined. You can also filter on nested fields. To filter on multiple expressions, you can separate expression using `AND` and `OR` operators, using parentheses to specify precedence. If neither operator is specified, `AND` is assumed. Examples: Include only pools with more than 100 reserved workers: `(worker_count > 100) (worker_config.reserved = true)` Include only pools with a certain label or machines of the n1-standard family: `worker_config.labels.key1 : * OR worker_config.machine_type: n1-standard` */ filter?: string; /** @@ -736,6 +749,10 @@ export namespace remotebuildexecution_v1 { * Defines the configuration to be used for a creating workers in the worker pool. */ export interface Schema$GoogleDevtoolsRemotebuildexecutionAdminV1alphaWorkerConfig { + /** + * The accelerator card attached to each VM. + */ + accelerator?: Schema$GoogleDevtoolsRemotebuildexecutionAdminV1alphaAcceleratorConfig; /** * Required. Size of the disk attached to the worker, in GB. See https://cloud.google.com/compute/docs/disks/ */ @@ -745,7 +762,7 @@ export namespace remotebuildexecution_v1 { */ diskType?: string; /** - * Labels associated with the workers. Label keys and values can be no longer than 63 characters, can only contain lowercase letters, numeric characters, underscores and dashes. International letters are permitted. Keys must start with a letter but values are optional. There can not be more than 64 labels per resource. + * Labels associated with the workers. Label keys and values can be no longer than 63 characters, can only contain lowercase letters, numeric characters, underscores and dashes. International letters are permitted. Label keys must start with a letter. Label values are optional. There can not be more than 64 labels per resource. */ labels?: {[key: string]: string}; /** diff --git a/src/apis/remotebuildexecution/v1alpha.ts b/src/apis/remotebuildexecution/v1alpha.ts index 525c4f2f047..fb038dfe91d 100644 --- a/src/apis/remotebuildexecution/v1alpha.ts +++ b/src/apis/remotebuildexecution/v1alpha.ts @@ -585,6 +585,19 @@ export namespace remotebuildexecution_v1alpha { */ message?: string; } + /** + * AcceleratorConfig defines the accelerator cards to attach to the VM. + */ + export interface Schema$GoogleDevtoolsRemotebuildexecutionAdminV1alphaAcceleratorConfig { + /** + * The number of the guest accelerator cards exposed to this VM. + */ + acceleratorCount?: string; + /** + * The type of accelerator to attach to this VM, e.g. "nvidia-tesla-k80" for nVidia Tesla K80. + */ + acceleratorType?: string; + } /** * The request used for `CreateInstance`. */ @@ -690,7 +703,7 @@ export namespace remotebuildexecution_v1alpha { } export interface Schema$GoogleDevtoolsRemotebuildexecutionAdminV1alphaListWorkerPoolsRequest { /** - * Optional. A filter to constrain the pools returned. Filters have the form: <field> <operator> <value> [[AND|OR] <field> <operator> <value>]... <field> is the path for a field or map key in the Pool proto message. e.g. "configuration.disk_size_gb" or "configuration.labels.key". <operator> can be one of "<", "<=", ">=", ">", "=", "!=", ":". ":" is a HAS operation for strings and repeated primitive fields. <value> is the value to test, case-insensitive for strings. "*" stands for any value and can be used to test for key presence. Parenthesis determine AND/OR precedence. In space separated restrictions, AND is implicit, e.g. "a = b x = y" is equivalent to "a = b AND x = y". Example filter: configuration.labels.key1 = * AND (state = RUNNING OR state = UPDATING) + * Optional. A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. String values are case-insensitive. The comparison operator must be either `:`, `=`, `!=`, `>`, `>=`, `<=` or `<`. The `:` operator can be used with string fields to match substrings. For non-string fields it is equivalent to the `=` operator. The `:*` comparison can be used to test whether a key has been defined. You can also filter on nested fields. To filter on multiple expressions, you can separate expression using `AND` and `OR` operators, using parentheses to specify precedence. If neither operator is specified, `AND` is assumed. Examples: Include only pools with more than 100 reserved workers: `(worker_count > 100) (worker_config.reserved = true)` Include only pools with a certain label or machines of the n1-standard family: `worker_config.labels.key1 : * OR worker_config.machine_type: n1-standard` */ filter?: string; /** @@ -721,6 +734,10 @@ export namespace remotebuildexecution_v1alpha { * Defines the configuration to be used for a creating workers in the worker pool. */ export interface Schema$GoogleDevtoolsRemotebuildexecutionAdminV1alphaWorkerConfig { + /** + * The accelerator card attached to each VM. + */ + accelerator?: Schema$GoogleDevtoolsRemotebuildexecutionAdminV1alphaAcceleratorConfig; /** * Required. Size of the disk attached to the worker, in GB. See https://cloud.google.com/compute/docs/disks/ */ @@ -730,7 +747,7 @@ export namespace remotebuildexecution_v1alpha { */ diskType?: string; /** - * Labels associated with the workers. Label keys and values can be no longer than 63 characters, can only contain lowercase letters, numeric characters, underscores and dashes. International letters are permitted. Keys must start with a letter but values are optional. There can not be more than 64 labels per resource. + * Labels associated with the workers. Label keys and values can be no longer than 63 characters, can only contain lowercase letters, numeric characters, underscores and dashes. International letters are permitted. Label keys must start with a letter. Label values are optional. There can not be more than 64 labels per resource. */ labels?: {[key: string]: string}; /** @@ -2008,7 +2025,7 @@ export namespace remotebuildexecution_v1alpha { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.filter Optional. A filter to constrain the pools returned. Filters have the form: [[AND|OR] ]... is the path for a field or map key in the Pool proto message. e.g. "configuration.disk_size_gb" or "configuration.labels.key". can be one of "<", "<=", ">=", ">", "=", "!=", ":". ":" is a HAS operation for strings and repeated primitive fields. is the value to test, case-insensitive for strings. "*" stands for any value and can be used to test for key presence. Parenthesis determine AND/OR precedence. In space separated restrictions, AND is implicit, e.g. "a = b x = y" is equivalent to "a = b AND x = y". Example filter: configuration.labels.key1 = * AND (state = RUNNING OR state = UPDATING) + * @param {string=} params.filter Optional. A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. String values are case-insensitive. The comparison operator must be either `:`, `=`, `!=`, `>`, `>=`, `<=` or `<`. The `:` operator can be used with string fields to match substrings. For non-string fields it is equivalent to the `=` operator. The `:*` comparison can be used to test whether a key has been defined. You can also filter on nested fields. To filter on multiple expressions, you can separate expression using `AND` and `OR` operators, using parentheses to specify precedence. If neither operator is specified, `AND` is assumed. Examples: Include only pools with more than 100 reserved workers: `(worker_count > 100) (worker_config.reserved = true)` Include only pools with a certain label or machines of the n1-standard family: `worker_config.labels.key1 : * OR worker_config.machine_type: n1-standard` * @param {string} params.parent Resource name of the instance. Format: `projects/[PROJECT_ID]/instances/[INSTANCE_ID]`. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2233,7 +2250,7 @@ export namespace remotebuildexecution_v1alpha { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. A filter to constrain the pools returned. Filters have the form: [[AND|OR] ]... is the path for a field or map key in the Pool proto message. e.g. "configuration.disk_size_gb" or "configuration.labels.key". can be one of "<", "<=", ">=", ">", "=", "!=", ":". ":" is a HAS operation for strings and repeated primitive fields. is the value to test, case-insensitive for strings. "*" stands for any value and can be used to test for key presence. Parenthesis determine AND/OR precedence. In space separated restrictions, AND is implicit, e.g. "a = b x = y" is equivalent to "a = b AND x = y". Example filter: configuration.labels.key1 = * AND (state = RUNNING OR state = UPDATING) + * Optional. A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. String values are case-insensitive. The comparison operator must be either `:`, `=`, `!=`, `>`, `>=`, `<=` or `<`. The `:` operator can be used with string fields to match substrings. For non-string fields it is equivalent to the `=` operator. The `:*` comparison can be used to test whether a key has been defined. You can also filter on nested fields. To filter on multiple expressions, you can separate expression using `AND` and `OR` operators, using parentheses to specify precedence. If neither operator is specified, `AND` is assumed. Examples: Include only pools with more than 100 reserved workers: `(worker_count > 100) (worker_config.reserved = true)` Include only pools with a certain label or machines of the n1-standard family: `worker_config.labels.key1 : * OR worker_config.machine_type: n1-standard` */ filter?: string; /** diff --git a/src/apis/remotebuildexecution/v2.ts b/src/apis/remotebuildexecution/v2.ts index d67e2320136..a0f35211307 100644 --- a/src/apis/remotebuildexecution/v2.ts +++ b/src/apis/remotebuildexecution/v2.ts @@ -853,6 +853,19 @@ export namespace remotebuildexecution_v2 { */ message?: string; } + /** + * AcceleratorConfig defines the accelerator cards to attach to the VM. + */ + export interface Schema$GoogleDevtoolsRemotebuildexecutionAdminV1alphaAcceleratorConfig { + /** + * The number of the guest accelerator cards exposed to this VM. + */ + acceleratorCount?: string; + /** + * The type of accelerator to attach to this VM, e.g. "nvidia-tesla-k80" for nVidia Tesla K80. + */ + acceleratorType?: string; + } /** * The request used for `CreateInstance`. */ @@ -958,7 +971,7 @@ export namespace remotebuildexecution_v2 { } export interface Schema$GoogleDevtoolsRemotebuildexecutionAdminV1alphaListWorkerPoolsRequest { /** - * Optional. A filter to constrain the pools returned. Filters have the form: <field> <operator> <value> [[AND|OR] <field> <operator> <value>]... <field> is the path for a field or map key in the Pool proto message. e.g. "configuration.disk_size_gb" or "configuration.labels.key". <operator> can be one of "<", "<=", ">=", ">", "=", "!=", ":". ":" is a HAS operation for strings and repeated primitive fields. <value> is the value to test, case-insensitive for strings. "*" stands for any value and can be used to test for key presence. Parenthesis determine AND/OR precedence. In space separated restrictions, AND is implicit, e.g. "a = b x = y" is equivalent to "a = b AND x = y". Example filter: configuration.labels.key1 = * AND (state = RUNNING OR state = UPDATING) + * Optional. A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. String values are case-insensitive. The comparison operator must be either `:`, `=`, `!=`, `>`, `>=`, `<=` or `<`. The `:` operator can be used with string fields to match substrings. For non-string fields it is equivalent to the `=` operator. The `:*` comparison can be used to test whether a key has been defined. You can also filter on nested fields. To filter on multiple expressions, you can separate expression using `AND` and `OR` operators, using parentheses to specify precedence. If neither operator is specified, `AND` is assumed. Examples: Include only pools with more than 100 reserved workers: `(worker_count > 100) (worker_config.reserved = true)` Include only pools with a certain label or machines of the n1-standard family: `worker_config.labels.key1 : * OR worker_config.machine_type: n1-standard` */ filter?: string; /** @@ -989,6 +1002,10 @@ export namespace remotebuildexecution_v2 { * Defines the configuration to be used for a creating workers in the worker pool. */ export interface Schema$GoogleDevtoolsRemotebuildexecutionAdminV1alphaWorkerConfig { + /** + * The accelerator card attached to each VM. + */ + accelerator?: Schema$GoogleDevtoolsRemotebuildexecutionAdminV1alphaAcceleratorConfig; /** * Required. Size of the disk attached to the worker, in GB. See https://cloud.google.com/compute/docs/disks/ */ @@ -998,7 +1015,7 @@ export namespace remotebuildexecution_v2 { */ diskType?: string; /** - * Labels associated with the workers. Label keys and values can be no longer than 63 characters, can only contain lowercase letters, numeric characters, underscores and dashes. International letters are permitted. Keys must start with a letter but values are optional. There can not be more than 64 labels per resource. + * Labels associated with the workers. Label keys and values can be no longer than 63 characters, can only contain lowercase letters, numeric characters, underscores and dashes. International letters are permitted. Label keys must start with a letter. Label values are optional. There can not be more than 64 labels per resource. */ labels?: {[key: string]: string}; /** diff --git a/src/apis/run/index.ts b/src/apis/run/index.ts index c2213a5405a..3fab8e0727a 100644 --- a/src/apis/run/index.ts +++ b/src/apis/run/index.ts @@ -16,29 +16,19 @@ import {AuthPlus, getAPI, GoogleConfigurable} from 'googleapis-common'; import {run_v1} from './v1'; import {run_v1alpha1} from './v1alpha1'; -import {run_v1beta1} from './v1beta1'; export const VERSIONS = { v1: run_v1.Run, v1alpha1: run_v1alpha1.Run, - v1beta1: run_v1beta1.Run, }; export function run(version: 'v1'): run_v1.Run; export function run(options: run_v1.Options): run_v1.Run; export function run(version: 'v1alpha1'): run_v1alpha1.Run; export function run(options: run_v1alpha1.Options): run_v1alpha1.Run; -export function run(version: 'v1beta1'): run_v1beta1.Run; -export function run(options: run_v1beta1.Options): run_v1beta1.Run; -export function run( +export function run( this: GoogleConfigurable, - versionOrOptions: - | 'v1' - | run_v1.Options - | 'v1alpha1' - | run_v1alpha1.Options - | 'v1beta1' - | run_v1beta1.Options + versionOrOptions: 'v1' | run_v1.Options | 'v1alpha1' | run_v1alpha1.Options ) { return getAPI('run', versionOrOptions, VERSIONS, this); } diff --git a/src/apis/run/v1.ts b/src/apis/run/v1.ts index c7e0b5b06f6..73ad00c5091 100644 --- a/src/apis/run/v1.ts +++ b/src/apis/run/v1.ts @@ -117,6 +117,19 @@ export namespace run_v1 { } } + /** + * The response message for Locations.ListLocations. + */ + export interface Schema$ListLocationsResponse { + /** + * A list of locations that matches the specified filter in the request. + */ + locations?: Schema$Location[]; + /** + * The standard List next-page token. + */ + nextPageToken?: string; + } /** * A resource that represents Google Cloud Platform location. */ @@ -226,6 +239,85 @@ export namespace run_v1 { return createAPIRequest(parameters); } } + + /** + * run.projects.locations.list + * @desc Lists information about the supported locations for this service. + * @alias run.projects.locations.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.filter The standard list filter. + * @param {string} params.name The resource that owns the locations collection, if applicable. + * @param {integer=} params.pageSize The standard list page size. + * @param {string=} params.pageToken The standard list page token. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Locations$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Locations$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Locations$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Locations$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://run.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}/locations').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } export interface Params$Resource$Projects$Locations$Get @@ -240,4 +332,28 @@ export namespace run_v1 { */ name?: string; } + export interface Params$Resource$Projects$Locations$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The standard list filter. + */ + filter?: string; + /** + * The resource that owns the locations collection, if applicable. + */ + name?: string; + /** + * The standard list page size. + */ + pageSize?: number; + /** + * The standard list page token. + */ + pageToken?: string; + } } diff --git a/src/apis/run/v1alpha1.ts b/src/apis/run/v1alpha1.ts index 426f9cc17c7..f5e6fc848d4 100644 --- a/src/apis/run/v1alpha1.ts +++ b/src/apis/run/v1alpha1.ts @@ -130,7 +130,7 @@ export namespace run_v1alpha1 { url?: string; } /** - * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "fooservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:bar@gmail.com" ] } ] } ] } For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts foo@gmail.com from DATA_READ logging, and bar@gmail.com from DATA_WRITE logging. + * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "sampleservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts jose@example.com from DATA_READ logging, and aliya@example.com from DATA_WRITE logging. */ export interface Schema$AuditConfig { /** @@ -143,7 +143,7 @@ export namespace run_v1alpha1 { service?: string; } /** - * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting foo@gmail.com from DATA_READ logging. + * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ logging. */ export interface Schema$AuditLogConfig { /** @@ -177,7 +177,7 @@ export namespace run_v1alpha1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -211,6 +211,23 @@ export namespace run_v1alpha1 { */ optional?: boolean; } + /** + * Cloud Run fully managed: not supported Cloud Run on GKE: supported Selects a key from a ConfigMap. + */ + export interface Schema$ConfigMapKeySelector { + /** + * Cloud Run fully managed: not supported Cloud Run on GKE: supported The key to select. + */ + key?: string; + /** + * Cloud Run fully managed: not supported Cloud Run on GKE: supported The ConfigMap to select from. + */ + localObjectReference?: Schema$LocalObjectReference; + /** + * Cloud Run fully managed: not supported Cloud Run on GKE: supported Specify whether the ConfigMap or its key must be defined +optional + */ + optional?: boolean; + } /** * Adapts a ConfigMap into a volume. The contents of the target ConfigMap's Data field will be presented in a volume as files using the keys in the Data field as the file names, unless the items element is populated with specific mappings of keys to paths. */ @@ -563,6 +580,23 @@ export namespace run_v1alpha1 { * Variable references $(VAR_NAME) are expanded using the previous defined environment variables in the container and any route environment variables. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Defaults to "". +optional */ value?: string; + /** + * Cloud Run fully managed: not supported Cloud Run on GKE: supported Source for the environment variable's value. Cannot be used if value is not empty. +optional + */ + valueFrom?: Schema$EnvVarSource; + } + /** + * Cloud Run fully managed: not supported Cloud Run on GKE: supported EnvVarSource represents a source for the value of an EnvVar. + */ + export interface Schema$EnvVarSource { + /** + * Cloud Run fully managed: not supported Cloud Run on GKE: supported Selects a key of a ConfigMap. +optional + */ + configMapKeyRef?: Schema$ConfigMapKeySelector; + /** + * Cloud Run fully managed: not supported Cloud Run on GKE: supported Selects a key of a secret in the pod's namespace +optional + */ + secretKeyRef?: Schema$SecretKeySelector; } export interface Schema$EventType { /** @@ -582,6 +616,30 @@ export namespace run_v1alpha1 { */ spec?: Schema$EventTypeSpec; } + export interface Schema$EventTypeImporter { + /** + * The API version of the importer CRD. + */ + apiVersion?: string; + /** + * The kind of the importer CRD. + */ + kind?: string; + /** + * Parameters required to create an importer for the EventType. + */ + parameters?: Schema$EventTypeParameter[]; + } + export interface Schema$EventTypeParameter { + /** + * Description of the parameter. E.g. "Google Cloud Project Id." + */ + description?: string; + /** + * Name of the parameter. E.g. googleCloudProject. + */ + name?: string; + } export interface Schema$EventTypeSpec { /** * Refers to the Broker that can provide the EventType. @@ -591,6 +649,10 @@ export namespace run_v1alpha1 { * Description is a string describing what the EventType is about. +optional */ description?: string; + /** + * The importer that provides this EventType to the eventing mesh. + */ + importer?: Schema$EventTypeImporter; /** * Schema is a URI with the EventType schema. It may be a JSON schema, a protobuf schema, etc. +optional */ @@ -634,6 +696,23 @@ export namespace run_v1alpha1 { */ title?: string; } + /** + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). + */ + export interface Schema$GoogleRpcStatus { + /** + * The status code, which should be an enum value of google.rpc.Code. + */ + code?: number; + /** + * A list of messages that carry the error details. There is a common set of message types for APIs to use. + */ + details?: Array<{[key: string]: any}>; + /** + * A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. + */ + message?: string; + } /** * Handler defines a specific action that should be taken */ @@ -722,7 +801,7 @@ export namespace run_v1alpha1 { /** * The type of the value. */ - type?: string; + type?: number; } /** * Maps a string key to a path within a volume. @@ -787,6 +866,10 @@ export namespace run_v1alpha1 { * Metadata associated with this Configuration list. */ metadata?: Schema$ListMeta; + /** + * Details for the regions used during a global call including any failures. This is not populated when targeting a specific region. + */ + regionDetails?: {[key: string]: Schema$RegionDetails}; /** * Locations that could not be reached. */ @@ -812,6 +895,10 @@ export namespace run_v1alpha1 { * Metadata associated with this DomainMapping list. */ metadata?: Schema$ListMeta; + /** + * Details for the regions used during a global call including any failures. This is not populated when targeting a specific region. + */ + regionDetails?: {[key: string]: Schema$RegionDetails}; } /** * ListEventTypesResponse is a list of EventType resources. @@ -833,6 +920,10 @@ export namespace run_v1alpha1 { * Metadata associated with this EventType list. */ metadata?: Schema$ListMeta; + /** + * Details for the regions used during a global call including any failures. This is not populated when targeting a specific region. + */ + regionDetails?: {[key: string]: Schema$RegionDetails}; /** * Locations that could not be reached. */ @@ -888,6 +979,10 @@ export namespace run_v1alpha1 { * Metadata associated with this revision list. */ metadata?: Schema$ListMeta; + /** + * Details for the regions used during a global call including any failures. This is not populated when targeting a specific region. + */ + regionDetails?: {[key: string]: Schema$RegionDetails}; /** * Locations that could not be reached. */ @@ -913,6 +1008,10 @@ export namespace run_v1alpha1 { * Metadata associated with this Route list. */ metadata?: Schema$ListMeta; + /** + * Details for the regions used during a global call including any failures. This is not populated when targeting a specific region. + */ + regionDetails?: {[key: string]: Schema$RegionDetails}; /** * Locations that could not be reached. */ @@ -938,6 +1037,10 @@ export namespace run_v1alpha1 { * Metadata associated with this Service list. */ metadata?: Schema$ListMeta; + /** + * Details for the regions used during a global call including any failures. This is not populated when targeting a specific region. + */ + regionDetails?: {[key: string]: Schema$RegionDetails}; /** * Locations that could not be reached. */ @@ -963,6 +1066,10 @@ export namespace run_v1alpha1 { * Metadata associated with this Trigger list. */ metadata?: Schema$ListMeta; + /** + * Details for the regions used during a global call including any failures. This is not populated when targeting a specific region. + */ + regionDetails?: {[key: string]: Schema$RegionDetails}; /** * Locations that could not be reached. */ @@ -1146,11 +1253,11 @@ export namespace run_v1alpha1 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** - * Deprecated. + * Specifies the format of the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ version?: number; } @@ -1192,6 +1299,15 @@ export namespace run_v1alpha1 { */ string?: string; } + /** + * Information for a regional call used for a global API. + */ + export interface Schema$RegionDetails { + /** + * The status indicating why the regional call failed + */ + error?: Schema$GoogleRpcStatus; + } /** * A DNS resource record. */ @@ -1297,7 +1413,7 @@ export namespace run_v1alpha1 { */ container?: Schema$Container; /** - * ContainerConcurrency specifies the maximum allowed in-flight (concurrent) requests per container of the Revision. Values are: - `0` thread-safe, the system should manage the max concurrency. This is the default value. - `1` not-thread-safe. Single concurrency - `2-N` thread-safe, max concurrency of N + * (Optional) ContainerConcurrency specifies the maximum allowed in-flight (concurrent) requests per container instance of the Revision. Cloud Run fully managed: supported, defaults to 80 Cloud Run on GKE: supported, defaults to 0, which means concurrency to the application is not limited, and the system decides the target concurrency for the autoscaler. */ containerConcurrency?: number; /** @@ -1473,6 +1589,23 @@ export namespace run_v1alpha1 { */ optional?: boolean; } + /** + * Cloud Run fully managed: not supported Cloud Run on GKE: supported SecretKeySelector selects a key of a Secret. + */ + export interface Schema$SecretKeySelector { + /** + * Cloud Run fully managed: not supported Cloud Run on GKE: supported The key of the secret to select from. Must be a valid secret key. + */ + key?: string; + /** + * Cloud Run fully managed: not supported Cloud Run on GKE: supported The name of the secret in the pod's namespace to select from. + */ + localObjectReference?: Schema$LocalObjectReference; + /** + * Cloud Run fully managed: not supported Cloud Run on GKE: supported Specify whether the Secret or its key must be defined +optional + */ + optional?: boolean; + } /** * The contents of the target Secret's Data field will be presented in a volume as files using the keys in the Data field as the file names. */ @@ -1517,7 +1650,7 @@ export namespace run_v1alpha1 { /** * The GID to run the entrypoint of the container process. Uses runtime default if unset. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. +optional */ - runAsGroup?: string; + runAsGroup?: number; /** * Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. +optional */ @@ -1525,7 +1658,7 @@ export namespace run_v1alpha1 { /** * The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. +optional */ - runAsUser?: string; + runAsUser?: number; /** * The SELinux context to be applied to the container. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. +optional */ @@ -1782,7 +1915,7 @@ export namespace run_v1alpha1 { */ configurationName?: string; /** - * LatestRevision may be optionally provided to indicate that the latest ready Revision of the Configuration should be used for this traffic target. When provided LatestRevision must be true if RevisionName is empty; it must be false when RevisionName is non-empty. Not currently supported in Cloud Run. +optional + * LatestRevision may be optionally provided to indicate that the latest ready Revision of the Configuration should be used for this traffic target. When provided LatestRevision must be true if RevisionName is empty; it must be false when RevisionName is non-empty. +optional */ latestRevision?: boolean; /** @@ -1867,6 +2000,16 @@ export namespace run_v1alpha1 { source?: string; type?: string; } + export interface Schema$TriggerImporterSpec { + /** + * Arguments to use for the importer. These must match the parameters in the EventType's importer. + */ + arguments?: {[key: string]: string}; + /** + * Name of the EventType that this importer provides. + */ + eventTypeName?: string; + } /** * The desired state of the Trigger. */ @@ -1876,9 +2019,13 @@ export namespace run_v1alpha1 { */ broker?: string; /** - * Filter is the filter to apply against all events from the Broker. Only events that pass this filter will be sent to the Subscriber. If not specified, will default to allowing all events. This must be specified in Cloud Run. + * Filter is the filter to apply against all events from the Broker. Only events that pass this filter will be sent to the Subscriber. */ filter?: Schema$TriggerFilter; + /** + * Specification of the importers that will provide events to the trigger. Note, for Cloud Run, the importers will only be used if a filter is not specified. + */ + importers?: Schema$TriggerImporterSpec[]; /** * Subscriber is the addressable that receives events from the Broker that pass the Filter. It is required. E.g. https://us-central1-myproject.cloudfunctions.net/myfunction or /namespaces/my-project/services/my-service. */ @@ -6309,7 +6456,7 @@ export namespace run_v1alpha1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -6749,7 +6896,7 @@ export namespace run_v1alpha1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ 'options.requestedPolicyVersion'?: number; /** diff --git a/src/apis/run/v1beta1.ts b/src/apis/run/v1beta1.ts deleted file mode 100644 index a4d1e60901d..00000000000 --- a/src/apis/run/v1beta1.ts +++ /dev/null @@ -1,278 +0,0 @@ -/** - * Copyright 2019 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { - OAuth2Client, - JWT, - Compute, - UserRefreshClient, -} from 'google-auth-library'; -import { - GoogleConfigurable, - createAPIRequest, - MethodOptions, - GlobalOptions, - BodyResponseCallback, - APIRequestContext, -} from 'googleapis-common'; -import {GaxiosPromise} from 'gaxios'; - -// tslint:disable: no-any -// tslint:disable: class-name -// tslint:disable: variable-name -// tslint:disable: jsdoc-format -// tslint:disable: no-namespace - -export namespace run_v1beta1 { - export interface Options extends GlobalOptions { - version: 'v1beta1'; - } - - interface StandardParameters { - /** - * V1 error format. - */ - '$.xgafv'?: string; - /** - * OAuth access token. - */ - access_token?: string; - /** - * Data format for response. - */ - alt?: string; - /** - * JSONP - */ - callback?: string; - /** - * Selector specifying which fields to include in a partial response. - */ - fields?: string; - /** - * 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. - */ - key?: string; - /** - * OAuth 2.0 token for the current user. - */ - oauth_token?: string; - /** - * Returns response with indentations and line breaks. - */ - prettyPrint?: boolean; - /** - * 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. - */ - quotaUser?: string; - /** - * Legacy upload protocol for media (e.g. "media", "multipart"). - */ - uploadType?: string; - /** - * Upload protocol for media (e.g. "raw", "multipart"). - */ - upload_protocol?: string; - } - - /** - * Cloud Run API - * - * Deploy and manage user provided container images that scale automatically based on HTTP traffic. - * - * @example - * const {google} = require('googleapis'); - * const run = google.run('v1beta1'); - * - * @namespace run - * @type {Function} - * @version v1beta1 - * @variation v1beta1 - * @param {object=} options Options for Run - */ - export class Run { - context: APIRequestContext; - projects: Resource$Projects; - - constructor(options: GlobalOptions, google?: GoogleConfigurable) { - this.context = { - _options: options || {}, - google, - }; - - this.projects = new Resource$Projects(this.context); - } - } - - /** - * The response message for Locations.ListLocations. - */ - export interface Schema$ListLocationsResponse { - /** - * A list of locations that matches the specified filter in the request. - */ - locations?: Schema$Location[]; - /** - * The standard List next-page token. - */ - nextPageToken?: string; - } - /** - * A resource that represents Google Cloud Platform location. - */ - export interface Schema$Location { - /** - * The friendly name for this location, typically a nearby city name. For example, "Tokyo". - */ - displayName?: string; - /** - * Cross-service attributes for the location. For example {"cloud.googleapis.com/region": "us-east1"} - */ - labels?: {[key: string]: string}; - /** - * The canonical id for this location. For example: `"us-east1"`. - */ - locationId?: string; - /** - * Service-specific metadata. For example the available capacity at the given location. - */ - metadata?: {[key: string]: any}; - /** - * Resource name for the location, which may vary between implementations. For example: `"projects/example-project/locations/us-east1"` - */ - name?: string; - } - - export class Resource$Projects { - context: APIRequestContext; - locations: Resource$Projects$Locations; - constructor(context: APIRequestContext) { - this.context = context; - this.locations = new Resource$Projects$Locations(this.context); - } - } - - export class Resource$Projects$Locations { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } - - /** - * run.projects.locations.list - * @desc Lists information about the supported locations for this service. - * @alias run.projects.locations.list - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string=} params.filter The standard list filter. - * @param {string} params.name The resource that owns the locations collection, if applicable. - * @param {integer=} params.pageSize The standard list page size. - * @param {string=} params.pageToken The standard list page token. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - list( - params?: Params$Resource$Projects$Locations$List, - options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Projects$Locations$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - list( - params: Params$Resource$Projects$Locations$List, - callback: BodyResponseCallback - ): void; - list(callback: BodyResponseCallback): void; - list( - paramsOrCallback?: - | Params$Resource$Projects$Locations$List - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Projects$Locations$List; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Projects$Locations$List; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = options.rootUrl || 'https://run.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1beta1/{+name}/locations').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'GET', - }, - options - ), - params, - requiredParams: ['name'], - pathParams: ['name'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Projects$Locations$List - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The standard list filter. - */ - filter?: string; - /** - * The resource that owns the locations collection, if applicable. - */ - name?: string; - /** - * The standard list page size. - */ - pageSize?: number; - /** - * The standard list page token. - */ - pageToken?: string; - } -} diff --git a/src/apis/runtimeconfig/v1beta1.ts b/src/apis/runtimeconfig/v1beta1.ts index 02316af8a1c..9634142b486 100644 --- a/src/apis/runtimeconfig/v1beta1.ts +++ b/src/apis/runtimeconfig/v1beta1.ts @@ -258,7 +258,7 @@ export namespace runtimeconfig_v1beta1 { */ etag?: string; /** - * Deprecated. + * Specifies the format of the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ version?: number; } @@ -634,7 +634,7 @@ export namespace runtimeconfig_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -1062,7 +1062,7 @@ export namespace runtimeconfig_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ 'options.requestedPolicyVersion'?: number; /** diff --git a/src/apis/securitycenter/v1.ts b/src/apis/securitycenter/v1.ts index 228cd14a80d..49974b464ad 100644 --- a/src/apis/securitycenter/v1.ts +++ b/src/apis/securitycenter/v1.ts @@ -184,10 +184,6 @@ export namespace securitycenter_v1 { * Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members. */ exemptedMembers?: string[]; - /** - * Specifies whether principals can be exempted for the same LogType in lower-level resource policies. If true, any lower-level exemptions will be ignored. - */ - ignoreChildExemptions?: boolean; /** * The log type that this config enables. */ @@ -294,7 +290,7 @@ export namespace securitycenter_v1 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ requestedPolicyVersion?: number; } @@ -333,7 +329,7 @@ export namespace securitycenter_v1 { */ compareDuration?: string; /** - * Expression that defines the filter to apply across assets. The expression is a list of zero or more restrictions combined via logical operators `AND` and `OR`. Parentheses are supported, and `OR` has higher precedence than `AND`. Restrictions have the form `<field> <operator> <value>` and may have a `-` character in front of them to indicate negation. The fields map to those defined in the Asset resource. Examples include: * name * security_center_properties.resource_name * resource_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `>`, `<`, `>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. The following field and operator combinations are supported: * name: `=` * update_time: `>`, `<`, `>=`, `<=`, `=` * create_time: `>`, `<`, `>=`, `<=`, `=` * iam_policy.policy_blob: `=`, `:` * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` * security_marks: `=`, `:` * security_center_properties.resource_name: `=`, `:` * security_center_properties.resource_type: `=`, `:` * security_center_properties.resource_parent: `=`, `:` * security_center_properties.resource_project: `=`, `:` * security_center_properties.resource_owners: `=`, `:` For example, `resource_properties.size = 100` is a valid filter string. + * Expression that defines the filter to apply across assets. The expression is a list of zero or more restrictions combined via logical operators `AND` and `OR`. Parentheses are supported, and `OR` has higher precedence than `AND`. Restrictions have the form `<field> <operator> <value>` and may have a `-` character in front of them to indicate negation. The fields map to those defined in the Asset resource. Examples include: * name * security_center_properties.resource_name * resource_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `>`, `<`, `>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. The following field and operator combinations are supported: * name: `=` * update_time: `=`, `>`, `<`, `>=`, `<=` Usage: This should be milliseconds since epoch or an RFC3339 string. Examples: "update_time = \"2019-06-10T16:07:18-07:00\"" "update_time = 1560208038000" * create_time: `=`, `>`, `<`, `>=`, `<=` Usage: This should be milliseconds since epoch or an RFC3339 string. Examples: "create_time = \"2019-06-10T16:07:18-07:00\"" "create_time = 1560208038000" * iam_policy.policy_blob: `=`, `:` * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` * security_marks: `=`, `:` * security_center_properties.resource_name: `=`, `:` * security_center_properties.resource_type: `=`, `:` * security_center_properties.resource_parent: `=`, `:` * security_center_properties.resource_project: `=`, `:` * security_center_properties.resource_owners: `=`, `:` For example, `resource_properties.size = 100` is a valid filter string. */ filter?: string; /** @@ -383,7 +379,7 @@ export namespace securitycenter_v1 { */ compareDuration?: string; /** - * Expression that defines the filter to apply across findings. The expression is a list of one or more restrictions combined via logical operators `AND` and `OR`. Parentheses are supported, and `OR` has higher precedence than `AND`. Restrictions have the form `<field> <operator> <value>` and may have a `-` character in front of them to indicate negation. Examples include: * name * source_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `>`, `<`, `>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. The following field and operator combinations are supported: * name: `=` * parent: `=`, `:` * resource_name: `=`, `:` * state: `=`, `:` * category: `=`, `:` * external_uri: `=`, `:` * event_time: `>`, `<`, `>=`, `<=` * security_marks: `=`, `:` * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` For example, `source_properties.size = 100` is a valid filter string. + * Expression that defines the filter to apply across findings. The expression is a list of one or more restrictions combined via logical operators `AND` and `OR`. Parentheses are supported, and `OR` has higher precedence than `AND`. Restrictions have the form `<field> <operator> <value>` and may have a `-` character in front of them to indicate negation. Examples include: * name * source_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `>`, `<`, `>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. The following field and operator combinations are supported: * name: `=` * parent: `=`, `:` * resource_name: `=`, `:` * state: `=`, `:` * category: `=`, `:` * external_uri: `=`, `:` * event_time: `=`, `>`, `<`, `>=`, `<=` Usage: This should be milliseconds since epoch or an RFC3339 string. Examples: "event_time = \"2019-06-10T16:07:18-07:00\"" "event_time = 1560208038000" * security_marks: `=`, `:` * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` For example, `source_properties.size = 100` is a valid filter string. */ filter?: string; /** @@ -1241,8 +1237,8 @@ export namespace securitycenter_v1 { * @param {object} params Parameters for request * @param {string=} params.compareDuration When compare_duration is set, the ListAssetsResult's "state_change" attribute is updated to indicate whether the asset was added, removed, or remained present during the compare_duration period of time that precedes the read_time. This is the time between (read_time - compare_duration) and read_time. The state_change value is derived based on the presence of the asset at the two points in time. Intermediate state changes between the two times don't affect the result. For example, the results aren't affected if the asset is removed and re-created again. Possible "state_change" values when compare_duration is specified: * "ADDED": indicates that the asset was not present at the start of compare_duration, but present at read_time. * "REMOVED": indicates that the asset was present at the start of compare_duration, but not present at read_time. * "ACTIVE": indicates that the asset was present at both the start and the end of the time period defined by compare_duration and read_time. If compare_duration is not specified, then the only possible state_change is "UNUSED", which will be the state_change set for all assets present at read_time. * @param {string=} params.fieldMask Optional. A field mask to specify the ListAssetsResult fields to be listed in the response. An empty field mask will list all fields. - * @param {string=} params.filter Expression that defines the filter to apply across assets. The expression is a list of zero or more restrictions combined via logical operators `AND` and `OR`. Parentheses are supported, and `OR` has higher precedence than `AND`. Restrictions have the form ` ` and may have a `-` character in front of them to indicate negation. The fields map to those defined in the Asset resource. Examples include: * name * security_center_properties.resource_name * resource_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `>`, `<`, `>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. The following are the allowed field and operator combinations: * name: `=` * update_time: `>`, `<`, `>=`, `<=` * iam_policy.policy_blob: `=`, `:` * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` * security_marks: `=`, `:` * security_center_properties.resource_name: `=`, `:` * security_center_properties.resource_type: `=`, `:` * security_center_properties.resource_parent: `=`, `:` * security_center_properties.resource_project: `=`, `:` * security_center_properties.resource_owners: `=`, `:` For example, `resource_properties.size = 100` is a valid filter string. - * @param {string=} params.orderBy Expression that defines what fields and order to use for sorting. The string value should follow SQL syntax: comma separated list of fields. For example: "name,resource_properties.a_property". The default sorting order is ascending. To specify descending order for a field, a suffix " desc" should be appended to the field name. For example: "name desc,resource_properties.a_property". Redundant space characters in the syntax are insignificant. "name desc,resource_properties.a_property" and " name desc , resource_properties.a_property " are equivalent. The following fields are supported: name update_time resource_properties security_marks security_center_properties.resource_name security_center_properties.resource_parent security_center_properties.resource_project security_center_properties.resource_type + * @param {string=} params.filter Expression that defines the filter to apply across assets. The expression is a list of zero or more restrictions combined via logical operators `AND` and `OR`. Parentheses are supported, and `OR` has higher precedence than `AND`. Restrictions have the form ` ` and may have a `-` character in front of them to indicate negation. The fields map to those defined in the Asset resource. Examples include: * name * security_center_properties.resource_name * resource_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `>`, `<`, `>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. The following are the allowed field and operator combinations: * name: `=` * update_time: `=`, `>`, `<`, `>=`, `<=` Usage: This should be milliseconds since epoch or an RFC3339 string. Examples: "update_time = \"2019-06-10T16:07:18-07:00\"" "update_time = 1560208038000" * create_time: `=`, `>`, `<`, `>=`, `<=` Usage: This should be milliseconds since epoch or an RFC3339 string. Examples: "create_time = \"2019-06-10T16:07:18-07:00\"" "create_time = 1560208038000" * iam_policy.policy_blob: `=`, `:` * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` * security_marks.marks: `=`, `:` * security_center_properties.resource_name: `=`, `:` * security_center_properties.resource_type: `=`, `:` * security_center_properties.resource_parent: `=`, `:` * security_center_properties.resource_project: `=`, `:` * security_center_properties.resource_owners: `=`, `:` For example, `resource_properties.size = 100` is a valid filter string. + * @param {string=} params.orderBy Expression that defines what fields and order to use for sorting. The string value should follow SQL syntax: comma separated list of fields. For example: "name,resource_properties.a_property". The default sorting order is ascending. To specify descending order for a field, a suffix " desc" should be appended to the field name. For example: "name desc,resource_properties.a_property". Redundant space characters in the syntax are insignificant. "name desc,resource_properties.a_property" and " name desc , resource_properties.a_property " are equivalent. The following fields are supported: name update_time resource_properties security_marks.marks security_center_properties.resource_name security_center_properties.resource_parent security_center_properties.resource_project security_center_properties.resource_type * @param {integer=} params.pageSize The maximum number of results to return in a single response. Default is 10, minimum is 1, maximum is 1000. * @param {string=} params.pageToken The value returned by the last `ListAssetsResponse`; indicates that this is a continuation of a prior `ListAssets` call, and that the system should return the next page of data. * @param {string} params.parent Name of the organization assets should belong to. Its format is "organizations/[organization_id]". @@ -1607,11 +1603,11 @@ export namespace securitycenter_v1 { */ fieldMask?: string; /** - * Expression that defines the filter to apply across assets. The expression is a list of zero or more restrictions combined via logical operators `AND` and `OR`. Parentheses are supported, and `OR` has higher precedence than `AND`. Restrictions have the form ` ` and may have a `-` character in front of them to indicate negation. The fields map to those defined in the Asset resource. Examples include: * name * security_center_properties.resource_name * resource_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `>`, `<`, `>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. The following are the allowed field and operator combinations: * name: `=` * update_time: `>`, `<`, `>=`, `<=` * iam_policy.policy_blob: `=`, `:` * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` * security_marks: `=`, `:` * security_center_properties.resource_name: `=`, `:` * security_center_properties.resource_type: `=`, `:` * security_center_properties.resource_parent: `=`, `:` * security_center_properties.resource_project: `=`, `:` * security_center_properties.resource_owners: `=`, `:` For example, `resource_properties.size = 100` is a valid filter string. + * Expression that defines the filter to apply across assets. The expression is a list of zero or more restrictions combined via logical operators `AND` and `OR`. Parentheses are supported, and `OR` has higher precedence than `AND`. Restrictions have the form ` ` and may have a `-` character in front of them to indicate negation. The fields map to those defined in the Asset resource. Examples include: * name * security_center_properties.resource_name * resource_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `>`, `<`, `>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. The following are the allowed field and operator combinations: * name: `=` * update_time: `=`, `>`, `<`, `>=`, `<=` Usage: This should be milliseconds since epoch or an RFC3339 string. Examples: "update_time = \"2019-06-10T16:07:18-07:00\"" "update_time = 1560208038000" * create_time: `=`, `>`, `<`, `>=`, `<=` Usage: This should be milliseconds since epoch or an RFC3339 string. Examples: "create_time = \"2019-06-10T16:07:18-07:00\"" "create_time = 1560208038000" * iam_policy.policy_blob: `=`, `:` * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` * security_marks.marks: `=`, `:` * security_center_properties.resource_name: `=`, `:` * security_center_properties.resource_type: `=`, `:` * security_center_properties.resource_parent: `=`, `:` * security_center_properties.resource_project: `=`, `:` * security_center_properties.resource_owners: `=`, `:` For example, `resource_properties.size = 100` is a valid filter string. */ filter?: string; /** - * Expression that defines what fields and order to use for sorting. The string value should follow SQL syntax: comma separated list of fields. For example: "name,resource_properties.a_property". The default sorting order is ascending. To specify descending order for a field, a suffix " desc" should be appended to the field name. For example: "name desc,resource_properties.a_property". Redundant space characters in the syntax are insignificant. "name desc,resource_properties.a_property" and " name desc , resource_properties.a_property " are equivalent. The following fields are supported: name update_time resource_properties security_marks security_center_properties.resource_name security_center_properties.resource_parent security_center_properties.resource_project security_center_properties.resource_type + * Expression that defines what fields and order to use for sorting. The string value should follow SQL syntax: comma separated list of fields. For example: "name,resource_properties.a_property". The default sorting order is ascending. To specify descending order for a field, a suffix " desc" should be appended to the field name. For example: "name desc,resource_properties.a_property". Redundant space characters in the syntax are insignificant. "name desc,resource_properties.a_property" and " name desc , resource_properties.a_property " are equivalent. The following fields are supported: name update_time resource_properties security_marks.marks security_center_properties.resource_name security_center_properties.resource_parent security_center_properties.resource_project security_center_properties.resource_type */ orderBy?: string; /** @@ -3589,8 +3585,8 @@ export namespace securitycenter_v1 { * @param {object} params Parameters for request * @param {string=} params.compareDuration When compare_duration is set, the ListFindingsResult's "state_change" attribute is updated to indicate whether the finding had its state changed, the finding's state remained unchanged, or if the finding was added in any state during the compare_duration period of time that precedes the read_time. This is the time between (read_time - compare_duration) and read_time. The state_change value is derived based on the presence and state of the finding at the two points in time. Intermediate state changes between the two times don't affect the result. For example, the results aren't affected if the finding is made inactive and then active again. Possible "state_change" values when compare_duration is specified: * "CHANGED": indicates that the finding was present at the start of compare_duration, but changed its state at read_time. * "UNCHANGED": indicates that the finding was present at the start of compare_duration and did not change state at read_time. * "ADDED": indicates that the finding was not present at the start of compare_duration, but was present at read_time. If compare_duration is not specified, then the only possible state_change is "UNUSED", which will be the state_change set for all findings present at read_time. * @param {string=} params.fieldMask Optional. A field mask to specify the Finding fields to be listed in the response. An empty field mask will list all fields. - * @param {string=} params.filter Expression that defines the filter to apply across findings. The expression is a list of one or more restrictions combined via logical operators `AND` and `OR`. Parentheses are supported, and `OR` has higher precedence than `AND`. Restrictions have the form ` ` and may have a `-` character in front of them to indicate negation. Examples include: * name * source_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `>`, `<`, `>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. The following field and operator combinations are supported: name: `=` parent: `=`, `:` resource_name: `=`, `:` state: `=`, `:` category: `=`, `:` external_uri: `=`, `:` event_time: `>`, `<`, `>=`, `<=` security_marks: `=`, `:` source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` For example, `source_properties.size = 100` is a valid filter string. - * @param {string=} params.orderBy Expression that defines what fields and order to use for sorting. The string value should follow SQL syntax: comma separated list of fields. For example: "name,resource_properties.a_property". The default sorting order is ascending. To specify descending order for a field, a suffix " desc" should be appended to the field name. For example: "name desc,source_properties.a_property". Redundant space characters in the syntax are insignificant. "name desc,source_properties.a_property" and " name desc , source_properties.a_property " are equivalent. The following fields are supported: name parent state category resource_name event_time source_properties security_marks + * @param {string=} params.filter Expression that defines the filter to apply across findings. The expression is a list of one or more restrictions combined via logical operators `AND` and `OR`. Parentheses are supported, and `OR` has higher precedence than `AND`. Restrictions have the form ` ` and may have a `-` character in front of them to indicate negation. Examples include: * name * source_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `>`, `<`, `>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. The following field and operator combinations are supported: name: `=` parent: `=`, `:` resource_name: `=`, `:` state: `=`, `:` category: `=`, `:` external_uri: `=`, `:` event_time: `=`, `>`, `<`, `>=`, `<=` Usage: This should be milliseconds since epoch or an RFC3339 string. Examples: "event_time = \"2019-06-10T16:07:18-07:00\"" "event_time = 1560208038000" security_marks.marks: `=`, `:` source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` For example, `source_properties.size = 100` is a valid filter string. + * @param {string=} params.orderBy Expression that defines what fields and order to use for sorting. The string value should follow SQL syntax: comma separated list of fields. For example: "name,resource_properties.a_property". The default sorting order is ascending. To specify descending order for a field, a suffix " desc" should be appended to the field name. For example: "name desc,source_properties.a_property". Redundant space characters in the syntax are insignificant. "name desc,source_properties.a_property" and " name desc , source_properties.a_property " are equivalent. The following fields are supported: name parent state category resource_name event_time source_properties security_marks.marks * @param {integer=} params.pageSize The maximum number of results to return in a single response. Default is 10, minimum is 1, maximum is 1000. * @param {string=} params.pageToken The value returned by the last `ListFindingsResponse`; indicates that this is a continuation of a prior `ListFindings` call, and that the system should return the next page of data. * @param {string} params.parent Name of the source the findings belong to. Its format is "organizations/[organization_id]/sources/[source_id]". To list across all sources provide a source_id of `-`. For example: organizations/123/sources/- @@ -4104,11 +4100,11 @@ export namespace securitycenter_v1 { */ fieldMask?: string; /** - * Expression that defines the filter to apply across findings. The expression is a list of one or more restrictions combined via logical operators `AND` and `OR`. Parentheses are supported, and `OR` has higher precedence than `AND`. Restrictions have the form ` ` and may have a `-` character in front of them to indicate negation. Examples include: * name * source_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `>`, `<`, `>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. The following field and operator combinations are supported: name: `=` parent: `=`, `:` resource_name: `=`, `:` state: `=`, `:` category: `=`, `:` external_uri: `=`, `:` event_time: `>`, `<`, `>=`, `<=` security_marks: `=`, `:` source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` For example, `source_properties.size = 100` is a valid filter string. + * Expression that defines the filter to apply across findings. The expression is a list of one or more restrictions combined via logical operators `AND` and `OR`. Parentheses are supported, and `OR` has higher precedence than `AND`. Restrictions have the form ` ` and may have a `-` character in front of them to indicate negation. Examples include: * name * source_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `>`, `<`, `>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. The following field and operator combinations are supported: name: `=` parent: `=`, `:` resource_name: `=`, `:` state: `=`, `:` category: `=`, `:` external_uri: `=`, `:` event_time: `=`, `>`, `<`, `>=`, `<=` Usage: This should be milliseconds since epoch or an RFC3339 string. Examples: "event_time = \"2019-06-10T16:07:18-07:00\"" "event_time = 1560208038000" security_marks.marks: `=`, `:` source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` For example, `source_properties.size = 100` is a valid filter string. */ filter?: string; /** - * Expression that defines what fields and order to use for sorting. The string value should follow SQL syntax: comma separated list of fields. For example: "name,resource_properties.a_property". The default sorting order is ascending. To specify descending order for a field, a suffix " desc" should be appended to the field name. For example: "name desc,source_properties.a_property". Redundant space characters in the syntax are insignificant. "name desc,source_properties.a_property" and " name desc , source_properties.a_property " are equivalent. The following fields are supported: name parent state category resource_name event_time source_properties security_marks + * Expression that defines what fields and order to use for sorting. The string value should follow SQL syntax: comma separated list of fields. For example: "name,resource_properties.a_property". The default sorting order is ascending. To specify descending order for a field, a suffix " desc" should be appended to the field name. For example: "name desc,source_properties.a_property". Redundant space characters in the syntax are insignificant. "name desc,source_properties.a_property" and " name desc , source_properties.a_property " are equivalent. The following fields are supported: name parent state category resource_name event_time source_properties security_marks.marks */ orderBy?: string; /** diff --git a/src/apis/securitycenter/v1beta1.ts b/src/apis/securitycenter/v1beta1.ts index 92c7c84e53b..ef63f725047 100644 --- a/src/apis/securitycenter/v1beta1.ts +++ b/src/apis/securitycenter/v1beta1.ts @@ -180,10 +180,6 @@ export namespace securitycenter_v1beta1 { * Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members. */ exemptedMembers?: string[]; - /** - * Specifies whether principals can be exempted for the same LogType in lower-level resource policies. If true, any lower-level exemptions will be ignored. - */ - ignoreChildExemptions?: boolean; /** * The log type that this config enables. */ @@ -294,7 +290,7 @@ export namespace securitycenter_v1beta1 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ requestedPolicyVersion?: number; } diff --git a/src/apis/servicebroker/v1.ts b/src/apis/servicebroker/v1.ts index 66a523c04be..0fb97ae97f5 100644 --- a/src/apis/servicebroker/v1.ts +++ b/src/apis/servicebroker/v1.ts @@ -213,7 +213,7 @@ export namespace servicebroker_v1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -461,7 +461,7 @@ export namespace servicebroker_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** diff --git a/src/apis/servicebroker/v1alpha1.ts b/src/apis/servicebroker/v1alpha1.ts index 65bf0ca3307..e9cebe9eaae 100644 --- a/src/apis/servicebroker/v1alpha1.ts +++ b/src/apis/servicebroker/v1alpha1.ts @@ -2304,7 +2304,7 @@ export namespace servicebroker_v1alpha1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -2555,7 +2555,7 @@ export namespace servicebroker_v1alpha1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** diff --git a/src/apis/servicebroker/v1beta1.ts b/src/apis/servicebroker/v1beta1.ts index 78dc75b2c2f..553fb446be4 100644 --- a/src/apis/servicebroker/v1beta1.ts +++ b/src/apis/servicebroker/v1beta1.ts @@ -2857,7 +2857,7 @@ export namespace servicebroker_v1beta1 { * @memberOf! () * * @param {object} params Parameters for request - * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * @param {integer=} params.options.requestedPolicyVersion Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. * @param {string} params.resource_ REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. @@ -3108,7 +3108,7 @@ export namespace servicebroker_v1beta1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Acceptable values are 0, 1, and 3. If the value is 0, or the field is omitted, policy format version 1 will be returned. */ 'options.requestedPolicyVersion'?: number; /** diff --git a/src/apis/serviceconsumermanagement/v1.ts b/src/apis/serviceconsumermanagement/v1.ts index ae36ba11638..94286417f1e 100644 --- a/src/apis/serviceconsumermanagement/v1.ts +++ b/src/apis/serviceconsumermanagement/v1.ts @@ -2268,7 +2268,7 @@ export namespace serviceconsumermanagement_v1 { /** * serviceconsumermanagement.services.tenancyUnits.create - * @desc Creates a tenancy unit with no tenant resources. + * @desc Creates a tenancy unit with no tenant resources. If tenancy unit already exists, it will be returned, however, in this case, returned TenancyUnit does not have tenant_resources field set and ListTenancyUnit has to be used to get a complete TenancyUnit with all fields populated. * @alias serviceconsumermanagement.services.tenancyUnits.create * @memberOf! () * diff --git a/src/apis/servicecontrol/v1.ts b/src/apis/servicecontrol/v1.ts index cff801abc2b..aedf3488fc4 100644 --- a/src/apis/servicecontrol/v1.ts +++ b/src/apis/servicecontrol/v1.ts @@ -119,7 +119,7 @@ export namespace servicecontrol_v1 { export interface Schema$AllocateInfo { /** - * A list of label keys that were unused by the server in processing the request. Thus, for similar requests repeated in a certain future time window, the caller can choose to ignore these labels in the requests to achieve better client-side cache hits and quota aggregation. + * A list of label keys that were unused by the server in processing the request. Thus, for similar requests repeated in a certain future time window, the caller can choose to ignore these labels in the requests to achieve better client-side cache hits and quota aggregation for rate quota. This field is not populated for allocation quota checks. */ unusedArguments?: string[]; } @@ -609,6 +609,10 @@ export namespace servicecontrol_v1 { * The severity of the log entry. The default value is `LogSeverity.DEFAULT`. */ severity?: string; + /** + * Optional. Source code location information associated with the log entry, if any. + */ + sourceLocation?: Schema$LogEntrySourceLocation; /** * The log entry payload, represented as a structure that is expressed as a JSON object. */ @@ -647,6 +651,23 @@ export namespace servicecontrol_v1 { */ producer?: string; } + /** + * Additional information about the source code location that produced the log entry. + */ + export interface Schema$LogEntrySourceLocation { + /** + * Optional. Source file name. Depending on the runtime environment, this might be a simple name or a fully-qualified name. + */ + file?: string; + /** + * Optional. Human-readable name of the function or method being invoked, with optional context such as the class or package name. This information may be used in contexts such as the logs viewer, where a file and line number are less meaningful. The format can vary by language. For example: `qual.if.ied.Class.method` (Java), `dir/package.func` (Go), `function` (Python). + */ + function?: string; + /** + * Optional. Line within the source file. 1-based; 0 indicates no line number available. + */ + line?: string; + } /** * Represents a single metric value. */ @@ -776,7 +797,7 @@ export namespace servicecontrol_v1 { userLabels?: {[key: string]: string}; } /** - * This message defines attributes for a node that handles a network request. The node can be either a service or an application that sends, forwards, or receives the request. Service peers should fill in the `service`, `principal`, and `labels` as appropriate. + * This message defines attributes for a node that handles a network request. The node can be either a service or an application that sends, forwards, or receives the request. Service peers should fill in `principal` and `labels` as appropriate. */ export interface Schema$Peer { /** @@ -799,10 +820,6 @@ export namespace servicecontrol_v1 { * The CLDR country/region code associated with the above IP address. If the IP address is private, the `region_code` should reflect the physical location where this peer is running. */ regionCode?: string; - /** - * The canonical service name of the peer. NOTE: different systems may have different service naming schemes. - */ - service?: string; } /** * Represents error information for QuotaOperation. @@ -944,10 +961,6 @@ export namespace servicecontrol_v1 { * The request authentication. May be absent for unauthenticated requests. Derived from the HTTP request `Authorization` header or equivalent. */ auth?: Schema$Auth; - /** - * The HTTP URL fragment. No URL decoding is performed. - */ - fragment?: string; /** * The HTTP request headers. If multiple headers share the same key, they must be merged according to the HTTP spec. All header keys must be lowercased, because HTTP header keys are case-insensitive. */ @@ -1035,7 +1048,7 @@ export namespace servicecontrol_v1 { */ service?: string; /** - * The type of the resource. The scheme is platform-specific because different platforms define their resources differently. + * The type of the resource. The syntax is platform-specific because different platforms define their resources differently. For Google APIs, the type format must be "{service}/{kind}". */ type?: string; } diff --git a/src/apis/servicemanagement/v1.ts b/src/apis/servicemanagement/v1.ts index 55f703e7501..4efcc6ea012 100644 --- a/src/apis/servicemanagement/v1.ts +++ b/src/apis/servicemanagement/v1.ts @@ -162,7 +162,7 @@ export namespace servicemanagement_v1 { version?: string; } /** - * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "fooservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:bar@gmail.com" ] } ] } ] } For fooservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts foo@gmail.com from DATA_READ logging, and bar@gmail.com from DATA_WRITE logging. + * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices" "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", }, { "log_type": "ADMIN_READ", } ] }, { "service": "sampleservice.googleapis.com" "audit_log_configs": [ { "log_type": "DATA_READ", }, { "log_type": "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts jose@example.com from DATA_READ logging, and aliya@example.com from DATA_WRITE logging. */ export interface Schema$AuditConfig { /** @@ -175,7 +175,7 @@ export namespace servicemanagement_v1 { service?: string; } /** - * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:foo@gmail.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting foo@gmail.com from DATA_READ logging. + * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE", } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ logging. */ export interface Schema$AuditLogConfig { /** @@ -329,7 +329,7 @@ export namespace servicemanagement_v1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -542,6 +542,10 @@ export namespace servicemanagement_v1 { * A list of documentation rules that apply to individual API elements. **NOTE:** All service configuration rules follow "last one wins" order. */ rules?: Schema$DocumentationRule[]; + /** + * Specifies the service root url if the default one (the service name from the yaml file) is not suitable. This can be seen in any fully specified service urls as well as sections that show a base that other urls are relative to. + */ + serviceRootUrl?: string; /** * A short summary of what the service does. Can only be provided by plain text. */ @@ -767,7 +771,7 @@ export namespace servicemanagement_v1 { */ export interface Schema$GetPolicyOptions { /** - * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + * Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ requestedPolicyVersion?: number; } @@ -1232,11 +1236,11 @@ export namespace servicemanagement_v1 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** - * Deprecated. + * Specifies the format of the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ version?: number; } diff --git a/src/apis/serviceusage/v1.ts b/src/apis/serviceusage/v1.ts index 5c7aa324a27..7e664ae17d8 100644 --- a/src/apis/serviceusage/v1.ts +++ b/src/apis/serviceusage/v1.ts @@ -286,7 +286,7 @@ export namespace serviceusage_v1 { */ export interface Schema$BatchEnableServicesRequest { /** - * The identifiers of the services to enable on the project. A valid identifier would be: serviceusage.googleapis.com Enabling services requires that each service is public or is shared with the user enabling the service. Two or more services must be specified. To enable a single service, use the `EnableService` method instead. A single request can enable a maximum of 20 services at a time. If more than 20 services are specified, the request will fail, and no state changes will occur. + * The identifiers of the services to enable on the project. A valid identifier would be: serviceusage.googleapis.com Enabling services requires that each service is public or is shared with the user enabling the service. A single request can enable a maximum of 20 services at a time. If more than 20 services are specified, the request will fail, and no state changes will occur. */ serviceIds?: string[]; } @@ -1269,6 +1269,19 @@ export namespace serviceusage_v1 { */ overrideValue?: string; } + /** + * Service identity for a service. This is the identity that service producer should use to access consumer resources. + */ + export interface Schema$ServiceIdentity { + /** + * The email address of the service account that a service producer would use to access consumer resources. + */ + email?: string; + /** + * The unique and stable id of the service account. https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts#ServiceAccount + */ + uniqueId?: string; + } /** * `SourceContext` represents information about the source of a protobuf element, like the file in which it is defined. */ @@ -1770,7 +1783,7 @@ export namespace serviceusage_v1 { /** * serviceusage.services.batchEnable - * @desc Enable multiple services on a project. The operation is atomic: if enabling any service fails, then the entire batch fails, and no state changes occur. + * @desc Enable multiple services on a project. The operation is atomic: if enabling any service fails, then the entire batch fails, and no state changes occur. To enable a single service, use the `EnableService` method instead. * @alias serviceusage.services.batchEnable * @memberOf! () * diff --git a/src/apis/serviceusage/v1beta1.ts b/src/apis/serviceusage/v1beta1.ts index e015897caf4..266e0b0a1bd 100644 --- a/src/apis/serviceusage/v1beta1.ts +++ b/src/apis/serviceusage/v1beta1.ts @@ -1318,6 +1318,19 @@ export namespace serviceusage_v1beta1 { */ usage?: Schema$Usage; } + /** + * Service identity for a service. This is the identity that service producer should use to access consumer resources. + */ + export interface Schema$ServiceIdentity { + /** + * The email address of the service account that a service producer would use to access consumer resources. + */ + email?: string; + /** + * The unique and stable id of the service account. https://cloud.google.com/iam/reference/rest/v1/projects.serviceAccounts#ServiceAccount + */ + uniqueId?: string; + } /** * `SourceContext` represents information about the source of a protobuf element, like the file in which it is defined. */ diff --git a/src/apis/sheets/v4.ts b/src/apis/sheets/v4.ts index e4af343ba2a..b1dc1386a0c 100644 --- a/src/apis/sheets/v4.ts +++ b/src/apis/sheets/v4.ts @@ -395,6 +395,10 @@ export namespace sheets_v4 { * The axis title text position. */ titleTextPosition?: Schema$TextPosition; + /** + * The view window options for this axis. + */ + viewWindowOptions?: Schema$ChartAxisViewWindowOptions; } /** * The domain of a chart. For example, if charting stock prices over time, this would be the date. @@ -1000,6 +1004,23 @@ export namespace sheets_v4 { */ wrapStrategy?: string; } + /** + * The options that define a "view window" for a chart (such as the visible values in an axis). + */ + export interface Schema$ChartAxisViewWindowOptions { + /** + * The maximum numeric value to be shown in this view window. If unset, will automatically determine a maximum value that looks good for the data. + */ + viewWindowMax?: number; + /** + * The minimum numeric value to be shown in this view window. If unset, will automatically determine a minimum value that looks good for the data. + */ + viewWindowMin?: number; + /** + * The view window's mode. + */ + viewWindowMode?: string; + } /** * The data included in a domain or series. */ @@ -1381,6 +1402,28 @@ export namespace sheets_v4 { */ range?: Schema$DimensionRange; } + /** + * Removes rows within this range that contain values in the specified columns that are duplicates of values in any previous row. Rows with identical values but different letter cases, formatting, or formulas are considered to be duplicates. This request also removes duplicate rows hidden from view (for example, due to a filter). When removing duplicates, the first instance of each duplicate row scanning from the top downwards is kept in the resulting range. Content outside of the specified range isn't removed, and rows considered duplicates do not have to be adjacent to each other in the range. + */ + export interface Schema$DeleteDuplicatesRequest { + /** + * The columns in the range to analyze for duplicate values. If no columns are selected then all columns are analyzed for duplicates. + */ + comparisonColumns?: Schema$DimensionRange[]; + /** + * The range to remove duplicates rows from. + */ + range?: Schema$GridRange; + } + /** + * The result of removing duplicates in a range. + */ + export interface Schema$DeleteDuplicatesResponse { + /** + * The number of duplicate rows removed. + */ + duplicatesRemovedCount?: number; + } /** * Deletes the embedded object with the given ID. */ @@ -2599,6 +2642,10 @@ export namespace sheets_v4 { * Deletes a group over the specified range. */ deleteDimensionGroup?: Schema$DeleteDimensionGroupRequest; + /** + * Removes rows containing duplicate values in specified columns of a cell range. + */ + deleteDuplicates?: Schema$DeleteDuplicatesRequest; /** * Deletes an embedded object (e.g, chart, image) in a sheet. */ @@ -2679,6 +2726,10 @@ export namespace sheets_v4 { * Converts a column of text into many columns of text. */ textToColumns?: Schema$TextToColumnsRequest; + /** + * Trims cells of whitespace (such as spaces, tabs, or new lines). + */ + trimWhitespace?: Schema$TrimWhitespaceRequest; /** * Unmerges merged cells. */ @@ -2788,6 +2839,10 @@ export namespace sheets_v4 { * A reply from deleting a dimension group. */ deleteDimensionGroup?: Schema$DeleteDimensionGroupResponse; + /** + * A reply from removing rows containing duplicate values. + */ + deleteDuplicates?: Schema$DeleteDuplicatesResponse; /** * A reply from duplicating a filter view. */ @@ -2800,6 +2855,10 @@ export namespace sheets_v4 { * A reply from doing a find/replace. */ findReplace?: Schema$FindReplaceResponse; + /** + * A reply from trimming whitespace. + */ + trimWhitespace?: Schema$TrimWhitespaceResponse; /** * A reply from updating a conditional format rule. */ @@ -3212,6 +3271,24 @@ export namespace sheets_v4 { */ textFormat?: Schema$TextFormat; } + /** + * Trims the whitespace (such as spaces, tabs, or new lines) in every cell in the specified range. This request removes all whitespace from the start and end of each cell's text, and reduces any subsequence of remaining whitespace characters to a single space. If the resulting trimmed text starts with a '+' or '=' character, the text remains as a string value and isn't interpreted as a formula. + */ + export interface Schema$TrimWhitespaceRequest { + /** + * The range whose cells to trim. + */ + range?: Schema$GridRange; + } + /** + * The result of trimming whitespace in cells. + */ + export interface Schema$TrimWhitespaceResponse { + /** + * The number of cells that were trimmed of whitespace. + */ + cellsChangedCount?: number; + } /** * Unmerges cells in the given range. */ diff --git a/src/apis/slides/v1.ts b/src/apis/slides/v1.ts index 23ac7aa69db..f5c2906720e 100644 --- a/src/apis/slides/v1.ts +++ b/src/apis/slides/v1.ts @@ -1134,7 +1134,7 @@ export namespace slides_v1 { */ export interface Schema$PageProperties { /** - * The color scheme of the page. If unset, the color scheme is inherited from a parent page. If the page has no parent, the color scheme uses a default Slides color scheme, matching the defaults in the Slides editor. Only the concrete colors of the first 12 ThemeColorTypes are editable. In addition, only the color scheme on Master pages can be updated. To update the field, a color scheme containing mappings from all the first 12 ThemeColorTypes to their concrete colors must be provided. Colors for the remaining ThemeColorTypes will be ignored. + * The color scheme of the page. If unset, the color scheme is inherited from a parent page. If the page has no parent, the color scheme uses a default Slides color scheme, matching the defaults in the Slides editor. Only the concrete colors of the first 12 ThemeColorTypes are editable. In addition, only the color scheme on `Master` pages can be updated. To update the field, a color scheme containing mappings from all the first 12 ThemeColorTypes to their concrete colors must be provided. Colors for the remaining ThemeColorTypes will be ignored. */ colorScheme?: Schema$ColorScheme; /** @@ -1400,7 +1400,7 @@ export namespace slides_v1 { */ imageReplaceMethod?: string; /** - * The URL of the new image. The image is fetched once at insertion time and a copy is stored for display inside the presentation. Images must be less than 50MB in size, cannot exceed 25 megapixels, and must be in one of PNG, JPEG, or GIF format. The provided URL can be at most 2 kB in length. The URL itself is saved with the image, and exposed via the Image.source_url field. + * The image URL. The image is fetched once at insertion time and a copy is stored for display inside the presentation. Images must be less than 50MB in size, cannot exceed 25 megapixels, and must be in one of PNG, JPEG, or GIF format. The provided URL can be at most 2 kB in length. The URL itself is saved with the image, and exposed via the Image.source_url field. */ url?: string; } diff --git a/src/apis/spanner/v1.ts b/src/apis/spanner/v1.ts index ca1db2c1058..1ebab465eff 100644 --- a/src/apis/spanner/v1.ts +++ b/src/apis/spanner/v1.ts @@ -117,6 +117,28 @@ export namespace spanner_v1 { } } + /** + * The request for BatchCreateSessions. + */ + export interface Schema$BatchCreateSessionsRequest { + /** + * Required. The number of sessions to be created in this batch call. The API may return fewer than the requested number of sessions. If a specific number of sessions are desired, the client can make additional calls to BatchCreateSessions (adjusting session_count as necessary). The maximum allowed sessions are documented at https://goo.gl/hBUQED. + */ + sessionCount?: number; + /** + * Parameters to be applied to each created session. + */ + sessionTemplate?: Schema$Session; + } + /** + * The response for BatchCreateSessions. + */ + export interface Schema$BatchCreateSessionsResponse { + /** + * The freshly created sessions. + */ + session?: Schema$Session[]; + } /** * The request for BeginTransaction. */ @@ -135,7 +157,7 @@ export namespace spanner_v1 { */ condition?: Schema$Expr; /** - * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@gmail.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. + * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[]; /** @@ -394,7 +416,21 @@ export namespace spanner_v1 { /** * Request message for `GetIamPolicy` method. */ - export interface Schema$GetIamPolicyRequest {} + export interface Schema$GetIamPolicyRequest { + /** + * OPTIONAL: A `GetPolicyOptions` object for specifying options to `GetIamPolicy`. This field is only used by Cloud IAM. + */ + options?: Schema$GetPolicyOptions; + } + /** + * Encapsulates settings provided to GetIamPolicy. + */ + export interface Schema$GetPolicyOptions { + /** + * Optional. The policy format version to be returned. Acceptable values are 0 and 1. If the value is 0, or the field is omitted, policy format version 1 will be returned. + */ + requestedPolicyVersion?: number; + } /** * An isolated set of Cloud Spanner resources on which databases can be hosted. */ @@ -754,7 +790,7 @@ export namespace spanner_v1 { */ bindings?: Schema$Binding[]; /** - * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten blindly. + * `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. If no `etag` is provided in the call to `setIamPolicy`, then the existing policy is overwritten. */ etag?: string; /** @@ -3297,6 +3333,88 @@ export namespace spanner_v1 { this.context = context; } + /** + * spanner.projects.instances.databases.sessions.batchCreate + * @desc Creates multiple new sessions. If the requested number of sessions would cause the database to exceed its session limit, returns a RESOURCE_EXHAUSTED error. This API can be used to initialize a session cache on the clients. See https://goo.gl/TgSFN2 for best practices on session cache management. + * @alias spanner.projects.instances.databases.sessions.batchCreate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.database Required. The database in which the new sessions are created. + * @param {().BatchCreateSessionsRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + batchCreate( + params?: Params$Resource$Projects$Instances$Databases$Sessions$Batchcreate, + options?: MethodOptions + ): GaxiosPromise; + batchCreate( + params: Params$Resource$Projects$Instances$Databases$Sessions$Batchcreate, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + batchCreate( + params: Params$Resource$Projects$Instances$Databases$Sessions$Batchcreate, + callback: BodyResponseCallback + ): void; + batchCreate( + callback: BodyResponseCallback + ): void; + batchCreate( + paramsOrCallback?: + | Params$Resource$Projects$Instances$Databases$Sessions$Batchcreate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Instances$Databases$Sessions$Batchcreate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Instances$Databases$Sessions$Batchcreate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://spanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+database}/sessions:batchCreate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['database'], + pathParams: ['database'], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest(parameters); + } + } + /** * spanner.projects.instances.databases.sessions.beginTransaction * @desc Begins a new transaction. This step can often be skipped: Read, ExecuteSql and Commit can begin a new transaction as a side-effect. @@ -4348,6 +4466,23 @@ export namespace spanner_v1 { } } + export interface Params$Resource$Projects$Instances$Databases$Sessions$Batchcreate + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The database in which the new sessions are created. + */ + database?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$BatchCreateSessionsRequest; + } export interface Params$Resource$Projects$Instances$Databases$Sessions$Begintransaction extends StandardParameters { /** diff --git a/src/apis/speech/index.ts b/src/apis/speech/index.ts index a6d94a7df17..143418d67dd 100644 --- a/src/apis/speech/index.ts +++ b/src/apis/speech/index.ts @@ -16,10 +16,12 @@ import {AuthPlus, getAPI, GoogleConfigurable} from 'googleapis-common'; import {speech_v1} from './v1'; import {speech_v1p1beta1} from './v1p1beta1'; +import {speech_v2beta} from './v2beta'; export const VERSIONS = { v1: speech_v1.Speech, v1p1beta1: speech_v1p1beta1.Speech, + v2beta: speech_v2beta.Speech, }; export function speech(version: 'v1'): speech_v1.Speech; @@ -28,13 +30,19 @@ export function speech(version: 'v1p1beta1'): speech_v1p1beta1.Speech; export function speech( options: speech_v1p1beta1.Options ): speech_v1p1beta1.Speech; -export function speech( +export function speech(version: 'v2beta'): speech_v2beta.Speech; +export function speech(options: speech_v2beta.Options): speech_v2beta.Speech; +export function speech< + T = speech_v1.Speech | speech_v1p1beta1.Speech | speech_v2beta.Speech +>( this: GoogleConfigurable, versionOrOptions: | 'v1' | speech_v1.Options | 'v1p1beta1' | speech_v1p1beta1.Options + | 'v2beta' + | speech_v2beta.Options ) { return getAPI('speech', versionOrOptions, VERSIONS, this); } diff --git a/src/apis/speech/v1.ts b/src/apis/speech/v1.ts index 3029e902c4a..3dbb0f10fd4 100644 --- a/src/apis/speech/v1.ts +++ b/src/apis/speech/v1.ts @@ -199,7 +199,7 @@ export namespace speech_v1 { response?: {[key: string]: any}; } /** - * Contains audio data in the encoding specified in the `RecognitionConfig`. Either `content` or `uri` must be supplied. Supplying both or neither returns google.rpc.Code.INVALID_ARGUMENT. See [content limits](/speech-to-text/quotas#content). + * Contains audio data in the encoding specified in the `RecognitionConfig`. Either `content` or `uri` must be supplied. Supplying both or neither returns google.rpc.Code.INVALID_ARGUMENT. See [content limits](https://cloud.google.com/speech-to-text/quotas#content). */ export interface Schema$RecognitionAudio { /** @@ -236,7 +236,7 @@ export namespace speech_v1 { */ encoding?: string; /** - * *Required* The language of the supplied audio as a [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. Example: "en-US". See [Language Support](/speech-to-text/docs/languages) for a list of the currently supported language codes. + * *Required* The language of the supplied audio as a [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. Example: "en-US". See [Language Support](https://cloud.google.com/speech-to-text/docs/languages) for a list of the currently supported language codes. */ languageCode?: string; /** @@ -260,7 +260,7 @@ export namespace speech_v1 { */ sampleRateHertz?: number; /** - * *Optional* array of SpeechContext. A means to provide context to assist the speech recognition. For more information, see [Phrase Hints](/speech-to-text/docs/basics#phrase-hints). + * *Optional* array of SpeechContext. A means to provide context to assist the speech recognition. For more information, see [speech adaptation](https://cloud.google.com/speech-to-text/docs/context-strength). */ speechContexts?: Schema$SpeechContext[]; /** @@ -336,7 +336,7 @@ export namespace speech_v1 { */ export interface Schema$SpeechContext { /** - * *Optional* A list of strings containing words and phrases "hints" so that the speech recognition is more likely to recognize them. This can be used to improve the accuracy for specific words and phrases, for example, if specific commands are typically spoken by the user. This can also be used to add additional words to the vocabulary of the recognizer. See [usage limits](/speech-to-text/quotas#content). List items can also be set to classes for groups of words that represent common concepts that occur in natural language. For example, rather than providing phrase hints for every month of the year, using the $MONTH class improves the likelihood of correctly transcribing audio that includes months. + * *Optional* A list of strings containing words and phrases "hints" so that the speech recognition is more likely to recognize them. This can be used to improve the accuracy for specific words and phrases, for example, if specific commands are typically spoken by the user. This can also be used to add additional words to the vocabulary of the recognizer. See [usage limits](https://cloud.google.com/speech-to-text/quotas#content). List items can also be set to classes for groups of words that represent common concepts that occur in natural language. For example, rather than providing phrase hints for every month of the year, using the $MONTH class improves the likelihood of correctly transcribing audio that includes months. */ phrases?: string[]; } diff --git a/src/apis/speech/v1p1beta1.ts b/src/apis/speech/v1p1beta1.ts index 2a821ed2135..29dfe5c5d0b 100644 --- a/src/apis/speech/v1p1beta1.ts +++ b/src/apis/speech/v1p1beta1.ts @@ -199,7 +199,7 @@ export namespace speech_v1p1beta1 { response?: {[key: string]: any}; } /** - * Contains audio data in the encoding specified in the `RecognitionConfig`. Either `content` or `uri` must be supplied. Supplying both or neither returns google.rpc.Code.INVALID_ARGUMENT. See [content limits](/speech-to-text/quotas#content). + * Contains audio data in the encoding specified in the `RecognitionConfig`. Either `content` or `uri` must be supplied. Supplying both or neither returns google.rpc.Code.INVALID_ARGUMENT. See [content limits](https://cloud.google.com/speech-to-text/quotas#content). */ export interface Schema$RecognitionAudio { /** @@ -216,7 +216,7 @@ export namespace speech_v1p1beta1 { */ export interface Schema$RecognitionConfig { /** - * *Optional* A list of up to 3 additional [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tags, listing possible alternative languages of the supplied audio. See [Language Support](/speech-to-text/docs/languages) for a list of the currently supported language codes. If alternative languages are listed, recognition result will contain recognition in the most likely language detected including the main language_code. The recognition result will include the language tag of the language detected in the audio. Note: This feature is only supported for Voice Command and Voice Search use cases and performance may vary for other use cases (e.g., phone call transcription). + * *Optional* A list of up to 3 additional [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tags, listing possible alternative languages of the supplied audio. See [Language Support](https://cloud.google.com/speech-to-text/docs/languages) for a list of the currently supported language codes. If alternative languages are listed, recognition result will contain recognition in the most likely language detected including the main language_code. The recognition result will include the language tag of the language detected in the audio. Note: This feature is only supported for Voice Command and Voice Search use cases and performance may vary for other use cases (e.g., phone call transcription). */ alternativeLanguageCodes?: string[]; /** @@ -228,7 +228,7 @@ export namespace speech_v1p1beta1 { */ diarizationConfig?: Schema$SpeakerDiarizationConfig; /** - * *Optional* If set, specifies the estimated number of speakers in the conversation. If not set, defaults to '2'. Ignored unless enable_speaker_diarization is set to true." Note: Use diarization_config instead. This field will be DEPRECATED soon. + * *Optional* If set, specifies the estimated number of speakers in the conversation. Defaults to '2'. Ignored unless enable_speaker_diarization is set to true. Note: Use diarization_config instead. */ diarizationSpeakerCount?: number; /** @@ -240,7 +240,7 @@ export namespace speech_v1p1beta1 { */ enableSeparateRecognitionPerChannel?: boolean; /** - * *Optional* If 'true', enables speaker detection for each recognized word in the top alternative of the recognition result using a speaker_tag provided in the WordInfo. Note: Use diarization_config instead. This field will be DEPRECATED soon. + * *Optional* If 'true', enables speaker detection for each recognized word in the top alternative of the recognition result using a speaker_tag provided in the WordInfo. Note: Use diarization_config instead. */ enableSpeakerDiarization?: boolean; /** @@ -256,7 +256,7 @@ export namespace speech_v1p1beta1 { */ encoding?: string; /** - * *Required* The language of the supplied audio as a [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. Example: "en-US". See [Language Support](/speech-to-text/docs/languages) for a list of the currently supported language codes. + * *Required* The language of the supplied audio as a [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. Example: "en-US". See [Language Support](https://cloud.google.com/speech-to-text/docs/languages) for a list of the currently supported language codes. */ languageCode?: string; /** @@ -280,7 +280,7 @@ export namespace speech_v1p1beta1 { */ sampleRateHertz?: number; /** - * *Optional* array of SpeechContext. A means to provide context to assist the speech recognition. For more information, see [Phrase Hints](/speech-to-text/docs/basics#phrase-hints). + * *Optional* array of SpeechContext. A means to provide context to assist the speech recognition. For more information, see [speech adaptation](https://cloud.google.com/speech-to-text/docs/context-strength). */ speechContexts?: Schema$SpeechContext[]; /** @@ -355,17 +355,20 @@ export namespace speech_v1p1beta1 { */ results?: Schema$SpeechRecognitionResult[]; } + /** + * *Optional* Config to enable speaker diarization. + */ export interface Schema$SpeakerDiarizationConfig { /** * *Optional* If 'true', enables speaker detection for each recognized word in the top alternative of the recognition result using a speaker_tag provided in the WordInfo. */ enableSpeakerDiarization?: boolean; /** - * *Optional* Only used if diarization_speaker_count is not set. Maximum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 6. + * *Optional* Maximum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 6. */ maxSpeakerCount?: number; /** - * *Optional* Only used if diarization_speaker_count is not set. Minimum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 2. + * *Optional* Minimum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 2. */ minSpeakerCount?: number; } @@ -378,7 +381,7 @@ export namespace speech_v1p1beta1 { */ boost?: number; /** - * *Optional* A list of strings containing words and phrases "hints" so that the speech recognition is more likely to recognize them. This can be used to improve the accuracy for specific words and phrases, for example, if specific commands are typically spoken by the user. This can also be used to add additional words to the vocabulary of the recognizer. See [usage limits](/speech-to-text/quotas#content). List items can also be set to classes for groups of words that represent common concepts that occur in natural language. For example, rather than providing phrase hints for every month of the year, using the $MONTH class improves the likelihood of correctly transcribing audio that includes months. + * *Optional* A list of strings containing words and phrases "hints" so that the speech recognition is more likely to recognize them. This can be used to improve the accuracy for specific words and phrases, for example, if specific commands are typically spoken by the user. This can also be used to add additional words to the vocabulary of the recognizer. See [usage limits](https://cloud.google.com/speech-to-text/quotas#content). List items can also be set to classes for groups of words that represent common concepts that occur in natural language. For example, rather than providing phrase hints for every month of the year, using the $MONTH class improves the likelihood of correctly transcribing audio that includes months. */ phrases?: string[]; } diff --git a/src/apis/speech/v2beta.ts b/src/apis/speech/v2beta.ts new file mode 100644 index 00000000000..3c2f6256af1 --- /dev/null +++ b/src/apis/speech/v2beta.ts @@ -0,0 +1,474 @@ +/** + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { + OAuth2Client, + JWT, + Compute, + UserRefreshClient, +} from 'google-auth-library'; +import { + GoogleConfigurable, + createAPIRequest, + MethodOptions, + GlobalOptions, + BodyResponseCallback, + APIRequestContext, +} from 'googleapis-common'; +import {GaxiosPromise} from 'gaxios'; + +// tslint:disable: no-any +// tslint:disable: class-name +// tslint:disable: variable-name +// tslint:disable: jsdoc-format +// tslint:disable: no-namespace + +export namespace speech_v2beta { + export interface Options extends GlobalOptions { + version: 'v2beta'; + } + + interface StandardParameters { + /** + * V1 error format. + */ + '$.xgafv'?: string; + /** + * OAuth access token. + */ + access_token?: string; + /** + * Data format for response. + */ + alt?: string; + /** + * JSONP + */ + callback?: string; + /** + * Selector specifying which fields to include in a partial response. + */ + fields?: string; + /** + * 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. + */ + key?: string; + /** + * OAuth 2.0 token for the current user. + */ + oauth_token?: string; + /** + * Returns response with indentations and line breaks. + */ + prettyPrint?: boolean; + /** + * 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. + */ + quotaUser?: string; + /** + * Legacy upload protocol for media (e.g. "media", "multipart"). + */ + uploadType?: string; + /** + * Upload protocol for media (e.g. "raw", "multipart"). + */ + upload_protocol?: string; + } + + /** + * Cloud Speech-to-Text API + * + * Converts audio to text by applying powerful neural network models. + * + * @example + * const {google} = require('googleapis'); + * const speech = google.speech('v2beta'); + * + * @namespace speech + * @type {Function} + * @version v2beta + * @variation v2beta + * @param {object=} options Options for Speech + */ + export class Speech { + context: APIRequestContext; + projects: Resource$Projects; + + constructor(options: GlobalOptions, google?: GoogleConfigurable) { + this.context = { + _options: options || {}, + google, + }; + + this.projects = new Resource$Projects(this.context); + } + } + + /** + * The response message for Operations.ListOperations. + */ + export interface Schema$ListOperationsResponse { + /** + * The standard List next-page token. + */ + nextPageToken?: string; + /** + * A list of operations that matches the specified filter in the request. + */ + operations?: Schema$Operation[]; + } + /** + * Describes the progress of a long-running `LongRunningRecognize` call. It is included in the `metadata` field of the `Operation` returned by the `GetOperation` call of the `google::longrunning::Operations` service. + */ + export interface Schema$LongRunningRecognizeMetadata { + /** + * Output only. Time of the most recent processing update. + */ + lastUpdateTime?: string; + /** + * Output only. Approximate percentage of audio processed thus far. Guaranteed to be 100 when the audio is fully processed and the results are available. + */ + progressPercent?: number; + /** + * Output only. Time when the request was received. + */ + startTime?: string; + } + /** + * The only message returned to the client by the `LongRunningRecognize` method. It contains the result as zero or more sequential `SpeechRecognitionResult` messages. It is included in the `result.response` field of the `Operation` returned by the `GetOperation` call of the `google::longrunning::Operations` service. + */ + export interface Schema$LongRunningRecognizeResponse { + /** + * Output only. Sequential list of transcription results corresponding to sequential portions of audio. + */ + results?: Schema$SpeechRecognitionResult[]; + } + /** + * This resource represents a long-running operation that is the result of a network API call. + */ + export interface Schema$Operation { + /** + * If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available. + */ + done?: boolean; + /** + * The error result of the operation in case of failure or cancellation. + */ + error?: Schema$Status; + /** + * Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any. + */ + metadata?: {[key: string]: any}; + /** + * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. + */ + name?: string; + /** + * The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. + */ + response?: {[key: string]: any}; + } + /** + * Alternative hypotheses (a.k.a. n-best list). + */ + export interface Schema$SpeechRecognitionAlternative { + /** + * Output only. The confidence estimate between 0.0 and 1.0. A higher number indicates an estimated greater likelihood that the recognized words are correct. This field is set only for the top alternative of a non-streaming result or, of a streaming result where `is_final=true`. This field is not guaranteed to be accurate and users should not rely on it to be always provided. The default of 0.0 is a sentinel value indicating `confidence` was not set. + */ + confidence?: number; + /** + * Output only. Transcript text representing the words that the user spoke. + */ + transcript?: string; + /** + * Output only. A list of word-specific information for each recognized word. Note: When `enable_speaker_diarization` is true, you will see all the words from the beginning of the audio. + */ + words?: Schema$WordInfo[]; + } + /** + * A speech recognition result corresponding to a portion of the audio. + */ + export interface Schema$SpeechRecognitionResult { + /** + * Output only. May contain one or more recognition hypotheses (up to the maximum specified in `max_alternatives`). These alternatives are ordered in terms of accuracy, with the top (first) alternative being the most probable, as ranked by the recognizer. + */ + alternatives?: Schema$SpeechRecognitionAlternative[]; + /** + * Output only. For multi-channel audio, this is the channel number corresponding to the recognized result for the audio from that channel. For audio_channel_count = N, its output values can range from '1' to 'N'. + */ + channelTag?: number; + /** + * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag of the language in this result. This language code was detected to have the most likelihood of being spoken in the audio. + */ + languageCode?: string; + } + /** + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). + */ + export interface Schema$Status { + /** + * The status code, which should be an enum value of google.rpc.Code. + */ + code?: number; + /** + * A list of messages that carry the error details. There is a common set of message types for APIs to use. + */ + details?: Array<{[key: string]: any}>; + /** + * A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. + */ + message?: string; + } + /** + * Word-specific information for recognized words. + */ + export interface Schema$WordInfo { + /** + * Output only. The confidence estimate between 0.0 and 1.0. A higher number indicates an estimated greater likelihood that the recognized words are correct. This field is set only for the top alternative of a non-streaming result or, of a streaming result where `is_final=true`. This field is not guaranteed to be accurate and users should not rely on it to be always provided. The default of 0.0 is a sentinel value indicating `confidence` was not set. + */ + confidence?: number; + /** + * Output only. Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary. + */ + endTime?: string; + /** + * Output only. A distinct integer value is assigned for every speaker within the audio. This field specifies which one of those speakers was detected to have spoken this word. Value ranges from '1' to `diarization_speaker_count`. speaker_tag is set if `enable_speaker_diarization` = `true` and only in the top alternative. + */ + speakerTag?: number; + /** + * Output only. Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary. + */ + startTime?: string; + /** + * Output only. The word corresponding to this set of information. + */ + word?: string; + } + + export class Resource$Projects { + context: APIRequestContext; + locations: Resource$Projects$Locations; + constructor(context: APIRequestContext) { + this.context = context; + this.locations = new Resource$Projects$Locations(this.context); + } + } + + export class Resource$Projects$Locations { + context: APIRequestContext; + operations: Resource$Projects$Locations$Operations; + constructor(context: APIRequestContext) { + this.context = context; + this.operations = new Resource$Projects$Locations$Operations( + this.context + ); + } + } + + export class Resource$Projects$Locations$Operations { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * speech.projects.locations.operations.get + * @desc 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. + * @alias speech.projects.locations.operations.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The name of the operation resource. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Projects$Locations$Operations$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Projects$Locations$Operations$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Projects$Locations$Operations$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Operations$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Operations$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Operations$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://speech.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v2beta/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * speech.projects.locations.operations.list + * @desc Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/x/operations`. To override the binding, API services can add a binding such as `"/v1/{name=users/x}/operations"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id. + * @alias speech.projects.locations.operations.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.filter The standard list filter. + * @param {string} params.name The name of the operation's parent resource. + * @param {integer=} params.pageSize The standard list page size. + * @param {string=} params.pageToken The standard list page token. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Locations$Operations$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Locations$Operations$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Locations$Operations$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Operations$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Operations$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Operations$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://speech.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v2beta/{+name}/operations').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Projects$Locations$Operations$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The name of the operation resource. + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$Operations$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The standard list filter. + */ + filter?: string; + /** + * The name of the operation's parent resource. + */ + name?: string; + /** + * The standard list page size. + */ + pageSize?: number; + /** + * The standard list page token. + */ + pageToken?: string; + } +} diff --git a/src/apis/sqladmin/v1beta4.ts b/src/apis/sqladmin/v1beta4.ts index 5b04ffee91e..40249b88a06 100644 --- a/src/apis/sqladmin/v1beta4.ts +++ b/src/apis/sqladmin/v1beta4.ts @@ -186,6 +186,14 @@ export namespace sqladmin_v1beta4 { * The description of this run, only applicable to on-demand backups. */ description?: string; + /** + * Disk encryption configuration specific to a backup. Applies only to Second Generation instances. + */ + diskEncryptionConfiguration?: Schema$DiskEncryptionConfiguration; + /** + * Disk encryption status specific to a backup. Applies only to Second Generation instances. + */ + diskEncryptionStatus?: Schema$DiskEncryptionStatus; /** * The time the backup operation completed in UTC timezone in RFC 3339 format, for example 2012-11-15T16:19:00.094Z. */ @@ -663,6 +671,16 @@ export namespace sqladmin_v1beta4 { * Database instance import context. */ export interface Schema$ImportContext { + /** + * Import parameters specific to SQL Server .BAK files + */ + bakImportOptions?: { + encryptionOptions?: { + certPath?: string; + pvkPassword?: string; + pvkPath?: string; + }; + }; /** * Options for importing data as CSV. */ @@ -5431,7 +5449,7 @@ export namespace sqladmin_v1beta4 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.host Host of the user in the instance. + * @param {string=} params.host Host of the user in the instance. For a MySQL instance, it's required; For a PostgreSQL instance, it's optional. * @param {string} params.instance Database instance ID. This does not include the project ID. * @param {string} params.name Name of the user in the instance. * @param {string} params.project Project ID of the project that contains the instance. @@ -5567,7 +5585,7 @@ export namespace sqladmin_v1beta4 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Host of the user in the instance. + * Host of the user in the instance. For a MySQL instance, it's required; For a PostgreSQL instance, it's optional. */ host?: string; /** diff --git a/src/apis/storage/v1.ts b/src/apis/storage/v1.ts index 538d671fe22..c0946f3f4f4 100644 --- a/src/apis/storage/v1.ts +++ b/src/apis/storage/v1.ts @@ -797,6 +797,10 @@ export namespace storage_v1 { * The ID of the resource to which this policy belongs. Will be of the form projects/_/buckets/bucket for buckets, and projects/_/buckets/bucket/objects/object for objects. A specific generation may be specified by appending #generationNumber to the end of the object name, e.g. projects/_/buckets/my-bucket/objects/data.txt#17. The current generation can be denoted with #0. This field is ignored on input. */ resourceId?: string; + /** + * The IAM policy format version. + */ + version?: number; } /** * A rewrite response. @@ -2079,6 +2083,7 @@ export namespace storage_v1 { * * @param {object} params Parameters for request * @param {string} params.bucket Name of a bucket. + * @param {integer=} params.optionsRequestedPolicyVersion The IAM policy format version to be returned. If the optionsRequestedPolicyVersion is for an older version that doesn't support part of the requested IAM policy, the request fails. * @param {string=} params.provisionalUserProject The project to be billed for this request if the target bucket is requester-pays bucket. * @param {string=} params.userProject The project to be billed for this request. Required for Requester Pays buckets. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. @@ -3113,6 +3118,10 @@ export namespace storage_v1 { * Name of a bucket. */ bucket?: string; + /** + * The IAM policy format version to be returned. If the optionsRequestedPolicyVersion is for an older version that doesn't support part of the requested IAM policy, the request fails. + */ + optionsRequestedPolicyVersion?: number; /** * The project to be billed for this request if the target bucket is requester-pays bucket. */ diff --git a/src/apis/storagetransfer/v1.ts b/src/apis/storagetransfer/v1.ts index d8b28fadc84..f164b8fc131 100644 --- a/src/apis/storagetransfer/v1.ts +++ b/src/apis/storagetransfer/v1.ts @@ -196,16 +196,16 @@ export namespace storagetransfer_v1 { */ errorCount?: string; /** - * Error samples. No more than 100 error log entries may be recorded for a given error code for a single task. + * Error samples. At most 5 error log entries will be recorded for a given error code for a single transfer operation. */ errorLogEntries?: Schema$ErrorLogEntry[]; } /** - * In a GcsData resource, an object's name is the Google Cloud Storage object's name and its `lastModificationTime` refers to the object's updated time, which changes when the content or the metadata of the object is updated. + * In a GcsData resource, an object's name is the Cloud Storage object's name and its `lastModificationTime` refers to the object's updated time, which changes when the content or the metadata of the object is updated. */ export interface Schema$GcsData { /** - * Required. Google Cloud Storage bucket name (see [Bucket Name Requirements](https://cloud.google.com/storage/docs/naming#requirements)). + * Required. Cloud Storage bucket name (see [Bucket Name Requirements](https://cloud.google.com/storage/docs/naming#requirements)). */ bucketName?: string; } @@ -219,7 +219,7 @@ export namespace storagetransfer_v1 { accountEmail?: string; } /** - * An HttpData resource specifies a list of objects on the web to be transferred over HTTP. The information of the objects to be transferred is contained in a file referenced by a URL. The first line in the file must be "TsvHttpData-1.0", which specifies the format of the file. Subsequent lines specify the information of the list of objects, one object per list entry. Each entry has the following tab-delimited fields: * HTTP URL - The location of the object. * Length - The size of the object in bytes. * MD5 - The base64-encoded MD5 hash of the object. For an example of a valid TSV file, see [Transferring data from URLs](https://cloud.google.com/storage/transfer/create-url-list). When transferring data based on a URL list, keep the following in mind: * When an object located at `http(s)://hostname:port/<URL-path>` is transferred to a data sink, the name of the object at the data sink is `<hostname>/<URL-path>`. * If the specified size of an object does not match the actual size of the object fetched, the object will not be transferred. * If the specified MD5 does not match the MD5 computed from the transferred bytes, the object transfer will fail. For more information, see [Generating MD5 hashes](https://cloud.google.com/storage/transfer/#md5) * Ensure that each URL you specify is publicly accessible. For example, in Google Cloud Storage you can [share an object publicly] (https://cloud.google.com/storage/docs/cloud-console#_sharingdata) and get a link to it. * Storage Transfer Service obeys `robots.txt` rules and requires the source HTTP server to support `Range` requests and to return a `Content-Length` header in each response. * [ObjectConditions](#ObjectConditions) have no effect when filtering objects to transfer. + * An HttpData resource specifies a list of objects on the web to be transferred over HTTP. The information of the objects to be transferred is contained in a file referenced by a URL. The first line in the file must be "TsvHttpData-1.0", which specifies the format of the file. Subsequent lines specify the information of the list of objects, one object per list entry. Each entry has the following tab-delimited fields: * HTTP URL - The location of the object. * Length - The size of the object in bytes. * MD5 - The base64-encoded MD5 hash of the object. For an example of a valid TSV file, see [Transferring data from URLs](https://cloud.google.com/storage/transfer/create-url-list). When transferring data based on a URL list, keep the following in mind: * When an object located at `http(s)://hostname:port/<URL-path>` is transferred to a data sink, the name of the object at the data sink is `<hostname>/<URL-path>`. * If the specified size of an object does not match the actual size of the object fetched, the object will not be transferred. * If the specified MD5 does not match the MD5 computed from the transferred bytes, the object transfer will fail. For more information, see [Generating MD5 hashes](https://cloud.google.com/storage/transfer/#md5) * Ensure that each URL you specify is publicly accessible. For example, in Cloud Storage you can [share an object publicly] (https://cloud.google.com/storage/docs/cloud-console#_sharingdata) and get a link to it. * Storage Transfer Service obeys `robots.txt` rules and requires the source HTTP server to support `Range` requests and to return a `Content-Length` header in each response. * [ObjectConditions](#ObjectConditions) have no effect when filtering objects to transfer. */ export interface Schema$HttpData { /** @@ -254,7 +254,7 @@ export namespace storagetransfer_v1 { transferJobs?: Schema$TransferJob[]; } /** - * Conditions that determine which objects will be transferred. Applies only to S3 and GCS objects. + * Conditions that determine which objects will be transferred. Applies only to S3 and Cloud Storage objects. */ export interface Schema$ObjectConditions { /** @@ -266,11 +266,11 @@ export namespace storagetransfer_v1 { */ includePrefixes?: string[]; /** - * If specified, only objects with a `lastModificationTime` on or after `NOW` - `maxTimeElapsedSinceLastModification` and objects that don't have a `lastModificationTime` are transferred. Note that, for each `TransferOperation` started by this `TransferJob`, `NOW` refers to the `start_time` of the 'TransferOperation`. Also, `lastModificationTime` refers to the time of the last change to the object's content or metadata - specifically, this would be the `updated` property of GCS objects and the `LastModified` field of S3 objects. + * If specified, only objects with a `lastModificationTime` on or after `NOW` - `maxTimeElapsedSinceLastModification` and objects that don't have a `lastModificationTime` are transferred. Note that, for each `TransferOperation` started by this `TransferJob`, `NOW` refers to the `start_time` of the 'TransferOperation`. Also, `lastModificationTime` refers to the time of the last change to the object's content or metadata - specifically, this would be the `updated` property of Cloud Storage objects and the `LastModified` field of S3 objects. */ maxTimeElapsedSinceLastModification?: string; /** - * If specified, only objects with a `lastModificationTime` before `NOW` - `minTimeElapsedSinceLastModification` and objects that don't have a `lastModificationTime` are transferred. Note that, for each `TransferOperation` started by this `TransferJob`, `NOW` refers to the `start_time` of the 'TransferOperation`. Also, `lastModificationTime` refers to the time of the last change to the object's content or metadata - specifically, this would be the `updated` property of GCS objects and the `LastModified` field of S3 objects. + * If specified, only objects with a `lastModificationTime` before `NOW` - `minTimeElapsedSinceLastModification` and objects that don't have a `lastModificationTime` are transferred. Note that, for each `TransferOperation` started by this `TransferJob`, `NOW` refers to the `start_time` of the 'TransferOperation`. Also, `lastModificationTime` refers to the time of the last change to the object's content or metadata - specifically, this would be the `updated` property of Cloud Storage objects and the `LastModified` field of S3 objects. */ minTimeElapsedSinceLastModification?: string; } @@ -539,11 +539,11 @@ export namespace storagetransfer_v1 { */ awsS3DataSource?: Schema$AwsS3Data; /** - * A Google Cloud Storage data sink. + * A Cloud Storage data sink. */ gcsDataSink?: Schema$GcsData; /** - * A Google Cloud Storage data source. + * A Cloud Storage data source. */ gcsDataSource?: Schema$GcsData; /** @@ -1638,7 +1638,7 @@ export namespace storagetransfer_v1 { /** * storagetransfer.transferOperations.list - * @desc Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/x/operations`. To override the binding, API services can add a binding such as `"/v1/{name=users/x}/operations"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id. + * @desc Lists transfer operations. * @example * * // BEFORE RUNNING: * // --------------- diff --git a/src/apis/testing/v1.ts b/src/apis/testing/v1.ts index 27d56df0511..0178bed0d1f 100644 --- a/src/apis/testing/v1.ts +++ b/src/apis/testing/v1.ts @@ -687,7 +687,7 @@ export namespace testing_v1 { iosDevices?: Schema$IosDevice[]; } /** - * A description of an iOS device tests may be run on. + * A description of an iOS device tests may be run on. Next tag: 10 */ export interface Schema$IosModel { /** @@ -706,6 +706,18 @@ export namespace testing_v1 { * The human-readable name for this device model. Examples: "iPhone 4s", "iPad Mini 2". */ name?: string; + /** + * Screen density in DPI. + */ + screenDensity?: number; + /** + * Screen size in the horizontal (X) dimension measured in pixels. + */ + screenX?: number; + /** + * Screen size in the vertical (Y) dimension measured in pixels. + */ + screenY?: number; /** * The set of iOS major software versions this device supports. */ diff --git a/src/apis/toolresults/v1beta3.ts b/src/apis/toolresults/v1beta3.ts index ceb1a820b8d..7f7aa4e777d 100644 --- a/src/apis/toolresults/v1beta3.ts +++ b/src/apis/toolresults/v1beta3.ts @@ -247,7 +247,7 @@ export namespace toolresults_v1beta3 { numberOfCores?: number; } /** - * A Duration represents a signed, fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like "day" or "month". It is related to Timestamp in that the difference between two Timestamp values is a Duration and it can be added or subtracted from a Timestamp. Range is approximately +-10,000 years. # Examples Example 1: Compute Duration from two Timestamps in pseudo code. Timestamp start = ...; Timestamp end = ...; Duration duration = ...; duration.seconds = end.seconds - start.seconds; duration.nanos = end.nanos - start.nanos; if (duration.seconds 0) { duration.seconds += 1; duration.nanos -= 1000000000; } else if (durations.seconds > 0 && duration.nanos < 0) { duration.seconds -= 1; duration.nanos += 1000000000; } Example 2: Compute Timestamp from Timestamp + Duration in pseudo code. Timestamp start = ...; Duration duration = ...; Timestamp end = ...; end.seconds = start.seconds + duration.seconds; end.nanos = start.nanos + duration.nanos; if (end.nanos = 1000000000) { end.seconds += 1; end.nanos -= 1000000000; } Example 3: Compute Duration from datetime.timedelta in Python. td = datetime.timedelta(days=3, minutes=10) duration = Duration() duration.FromTimedelta(td) # JSON Mapping In JSON format, the Duration type is encoded as a string rather than an object, where the string ends in the suffix "s" (indicating seconds) and is preceded by the number of seconds, with nanoseconds expressed as fractional seconds. For example, 3 seconds with 0 nanoseconds should be encoded in JSON format as "3s", while 3 seconds and 1 nanosecond should be expressed in JSON format as "3.000000001s", and 3 seconds and 1 microsecond should be expressed in JSON format as "3.000001s". + * A Duration represents a signed, fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like "day" or "month". It is related to Timestamp in that the difference between two Timestamp values is a Duration and it can be added or subtracted from a Timestamp. Range is approximately +-10,000 years. # Examples Example 1: Compute Duration from two Timestamps in pseudo code. Timestamp start = ...; Timestamp end = ...; Duration duration = ...; duration.seconds = end.seconds - start.seconds; duration.nanos = end.nanos - start.nanos; if (duration.seconds 0) { duration.seconds += 1; duration.nanos -= 1000000000; } else if (duration.seconds > 0 && duration.nanos < 0) { duration.seconds -= 1; duration.nanos += 1000000000; } Example 2: Compute Timestamp from Timestamp + Duration in pseudo code. Timestamp start = ...; Duration duration = ...; Timestamp end = ...; end.seconds = start.seconds + duration.seconds; end.nanos = start.nanos + duration.nanos; if (end.nanos = 1000000000) { end.seconds += 1; end.nanos -= 1000000000; } Example 3: Compute Duration from datetime.timedelta in Python. td = datetime.timedelta(days=3, minutes=10) duration = Duration() duration.FromTimedelta(td) # JSON Mapping In JSON format, the Duration type is encoded as a string rather than an object, where the string ends in the suffix "s" (indicating seconds) and is preceded by the number of seconds, with nanoseconds expressed as fractional seconds. For example, 3 seconds with 0 nanoseconds should be encoded in JSON format as "3s", while 3 seconds and 1 nanosecond should be expressed in JSON format as "3.000000001s", and 3 seconds and 1 microsecond should be expressed in JSON format as "3.000001s". */ export interface Schema$Duration { /** @@ -802,7 +802,7 @@ export namespace toolresults_v1beta3 { message?: string; } /** - * A Step represents a single operation performed as part of Execution. A step can be used to represent the execution of a tool ( for example a test runner execution or an execution of a compiler). Steps can overlap (for instance two steps might have the same start time if some operations are done in parallel). Here is an example, let's consider that we have a continuous build is executing a test runner for each iteration. The workflow would look like: - user creates a Execution with id 1 - user creates an TestExecutionStep with id 100 for Execution 1 - user update TestExecutionStep with id 100 to add a raw xml log + the service parses the xml logs and returns a TestExecutionStep with updated TestResult(s). - user update the status of TestExecutionStep with id 100 to COMPLETE A Step can be updated until its state is set to COMPLETE at which points it becomes immutable. + * A Step represents a single operation performed as part of Execution. A step can be used to represent the execution of a tool ( for example a test runner execution or an execution of a compiler). Steps can overlap (for instance two steps might have the same start time if some operations are done in parallel). Here is an example, let's consider that we have a continuous build is executing a test runner for each iteration. The workflow would look like: - user creates a Execution with id 1 - user creates an TestExecutionStep with id 100 for Execution 1 - user update TestExecutionStep with id 100 to add a raw xml log + the service parses the xml logs and returns a TestExecutionStep with updated TestResult(s). - user update the status of TestExecutionStep with id 100 to COMPLETE A Step can be updated until its state is set to COMPLETE at which points it becomes immutable. Next tag: 23 */ export interface Schema$Step { /** @@ -884,6 +884,10 @@ export namespace toolresults_v1beta3 { otherNativeCrash?: boolean; } export interface Schema$TestCase { + /** + * The elapsed run time of the test case. Required. + */ + elapsedTime?: Schema$Duration; /** * The end time of the test case. Optional. */ @@ -2264,9 +2268,9 @@ export namespace toolresults_v1beta3 { * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.executionId A Execution id. Required. - * @param {string} params.historyId A History id. Required. - * @param {string} params.projectId A Project id. Required. + * @param {string} params.executionId Required. An Execution id. + * @param {string} params.historyId Required. A History id. + * @param {string} params.projectId Required. A Project id. * @param {string=} params.requestId A unique request ID for server to detect duplicated requests. For example, a UUID. Optional, but strongly recommended. * @param {().Step} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. @@ -2727,15 +2731,15 @@ export namespace toolresults_v1beta3 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * A Execution id. Required. + * Required. An Execution id. */ executionId?: string; /** - * A History id. Required. + * Required. A History id. */ historyId?: string; /** - * A Project id. Required. + * Required. A Project id. */ projectId?: string; /** diff --git a/src/apis/tpu/v1.ts b/src/apis/tpu/v1.ts index cfa8af93376..2fe0a1b7762 100644 --- a/src/apis/tpu/v1.ts +++ b/src/apis/tpu/v1.ts @@ -146,6 +146,10 @@ export namespace tpu_v1 { * The next page token or empty if none. */ nextPageToken?: string; + /** + * Locations that could not be reached. + */ + unreachable?: string[]; } /** * The response message for Locations.ListLocations. @@ -202,6 +206,10 @@ export namespace tpu_v1 { * The listed nodes. */ tensorflowVersions?: Schema$TensorFlowVersion[]; + /** + * Locations that could not be reached. + */ + unreachable?: string[]; } /** * A resource that represents Google Cloud Platform location. diff --git a/src/apis/tpu/v1alpha1.ts b/src/apis/tpu/v1alpha1.ts index 0e35ef41968..6cd00bad9bb 100644 --- a/src/apis/tpu/v1alpha1.ts +++ b/src/apis/tpu/v1alpha1.ts @@ -146,6 +146,10 @@ export namespace tpu_v1alpha1 { * The next page token or empty if none. */ nextPageToken?: string; + /** + * Locations that could not be reached. + */ + unreachable?: string[]; } /** * The response message for Locations.ListLocations. @@ -202,6 +206,10 @@ export namespace tpu_v1alpha1 { * The listed nodes. */ tensorflowVersions?: Schema$TensorFlowVersion[]; + /** + * Locations that could not be reached. + */ + unreachable?: string[]; } /** * A resource that represents Google Cloud Platform location. diff --git a/src/apis/translate/index.ts b/src/apis/translate/index.ts index c7bcb869d31..79d73c00dd6 100644 --- a/src/apis/translate/index.ts +++ b/src/apis/translate/index.ts @@ -15,18 +15,30 @@ import {AuthPlus, getAPI, GoogleConfigurable} from 'googleapis-common'; import {translate_v2} from './v2'; +import {translate_v3beta1} from './v3beta1'; export const VERSIONS = { v2: translate_v2.Translate, + v3beta1: translate_v3beta1.Translate, }; export function translate(version: 'v2'): translate_v2.Translate; export function translate( options: translate_v2.Options ): translate_v2.Translate; -export function translate( +export function translate(version: 'v3beta1'): translate_v3beta1.Translate; +export function translate( + options: translate_v3beta1.Options +): translate_v3beta1.Translate; +export function translate< + T = translate_v2.Translate | translate_v3beta1.Translate +>( this: GoogleConfigurable, - versionOrOptions: 'v2' | translate_v2.Options + versionOrOptions: + | 'v2' + | translate_v2.Options + | 'v3beta1' + | translate_v3beta1.Options ) { return getAPI('translate', versionOrOptions, VERSIONS, this); } diff --git a/src/apis/translate/v3beta1.ts b/src/apis/translate/v3beta1.ts new file mode 100644 index 00000000000..6459deeec08 --- /dev/null +++ b/src/apis/translate/v3beta1.ts @@ -0,0 +1,2224 @@ +/** + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { + OAuth2Client, + JWT, + Compute, + UserRefreshClient, +} from 'google-auth-library'; +import { + GoogleConfigurable, + createAPIRequest, + MethodOptions, + GlobalOptions, + BodyResponseCallback, + APIRequestContext, +} from 'googleapis-common'; +import {GaxiosPromise} from 'gaxios'; + +// tslint:disable: no-any +// tslint:disable: class-name +// tslint:disable: variable-name +// tslint:disable: jsdoc-format +// tslint:disable: no-namespace + +export namespace translate_v3beta1 { + export interface Options extends GlobalOptions { + version: 'v3beta1'; + } + + interface StandardParameters { + /** + * V1 error format. + */ + '$.xgafv'?: string; + /** + * OAuth access token. + */ + access_token?: string; + /** + * Data format for response. + */ + alt?: string; + /** + * JSONP + */ + callback?: string; + /** + * Selector specifying which fields to include in a partial response. + */ + fields?: string; + /** + * 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. + */ + key?: string; + /** + * OAuth 2.0 token for the current user. + */ + oauth_token?: string; + /** + * Returns response with indentations and line breaks. + */ + prettyPrint?: boolean; + /** + * 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. + */ + quotaUser?: string; + /** + * Legacy upload protocol for media (e.g. "media", "multipart"). + */ + uploadType?: string; + /** + * Upload protocol for media (e.g. "raw", "multipart"). + */ + upload_protocol?: string; + } + + /** + * Cloud Translation API + * + * Integrates text translation into your website or application. + * + * @example + * const {google} = require('googleapis'); + * const translate = google.translate('v3beta1'); + * + * @namespace translate + * @type {Function} + * @version v3beta1 + * @variation v3beta1 + * @param {object=} options Options for Translate + */ + export class Translate { + context: APIRequestContext; + projects: Resource$Projects; + + constructor(options: GlobalOptions, google?: GoogleConfigurable) { + this.context = { + _options: options || {}, + google, + }; + + this.projects = new Resource$Projects(this.context); + } + } + + /** + * The batch translation request. + */ + export interface Schema$BatchTranslateTextRequest { + /** + * Optional. Glossaries to be applied for translation. It's keyed by target language code. + */ + glossaries?: {[key: string]: Schema$TranslateTextGlossaryConfig}; + /** + * Required. Input configurations. The total number of files matched should be <= 1000. The total content size should be <= 100M Unicode codepoints. The files must use UTF-8 encoding. + */ + inputConfigs?: Schema$InputConfig[]; + /** + * Optional. The models to use for translation. Map's key is target language code. Map's value is model name. Value can be a built-in general model, or an AutoML Translation model. The value format depends on model type: - AutoML Translation models: `projects/{project-id}/locations/{location-id}/models/{model-id}` - General (built-in) models: `projects/{project-id}/locations/{location-id}/models/general/nmt`, `projects/{project-id}/locations/{location-id}/models/general/base` If the map is empty or a specific model is not requested for a language pair, then default google model (nmt) is used. + */ + models?: {[key: string]: string}; + /** + * Required. Output configuration. If 2 input configs match to the same file (that is, same input path), we don't generate output for duplicate inputs. + */ + outputConfig?: Schema$OutputConfig; + /** + * Required. Source language code. + */ + sourceLanguageCode?: string; + /** + * Required. Specify up to 10 language codes here. + */ + targetLanguageCodes?: string[]; + } + /** + * The request message for Operations.CancelOperation. + */ + export interface Schema$CancelOperationRequest {} + /** + * The response message for language detection. + */ + export interface Schema$DetectedLanguage { + /** + * The confidence of the detection result for this language. + */ + confidence?: number; + /** + * The BCP-47 language code of source content in the request, detected automatically. + */ + languageCode?: string; + } + /** + * The request message for language detection. + */ + export interface Schema$DetectLanguageRequest { + /** + * The content of the input stored as a string. + */ + content?: string; + /** + * Optional. The format of the source text, for example, "text/html", "text/plain". If left blank, the MIME type defaults to "text/html". + */ + mimeType?: string; + /** + * Optional. The language detection model to be used. Format: `projects/{project-id}/locations/{location-id}/models/language-detection/{model-id}` Only one language detection model is currently supported: `projects/{project-id}/locations/{location-id}/models/language-detection/default`. If not specified, the default model is used. + */ + model?: string; + } + /** + * The response message for language detection. + */ + export interface Schema$DetectLanguageResponse { + /** + * A list of detected languages sorted by detection confidence in descending order. The most probable language first. + */ + languages?: Schema$DetectedLanguage[]; + } + /** + * A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`. + */ + export interface Schema$Empty {} + /** + * The Google Cloud Storage location for the output content. + */ + export interface Schema$GcsDestination { + /** + * Required. There must be no files under 'output_uri_prefix'. 'output_uri_prefix' must end with "/" and start with "gs://", otherwise an INVALID_ARGUMENT (400) error is returned. + */ + outputUriPrefix?: string; + } + /** + * The Google Cloud Storage location for the input content. + */ + export interface Schema$GcsSource { + /** + * Required. Source data URI. For example, `gs://my_bucket/my_object`. + */ + inputUri?: string; + } + /** + * Represents a glossary built from user provided data. + */ + export interface Schema$Glossary { + /** + * Output only. When the glossary creation was finished. + */ + endTime?: string; + /** + * Output only. The number of entries defined in the glossary. + */ + entryCount?: number; + /** + * Required. Provides examples to build the glossary from. Total glossary must not exceed 10M Unicode codepoints. + */ + inputConfig?: Schema$GlossaryInputConfig; + /** + * Used with equivalent term set glossaries. + */ + languageCodesSet?: Schema$LanguageCodesSet; + /** + * Used with unidirectional glossaries. + */ + languagePair?: Schema$LanguageCodePair; + /** + * Required. The resource name of the glossary. Glossary names have the form `projects/{project-id}/locations/{location-id}/glossaries/{glossary-id}`. + */ + name?: string; + /** + * Output only. When CreateGlossary was called. + */ + submitTime?: string; + } + /** + * Input configuration for glossaries. + */ + export interface Schema$GlossaryInputConfig { + /** + * Required. Google Cloud Storage location of glossary data. File format is determined based on the filename extension. API returns [google.rpc.Code.INVALID_ARGUMENT] for unsupported URI-s and file formats. Wildcards are not allowed. This must be a single file in one of the following formats: For unidirectional glossaries: - TSV/CSV (`.tsv`/`.csv`): 2 column file, tab- or comma-separated. The first column is source text. The second column is target text. The file must not contain headers. That is, the first row is data, not column names. - TMX (`.tmx`): TMX file with parallel data defining source/target term pairs. For equivalent term sets glossaries: - CSV (`.csv`): Multi-column CSV file defining equivalent glossary terms in multiple languages. The format is defined for Google Translation Toolkit and documented in [Use a glossary](https://support.google.com/translatortoolkit/answer/6306379?hl=en). + */ + gcsSource?: Schema$GcsSource; + } + /** + * Input configuration for BatchTranslateText request. + */ + export interface Schema$InputConfig { + /** + * Required. Google Cloud Storage location for the source input. This can be a single file (for example, `gs://translation-test/input.tsv`) or a wildcard (for example, `gs://translation-test/x). If a file extension is `.tsv`, it can contain either one or two columns. The first column (optional) is the id of the text request. If the first column is missing, we use the row number (0-based) from the input file as the ID in the output file. The second column is the actual text to be translated. We recommend each row be <= 10K Unicode codepoints, otherwise an error might be returned. Note that the input tsv must be RFC 4180 compliant. You could use https://github.com/Clever/csvlint to check potential formatting errors in your tsv file. csvlint --delimiter='\t' your_input_file.tsv The other supported file extensions are `.txt` or `.html`, which is treated as a single large chunk of text. + */ + gcsSource?: Schema$GcsSource; + /** + * Optional. Can be "text/plain" or "text/html". For `.tsv`, "text/html" is used if mime_type is missing. For `.html`, this field must be "text/html" or empty. For `.txt`, this field must be "text/plain" or empty. + */ + mimeType?: string; + } + /** + * Used with unidirectional glossaries. + */ + export interface Schema$LanguageCodePair { + /** + * Required. The BCP-47 language code of the input text, for example, "en-US". Expected to be an exact match for GlossaryTerm.language_code. + */ + sourceLanguageCode?: string; + /** + * Required. The BCP-47 language code for translation output, for example, "zh-CN". Expected to be an exact match for GlossaryTerm.language_code. + */ + targetLanguageCode?: string; + } + /** + * Used with equivalent term set glossaries. + */ + export interface Schema$LanguageCodesSet { + /** + * The BCP-47 language code(s) for terms defined in the glossary. All entries are unique. The list contains at least two entries. Expected to be an exact match for GlossaryTerm.language_code. + */ + languageCodes?: string[]; + } + /** + * Response message for ListGlossaries. + */ + export interface Schema$ListGlossariesResponse { + /** + * The list of glossaries for a project. + */ + glossaries?: Schema$Glossary[]; + /** + * A token to retrieve a page of results. Pass this value in the [ListGlossariesRequest.page_token] field in the subsequent call to `ListGlossaries` method to retrieve the next page of results. + */ + nextPageToken?: string; + } + /** + * The response message for Locations.ListLocations. + */ + export interface Schema$ListLocationsResponse { + /** + * A list of locations that matches the specified filter in the request. + */ + locations?: Schema$Location[]; + /** + * The standard List next-page token. + */ + nextPageToken?: string; + } + /** + * The response message for Operations.ListOperations. + */ + export interface Schema$ListOperationsResponse { + /** + * The standard List next-page token. + */ + nextPageToken?: string; + /** + * A list of operations that matches the specified filter in the request. + */ + operations?: Schema$Operation[]; + } + /** + * A resource that represents Google Cloud Platform location. + */ + export interface Schema$Location { + /** + * The friendly name for this location, typically a nearby city name. For example, "Tokyo". + */ + displayName?: string; + /** + * Cross-service attributes for the location. For example {"cloud.googleapis.com/region": "us-east1"} + */ + labels?: {[key: string]: string}; + /** + * The canonical id for this location. For example: `"us-east1"`. + */ + locationId?: string; + /** + * Service-specific metadata. For example the available capacity at the given location. + */ + metadata?: {[key: string]: any}; + /** + * Resource name for the location, which may vary between implementations. For example: `"projects/example-project/locations/us-east1"` + */ + name?: string; + } + /** + * This resource represents a long-running operation that is the result of a network API call. + */ + export interface Schema$Operation { + /** + * If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available. + */ + done?: boolean; + /** + * The error result of the operation in case of failure or cancellation. + */ + error?: Schema$Status; + /** + * Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any. + */ + metadata?: {[key: string]: any}; + /** + * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. + */ + name?: string; + /** + * The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. + */ + response?: {[key: string]: any}; + } + /** + * Output configuration for BatchTranslateText request. + */ + export interface Schema$OutputConfig { + /** + * Google Cloud Storage destination for output content. For every single input file (for example, gs://a/b/c.[extension]), we generate at most 2 * n output files. (n is the # of target_language_codes in the BatchTranslateTextRequest). Output files (tsv) generated are compliant with RFC 4180 except that record delimiters are 'x/' instead of '\rx/'. We don't provide any way to change record delimiters. While the input files are being processed, we write/update an index file 'index.csv' under 'output_uri_prefix' (for example, gs://translation-test/index.csv) The index file is generated/updated as new files are being translated. The format is: input_file,target_language_code,translations_file,errors_file, glossary_translations_file,glossary_errors_file input_file is one file we matched using gcs_source.input_uri. target_language_code is provided in the request. translations_file contains the translations. (details provided below) errors_file contains the errors during processing of the file. (details below). Both translations_file and errors_file could be empty strings if we have no content to output. glossary_translations_file and glossary_errors_file are always empty strings if the input_file is tsv. They could also be empty if we have no content to output. Once a row is present in index.csv, the input/output matching never changes. Callers should also expect all the content in input_file are processed and ready to be consumed (that is, no partial output file is written). The format of translations_file (for target language code 'trg') is: gs://translation_test/a_b_c_'trg'_translations.[extension] If the input file extension is tsv, the output has the following columns: Column 1: ID of the request provided in the input, if it's not provided in the input, then the input row number is used (0-based). Column 2: source sentence. Column 3: translation without applying a glossary. Empty string if there is an error. Column 4 (only present if a glossary is provided in the request): translation after applying the glossary. Empty string if there is an error applying the glossary. Could be same string as column 3 if there is no glossary applied. If input file extension is a txt or html, the translation is directly written to the output file. If glossary is requested, a separate glossary_translations_file has format of gs://translation_test/a_b_c_'trg'_glossary_translations.[extension] The format of errors file (for target language code 'trg') is: gs://translation_test/a_b_c_'trg'_errors.[extension] If the input file extension is tsv, errors_file contains the following: Column 1: ID of the request provided in the input, if it's not provided in the input, then the input row number is used (0-based). Column 2: source sentence. Column 3: Error detail for the translation. Could be empty. Column 4 (only present if a glossary is provided in the request): Error when applying the glossary. If the input file extension is txt or html, glossary_error_file will be generated that contains error details. glossary_error_file has format of gs://translation_test/a_b_c_'trg'_glossary_errors.[extension] + */ + gcsDestination?: Schema$GcsDestination; + } + /** + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). + */ + export interface Schema$Status { + /** + * The status code, which should be an enum value of google.rpc.Code. + */ + code?: number; + /** + * A list of messages that carry the error details. There is a common set of message types for APIs to use. + */ + details?: Array<{[key: string]: any}>; + /** + * A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. + */ + message?: string; + } + /** + * A single supported language response corresponds to information related to one supported language. + */ + export interface Schema$SupportedLanguage { + /** + * Human readable name of the language localized in the display language specified in the request. + */ + displayName?: string; + /** + * Supported language code, generally consisting of its ISO 639-1 identifier, for example, 'en', 'ja'. In certain cases, BCP-47 codes including language and region identifiers are returned (for example, 'zh-TW' and 'zh-CN') + */ + languageCode?: string; + /** + * Can be used as source language. + */ + supportSource?: boolean; + /** + * Can be used as target language. + */ + supportTarget?: boolean; + } + /** + * The response message for discovering supported languages. + */ + export interface Schema$SupportedLanguages { + /** + * A list of supported language responses. This list contains an entry for each language the Translation API supports. + */ + languages?: Schema$SupportedLanguage[]; + } + /** + * Configures which glossary should be used for a specific target language, and defines options for applying that glossary. + */ + export interface Schema$TranslateTextGlossaryConfig { + /** + * Required. Specifies the glossary used for this translation. Use this format: projects/x/locations/x/glossaries/* + */ + glossary?: string; + /** + * Optional. Indicates match is case-insensitive. Default value is false if missing. + */ + ignoreCase?: boolean; + } + /** + * The request message for synchronous translation. + */ + export interface Schema$TranslateTextRequest { + /** + * Required. The content of the input in string format. We recommend the total content be less than 30k codepoints. Use BatchTranslateText for larger text. + */ + contents?: string[]; + /** + * Optional. Glossary to be applied. The glossary must be within the same region (have the same location-id) as the model, otherwise an INVALID_ARGUMENT (400) error is returned. + */ + glossaryConfig?: Schema$TranslateTextGlossaryConfig; + /** + * Optional. The format of the source text, for example, "text/html", "text/plain". If left blank, the MIME type defaults to "text/html". + */ + mimeType?: string; + /** + * Optional. The `model` type requested for this translation. The format depends on model type: - AutoML Translation models: `projects/{project-id}/locations/{location-id}/models/{model-id}` - General (built-in) models: `projects/{project-id}/locations/{location-id}/models/general/nmt`, `projects/{project-id}/locations/{location-id}/models/general/base` For global (non-regionalized) requests, use `location-id` `global`. For example, `projects/{project-id}/locations/global/models/general/nmt`. If missing, the system decides which google base model to use. + */ + model?: string; + /** + * Optional. The BCP-47 language code of the input text if known, for example, "en-US" or "sr-Latn". Supported language codes are listed in Language Support. If the source language isn't specified, the API attempts to identify the source language automatically and returns the source language within the response. + */ + sourceLanguageCode?: string; + /** + * Required. The BCP-47 language code to use for translation of the input text, set to one of the language codes listed in Language Support. + */ + targetLanguageCode?: string; + } + export interface Schema$TranslateTextResponse { + /** + * Text translation responses if a glossary is provided in the request. This can be the same as `translations` if no terms apply. This field has the same length as `contents`. + */ + glossaryTranslations?: Schema$Translation[]; + /** + * Text translation responses with no glossary applied. This field has the same length as `contents`. + */ + translations?: Schema$Translation[]; + } + /** + * A single translation response. + */ + export interface Schema$Translation { + /** + * The BCP-47 language code of source text in the initial request, detected automatically, if no source language was passed within the initial request. If the source language was passed, auto-detection of the language does not occur and this field is empty. + */ + detectedLanguageCode?: string; + /** + * The `glossary_config` used for this translation. + */ + glossaryConfig?: Schema$TranslateTextGlossaryConfig; + /** + * Only present when `model` is present in the request. This is same as `model` provided in the request. + */ + model?: string; + /** + * Text translated into the target language. + */ + translatedText?: string; + } + /** + * The request message for Operations.WaitOperation. + */ + export interface Schema$WaitOperationRequest { + /** + * The maximum duration to wait before timing out. If left blank, the wait will be at most the time permitted by the underlying HTTP/RPC protocol. If RPC context deadline is also specified, the shorter one will be used. + */ + timeout?: string; + } + + export class Resource$Projects { + context: APIRequestContext; + locations: Resource$Projects$Locations; + constructor(context: APIRequestContext) { + this.context = context; + this.locations = new Resource$Projects$Locations(this.context); + } + + /** + * translate.projects.detectLanguage + * @desc Detects the language of text within a request. + * @alias translate.projects.detectLanguage + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-id}/locations/{location-id}` or `projects/{project-id}`. For global calls, use `projects/{project-id}/locations/global` or `projects/{project-id}`. Only models within the same region (has same location-id) can be used. Otherwise an INVALID_ARGUMENT (400) error is returned. + * @param {().DetectLanguageRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + detectLanguage( + params?: Params$Resource$Projects$Detectlanguage, + options?: MethodOptions + ): GaxiosPromise; + detectLanguage( + params: Params$Resource$Projects$Detectlanguage, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + detectLanguage( + params: Params$Resource$Projects$Detectlanguage, + callback: BodyResponseCallback + ): void; + detectLanguage( + callback: BodyResponseCallback + ): void; + detectLanguage( + paramsOrCallback?: + | Params$Resource$Projects$Detectlanguage + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Detectlanguage; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Detectlanguage; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+parent}:detectLanguage').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.getSupportedLanguages + * @desc Returns a list of supported languages for translation. + * @alias translate.projects.getSupportedLanguages + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.displayLanguageCode Optional. The language to use to return localized, human readable names of supported languages. If missing, then display names are not returned in a response. + * @param {string=} params.model Optional. Get supported languages of this model. The format depends on model type: - AutoML Translation models: `projects/{project-id}/locations/{location-id}/models/{model-id}` - General (built-in) models: `projects/{project-id}/locations/{location-id}/models/general/nmt`, `projects/{project-id}/locations/{location-id}/models/general/base` Returns languages supported by the specified model. If missing, we get supported languages of Google general base (PBMT) model. + * @param {string} params.parent Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-id}` or `projects/{project-id}/locations/{location-id}`. For global calls, use `projects/{project-id}/locations/global` or `projects/{project-id}`. Non-global location is required for AutoML models. Only models within the same region (have same location-id) can be used, otherwise an INVALID_ARGUMENT (400) error is returned. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + getSupportedLanguages( + params?: Params$Resource$Projects$Getsupportedlanguages, + options?: MethodOptions + ): GaxiosPromise; + getSupportedLanguages( + params: Params$Resource$Projects$Getsupportedlanguages, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + getSupportedLanguages( + params: Params$Resource$Projects$Getsupportedlanguages, + callback: BodyResponseCallback + ): void; + getSupportedLanguages( + callback: BodyResponseCallback + ): void; + getSupportedLanguages( + paramsOrCallback?: + | Params$Resource$Projects$Getsupportedlanguages + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Getsupportedlanguages; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Getsupportedlanguages; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+parent}/supportedLanguages').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.translateText + * @desc Translates input text and returns translated text. + * @alias translate.projects.translateText + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-id}` or `projects/{project-id}/locations/{location-id}`. For global calls, use `projects/{project-id}/locations/global` or `projects/{project-id}`. Non-global location is required for requests using AutoML models or custom glossaries. Models and glossaries must be within the same region (have same location-id), otherwise an INVALID_ARGUMENT (400) error is returned. + * @param {().TranslateTextRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + translateText( + params?: Params$Resource$Projects$Translatetext, + options?: MethodOptions + ): GaxiosPromise; + translateText( + params: Params$Resource$Projects$Translatetext, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + translateText( + params: Params$Resource$Projects$Translatetext, + callback: BodyResponseCallback + ): void; + translateText( + callback: BodyResponseCallback + ): void; + translateText( + paramsOrCallback?: + | Params$Resource$Projects$Translatetext + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Translatetext; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Translatetext; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+parent}:translateText').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Projects$Detectlanguage + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-id}/locations/{location-id}` or `projects/{project-id}`. For global calls, use `projects/{project-id}/locations/global` or `projects/{project-id}`. Only models within the same region (has same location-id) can be used. Otherwise an INVALID_ARGUMENT (400) error is returned. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$DetectLanguageRequest; + } + export interface Params$Resource$Projects$Getsupportedlanguages + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Optional. The language to use to return localized, human readable names of supported languages. If missing, then display names are not returned in a response. + */ + displayLanguageCode?: string; + /** + * Optional. Get supported languages of this model. The format depends on model type: - AutoML Translation models: `projects/{project-id}/locations/{location-id}/models/{model-id}` - General (built-in) models: `projects/{project-id}/locations/{location-id}/models/general/nmt`, `projects/{project-id}/locations/{location-id}/models/general/base` Returns languages supported by the specified model. If missing, we get supported languages of Google general base (PBMT) model. + */ + model?: string; + /** + * Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-id}` or `projects/{project-id}/locations/{location-id}`. For global calls, use `projects/{project-id}/locations/global` or `projects/{project-id}`. Non-global location is required for AutoML models. Only models within the same region (have same location-id) can be used, otherwise an INVALID_ARGUMENT (400) error is returned. + */ + parent?: string; + } + export interface Params$Resource$Projects$Translatetext + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-id}` or `projects/{project-id}/locations/{location-id}`. For global calls, use `projects/{project-id}/locations/global` or `projects/{project-id}`. Non-global location is required for requests using AutoML models or custom glossaries. Models and glossaries must be within the same region (have same location-id), otherwise an INVALID_ARGUMENT (400) error is returned. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$TranslateTextRequest; + } + + export class Resource$Projects$Locations { + context: APIRequestContext; + glossaries: Resource$Projects$Locations$Glossaries; + operations: Resource$Projects$Locations$Operations; + constructor(context: APIRequestContext) { + this.context = context; + this.glossaries = new Resource$Projects$Locations$Glossaries( + this.context + ); + this.operations = new Resource$Projects$Locations$Operations( + this.context + ); + } + + /** + * translate.projects.locations.batchTranslateText + * @desc Translates a large volume of text in asynchronous batch mode. This function provides real-time output as the inputs are being processed. If caller cancels a request, the partial results (for an input file, it's all or nothing) may still be available on the specified output location. This call returns immediately and you can use google.longrunning.Operation.name to poll the status of the call. + * @alias translate.projects.locations.batchTranslateText + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Required. Location to make a call. Must refer to a caller's project. Format: `projects/{project-id}/locations/{location-id}`. The `global` location is not supported for batch translation. Only AutoML Translation models or glossaries within the same region (have the same location-id) can be used, otherwise an INVALID_ARGUMENT (400) error is returned. + * @param {().BatchTranslateTextRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + batchTranslateText( + params?: Params$Resource$Projects$Locations$Batchtranslatetext, + options?: MethodOptions + ): GaxiosPromise; + batchTranslateText( + params: Params$Resource$Projects$Locations$Batchtranslatetext, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + batchTranslateText( + params: Params$Resource$Projects$Locations$Batchtranslatetext, + callback: BodyResponseCallback + ): void; + batchTranslateText(callback: BodyResponseCallback): void; + batchTranslateText( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Batchtranslatetext + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Batchtranslatetext; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Batchtranslatetext; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+parent}:batchTranslateText').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.locations.detectLanguage + * @desc Detects the language of text within a request. + * @alias translate.projects.locations.detectLanguage + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-id}/locations/{location-id}` or `projects/{project-id}`. For global calls, use `projects/{project-id}/locations/global` or `projects/{project-id}`. Only models within the same region (has same location-id) can be used. Otherwise an INVALID_ARGUMENT (400) error is returned. + * @param {().DetectLanguageRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + detectLanguage( + params?: Params$Resource$Projects$Locations$Detectlanguage, + options?: MethodOptions + ): GaxiosPromise; + detectLanguage( + params: Params$Resource$Projects$Locations$Detectlanguage, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + detectLanguage( + params: Params$Resource$Projects$Locations$Detectlanguage, + callback: BodyResponseCallback + ): void; + detectLanguage( + callback: BodyResponseCallback + ): void; + detectLanguage( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Detectlanguage + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Detectlanguage; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Detectlanguage; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+parent}:detectLanguage').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.locations.get + * @desc Gets information about a location. + * @alias translate.projects.locations.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Resource name for the location. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Projects$Locations$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Projects$Locations$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Projects$Locations$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Get + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.locations.getSupportedLanguages + * @desc Returns a list of supported languages for translation. + * @alias translate.projects.locations.getSupportedLanguages + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.displayLanguageCode Optional. The language to use to return localized, human readable names of supported languages. If missing, then display names are not returned in a response. + * @param {string=} params.model Optional. Get supported languages of this model. The format depends on model type: - AutoML Translation models: `projects/{project-id}/locations/{location-id}/models/{model-id}` - General (built-in) models: `projects/{project-id}/locations/{location-id}/models/general/nmt`, `projects/{project-id}/locations/{location-id}/models/general/base` Returns languages supported by the specified model. If missing, we get supported languages of Google general base (PBMT) model. + * @param {string} params.parent Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-id}` or `projects/{project-id}/locations/{location-id}`. For global calls, use `projects/{project-id}/locations/global` or `projects/{project-id}`. Non-global location is required for AutoML models. Only models within the same region (have same location-id) can be used, otherwise an INVALID_ARGUMENT (400) error is returned. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + getSupportedLanguages( + params?: Params$Resource$Projects$Locations$Getsupportedlanguages, + options?: MethodOptions + ): GaxiosPromise; + getSupportedLanguages( + params: Params$Resource$Projects$Locations$Getsupportedlanguages, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + getSupportedLanguages( + params: Params$Resource$Projects$Locations$Getsupportedlanguages, + callback: BodyResponseCallback + ): void; + getSupportedLanguages( + callback: BodyResponseCallback + ): void; + getSupportedLanguages( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Getsupportedlanguages + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Getsupportedlanguages; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Getsupportedlanguages; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+parent}/supportedLanguages').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.locations.list + * @desc Lists information about the supported locations for this service. + * @alias translate.projects.locations.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.filter The standard list filter. + * @param {string} params.name The resource that owns the locations collection, if applicable. + * @param {integer=} params.pageSize The standard list page size. + * @param {string=} params.pageToken The standard list page token. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Locations$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Locations$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Locations$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Locations$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+name}/locations').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.locations.translateText + * @desc Translates input text and returns translated text. + * @alias translate.projects.locations.translateText + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-id}` or `projects/{project-id}/locations/{location-id}`. For global calls, use `projects/{project-id}/locations/global` or `projects/{project-id}`. Non-global location is required for requests using AutoML models or custom glossaries. Models and glossaries must be within the same region (have same location-id), otherwise an INVALID_ARGUMENT (400) error is returned. + * @param {().TranslateTextRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + translateText( + params?: Params$Resource$Projects$Locations$Translatetext, + options?: MethodOptions + ): GaxiosPromise; + translateText( + params: Params$Resource$Projects$Locations$Translatetext, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + translateText( + params: Params$Resource$Projects$Locations$Translatetext, + callback: BodyResponseCallback + ): void; + translateText( + callback: BodyResponseCallback + ): void; + translateText( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Translatetext + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Translatetext; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Translatetext; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+parent}:translateText').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Projects$Locations$Batchtranslatetext + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. Location to make a call. Must refer to a caller's project. Format: `projects/{project-id}/locations/{location-id}`. The `global` location is not supported for batch translation. Only AutoML Translation models or glossaries within the same region (have the same location-id) can be used, otherwise an INVALID_ARGUMENT (400) error is returned. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$BatchTranslateTextRequest; + } + export interface Params$Resource$Projects$Locations$Detectlanguage + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-id}/locations/{location-id}` or `projects/{project-id}`. For global calls, use `projects/{project-id}/locations/global` or `projects/{project-id}`. Only models within the same region (has same location-id) can be used. Otherwise an INVALID_ARGUMENT (400) error is returned. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$DetectLanguageRequest; + } + export interface Params$Resource$Projects$Locations$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Resource name for the location. + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$Getsupportedlanguages + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Optional. The language to use to return localized, human readable names of supported languages. If missing, then display names are not returned in a response. + */ + displayLanguageCode?: string; + /** + * Optional. Get supported languages of this model. The format depends on model type: - AutoML Translation models: `projects/{project-id}/locations/{location-id}/models/{model-id}` - General (built-in) models: `projects/{project-id}/locations/{location-id}/models/general/nmt`, `projects/{project-id}/locations/{location-id}/models/general/base` Returns languages supported by the specified model. If missing, we get supported languages of Google general base (PBMT) model. + */ + model?: string; + /** + * Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-id}` or `projects/{project-id}/locations/{location-id}`. For global calls, use `projects/{project-id}/locations/global` or `projects/{project-id}`. Non-global location is required for AutoML models. Only models within the same region (have same location-id) can be used, otherwise an INVALID_ARGUMENT (400) error is returned. + */ + parent?: string; + } + export interface Params$Resource$Projects$Locations$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The standard list filter. + */ + filter?: string; + /** + * The resource that owns the locations collection, if applicable. + */ + name?: string; + /** + * The standard list page size. + */ + pageSize?: number; + /** + * The standard list page token. + */ + pageToken?: string; + } + export interface Params$Resource$Projects$Locations$Translatetext + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-id}` or `projects/{project-id}/locations/{location-id}`. For global calls, use `projects/{project-id}/locations/global` or `projects/{project-id}`. Non-global location is required for requests using AutoML models or custom glossaries. Models and glossaries must be within the same region (have same location-id), otherwise an INVALID_ARGUMENT (400) error is returned. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$TranslateTextRequest; + } + + export class Resource$Projects$Locations$Glossaries { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * translate.projects.locations.glossaries.create + * @desc Creates a glossary and returns the long-running operation. Returns NOT_FOUND, if the project doesn't exist. + * @alias translate.projects.locations.glossaries.create + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Required. The project name. + * @param {().Glossary} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + create( + params?: Params$Resource$Projects$Locations$Glossaries$Create, + options?: MethodOptions + ): GaxiosPromise; + create( + params: Params$Resource$Projects$Locations$Glossaries$Create, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + create( + params: Params$Resource$Projects$Locations$Glossaries$Create, + callback: BodyResponseCallback + ): void; + create(callback: BodyResponseCallback): void; + create( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Glossaries$Create + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Glossaries$Create; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Glossaries$Create; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+parent}/glossaries').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.locations.glossaries.delete + * @desc Deletes a glossary, or cancels glossary construction if the glossary isn't created yet. Returns NOT_FOUND, if the glossary doesn't exist. + * @alias translate.projects.locations.glossaries.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Required. The name of the glossary to delete. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + delete( + params?: Params$Resource$Projects$Locations$Glossaries$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Projects$Locations$Glossaries$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Projects$Locations$Glossaries$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Glossaries$Delete + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Glossaries$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Glossaries$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.locations.glossaries.get + * @desc Gets a glossary. Returns NOT_FOUND, if the glossary doesn't exist. + * @alias translate.projects.locations.glossaries.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Required. The name of the glossary to retrieve. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Projects$Locations$Glossaries$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Projects$Locations$Glossaries$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Projects$Locations$Glossaries$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Glossaries$Get + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Glossaries$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Glossaries$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.locations.glossaries.list + * @desc Lists glossaries in a project. Returns NOT_FOUND, if the project doesn't exist. + * @alias translate.projects.locations.glossaries.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.filter Optional. Filter specifying constraints of a list operation. Filtering is not supported yet, and the parameter currently has no effect. If missing, no filtering is performed. + * @param {integer=} params.pageSize Optional. Requested page size. The server may return fewer glossaries than requested. If unspecified, the server picks an appropriate default. + * @param {string=} params.pageToken Optional. A token identifying a page of results the server should return. Typically, this is the value of [ListGlossariesResponse.next_page_token] returned from the previous call to `ListGlossaries` method. The first page is returned if `page_token`is empty or missing. + * @param {string} params.parent Required. The name of the project from which to list all of the glossaries. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Locations$Glossaries$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Locations$Glossaries$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Locations$Glossaries$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Glossaries$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Glossaries$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Glossaries$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+parent}/glossaries').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Projects$Locations$Glossaries$Create + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The project name. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$Glossary; + } + export interface Params$Resource$Projects$Locations$Glossaries$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The name of the glossary to delete. + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$Glossaries$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The name of the glossary to retrieve. + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$Glossaries$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Optional. Filter specifying constraints of a list operation. Filtering is not supported yet, and the parameter currently has no effect. If missing, no filtering is performed. + */ + filter?: string; + /** + * Optional. Requested page size. The server may return fewer glossaries than requested. If unspecified, the server picks an appropriate default. + */ + pageSize?: number; + /** + * Optional. A token identifying a page of results the server should return. Typically, this is the value of [ListGlossariesResponse.next_page_token] returned from the previous call to `ListGlossaries` method. The first page is returned if `page_token`is empty or missing. + */ + pageToken?: string; + /** + * Required. The name of the project from which to list all of the glossaries. + */ + parent?: string; + } + + export class Resource$Projects$Locations$Operations { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * translate.projects.locations.operations.cancel + * @desc Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`. + * @alias translate.projects.locations.operations.cancel + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The name of the operation resource to be cancelled. + * @param {().CancelOperationRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + cancel( + params?: Params$Resource$Projects$Locations$Operations$Cancel, + options?: MethodOptions + ): GaxiosPromise; + cancel( + params: Params$Resource$Projects$Locations$Operations$Cancel, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + cancel( + params: Params$Resource$Projects$Locations$Operations$Cancel, + callback: BodyResponseCallback + ): void; + cancel(callback: BodyResponseCallback): void; + cancel( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Operations$Cancel + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Operations$Cancel; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Operations$Cancel; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+name}:cancel').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.locations.operations.delete + * @desc Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. + * @alias translate.projects.locations.operations.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The name of the operation resource to be deleted. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + delete( + params?: Params$Resource$Projects$Locations$Operations$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Projects$Locations$Operations$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Projects$Locations$Operations$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Operations$Delete + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Operations$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Operations$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.locations.operations.get + * @desc 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. + * @alias translate.projects.locations.operations.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The name of the operation resource. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Projects$Locations$Operations$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Projects$Locations$Operations$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Projects$Locations$Operations$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Operations$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Operations$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Operations$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.locations.operations.list + * @desc Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/x/operations`. To override the binding, API services can add a binding such as `"/v1/{name=users/x}/operations"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id. + * @alias translate.projects.locations.operations.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.filter The standard list filter. + * @param {string} params.name The name of the operation's parent resource. + * @param {integer=} params.pageSize The standard list page size. + * @param {string=} params.pageToken The standard list page token. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Locations$Operations$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Locations$Operations$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Locations$Operations$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Operations$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Operations$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Operations$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+name}/operations').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * translate.projects.locations.operations.wait + * @desc Waits for the specified long-running operation until it is done or reaches at most a specified timeout, returning the latest state. If the operation is already done, the latest state is immediately returned. If the timeout specified is greater than the default HTTP/RPC timeout, the HTTP/RPC timeout is used. If the server does not support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Note that this method is on a best-effort basis. It may return the latest state before the specified timeout (including immediately), meaning even an immediate response is no guarantee that the operation is done. + * @alias translate.projects.locations.operations.wait + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The name of the operation resource to wait on. + * @param {().WaitOperationRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + wait( + params?: Params$Resource$Projects$Locations$Operations$Wait, + options?: MethodOptions + ): GaxiosPromise; + wait( + params: Params$Resource$Projects$Locations$Operations$Wait, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + wait( + params: Params$Resource$Projects$Locations$Operations$Wait, + callback: BodyResponseCallback + ): void; + wait(callback: BodyResponseCallback): void; + wait( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Operations$Wait + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Operations$Wait; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Operations$Wait; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://translation.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v3beta1/{+name}:wait').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Projects$Locations$Operations$Cancel + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The name of the operation resource to be cancelled. + */ + name?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$CancelOperationRequest; + } + export interface Params$Resource$Projects$Locations$Operations$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The name of the operation resource to be deleted. + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$Operations$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The name of the operation resource. + */ + name?: string; + } + export interface Params$Resource$Projects$Locations$Operations$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The standard list filter. + */ + filter?: string; + /** + * The name of the operation's parent resource. + */ + name?: string; + /** + * The standard list page size. + */ + pageSize?: number; + /** + * The standard list page token. + */ + pageToken?: string; + } + export interface Params$Resource$Projects$Locations$Operations$Wait + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The name of the operation resource to wait on. + */ + name?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$WaitOperationRequest; + } +} diff --git a/src/apis/verifiedaccess/README.md b/src/apis/verifiedaccess/README.md new file mode 100644 index 00000000000..badc795b113 --- /dev/null +++ b/src/apis/verifiedaccess/README.md @@ -0,0 +1,47 @@ +Google Inc. logo + +# verifiedaccess + +> API for Verified Access chrome extension to provide credential verification for chrome devices connecting to an enterprise network + +## Installation + +```sh +$ npm install googleapis +``` + +## Usage +All documentation and usage information can be found on [GitHub](https://github.com/googleapis/google-api-nodejs-client). + +## Building a browser bundle + +This library can be used in a browser. To prepare a single file bundle, clone the +[repository](https://github.com/googleapis/google-api-nodejs-client) and run + +```sh +$ cd src/apis/verifiedaccess +$ npm install +$ npm run webpack +``` + +The generated bundle will be written to `dist/verifiedaccess.min.js`. Use it from your HTML file: + +```html + + +``` + +## License +This library is licensed under Apache 2.0. Full license text is available in [LICENSE](https://github.com/googleapis/google-api-nodejs-client/blob/master/LICENSE). + +## Contributing +We love contributions! Before submitting a Pull Request, it's always good to start with a new issue first. To learn more, see [CONTRIBUTING](https://github.com/google/google-api-nodejs-client/blob/master/.github/CONTRIBUTING.md). + +## Questions/problems? +* Ask your development related questions on [StackOverflow](http://stackoverflow.com/questions/tagged/google-api-nodejs-client). +* If you've found an bug/issue, please [file it on GitHub](https://github.com/googleapis/google-api-nodejs-client/issues). + + +*Crafted with ❤️ by the Google Node.js team* diff --git a/src/apis/verifiedaccess/index.ts b/src/apis/verifiedaccess/index.ts new file mode 100644 index 00000000000..78211a9681a --- /dev/null +++ b/src/apis/verifiedaccess/index.ts @@ -0,0 +1,35 @@ +// Copyright 2019 Google LLC +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +/*! THIS FILE IS AUTO-GENERATED */ + +import {AuthPlus, getAPI, GoogleConfigurable} from 'googleapis-common'; +import {verifiedaccess_v1} from './v1'; + +export const VERSIONS = { + v1: verifiedaccess_v1.Verifiedaccess, +}; + +export function verifiedaccess(version: 'v1'): verifiedaccess_v1.Verifiedaccess; +export function verifiedaccess( + options: verifiedaccess_v1.Options +): verifiedaccess_v1.Verifiedaccess; +export function verifiedaccess( + this: GoogleConfigurable, + versionOrOptions: 'v1' | verifiedaccess_v1.Options +) { + return getAPI('verifiedaccess', versionOrOptions, VERSIONS, this); +} + +const auth = new AuthPlus(); +export {auth}; diff --git a/src/apis/verifiedaccess/package.json b/src/apis/verifiedaccess/package.json new file mode 100644 index 00000000000..faf6a4243ae --- /dev/null +++ b/src/apis/verifiedaccess/package.json @@ -0,0 +1,43 @@ +{ + "name": "@google/verifiedaccess", + "version": "0.1.0", + "description": "verifiedaccess", + "main": "build/index.js", + "types": "build/index.d.ts", + "keywords": [ + "google" + ], + "author": "Google LLC", + "license": "Apache-2.0", + "homepage": "https://github.com/googleapis/google-api-nodejs-client", + "bugs": { + "url": "https://github.com/googleapis/google-api-nodejs-client/issues" + }, + "repository": { + "type": "git", + "url": "https://github.com/googleapis/google-api-nodejs-client.git" + }, + "engines": { + "node": ">=8.0.0" + }, + "scripts": { + "fix": "gts fix", + "lint": "gts check", + "compile": "tsc -p .", + "prepare": "npm run compile", + "docs": "typedoc --out docs/", + "webpack": "webpack" + }, + "dependencies": { + "googleapis-common": "^3.0.0" + }, + "devDependencies": { + "gts": "^1.0.0", + "null-loader": "^3.0.0", + "ts-loader": "^6.0.4", + "typedoc": "^0.15.0", + "typescript": "~3.6.0", + "webpack": "^4.35.3", + "webpack-cli": "^3.3.5" + } +} diff --git a/src/apis/verifiedaccess/tsconfig.json b/src/apis/verifiedaccess/tsconfig.json new file mode 100644 index 00000000000..e0810904968 --- /dev/null +++ b/src/apis/verifiedaccess/tsconfig.json @@ -0,0 +1,10 @@ +{ + "extends": "./node_modules/gts/tsconfig-google.json", + "compilerOptions": { + "rootDir": ".", + "outDir": "build" + }, + "include": [ + "*.ts", + ] +} diff --git a/src/apis/verifiedaccess/v1.ts b/src/apis/verifiedaccess/v1.ts new file mode 100644 index 00000000000..f85d31ad22d --- /dev/null +++ b/src/apis/verifiedaccess/v1.ts @@ -0,0 +1,368 @@ +/** + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { + OAuth2Client, + JWT, + Compute, + UserRefreshClient, +} from 'google-auth-library'; +import { + GoogleConfigurable, + createAPIRequest, + MethodOptions, + GlobalOptions, + BodyResponseCallback, + APIRequestContext, +} from 'googleapis-common'; +import {GaxiosPromise} from 'gaxios'; + +// tslint:disable: no-any +// tslint:disable: class-name +// tslint:disable: variable-name +// tslint:disable: jsdoc-format +// tslint:disable: no-namespace + +export namespace verifiedaccess_v1 { + export interface Options extends GlobalOptions { + version: 'v1'; + } + + interface StandardParameters { + /** + * V1 error format. + */ + '$.xgafv'?: string; + /** + * OAuth access token. + */ + access_token?: string; + /** + * Data format for response. + */ + alt?: string; + /** + * JSONP + */ + callback?: string; + /** + * Selector specifying which fields to include in a partial response. + */ + fields?: string; + /** + * 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. + */ + key?: string; + /** + * OAuth 2.0 token for the current user. + */ + oauth_token?: string; + /** + * Returns response with indentations and line breaks. + */ + prettyPrint?: boolean; + /** + * 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. + */ + quotaUser?: string; + /** + * Legacy upload protocol for media (e.g. "media", "multipart"). + */ + uploadType?: string; + /** + * Upload protocol for media (e.g. "raw", "multipart"). + */ + upload_protocol?: string; + } + + /** + * Verified Access API + * + * API for Verified Access chrome extension to provide credential verification for chrome devices connecting to an enterprise network + * + * @example + * const {google} = require('googleapis'); + * const verifiedaccess = google.verifiedaccess('v1'); + * + * @namespace verifiedaccess + * @type {Function} + * @version v1 + * @variation v1 + * @param {object=} options Options for Verifiedaccess + */ + export class Verifiedaccess { + context: APIRequestContext; + challenge: Resource$Challenge; + + constructor(options: GlobalOptions, google?: GoogleConfigurable) { + this.context = { + _options: options || {}, + google, + }; + + this.challenge = new Resource$Challenge(this.context); + } + } + + /** + * Result message for VerifiedAccess.CreateChallenge. + */ + export interface Schema$Challenge { + /** + * Challenge generated with the old signing key (this will only be present during key rotation) + */ + alternativeChallenge?: Schema$SignedData; + /** + * Generated challenge + */ + challenge?: Schema$SignedData; + } + /** + * A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`. + */ + export interface Schema$Empty {} + /** + * The wrapper message of any data and its signature. + */ + export interface Schema$SignedData { + /** + * The data to be signed. + */ + data?: string; + /** + * The signature of the data field. + */ + signature?: string; + } + /** + * signed ChallengeResponse + */ + export interface Schema$VerifyChallengeResponseRequest { + /** + * The generated response to the challenge + */ + challengeResponse?: Schema$SignedData; + /** + * Service can optionally provide identity information about the device or user associated with the key. For an EMK, this value is the enrolled domain. For an EUK, this value is the user's email address. If present, this value will be checked against contents of the response, and verification will fail if there is no match. + */ + expectedIdentity?: string; + } + /** + * Result message for VerifiedAccess.VerifyChallengeResponse. + */ + export interface Schema$VerifyChallengeResponseResult { + /** + * Device enrollment id is returned in this field (for the machine response only). + */ + deviceEnrollmentId?: string; + /** + * Device permanent id is returned in this field (for the machine response only). + */ + devicePermanentId?: string; + /** + * Certificate Signing Request (in the SPKAC format, base64 encoded) is returned in this field. This field will be set only if device has included CSR in its challenge response. (the option to include CSR is now available for both user and machine responses) + */ + signedPublicKeyAndChallenge?: string; + /** + * For EMCert check, device permanent id is returned here. For EUCert check, signed_public_key_and_challenge [base64 encoded] is returned if present, otherwise empty string is returned. This field is deprecated, please use device_permanent_id or signed_public_key_and_challenge fields. + */ + verificationOutput?: string; + } + + export class Resource$Challenge { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * verifiedaccess.challenge.create + * @desc CreateChallenge API + * @alias verifiedaccess.challenge.create + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().Empty} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + create( + params?: Params$Resource$Challenge$Create, + options?: MethodOptions + ): GaxiosPromise; + create( + params: Params$Resource$Challenge$Create, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + create( + params: Params$Resource$Challenge$Create, + callback: BodyResponseCallback + ): void; + create(callback: BodyResponseCallback): void; + create( + paramsOrCallback?: + | Params$Resource$Challenge$Create + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Challenge$Create; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Challenge$Create; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://verifiedaccess.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/challenge').replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * verifiedaccess.challenge.verify + * @desc VerifyChallengeResponse API + * @alias verifiedaccess.challenge.verify + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().VerifyChallengeResponseRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + verify( + params?: Params$Resource$Challenge$Verify, + options?: MethodOptions + ): GaxiosPromise; + verify( + params: Params$Resource$Challenge$Verify, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + verify( + params: Params$Resource$Challenge$Verify, + callback: BodyResponseCallback + ): void; + verify( + callback: BodyResponseCallback + ): void; + verify( + paramsOrCallback?: + | Params$Resource$Challenge$Verify + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Challenge$Verify; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Challenge$Verify; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://verifiedaccess.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/challenge:verify').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest( + parameters + ); + } + } + } + + export interface Params$Resource$Challenge$Create extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Request body metadata + */ + requestBody?: Schema$Empty; + } + export interface Params$Resource$Challenge$Verify extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Request body metadata + */ + requestBody?: Schema$VerifyChallengeResponseRequest; + } +} diff --git a/src/apis/verifiedaccess/webpack.config.js b/src/apis/verifiedaccess/webpack.config.js new file mode 100644 index 00000000000..b896bf73b6c --- /dev/null +++ b/src/apis/verifiedaccess/webpack.config.js @@ -0,0 +1,71 @@ +/** + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Use `npm run webpack` to produce Webpack bundle for this library. + +const path = require('path'); + +module.exports = { + entry: './index.ts', + resolve: { + extensions: ['.ts', '.js', '.json'], + }, + output: { + library: 'Verifiedaccess', + filename: 'verifiedaccess.min.js', + path: path.resolve(__dirname, 'dist'), + }, + node: { + child_process: 'empty', + fs: 'empty', + crypto: 'empty', + }, + module: { + rules: [ + { + test: /node_modules[\\/]google-auth-library[\\/]src[\\/]crypto[\\/]node[\\/]crypto/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]https-proxy-agent[\\/]/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]gcp-metadata[\\/]/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]gtoken[\\/]/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]pkginfo[\\/]/, + use: 'null-loader', + }, + { + test: /node_modules[\\/]semver[\\/]/, + use: 'null-loader', + }, + { + test: /\.ts$/, + use: 'ts-loader', + exclude: /node_modules/, + }, + ], + }, + mode: 'production', + plugins: [], +}; diff --git a/src/apis/videointelligence/v1.ts b/src/apis/videointelligence/v1.ts index d92405e9098..497ffbdd0bb 100644 --- a/src/apis/videointelligence/v1.ts +++ b/src/apis/videointelligence/v1.ts @@ -432,6 +432,10 @@ export namespace videointelligence_v1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1beta2_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1beta2_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -802,6 +806,10 @@ export namespace videointelligence_v1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p1beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p1beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -1172,6 +1180,10 @@ export namespace videointelligence_v1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p2beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p2beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -1656,6 +1668,10 @@ export namespace videointelligence_v1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p3beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p3beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -2170,6 +2186,10 @@ export namespace videointelligence_v1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -2333,277 +2353,6 @@ export namespace videointelligence_v1 { this.context = context; this.projects = new Resource$Operations$Projects(this.context); } - - /** - * videointelligence.operations.cancel - * @desc Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`. - * @alias videointelligence.operations.cancel - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.name The name of the operation resource to be cancelled. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - cancel( - params?: Params$Resource$Operations$Cancel, - options?: MethodOptions - ): GaxiosPromise; - cancel( - params: Params$Resource$Operations$Cancel, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - cancel( - params: Params$Resource$Operations$Cancel, - callback: BodyResponseCallback - ): void; - cancel(callback: BodyResponseCallback): void; - cancel( - paramsOrCallback?: - | Params$Resource$Operations$Cancel - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Operations$Cancel; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Operations$Cancel; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = - options.rootUrl || 'https://videointelligence.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1/operations/{+name}:cancel').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'POST', - }, - options - ), - params, - requiredParams: ['name'], - pathParams: ['name'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * videointelligence.operations.delete - * @desc Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. - * @alias videointelligence.operations.delete - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.name The name of the operation resource to be deleted. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - delete( - params?: Params$Resource$Operations$Delete, - options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Operations$Delete, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - delete( - params: Params$Resource$Operations$Delete, - callback: BodyResponseCallback - ): void; - delete(callback: BodyResponseCallback): void; - delete( - paramsOrCallback?: - | Params$Resource$Operations$Delete - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Operations$Delete; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Operations$Delete; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = - options.rootUrl || 'https://videointelligence.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1/operations/{+name}').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'DELETE', - }, - options - ), - params, - requiredParams: ['name'], - pathParams: ['name'], - context: this.context, - }; - if (callback) { - createAPIRequest(parameters, callback); - } else { - return createAPIRequest(parameters); - } - } - - /** - * videointelligence.operations.get - * @desc 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. - * @alias videointelligence.operations.get - * @memberOf! () - * - * @param {object} params Parameters for request - * @param {string} params.name The name of the operation resource. - * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. - * @param {callback} callback The callback that handles the response. - * @return {object} Request object - */ - get( - params?: Params$Resource$Operations$Get, - options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Operations$Get, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - get( - params: Params$Resource$Operations$Get, - callback: BodyResponseCallback - ): void; - get( - callback: BodyResponseCallback - ): void; - get( - paramsOrCallback?: - | Params$Resource$Operations$Get - | BodyResponseCallback, - optionsOrCallback?: - | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Operations$Get; - let options = (optionsOrCallback || {}) as MethodOptions; - - if (typeof paramsOrCallback === 'function') { - callback = paramsOrCallback; - params = {} as Params$Resource$Operations$Get; - options = {}; - } - - if (typeof optionsOrCallback === 'function') { - callback = optionsOrCallback; - options = {}; - } - - const rootUrl = - options.rootUrl || 'https://videointelligence.googleapis.com/'; - const parameters = { - options: Object.assign( - { - url: (rootUrl + '/v1/operations/{+name}').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'GET', - }, - options - ), - params, - requiredParams: ['name'], - pathParams: ['name'], - context: this.context, - }; - if (callback) { - createAPIRequest( - parameters, - callback - ); - } else { - return createAPIRequest(parameters); - } - } - } - - export interface Params$Resource$Operations$Cancel - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the operation resource to be cancelled. - */ - name?: string; - } - export interface Params$Resource$Operations$Delete - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the operation resource to be deleted. - */ - name?: string; - } - export interface Params$Resource$Operations$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the operation resource. - */ - name?: string; } export class Resource$Operations$Projects { diff --git a/src/apis/videointelligence/v1beta2.ts b/src/apis/videointelligence/v1beta2.ts index 30b621521c4..6095f431155 100644 --- a/src/apis/videointelligence/v1beta2.ts +++ b/src/apis/videointelligence/v1beta2.ts @@ -572,6 +572,10 @@ export namespace videointelligence_v1beta2 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1beta2_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1beta2_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -975,6 +979,10 @@ export namespace videointelligence_v1beta2 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p1beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p1beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -1345,6 +1353,10 @@ export namespace videointelligence_v1beta2 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p2beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p2beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -1829,6 +1841,10 @@ export namespace videointelligence_v1beta2 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p3beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p3beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -2199,6 +2215,10 @@ export namespace videointelligence_v1beta2 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ diff --git a/src/apis/videointelligence/v1p1beta1.ts b/src/apis/videointelligence/v1p1beta1.ts index 117b71f9479..ae46e731b53 100644 --- a/src/apis/videointelligence/v1p1beta1.ts +++ b/src/apis/videointelligence/v1p1beta1.ts @@ -428,6 +428,10 @@ export namespace videointelligence_v1p1beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1beta2_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1beta2_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -942,6 +946,10 @@ export namespace videointelligence_v1p1beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p1beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p1beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -1345,6 +1353,10 @@ export namespace videointelligence_v1p1beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p2beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p2beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -1829,6 +1841,10 @@ export namespace videointelligence_v1p1beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p3beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p3beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -2199,6 +2215,10 @@ export namespace videointelligence_v1p1beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ diff --git a/src/apis/videointelligence/v1p2beta1.ts b/src/apis/videointelligence/v1p2beta1.ts index b42b75afe88..a15d748abb3 100644 --- a/src/apis/videointelligence/v1p2beta1.ts +++ b/src/apis/videointelligence/v1p2beta1.ts @@ -428,6 +428,10 @@ export namespace videointelligence_v1p2beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1beta2_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1beta2_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -798,6 +802,10 @@ export namespace videointelligence_v1p2beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p1beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p1beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -1312,6 +1320,10 @@ export namespace videointelligence_v1p2beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p2beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p2beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -1829,6 +1841,10 @@ export namespace videointelligence_v1p2beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p3beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p3beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -2199,6 +2215,10 @@ export namespace videointelligence_v1p2beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ diff --git a/src/apis/videointelligence/v1p3beta1.ts b/src/apis/videointelligence/v1p3beta1.ts index 3d747b23f5c..ae8e91948de 100644 --- a/src/apis/videointelligence/v1p3beta1.ts +++ b/src/apis/videointelligence/v1p3beta1.ts @@ -428,6 +428,10 @@ export namespace videointelligence_v1p3beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1beta2_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1beta2_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -798,6 +802,10 @@ export namespace videointelligence_v1p3beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p1beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p1beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -1168,6 +1176,10 @@ export namespace videointelligence_v1p3beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p2beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p2beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -1796,6 +1808,10 @@ export namespace videointelligence_v1p3beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1p3beta1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1p3beta1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ @@ -2199,6 +2215,10 @@ export namespace videointelligence_v1p3beta1 { * Annotations for list of objects detected and tracked in video. */ objectAnnotations?: Schema$GoogleCloudVideointelligenceV1_ObjectTrackingAnnotation[]; + /** + * Video segment on which the annotation is run. + */ + segment?: Schema$GoogleCloudVideointelligenceV1_VideoSegment; /** * Topical label annotations on video level or user specified segment level. There is exactly one element for each unique label. */ diff --git a/src/apis/vision/v1.ts b/src/apis/vision/v1.ts index b512e3998d5..7cddb4cd436 100644 --- a/src/apis/vision/v1.ts +++ b/src/apis/vision/v1.ts @@ -159,12 +159,16 @@ export namespace vision_v1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$AnnotateImageResponse[]; /** @@ -284,6 +288,10 @@ export namespace vision_v1 { * Multiple async file annotation requests are batched into a single service call. */ export interface Schema$AsyncBatchAnnotateFilesRequest { + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; /** * Individual async file annotation requests for this batch. */ @@ -306,6 +314,10 @@ export namespace vision_v1 { * Required. The desired output location and metadata (e.g. format). */ outputConfig?: Schema$OutputConfig; + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; /** * Individual image annotation requests for this batch. */ @@ -324,6 +336,10 @@ export namespace vision_v1 { * A list of requests to annotate files using the BatchAnnotateFiles API. */ export interface Schema$BatchAnnotateFilesRequest { + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; /** * The list of file annotation requests. Right now we support only one AnnotateFileRequest in BatchAnnotateFilesRequest. */ @@ -342,6 +358,10 @@ export namespace vision_v1 { * Multiple image annotation requests are batched into a single service call. */ export interface Schema$BatchAnnotateImagesRequest { + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; /** * Individual image annotation requests for this batch. */ @@ -672,12 +692,16 @@ export namespace vision_v1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p1beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p1beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p1beta1AnnotateImageResponse[]; /** @@ -1149,7 +1173,7 @@ export namespace vision_v1 { */ property?: Schema$GoogleCloudVisionV1p1beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p1beta1Word[]; } @@ -1191,7 +1215,7 @@ export namespace vision_v1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p1beta1ProductKeyValue[]; } @@ -1233,11 +1257,36 @@ export namespace vision_v1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p1beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p1beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p1beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p1beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -1302,7 +1351,7 @@ export namespace vision_v1 { */ export interface Schema$GoogleCloudVisionV1p1beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p1beta1BoundingPoly; /** @@ -1505,12 +1554,16 @@ export namespace vision_v1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p2beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p2beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p2beta1AnnotateImageResponse[]; /** @@ -1982,7 +2035,7 @@ export namespace vision_v1 { */ property?: Schema$GoogleCloudVisionV1p2beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p2beta1Word[]; } @@ -2024,7 +2077,7 @@ export namespace vision_v1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p2beta1ProductKeyValue[]; } @@ -2066,11 +2119,36 @@ export namespace vision_v1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p2beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p2beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p2beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p2beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -2135,7 +2213,7 @@ export namespace vision_v1 { */ export interface Schema$GoogleCloudVisionV1p2beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p2beta1BoundingPoly; /** @@ -2338,12 +2416,16 @@ export namespace vision_v1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p3beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p3beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p3beta1AnnotateImageResponse[]; /** @@ -2845,7 +2927,7 @@ export namespace vision_v1 { */ property?: Schema$GoogleCloudVisionV1p3beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p3beta1Word[]; } @@ -2887,7 +2969,7 @@ export namespace vision_v1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p3beta1ProductKeyValue[]; } @@ -2929,11 +3011,36 @@ export namespace vision_v1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p3beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p3beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p3beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p3beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -3015,7 +3122,7 @@ export namespace vision_v1 { */ export interface Schema$GoogleCloudVisionV1p3beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p3beta1BoundingPoly; /** @@ -3218,12 +3325,16 @@ export namespace vision_v1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p4beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p4beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p4beta1AnnotateImageResponse[]; /** @@ -3259,6 +3370,10 @@ export namespace vision_v1 { * If present, image properties were extracted successfully. */ imagePropertiesAnnotation?: Schema$GoogleCloudVisionV1p4beta1ImageProperties; + /** + * If present, image quality calculation has completed successfully. + */ + imageQualityAnnotation?: Schema$GoogleCloudVisionV1p4beta1ImageQuality; /** * If present, label detection has completed successfully. */ @@ -3279,6 +3394,10 @@ export namespace vision_v1 { * If present, product search has completed successfully. */ productSearchResults?: Schema$GoogleCloudVisionV1p4beta1ProductSearchResults; + /** + * If present, image quality optimization has completed successfully. + */ + qualityOptimizationResult?: Schema$GoogleCloudVisionV1p4beta1QualityOptimizationResult; /** * If present, safe-search annotation has completed successfully. */ @@ -3594,6 +3713,15 @@ export namespace vision_v1 { */ dominantColors?: Schema$GoogleCloudVisionV1p4beta1DominantColorsAnnotation; } + /** + * Stores image quality scores, could be aesthetic quality or technical quality. + */ + export interface Schema$GoogleCloudVisionV1p4beta1ImageQuality { + /** + * A score representing the aesthetic/technical quality of the image. The score is in range [0, 1]. Higher value corresponds to more professional looking photos. 0 means the image looks very bad, 1 means the image with very high quality. + */ + qualityScore?: number; + } /** * Response message for the `ImportProductSets` method. This message is returned by the google.longrunning.Operations.GetOperation method in the returned google.longrunning.Operation.response field. */ @@ -3743,7 +3871,7 @@ export namespace vision_v1 { */ property?: Schema$GoogleCloudVisionV1p4beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p4beta1Word[]; } @@ -3785,7 +3913,7 @@ export namespace vision_v1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p4beta1ProductKeyValue[]; } @@ -3827,11 +3955,36 @@ export namespace vision_v1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p4beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p4beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p4beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p4beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -3866,6 +4019,23 @@ export namespace vision_v1 { */ value?: string; } + /** + * Stores enhanced image bytes. + */ + export interface Schema$GoogleCloudVisionV1p4beta1QualityOptimizationResult { + /** + * Optimized image bytes. + */ + image?: string; + /** + * Mime type of the output image. + */ + mimeType?: string; + /** + * Required optimization type. + */ + qualityOptimizationType?: string; + } /** * A `ReferenceImage` represents a product image and its associated metadata, such as bounding boxes. */ @@ -3891,29 +4061,53 @@ export namespace vision_v1 { * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. */ adult?: string; + /** + * Confidence of adult_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + adultConfidence?: number; /** * Likelihood that this is a medical image. */ medical?: string; + /** + * Confidence of medical_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + medicalConfidence?: number; + /** + * Confidence of nsfw_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + nsfwConfidence?: number; /** * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. */ racy?: string; + /** + * Confidence of racy_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + racyConfidence?: number; /** * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. */ spoof?: string; + /** + * Confidence of spoof_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + spoofConfidence?: number; /** * Likelihood that this image contains violent content. */ violence?: string; + /** + * Confidence of violence_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + violenceConfidence?: number; } /** * A single symbol representation. */ export interface Schema$GoogleCloudVisionV1p4beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p4beta1BoundingPoly; /** @@ -4116,12 +4310,16 @@ export namespace vision_v1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p5beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p5beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p5beta1AnnotateImageResponse[]; /** @@ -4686,7 +4884,7 @@ export namespace vision_v1 { */ property?: Schema$GoogleCloudVisionV1p5beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p5beta1Word[]; } @@ -4728,7 +4926,7 @@ export namespace vision_v1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p5beta1ProductKeyValue[]; } @@ -4770,11 +4968,36 @@ export namespace vision_v1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p5beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p5beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p5beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p5beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -4834,29 +5057,53 @@ export namespace vision_v1 { * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. */ adult?: string; + /** + * Confidence of adult_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + adultConfidence?: number; /** * Likelihood that this is a medical image. */ medical?: string; + /** + * Confidence of medical_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + medicalConfidence?: number; + /** + * Confidence of nsfw_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + nsfwConfidence?: number; /** * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. */ racy?: string; + /** + * Confidence of racy_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + racyConfidence?: number; /** * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. */ spoof?: string; + /** + * Confidence of spoof_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + spoofConfidence?: number; /** * Likelihood that this image contains violent content. */ violence?: string; + /** + * Confidence of violence_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + violenceConfidence?: number; } /** * A single symbol representation. */ export interface Schema$GoogleCloudVisionV1p5beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p5beta1BoundingPoly; /** @@ -5103,488 +5350,376 @@ export namespace vision_v1 { symbols?: Schema$GoogleCloudVisionV1p5beta1Symbol[]; } /** - * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. + * Information about the products similar to a single product in a query image. */ - export interface Schema$GoogleCloudVisionV1p6beta1AnnotateFileResponse { + export interface Schema$GroupedResult { /** - * Information about the file for which this response is generated. + * The bounding polygon around the product detected in the query image. */ - inputConfig?: Schema$GoogleCloudVisionV1p6beta1InputConfig; + boundingPoly?: Schema$BoundingPoly; /** - * Individual responses to images found within the file. + * List of generic predictions for the object in the bounding box. */ - responses?: Schema$GoogleCloudVisionV1p6beta1AnnotateImageResponse[]; + objectAnnotations?: Schema$ObjectAnnotation[]; /** - * This field gives the total number of pages in the file. + * List of results, one for each product match. */ - totalPages?: number; + results?: Schema$Result[]; } /** - * Response to an image annotation request. + * Client image to perform Google Cloud Vision API tasks over. */ - export interface Schema$GoogleCloudVisionV1p6beta1AnnotateImageResponse { + export interface Schema$Image { /** - * If present, contextual information is needed to understand where this image comes from. + * Image content, represented as a stream of bytes. Note: As with all `bytes` fields, protobuffers use a pure binary representation, whereas JSON representations use base64. */ - context?: Schema$GoogleCloudVisionV1p6beta1ImageAnnotationContext; + content?: string; /** - * If present, crop hints have completed successfully. + * Google Cloud Storage image location, or publicly-accessible image URL. If both `content` and `source` are provided for an image, `content` takes precedence and is used to perform the image annotation request. */ - cropHintsAnnotation?: Schema$GoogleCloudVisionV1p6beta1CropHintsAnnotation; + source?: Schema$ImageSource; + } + /** + * If an image was produced from a file (e.g. a PDF), this message gives information about the source of that image. + */ + export interface Schema$ImageAnnotationContext { /** - * If set, represents the error message for the operation. Note that filled-in image annotations are guaranteed to be correct, even when `error` is set. + * If the file was a PDF or TIFF, this field gives the page number within the file used to produce the image. */ - error?: Schema$Status; + pageNumber?: number; /** - * If present, face detection has completed successfully. + * The URI of the file used to produce the image. */ - faceAnnotations?: Schema$GoogleCloudVisionV1p6beta1FaceAnnotation[]; + uri?: string; + } + /** + * Image context and/or feature-specific parameters. + */ + export interface Schema$ImageContext { /** - * If present, text (OCR) detection or document (OCR) text detection has completed successfully. This annotation provides the structural hierarchy for the OCR detected text. + * Parameters for crop hints annotation request. */ - fullTextAnnotation?: Schema$GoogleCloudVisionV1p6beta1TextAnnotation; + cropHintsParams?: Schema$CropHintsParams; /** - * If present, image properties were extracted successfully. + * List of languages to use for TEXT_DETECTION. In most cases, an empty value yields the best results since it enables automatic language detection. For languages based on the Latin alphabet, setting `language_hints` is not needed. In rare cases, when the language of the text in the image is known, setting a hint will help get better results (although it will be a significant hindrance if the hint is wrong). Text detection returns an error if one or more of the specified languages is not one of the [supported languages](/vision/docs/languages). */ - imagePropertiesAnnotation?: Schema$GoogleCloudVisionV1p6beta1ImageProperties; + languageHints?: string[]; /** - * If present, image quality calculation has completed successfully. + * Not used. */ - imageQualityAnnotation?: Schema$GoogleCloudVisionV1p6beta1ImageQuality; + latLongRect?: Schema$LatLongRect; /** - * If present, label detection has completed successfully. + * Parameters for product search. */ - labelAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; + productSearchParams?: Schema$ProductSearchParams; /** - * If present, landmark detection has completed successfully. + * Parameters for web detection. */ - landmarkAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; + webDetectionParams?: Schema$WebDetectionParams; + } + /** + * Stores image properties, such as dominant colors. + */ + export interface Schema$ImageProperties { /** - * If present, localized object detection has completed successfully. This will be sorted descending by confidence score. + * If present, dominant colors completed successfully. */ - localizedObjectAnnotations?: Schema$GoogleCloudVisionV1p6beta1LocalizedObjectAnnotation[]; + dominantColors?: Schema$DominantColorsAnnotation; + } + /** + * External image source (Google Cloud Storage or web URL image location). + */ + export interface Schema$ImageSource { /** - * If present, logo detection has completed successfully. + * **Use `image_uri` instead.** The Google Cloud Storage URI of the form `gs://bucket_name/object_name`. Object versioning is not supported. See [Google Cloud Storage Request URIs](https://cloud.google.com/storage/docs/reference-uris) for more info. */ - logoAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; + gcsImageUri?: string; /** - * If present, objects attributes calculation has completed successfully. The attributes value will be filled in the EntityAnnotation.properties. Example: object_attribute_annotations { properties { name: "color" value: "blue" confidence: 0.1 } properties { name: "color" value: "white" confidence: 0.2 } properties { name: "material" value: "silk" confidence: 0.3 } } + * The URI of the source image. Can be either: 1. A Google Cloud Storage URI of the form `gs://bucket_name/object_name`. Object versioning is not supported. See [Google Cloud Storage Request URIs](https://cloud.google.com/storage/docs/reference-uris) for more info. 2. A publicly-accessible image HTTP/HTTPS URL. When fetching images from HTTP/HTTPS URLs, Google cannot guarantee that the request will be completed. Your request may fail if the specified host denies the request (e.g. due to request throttling or DOS prevention), or if Google throttles requests to the site for abuse prevention. You should not depend on externally-hosted images for production applications. When both `gcs_image_uri` and `image_uri` are specified, `image_uri` takes precedence. */ - objectAttributeAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; - /** - * If present, product search has completed successfully. - */ - productSearchResults?: Schema$GoogleCloudVisionV1p6beta1ProductSearchResults; - /** - * If present, image quality optimization has completed successfully. - */ - qualityOptimizationResult?: Schema$GoogleCloudVisionV1p6beta1QualityOptimizationResult; - /** - * If present, safe-search annotation has completed successfully. - */ - safeSearchAnnotation?: Schema$GoogleCloudVisionV1p6beta1SafeSearchAnnotation; - /** - * If present, text (OCR) detection has completed successfully. - */ - textAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; - /** - * If present, web detection has completed successfully. - */ - webDetection?: Schema$GoogleCloudVisionV1p6beta1WebDetection; + imageUri?: string; } /** - * The response for a single offline file annotation request. + * The Google Cloud Storage location for a csv file which preserves a list of ImportProductSetRequests in each line. */ - export interface Schema$GoogleCloudVisionV1p6beta1AsyncAnnotateFileResponse { + export interface Schema$ImportProductSetsGcsSource { /** - * The output location and metadata from AsyncAnnotateFileRequest. + * The Google Cloud Storage URI of the input csv file. The URI must start with `gs://`. The format of the input csv file should be one image per line. In each line, there are 8 columns. 1. image-uri 2. image-id 3. product-set-id 4. product-id 5. product-category 6. product-display-name 7. labels 8. bounding-poly The `image-uri`, `product-set-id`, `product-id`, and `product-category` columns are required. All other columns are optional. If the `ProductSet` or `Product` specified by the `product-set-id` and `product-id` values does not exist, then the system will create a new `ProductSet` or `Product` for the image. In this case, the `product-display-name` column refers to display_name, the `product-category` column refers to product_category, and the `labels` column refers to product_labels. The `image-id` column is optional but must be unique if provided. If it is empty, the system will automatically assign a unique id to the image. The `product-display-name` column is optional. If it is empty, the system sets the display_name field for the product to a space (" "). You can update the `display_name` later by using the API. If a `Product` with the specified `product-id` already exists, then the system ignores the `product-display-name`, `product-category`, and `labels` columns. The `labels` column (optional) is a line containing a list of comma-separated key-value pairs, in the following format: "key_1=value_1,key_2=value_2,...,key_n=value_n" The `bounding-poly` column (optional) identifies one region of interest from the image in the same manner as `CreateReferenceImage`. If you do not specify the `bounding-poly` column, then the system will try to detect regions of interest automatically. At most one `bounding-poly` column is allowed per line. If the image contains multiple regions of interest, add a line to the CSV file that includes the same product information, and the `bounding-poly` values for each region of interest. The `bounding-poly` column must contain an even number of comma-separated numbers, in the format "p1_x,p1_y,p2_x,p2_y,...,pn_x,pn_y". Use non-negative integers for absolute bounding polygons, and float values in [0, 1] for normalized bounding polygons. The system will resize the image if the image resolution is too large to process (larger than 20MP). */ - outputConfig?: Schema$GoogleCloudVisionV1p6beta1OutputConfig; + csvFileUri?: string; } /** - * Response to an async batch file annotation request. + * The input content for the `ImportProductSets` method. */ - export interface Schema$GoogleCloudVisionV1p6beta1AsyncBatchAnnotateFilesResponse { + export interface Schema$ImportProductSetsInputConfig { /** - * The list of file annotation responses, one for each request in AsyncBatchAnnotateFilesRequest. + * The Google Cloud Storage location for a csv file which preserves a list of ImportProductSetRequests in each line. */ - responses?: Schema$GoogleCloudVisionV1p6beta1AsyncAnnotateFileResponse[]; + gcsSource?: Schema$ImportProductSetsGcsSource; } /** - * Response to an async batch image annotation request. + * Request message for the `ImportProductSets` method. */ - export interface Schema$GoogleCloudVisionV1p6beta1AsyncBatchAnnotateImagesResponse { + export interface Schema$ImportProductSetsRequest { /** - * The output location and metadata from AsyncBatchAnnotateImagesRequest. + * The input content for the list of requests. */ - outputConfig?: Schema$GoogleCloudVisionV1p6beta1OutputConfig; + inputConfig?: Schema$ImportProductSetsInputConfig; } /** - * A list of file annotation responses. + * Response message for the `ImportProductSets` method. This message is returned by the google.longrunning.Operations.GetOperation method in the returned google.longrunning.Operation.response field. */ - export interface Schema$GoogleCloudVisionV1p6beta1BatchAnnotateFilesResponse { + export interface Schema$ImportProductSetsResponse { /** - * The list of file annotation responses, each response corresponding to each AnnotateFileRequest in BatchAnnotateFilesRequest. + * The list of reference_images that are imported successfully. + */ + referenceImages?: Schema$ReferenceImage[]; + /** + * The rpc status for each ImportProductSet request, including both successes and errors. The number of statuses here matches the number of lines in the csv file, and statuses[i] stores the success or failure status of processing the i-th line of the csv, starting from line 0. */ - responses?: Schema$GoogleCloudVisionV1p6beta1AnnotateFileResponse[]; + statuses?: Schema$Status[]; } /** - * Metadata for the batch operations such as the current state. This is included in the `metadata` field of the `Operation` returned by the `GetOperation` call of the `google::longrunning::Operations` service. + * The desired input location and metadata. */ - export interface Schema$GoogleCloudVisionV1p6beta1BatchOperationMetadata { + export interface Schema$InputConfig { /** - * The time when the batch request is finished and google.longrunning.Operation.done is set to true. + * File content, represented as a stream of bytes. Note: As with all `bytes` fields, protobuffers use a pure binary representation, whereas JSON representations use base64. Currently, this field only works for BatchAnnotateFiles requests. It does not work for AsyncBatchAnnotateFiles requests. */ - endTime?: string; + content?: string; /** - * The current state of the batch operation. + * The Google Cloud Storage location to read the input from. */ - state?: string; + gcsSource?: Schema$GcsSource; /** - * The time when the batch request was submitted to the server. + * The type of the file. Currently only "application/pdf", "image/tiff" and "image/gif" are supported. Wildcards are not supported. */ - submitTime?: string; + mimeType?: string; } /** - * Logical element on the page. + * A product label represented as a key-value pair. */ - export interface Schema$GoogleCloudVisionV1p6beta1Block { - /** - * Detected block type (text, image etc) for this block. - */ - blockType?: string; + export interface Schema$KeyValue { /** - * The bounding box for the block. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). + * The key of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. */ - boundingBox?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + key?: string; /** - * Confidence of the OCR results on the block. Range [0, 1]. + * The value of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. */ - confidence?: number; + value?: string; + } + /** + * A face-specific landmark (for example, a face feature). + */ + export interface Schema$Landmark { /** - * List of paragraphs in this block (if this blocks is of type text). + * Face landmark position. */ - paragraphs?: Schema$GoogleCloudVisionV1p6beta1Paragraph[]; + position?: Schema$Position; /** - * Additional information detected for the block. + * Face landmark type. */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + type?: string; } /** - * A bounding polygon for the detected image annotation. + * An object representing a latitude/longitude pair. This is expressed as a pair of doubles representing degrees latitude and degrees longitude. Unless specified otherwise, this must conform to the <a href="http://www.unoosa.org/pdf/icg/2012/template/WGS_84.pdf">WGS84 standard</a>. Values must be within normalized ranges. */ - export interface Schema$GoogleCloudVisionV1p6beta1BoundingPoly { + export interface Schema$LatLng { /** - * The bounding polygon normalized vertices. + * The latitude in degrees. It must be in the range [-90.0, +90.0]. */ - normalizedVertices?: Schema$GoogleCloudVisionV1p6beta1NormalizedVertex[]; + latitude?: number; /** - * The bounding polygon vertices. + * The longitude in degrees. It must be in the range [-180.0, +180.0]. */ - vertices?: Schema$GoogleCloudVisionV1p6beta1Vertex[]; + longitude?: number; } /** - * Color information consists of RGB channels, score, and the fraction of the image that the color occupies in the image. + * Rectangle determined by min and max `LatLng` pairs. */ - export interface Schema$GoogleCloudVisionV1p6beta1ColorInfo { - /** - * RGB components of the color. - */ - color?: Schema$Color; + export interface Schema$LatLongRect { /** - * The fraction of pixels the color occupies in the image. Value in range [0, 1]. + * Max lat/long pair. */ - pixelFraction?: number; + maxLatLng?: Schema$LatLng; /** - * Image-specific score for this color. Value in range [0, 1]. + * Min lat/long pair. */ - score?: number; + minLatLng?: Schema$LatLng; } /** - * Single crop hint that is used to generate a new crop when serving an image. + * The response message for Operations.ListOperations. */ - export interface Schema$GoogleCloudVisionV1p6beta1CropHint { + export interface Schema$ListOperationsResponse { /** - * The bounding polygon for the crop region. The coordinates of the bounding box are in the original image's scale. + * The standard List next-page token. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + nextPageToken?: string; /** - * Confidence of this being a salient region. Range [0, 1]. + * A list of operations that matches the specified filter in the request. */ - confidence?: number; + operations?: Schema$Operation[]; + } + /** + * Response message for the `ListProductSets` method. + */ + export interface Schema$ListProductSetsResponse { /** - * Fraction of importance of this salient region with respect to the original image. + * Token to retrieve the next page of results, or empty if there are no more results in the list. */ - importanceFraction?: number; + nextPageToken?: string; + /** + * List of ProductSets. + */ + productSets?: Schema$ProductSet[]; } /** - * Set of crop hints that are used to generate new crops when serving images. + * Response message for the `ListProductsInProductSet` method. */ - export interface Schema$GoogleCloudVisionV1p6beta1CropHintsAnnotation { + export interface Schema$ListProductsInProductSetResponse { /** - * Crop hint results. + * Token to retrieve the next page of results, or empty if there are no more results in the list. + */ + nextPageToken?: string; + /** + * The list of Products. */ - cropHints?: Schema$GoogleCloudVisionV1p6beta1CropHint[]; + products?: Schema$Product[]; } /** - * Set of dominant colors and their corresponding scores. + * Response message for the `ListProducts` method. */ - export interface Schema$GoogleCloudVisionV1p6beta1DominantColorsAnnotation { + export interface Schema$ListProductsResponse { /** - * RGB color values with their score and pixel fraction. + * Token to retrieve the next page of results, or empty if there are no more results in the list. + */ + nextPageToken?: string; + /** + * List of products. */ - colors?: Schema$GoogleCloudVisionV1p6beta1ColorInfo[]; + products?: Schema$Product[]; } /** - * Set of detected entity features. + * Response message for the `ListReferenceImages` method. */ - export interface Schema$GoogleCloudVisionV1p6beta1EntityAnnotation { + export interface Schema$ListReferenceImagesResponse { /** - * Image region to which this entity belongs. Not produced for `LABEL_DETECTION` features. + * The next_page_token returned from a previous List request, if any. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + nextPageToken?: string; /** - * **Deprecated. Use `score` instead.** The accuracy of the entity detection in an image. For example, for an image in which the "Eiffel Tower" entity is detected, this field represents the confidence that there is a tower in the query image. Range [0, 1]. + * The maximum number of items to return. Default 10, maximum 100. */ - confidence?: number; + pageSize?: number; /** - * Entity textual description, expressed in its `locale` language. + * The list of reference images. */ - description?: string; + referenceImages?: Schema$ReferenceImage[]; + } + /** + * Set of detected objects with bounding boxes. + */ + export interface Schema$LocalizedObjectAnnotation { /** - * The language code for the locale in which the entity textual `description` is expressed. + * Image region to which this object belongs. This must be populated. */ - locale?: string; + boundingPoly?: Schema$BoundingPoly; /** - * The location information for the detected entity. Multiple `LocationInfo` elements can be present because one location may indicate the location of the scene in the image, and another location may indicate the location of the place where the image was taken. Location information is usually present for landmarks. + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */ - locations?: Schema$GoogleCloudVisionV1p6beta1LocationInfo[]; + languageCode?: string; /** - * Opaque entity ID. Some IDs may be available in [Google Knowledge Graph Search API](https://developers.google.com/knowledge-graph/). + * Object ID that should align with EntityAnnotation mid. */ mid?: string; /** - * Some entities may have optional user-supplied `Property` (name/value) fields, such a score or string that qualifies the entity. + * Object name, expressed in its `language_code` language. */ - properties?: Schema$GoogleCloudVisionV1p6beta1Property[]; + name?: string; /** - * Overall score of the result. Range [0, 1]. + * Score of the result. Range [0, 1]. */ score?: number; + } + /** + * Detected entity location information. + */ + export interface Schema$LocationInfo { /** - * The relevancy of the ICA (Image Content Annotation) label to the image. For example, the relevancy of "tower" is likely higher to an image containing the detected "Eiffel Tower" than to an image containing a detected distant towering building, even though the confidence that there is a tower in each image may be the same. Range [0, 1]. + * lat/long location coordinates. */ - topicality?: number; + latLng?: Schema$LatLng; } /** - * A face annotation object contains the results of face detection. + * A vertex represents a 2D point in the image. NOTE: the normalized vertex coordinates are relative to the original image and range from 0 to 1. */ - export interface Schema$GoogleCloudVisionV1p6beta1FaceAnnotation { + export interface Schema$NormalizedVertex { /** - * Anger likelihood. + * X coordinate. */ - angerLikelihood?: string; + x?: number; /** - * Blurred likelihood. + * Y coordinate. */ - blurredLikelihood?: string; + y?: number; + } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$ObjectAnnotation { /** - * The bounding polygon around the face. The coordinates of the bounding box are in the original image's scale. The bounding box is computed to "frame" the face in accordance with human expectations. It is based on the landmarker results. Note that one or more x and/or y coordinates may not be generated in the `BoundingPoly` (the polygon will be unbounded) if only a partial face appears in the image to be annotated. + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + languageCode?: string; /** - * Detection confidence. Range [0, 1]. + * Object ID that should align with EntityAnnotation mid. */ - detectionConfidence?: number; + mid?: string; /** - * The `fd_bounding_poly` bounding polygon is tighter than the `boundingPoly`, and encloses only the skin part of the face. Typically, it is used to eliminate the face from any image analysis that detects the "amount of skin" visible in an image. It is not based on the landmarker results, only on the initial face detection, hence the <code>fd</code> (face detection) prefix. + * Object name, expressed in its `language_code` language. */ - fdBoundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + name?: string; /** - * Headwear likelihood. + * Score of the result. Range [0, 1]. */ - headwearLikelihood?: string; + score?: number; + } + /** + * This resource represents a long-running operation that is the result of a network API call. + */ + export interface Schema$Operation { /** - * Joy likelihood. + * If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available. */ - joyLikelihood?: string; + done?: boolean; /** - * Face landmarking confidence. Range [0, 1]. + * The error result of the operation in case of failure or cancellation. */ - landmarkingConfidence?: number; + error?: Schema$Status; /** - * Detected face landmarks. + * Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any. */ - landmarks?: Schema$GoogleCloudVisionV1p6beta1FaceAnnotationLandmark[]; + metadata?: {[key: string]: any}; /** - * Yaw angle, which indicates the leftward/rightward angle that the face is pointing relative to the vertical plane perpendicular to the image. Range [-180,180]. + * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. */ - panAngle?: number; + name?: string; /** - * Roll angle, which indicates the amount of clockwise/anti-clockwise rotation of the face relative to the image vertical about the axis perpendicular to the face. Range [-180,180]. + * The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. */ - rollAngle?: number; + response?: {[key: string]: any}; + } + /** + * Contains metadata for the BatchAnnotateImages operation. + */ + export interface Schema$OperationMetadata { /** - * Sorrow likelihood. + * The time when the batch request was received. */ - sorrowLikelihood?: string; + createTime?: string; /** - * Surprise likelihood. - */ - surpriseLikelihood?: string; - /** - * Pitch angle, which indicates the upwards/downwards angle that the face is pointing relative to the image's horizontal plane. Range [-180,180]. - */ - tiltAngle?: number; - /** - * Under-exposed likelihood. - */ - underExposedLikelihood?: string; - } - /** - * A face-specific landmark (for example, a face feature). - */ - export interface Schema$GoogleCloudVisionV1p6beta1FaceAnnotationLandmark { - /** - * Face landmark position. - */ - position?: Schema$GoogleCloudVisionV1p6beta1Position; - /** - * Face landmark type. - */ - type?: string; - } - /** - * The Google Cloud Storage location where the output will be written to. - */ - export interface Schema$GoogleCloudVisionV1p6beta1GcsDestination { - /** - * Google Cloud Storage URI prefix where the results will be stored. Results will be in JSON format and preceded by its corresponding input URI prefix. This field can either represent a gcs file prefix or gcs directory. In either case, the uri should be unique because in order to get all of the output files, you will need to do a wildcard gcs search on the uri prefix you provide. Examples: * File Prefix: gs://bucket-name/here/filenameprefix The output files will be created in gs://bucket-name/here/ and the names of the output files will begin with "filenameprefix". * Directory Prefix: gs://bucket-name/some/location/ The output files will be created in gs://bucket-name/some/location/ and the names of the output files could be anything because there was no filename prefix specified. If multiple outputs, each response is still AnnotateFileResponse, each of which contains some subset of the full list of AnnotateImageResponse. Multiple outputs can happen if, for example, the output JSON is too large and overflows into multiple sharded files. - */ - uri?: string; - } - /** - * The Google Cloud Storage location where the input will be read from. - */ - export interface Schema$GoogleCloudVisionV1p6beta1GcsSource { - /** - * Google Cloud Storage URI for the input file. This must only be a Google Cloud Storage object. Wildcards are not currently supported. - */ - uri?: string; - } - /** - * If an image was produced from a file (e.g. a PDF), this message gives information about the source of that image. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ImageAnnotationContext { - /** - * If the file was a PDF or TIFF, this field gives the page number within the file used to produce the image. - */ - pageNumber?: number; - /** - * The URI of the file used to produce the image. - */ - uri?: string; - } - /** - * Stores image properties, such as dominant colors. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ImageProperties { - /** - * If present, dominant colors completed successfully. - */ - dominantColors?: Schema$GoogleCloudVisionV1p6beta1DominantColorsAnnotation; - } - /** - * Stores image quality scores, could be aesthetic quality or technical quality. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ImageQuality {} - /** - * Response message for the `ImportProductSets` method. This message is returned by the google.longrunning.Operations.GetOperation method in the returned google.longrunning.Operation.response field. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ImportProductSetsResponse { - /** - * The list of reference_images that are imported successfully. - */ - referenceImages?: Schema$GoogleCloudVisionV1p6beta1ReferenceImage[]; - /** - * The rpc status for each ImportProductSet request, including both successes and errors. The number of statuses here matches the number of lines in the csv file, and statuses[i] stores the success or failure status of processing the i-th line of the csv, starting from line 0. - */ - statuses?: Schema$Status[]; - } - /** - * The desired input location and metadata. - */ - export interface Schema$GoogleCloudVisionV1p6beta1InputConfig { - /** - * File content, represented as a stream of bytes. Note: As with all `bytes` fields, protobuffers use a pure binary representation, whereas JSON representations use base64. Currently, this field only works for BatchAnnotateFiles requests. It does not work for AsyncBatchAnnotateFiles requests. - */ - content?: string; - /** - * The Google Cloud Storage location to read the input from. - */ - gcsSource?: Schema$GoogleCloudVisionV1p6beta1GcsSource; - /** - * The type of the file. Currently only "application/pdf", "image/tiff" and "image/gif" are supported. Wildcards are not supported. - */ - mimeType?: string; - } - /** - * Set of detected objects with bounding boxes. - */ - export interface Schema$GoogleCloudVisionV1p6beta1LocalizedObjectAnnotation { - /** - * Image region to which this object belongs. This must be populated. - */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; - /** - * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. - */ - languageCode?: string; - /** - * Object ID that should align with EntityAnnotation mid. - */ - mid?: string; - /** - * Object name, expressed in its `language_code` language. - */ - name?: string; - /** - * Score of the result. Range [0, 1]. - */ - score?: number; - } - /** - * Detected entity location information. - */ - export interface Schema$GoogleCloudVisionV1p6beta1LocationInfo { - /** - * lat/long location coordinates. - */ - latLng?: Schema$LatLng; - } - /** - * A vertex represents a 2D point in the image. NOTE: the normalized vertex coordinates are relative to the original image and range from 0 to 1. - */ - export interface Schema$GoogleCloudVisionV1p6beta1NormalizedVertex { - /** - * X coordinate. - */ - x?: number; - /** - * Y coordinate. - */ - y?: number; - } - /** - * Contains metadata for the BatchAnnotateImages operation. - */ - export interface Schema$GoogleCloudVisionV1p6beta1OperationMetadata { - /** - * The time when the batch request was received. - */ - createTime?: string; - /** - * Current state of the batch operation. + * Current state of the batch operation. */ state?: string; /** @@ -5595,7 +5730,7 @@ export namespace vision_v1 { /** * The desired output location and metadata. */ - export interface Schema$GoogleCloudVisionV1p6beta1OutputConfig { + export interface Schema$OutputConfig { /** * The max number of response protos to put into each output JSON file on Google Cloud Storage. The valid range is [1, 100]. If not specified, the default value is 20. For example, for one pdf file with 100 pages, 100 response protos will be generated. If `batch_size` = 20, then 5 json files each containing 20 response protos will be written under the prefix `gcs_destination`.`uri`. Currently, batch_size only applies to GcsDestination, with potential future support for other output configurations. */ @@ -5603,16 +5738,16 @@ export namespace vision_v1 { /** * The Google Cloud Storage location to write the output(s) to. */ - gcsDestination?: Schema$GoogleCloudVisionV1p6beta1GcsDestination; + gcsDestination?: Schema$GcsDestination; } /** * Detected page from OCR. */ - export interface Schema$GoogleCloudVisionV1p6beta1Page { + export interface Schema$Page { /** * List of blocks of text, images etc on this page. */ - blocks?: Schema$GoogleCloudVisionV1p6beta1Block[]; + blocks?: Schema$Block[]; /** * Confidence of the OCR results on the page. Range [0, 1]. */ @@ -5624,7 +5759,7 @@ export namespace vision_v1 { /** * Additional information detected on the page. */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + property?: Schema$TextProperty; /** * Page width. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. */ @@ -5633,11 +5768,11 @@ export namespace vision_v1 { /** * Structural unit of text representing a number of words in certain order. */ - export interface Schema$GoogleCloudVisionV1p6beta1Paragraph { + export interface Schema$Paragraph { /** * The bounding box for the paragraph. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ - boundingBox?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + boundingBox?: Schema$BoundingPoly; /** * Confidence of the OCR results for the paragraph. Range [0, 1]. */ @@ -5645,16 +5780,16 @@ export namespace vision_v1 { /** * Additional information detected for the paragraph. */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + property?: Schema$TextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ - words?: Schema$GoogleCloudVisionV1p6beta1Word[]; + words?: Schema$Word[]; } /** * A 3D position in the image, used primarily for Face detection landmarks. A valid Position must have both x and y coordinates. The position coordinates are in the same scale as the original image. */ - export interface Schema$GoogleCloudVisionV1p6beta1Position { + export interface Schema$Position { /** * X coordinate. */ @@ -5671,7 +5806,7 @@ export namespace vision_v1 { /** * A Product contains ReferenceImages. */ - export interface Schema$GoogleCloudVisionV1p6beta1Product { + export interface Schema$Product { /** * User-provided metadata to be stored with this product. Must be at most 4096 characters long. */ @@ -5689,27 +5824,35 @@ export namespace vision_v1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ - productLabels?: Schema$GoogleCloudVisionV1p6beta1ProductKeyValue[]; + productLabels?: Schema$KeyValue[]; } /** - * A product label represented as a key-value pair. + * Parameters for a product search request. */ - export interface Schema$GoogleCloudVisionV1p6beta1ProductKeyValue { + export interface Schema$ProductSearchParams { /** - * The key of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. + * The bounding polygon around the area of interest in the image. Optional. If it is not specified, system discretion will be applied. */ - key?: string; + boundingPoly?: Schema$BoundingPoly; /** - * The value of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. + * The filtering expression. This can be used to restrict search results based on Product labels. We currently support an AND of OR of key-value expressions, where each expression within an OR must have the same key. An '=' should be used to connect the key and value. For example, "(color = red OR color = blue) AND brand = Google" is acceptable, but "(color = red OR brand = Google)" is not acceptable. "color: red" is not acceptable because it uses a ':' instead of an '='. */ - value?: string; + filter?: string; + /** + * The list of product categories to search in. Currently, we only consider the first category, and either "homegoods-v2", "apparel-v2", or "toys-v2" should be specified. The legacy categories "homegoods", "apparel", and "toys" are still supported but will be deprecated. For new products, please use "homegoods-v2", "apparel-v2", or "toys-v2" for better product search accuracy. It is recommended to migrate existing products to these categories as well. + */ + productCategories?: string[]; + /** + * The resource name of a ProductSet to be searched for similar images. Format is: `projects/PROJECT_ID/locations/LOC_ID/productSets/PRODUCT_SET_ID`. + */ + productSet?: string; } /** * Results for a product search request. */ - export interface Schema$GoogleCloudVisionV1p6beta1ProductSearchResults { + export interface Schema$ProductSearchResults { /** * Timestamp of the index which provided these results. Products added to the product set and products removed from the product set after this time are not reflected in the current results. */ @@ -5717,54 +5860,46 @@ export namespace vision_v1 { /** * List of results grouped by products detected in the query image. Each entry corresponds to one bounding polygon in the query image, and contains the matching products specific to that region. There may be duplicate product matches in the union of all the per-product results. */ - productGroupedResults?: Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsGroupedResult[]; + productGroupedResults?: Schema$GroupedResult[]; /** * List of results, one for each product match. */ - results?: Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsResult[]; + results?: Schema$Result[]; } /** - * Information about the products similar to a single product in a query image. + * A ProductSet contains Products. A ProductSet can contain a maximum of 1 million reference images. If the limit is exceeded, periodic indexing will fail. */ - export interface Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsGroupedResult { + export interface Schema$ProductSet { /** - * The bounding polygon around the product detected in the query image. + * The user-provided name for this ProductSet. Must not be empty. Must be at most 4096 characters long. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + displayName?: string; /** - * List of results, one for each product match. + * Output only. If there was an error with indexing the product set, the field is populated. This field is ignored when creating a ProductSet. */ - results?: Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsResult[]; - } - /** - * Information about a product. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsResult { + indexError?: Schema$Status; /** - * The resource name of the image from the product that is the closest match to the query. + * Output only. The time at which this ProductSet was last indexed. Query results will reflect all updates before this time. If this ProductSet has never been indexed, this timestamp is the default value "1970-01-01T00:00:00Z". This field is ignored when creating a ProductSet. */ - image?: string; + indexTime?: string; /** - * The Product. + * The resource name of the ProductSet. Format is: `projects/PROJECT_ID/locations/LOC_ID/productSets/PRODUCT_SET_ID`. This field is ignored when creating a ProductSet. */ - product?: Schema$GoogleCloudVisionV1p6beta1Product; + name?: string; + } + /** + * Config to control which ProductSet contains the Products to be deleted. + */ + export interface Schema$ProductSetPurgeConfig { /** - * A confidence level on the match, ranging from 0 (no confidence) to 1 (full confidence). + * The ProductSet that contains the Products to delete. If a Product is a member of product_set_id in addition to other ProductSets, the Product will still be deleted. */ - score?: number; + productSetId?: string; } /** * A `Property` consists of a user-supplied name/value pair. */ - export interface Schema$GoogleCloudVisionV1p6beta1Property { - /** - * Value in range [0..1]. Confidence of this property value. - */ - confidence?: number; - /** - * Opaque property value ID. Some IDs may be available in [Google Knowledge Graph Search API](https://developers.google.com/knowledge-graph/). An example property for a blue coat would be: Property { name: 'color' value: 'blue' mid: '/m/01g5v' // For color blue } - */ - mid?: string; + export interface Schema$Property { /** * Name of the property. */ @@ -5779,30 +5914,30 @@ export namespace vision_v1 { value?: string; } /** - * Stores enhanced image bytes. + * Request message for the `PurgeProducts` method. */ - export interface Schema$GoogleCloudVisionV1p6beta1QualityOptimizationResult { + export interface Schema$PurgeProductsRequest { /** - * Optimized image bytes. + * If delete_orphan_products is true, all Products that are not in any ProductSet will be deleted. */ - image?: string; + deleteOrphanProducts?: boolean; /** - * Mime type of the output image. + * The default value is false. Override this value to true to actually perform the purge. */ - mimeType?: string; + force?: boolean; /** - * Required optimization type. + * Specify which ProductSet contains the Products to be deleted. */ - qualityOptimizationType?: string; + productSetPurgeConfig?: Schema$ProductSetPurgeConfig; } /** * A `ReferenceImage` represents a product image and its associated metadata, such as bounding boxes. */ - export interface Schema$GoogleCloudVisionV1p6beta1ReferenceImage { + export interface Schema$ReferenceImage { /** * Bounding polygons around the areas of interest in the reference image. Optional. If this field is empty, the system will try to detect regions of interest. At most 10 bounding polygons will be used. The provided shape is converted into a non-rotated rectangle. Once converted, the small edge of the rectangle must be greater than or equal to 300 pixels. The aspect ratio must be 1:4 or less (i.e. 1:3 is ok; 1:5 is not). */ - boundingPolys?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly[]; + boundingPolys?: Schema$BoundingPoly[]; /** * The resource name of the reference image. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`. This field is ignored when creating a reference image. */ @@ -5812,108 +5947,149 @@ export namespace vision_v1 { */ uri?: string; } + /** + * Request message for the `RemoveProductFromProductSet` method. + */ + export interface Schema$RemoveProductFromProductSetRequest { + /** + * The resource name for the Product to be removed from this ProductSet. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID` + */ + product?: string; + } + /** + * Information about a product. + */ + export interface Schema$Result { + /** + * The resource name of the image from the product that is the closest match to the query. + */ + image?: string; + /** + * The Product. + */ + product?: Schema$Product; + /** + * A confidence level on the match, ranging from 0 (no confidence) to 1 (full confidence). + */ + score?: number; + } /** * Set of features pertaining to the image, computed by computer vision methods over safe-search verticals (for example, adult, spoof, medical, violence). */ - export interface Schema$GoogleCloudVisionV1p6beta1SafeSearchAnnotation { + export interface Schema$SafeSearchAnnotation { /** * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. */ adult?: string; + /** + * Confidence of adult_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + adultConfidence?: number; /** * Likelihood that this is a medical image. */ medical?: string; + /** + * Confidence of medical_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + medicalConfidence?: number; + /** + * Confidence of nsfw_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + nsfwConfidence?: number; /** * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. */ racy?: string; + /** + * Confidence of racy_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + racyConfidence?: number; /** * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. */ spoof?: string; + /** + * Confidence of spoof_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + spoofConfidence?: number; /** * Likelihood that this image contains violent content. */ violence?: string; + /** + * Confidence of violence_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + violenceConfidence?: number; } /** - * A single symbol representation. + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). */ - export interface Schema$GoogleCloudVisionV1p6beta1Symbol { + export interface Schema$Status { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The status code, which should be an enum value of google.rpc.Code. */ - boundingBox?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; - /** - * Confidence of the OCR results for the symbol. Range [0, 1]. - */ - confidence?: number; + code?: number; /** - * Additional information detected for the symbol. + * A list of messages that carry the error details. There is a common set of message types for APIs to use. */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + details?: Array<{[key: string]: any}>; /** - * The actual UTF-8 representation of the symbol. + * A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. */ - text?: string; + message?: string; } /** - * TextAnnotation contains a structured representation of OCR extracted text. The hierarchy of an OCR extracted text structure is like this: TextAnnotation -> Page -> Block -> Paragraph -> Word -> Symbol Each structural component, starting from Page, may further have their own properties. Properties describe detected languages, breaks etc.. Please refer to the TextAnnotation.TextProperty message definition below for more detail. + * A single symbol representation. */ - export interface Schema$GoogleCloudVisionV1p6beta1TextAnnotation { + export interface Schema$Symbol { /** - * List of pages detected by OCR. + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ - pages?: Schema$GoogleCloudVisionV1p6beta1Page[]; + boundingBox?: Schema$BoundingPoly; /** - * UTF-8 text detected on the pages. + * Confidence of the OCR results for the symbol. Range [0, 1]. */ - text?: string; - } - /** - * Detected start or end of a structural component. - */ - export interface Schema$GoogleCloudVisionV1p6beta1TextAnnotationDetectedBreak { + confidence?: number; /** - * True if break prepends the element. + * Additional information detected for the symbol. */ - isPrefix?: boolean; + property?: Schema$TextProperty; /** - * Detected break type. + * The actual UTF-8 representation of the symbol. */ - type?: string; + text?: string; } /** - * Detected language for a structural component. + * TextAnnotation contains a structured representation of OCR extracted text. The hierarchy of an OCR extracted text structure is like this: TextAnnotation -> Page -> Block -> Paragraph -> Word -> Symbol Each structural component, starting from Page, may further have their own properties. Properties describe detected languages, breaks etc.. Please refer to the TextAnnotation.TextProperty message definition below for more detail. */ - export interface Schema$GoogleCloudVisionV1p6beta1TextAnnotationDetectedLanguage { + export interface Schema$TextAnnotation { /** - * Confidence of detected language. Range [0, 1]. + * List of pages detected by OCR. */ - confidence?: number; + pages?: Schema$Page[]; /** - * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + * UTF-8 text detected on the pages. */ - languageCode?: string; + text?: string; } /** * Additional information detected on the structural component. */ - export interface Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty { + export interface Schema$TextProperty { /** * Detected start or end of a text segment. */ - detectedBreak?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationDetectedBreak; + detectedBreak?: Schema$DetectedBreak; /** * A list of detected languages together with confidence. */ - detectedLanguages?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationDetectedLanguage[]; + detectedLanguages?: Schema$DetectedLanguage[]; } /** * A vertex represents a 2D point in the image. NOTE: the vertex coordinates are in the same scale as the original image. */ - export interface Schema$GoogleCloudVisionV1p6beta1Vertex { + export interface Schema$Vertex { /** * X coordinate. */ @@ -5926,36 +6102,45 @@ export namespace vision_v1 { /** * Relevant information for the image from the Internet. */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetection { + export interface Schema$WebDetection { /** * The service's best guess as to the topic of the request image. Inferred from similar images on the open web. */ - bestGuessLabels?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebLabel[]; + bestGuessLabels?: Schema$WebLabel[]; /** * Fully matching images from the Internet. Can include resized copies of the query image. */ - fullMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; + fullMatchingImages?: Schema$WebImage[]; /** * Web pages containing the matching images from the Internet. */ - pagesWithMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebPage[]; + pagesWithMatchingImages?: Schema$WebPage[]; /** * Partial matching images from the Internet. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. */ - partialMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; + partialMatchingImages?: Schema$WebImage[]; /** * The visually similar image results. */ - visuallySimilarImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; + visuallySimilarImages?: Schema$WebImage[]; /** * Deduced entities from similar images on the Internet. */ - webEntities?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebEntity[]; + webEntities?: Schema$WebEntity[]; + } + /** + * Parameters for web detection request. + */ + export interface Schema$WebDetectionParams { + /** + * Whether to include results derived from the geo information in the image. + */ + includeGeoResults?: boolean; } /** * Entity deduced from similar images on the Internet. */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetectionWebEntity { + export interface Schema$WebEntity { /** * Canonical description of the entity, in English. */ @@ -5972,7 +6157,7 @@ export namespace vision_v1 { /** * Metadata for online images. */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage { + export interface Schema$WebImage { /** * (Deprecated) Overall relevancy score for the image. */ @@ -5985,7 +6170,7 @@ export namespace vision_v1 { /** * Label to provide extra metadata for the web detection. */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetectionWebLabel { + export interface Schema$WebLabel { /** * Label for extra metadata. */ @@ -5998,11 +6183,11 @@ export namespace vision_v1 { /** * Metadata for web pages. */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetectionWebPage { + export interface Schema$WebPage { /** * Fully matching images on the page. Can include resized copies of the query image. */ - fullMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; + fullMatchingImages?: Schema$WebImage[]; /** * Title for the web page, may contain HTML markups. */ @@ -6010,7 +6195,7 @@ export namespace vision_v1 { /** * Partial matching images on the page. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. */ - partialMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; + partialMatchingImages?: Schema$WebImage[]; /** * (Deprecated) Overall relevancy score for the web page. */ @@ -6023,11 +6208,11 @@ export namespace vision_v1 { /** * A word representation. */ - export interface Schema$GoogleCloudVisionV1p6beta1Word { + export interface Schema$Word { /** * The bounding box for the word. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ - boundingBox?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + boundingBox?: Schema$BoundingPoly; /** * Confidence of the OCR results for the word. Range [0, 1]. */ @@ -6035,824 +6220,952 @@ export namespace vision_v1 { /** * Additional information detected for the word. */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + property?: Schema$TextProperty; /** * List of symbols in the word. The order of the symbols follows the natural reading order. */ - symbols?: Schema$GoogleCloudVisionV1p6beta1Symbol[]; - } - /** - * Information about the products similar to a single product in a query image. - */ - export interface Schema$GroupedResult { - /** - * The bounding polygon around the product detected in the query image. - */ - boundingPoly?: Schema$BoundingPoly; - /** - * List of results, one for each product match. - */ - results?: Schema$Result[]; - } - /** - * Client image to perform Google Cloud Vision API tasks over. - */ - export interface Schema$Image { - /** - * Image content, represented as a stream of bytes. Note: As with all `bytes` fields, protobuffers use a pure binary representation, whereas JSON representations use base64. - */ - content?: string; - /** - * Google Cloud Storage image location, or publicly-accessible image URL. If both `content` and `source` are provided for an image, `content` takes precedence and is used to perform the image annotation request. - */ - source?: Schema$ImageSource; - } - /** - * If an image was produced from a file (e.g. a PDF), this message gives information about the source of that image. - */ - export interface Schema$ImageAnnotationContext { - /** - * If the file was a PDF or TIFF, this field gives the page number within the file used to produce the image. - */ - pageNumber?: number; - /** - * The URI of the file used to produce the image. - */ - uri?: string; + symbols?: Schema$Symbol[]; } - /** - * Image context and/or feature-specific parameters. - */ - export interface Schema$ImageContext { - /** - * Parameters for crop hints annotation request. - */ - cropHintsParams?: Schema$CropHintsParams; - /** - * List of languages to use for TEXT_DETECTION. In most cases, an empty value yields the best results since it enables automatic language detection. For languages based on the Latin alphabet, setting `language_hints` is not needed. In rare cases, when the language of the text in the image is known, setting a hint will help get better results (although it will be a significant hindrance if the hint is wrong). Text detection returns an error if one or more of the specified languages is not one of the [supported languages](/vision/docs/languages). - */ - languageHints?: string[]; + + export class Resource$Files { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + /** - * Not used. + * vision.files.annotate + * @desc Service that performs image detection and annotation for a batch of files. Now only "application/pdf", "image/tiff" and "image/gif" are supported. This service will extract at most 5 (customers can specify which 5 in AnnotateFileRequest.pages) frames (gif) or pages (pdf or tiff) from each file provided and perform detection and annotation for each image extracted. + * @example + * * // BEFORE RUNNING: + * // --------------- + * // 1. If not already done, enable the Cloud Vision API + * // and check the quota for your project at + * // https://console.developers.google.com/apis/api/vision + * // 2. This sample uses Application Default Credentials for authentication. + * // If not already done, install the gcloud CLI from + * // https://cloud.google.com/sdk and run + * // `gcloud beta auth application-default login`. + * // For more information, see + * // https://developers.google.com/identity/protocols/application-default-credentials + * // 3. Install the Node.js client library by running + * // `npm install googleapis --save` + * + * const {google} = require('googleapis'); + * var vision = google.vision('v1'); + * + * authorize(function(authClient) { + * var request = { + * resource: { + * // TODO: Add desired properties to the request body. + * }, + * + * auth: authClient, + * }; + * + * vision.files.annotate(request, function(err, response) { + * if (err) { + * console.error(err); + * return; + * } + * + * // TODO: Change code below to process the `response` object: + * console.log(JSON.stringify(response, null, 2)); + * }); + * }); + * + * function authorize(callback) { + * google.auth.getClient({ + * scopes: ['https://www.googleapis.com/auth/cloud-platform'] + * }).then(client => { + * callback(client); + * }).catch(err => { + * console.error('authentication failed: ', err); + * }); + * } + * @alias vision.files.annotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().BatchAnnotateFilesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - latLongRect?: Schema$LatLongRect; + annotate( + params?: Params$Resource$Files$Annotate, + options?: MethodOptions + ): GaxiosPromise; + annotate( + params: Params$Resource$Files$Annotate, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + annotate( + params: Params$Resource$Files$Annotate, + callback: BodyResponseCallback + ): void; + annotate( + callback: BodyResponseCallback + ): void; + annotate( + paramsOrCallback?: + | Params$Resource$Files$Annotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Files$Annotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Files$Annotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/files:annotate').replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest(parameters); + } + } + /** - * Parameters for product search. - */ - productSearchParams?: Schema$ProductSearchParams; - /** - * Parameters for web detection. - */ - webDetectionParams?: Schema$WebDetectionParams; - } - /** - * Stores image properties, such as dominant colors. - */ - export interface Schema$ImageProperties { - /** - * If present, dominant colors completed successfully. + * vision.files.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of generic files, such as PDF files, which may contain multiple pages and multiple images per page. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results). + * @example + * * // BEFORE RUNNING: + * // --------------- + * // 1. If not already done, enable the Cloud Vision API + * // and check the quota for your project at + * // https://console.developers.google.com/apis/api/vision + * // 2. This sample uses Application Default Credentials for authentication. + * // If not already done, install the gcloud CLI from + * // https://cloud.google.com/sdk and run + * // `gcloud beta auth application-default login`. + * // For more information, see + * // https://developers.google.com/identity/protocols/application-default-credentials + * // 3. Install the Node.js client library by running + * // `npm install googleapis --save` + * + * const {google} = require('googleapis'); + * var vision = google.vision('v1'); + * + * authorize(function(authClient) { + * var request = { + * resource: { + * // TODO: Add desired properties to the request body. + * }, + * + * auth: authClient, + * }; + * + * vision.files.asyncBatchAnnotate(request, function(err, response) { + * if (err) { + * console.error(err); + * return; + * } + * + * // TODO: Change code below to process the `response` object: + * console.log(JSON.stringify(response, null, 2)); + * }); + * }); + * + * function authorize(callback) { + * google.auth.getClient({ + * scopes: ['https://www.googleapis.com/auth/cloud-platform'] + * }).then(client => { + * callback(client); + * }).catch(err => { + * console.error('authentication failed: ', err); + * }); + * } + * @alias vision.files.asyncBatchAnnotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().AsyncBatchAnnotateFilesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - dominantColors?: Schema$DominantColorsAnnotation; + asyncBatchAnnotate( + params?: Params$Resource$Files$Asyncbatchannotate, + options?: MethodOptions + ): GaxiosPromise; + asyncBatchAnnotate( + params: Params$Resource$Files$Asyncbatchannotate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate( + params: Params$Resource$Files$Asyncbatchannotate, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( + paramsOrCallback?: + | Params$Resource$Files$Asyncbatchannotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Files$Asyncbatchannotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Files$Asyncbatchannotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/files:asyncBatchAnnotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } - /** - * External image source (Google Cloud Storage or web URL image location). - */ - export interface Schema$ImageSource { - /** - * **Use `image_uri` instead.** The Google Cloud Storage URI of the form `gs://bucket_name/object_name`. Object versioning is not supported. See [Google Cloud Storage Request URIs](https://cloud.google.com/storage/docs/reference-uris) for more info. - */ - gcsImageUri?: string; + + export interface Params$Resource$Files$Annotate extends StandardParameters { /** - * The URI of the source image. Can be either: 1. A Google Cloud Storage URI of the form `gs://bucket_name/object_name`. Object versioning is not supported. See [Google Cloud Storage Request URIs](https://cloud.google.com/storage/docs/reference-uris) for more info. 2. A publicly-accessible image HTTP/HTTPS URL. When fetching images from HTTP/HTTPS URLs, Google cannot guarantee that the request will be completed. Your request may fail if the specified host denies the request (e.g. due to request throttling or DOS prevention), or if Google throttles requests to the site for abuse prevention. You should not depend on externally-hosted images for production applications. When both `gcs_image_uri` and `image_uri` are specified, `image_uri` takes precedence. + * Auth client or API Key for the request */ - imageUri?: string; - } - /** - * The Google Cloud Storage location for a csv file which preserves a list of ImportProductSetRequests in each line. - */ - export interface Schema$ImportProductSetsGcsSource { + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * The Google Cloud Storage URI of the input csv file. The URI must start with `gs://`. The format of the input csv file should be one image per line. In each line, there are 8 columns. 1. image-uri 2. image-id 3. product-set-id 4. product-id 5. product-category 6. product-display-name 7. labels 8. bounding-poly The `image-uri`, `product-set-id`, `product-id`, and `product-category` columns are required. All other columns are optional. If the `ProductSet` or `Product` specified by the `product-set-id` and `product-id` values does not exist, then the system will create a new `ProductSet` or `Product` for the image. In this case, the `product-display-name` column refers to display_name, the `product-category` column refers to product_category, and the `labels` column refers to product_labels. The `image-id` column is optional but must be unique if provided. If it is empty, the system will automatically assign a unique id to the image. The `product-display-name` column is optional. If it is empty, the system sets the display_name field for the product to a space (" "). You can update the `display_name` later by using the API. If a `Product` with the specified `product-id` already exists, then the system ignores the `product-display-name`, `product-category`, and `labels` columns. The `labels` column (optional) is a line containing a list of comma-separated key-value pairs, in the following format: "key_1=value_1,key_2=value_2,...,key_n=value_n" The `bounding-poly` column (optional) identifies one region of interest from the image in the same manner as `CreateReferenceImage`. If you do not specify the `bounding-poly` column, then the system will try to detect regions of interest automatically. At most one `bounding-poly` column is allowed per line. If the image contains multiple regions of interest, add a line to the CSV file that includes the same product information, and the `bounding-poly` values for each region of interest. The `bounding-poly` column must contain an even number of comma-separated numbers, in the format "p1_x,p1_y,p2_x,p2_y,...,pn_x,pn_y". Use non-negative integers for absolute bounding polygons, and float values in [0, 1] for normalized bounding polygons. The system will resize the image if the image resolution is too large to process (larger than 20MP). + * Request body metadata */ - csvFileUri?: string; + requestBody?: Schema$BatchAnnotateFilesRequest; } - /** - * The input content for the `ImportProductSets` method. - */ - export interface Schema$ImportProductSetsInputConfig { + export interface Params$Resource$Files$Asyncbatchannotate + extends StandardParameters { /** - * The Google Cloud Storage location for a csv file which preserves a list of ImportProductSetRequests in each line. + * Auth client or API Key for the request */ - gcsSource?: Schema$ImportProductSetsGcsSource; - } - /** - * Request message for the `ImportProductSets` method. - */ - export interface Schema$ImportProductSetsRequest { + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * The input content for the list of requests. + * Request body metadata */ - inputConfig?: Schema$ImportProductSetsInputConfig; + requestBody?: Schema$AsyncBatchAnnotateFilesRequest; } - /** - * Response message for the `ImportProductSets` method. This message is returned by the google.longrunning.Operations.GetOperation method in the returned google.longrunning.Operation.response field. - */ - export interface Schema$ImportProductSetsResponse { - /** - * The list of reference_images that are imported successfully. - */ - referenceImages?: Schema$ReferenceImage[]; + + export class Resource$Images { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + /** - * The rpc status for each ImportProductSet request, including both successes and errors. The number of statuses here matches the number of lines in the csv file, and statuses[i] stores the success or failure status of processing the i-th line of the csv, starting from line 0. + * vision.images.annotate + * @desc Run image detection and annotation for a batch of images. + * @example + * * // BEFORE RUNNING: + * // --------------- + * // 1. If not already done, enable the Cloud Vision API + * // and check the quota for your project at + * // https://console.developers.google.com/apis/api/vision + * // 2. This sample uses Application Default Credentials for authentication. + * // If not already done, install the gcloud CLI from + * // https://cloud.google.com/sdk and run + * // `gcloud beta auth application-default login`. + * // For more information, see + * // https://developers.google.com/identity/protocols/application-default-credentials + * // 3. Install the Node.js client library by running + * // `npm install googleapis --save` + * + * const {google} = require('googleapis'); + * var vision = google.vision('v1'); + * + * authorize(function(authClient) { + * var request = { + * resource: { + * // TODO: Add desired properties to the request body. + * }, + * + * auth: authClient, + * }; + * + * vision.images.annotate(request, function(err, response) { + * if (err) { + * console.error(err); + * return; + * } + * + * // TODO: Change code below to process the `response` object: + * console.log(JSON.stringify(response, null, 2)); + * }); + * }); + * + * function authorize(callback) { + * google.auth.getClient({ + * scopes: ['https://www.googleapis.com/auth/cloud-platform'] + * }).then(client => { + * callback(client); + * }).catch(err => { + * console.error('authentication failed: ', err); + * }); + * } + * @alias vision.images.annotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().BatchAnnotateImagesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - statuses?: Schema$Status[]; - } - /** - * The desired input location and metadata. - */ - export interface Schema$InputConfig { - /** - * File content, represented as a stream of bytes. Note: As with all `bytes` fields, protobuffers use a pure binary representation, whereas JSON representations use base64. Currently, this field only works for BatchAnnotateFiles requests. It does not work for AsyncBatchAnnotateFiles requests. - */ - content?: string; - /** - * The Google Cloud Storage location to read the input from. - */ - gcsSource?: Schema$GcsSource; + annotate( + params?: Params$Resource$Images$Annotate, + options?: MethodOptions + ): GaxiosPromise; + annotate( + params: Params$Resource$Images$Annotate, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + annotate( + params: Params$Resource$Images$Annotate, + callback: BodyResponseCallback + ): void; + annotate( + callback: BodyResponseCallback + ): void; + annotate( + paramsOrCallback?: + | Params$Resource$Images$Annotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Images$Annotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Images$Annotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/images:annotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest(parameters); + } + } + /** - * The type of the file. Currently only "application/pdf", "image/tiff" and "image/gif" are supported. Wildcards are not supported. + * vision.images.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of images. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateImagesResponse` (results). This service will write image annotation outputs to json files in customer GCS bucket, each json file containing BatchAnnotateImagesResponse proto. + * @example + * * // BEFORE RUNNING: + * // --------------- + * // 1. If not already done, enable the Cloud Vision API + * // and check the quota for your project at + * // https://console.developers.google.com/apis/api/vision + * // 2. This sample uses Application Default Credentials for authentication. + * // If not already done, install the gcloud CLI from + * // https://cloud.google.com/sdk and run + * // `gcloud beta auth application-default login`. + * // For more information, see + * // https://developers.google.com/identity/protocols/application-default-credentials + * // 3. Install the Node.js client library by running + * // `npm install googleapis --save` + * + * const {google} = require('googleapis'); + * var vision = google.vision('v1'); + * + * authorize(function(authClient) { + * var request = { + * resource: { + * // TODO: Add desired properties to the request body. + * }, + * + * auth: authClient, + * }; + * + * vision.images.asyncBatchAnnotate(request, function(err, response) { + * if (err) { + * console.error(err); + * return; + * } + * + * // TODO: Change code below to process the `response` object: + * console.log(JSON.stringify(response, null, 2)); + * }); + * }); + * + * function authorize(callback) { + * google.auth.getClient({ + * scopes: ['https://www.googleapis.com/auth/cloud-platform'] + * }).then(client => { + * callback(client); + * }).catch(err => { + * console.error('authentication failed: ', err); + * }); + * } + * @alias vision.images.asyncBatchAnnotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().AsyncBatchAnnotateImagesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - mimeType?: string; + asyncBatchAnnotate( + params?: Params$Resource$Images$Asyncbatchannotate, + options?: MethodOptions + ): GaxiosPromise; + asyncBatchAnnotate( + params: Params$Resource$Images$Asyncbatchannotate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate( + params: Params$Resource$Images$Asyncbatchannotate, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( + paramsOrCallback?: + | Params$Resource$Images$Asyncbatchannotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Images$Asyncbatchannotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Images$Asyncbatchannotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/images:asyncBatchAnnotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } - /** - * A product label represented as a key-value pair. - */ - export interface Schema$KeyValue { + + export interface Params$Resource$Images$Annotate extends StandardParameters { /** - * The key of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. + * Auth client or API Key for the request */ - key?: string; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * The value of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. + * Request body metadata */ - value?: string; + requestBody?: Schema$BatchAnnotateImagesRequest; } - /** - * A face-specific landmark (for example, a face feature). - */ - export interface Schema$Landmark { + export interface Params$Resource$Images$Asyncbatchannotate + extends StandardParameters { /** - * Face landmark position. + * Auth client or API Key for the request */ - position?: Schema$Position; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * Face landmark type. + * Request body metadata */ - type?: string; + requestBody?: Schema$AsyncBatchAnnotateImagesRequest; } - /** - * An object representing a latitude/longitude pair. This is expressed as a pair of doubles representing degrees latitude and degrees longitude. Unless specified otherwise, this must conform to the <a href="http://www.unoosa.org/pdf/icg/2012/template/WGS_84.pdf">WGS84 standard</a>. Values must be within normalized ranges. - */ - export interface Schema$LatLng { - /** - * The latitude in degrees. It must be in the range [-90.0, +90.0]. - */ - latitude?: number; - /** - * The longitude in degrees. It must be in the range [-180.0, +180.0]. - */ - longitude?: number; + + export class Resource$Locations { + context: APIRequestContext; + operations: Resource$Locations$Operations; + constructor(context: APIRequestContext) { + this.context = context; + this.operations = new Resource$Locations$Operations(this.context); + } } - /** - * Rectangle determined by min and max `LatLng` pairs. - */ - export interface Schema$LatLongRect { - /** - * Max lat/long pair. - */ - maxLatLng?: Schema$LatLng; - /** - * Min lat/long pair. - */ - minLatLng?: Schema$LatLng; - } - /** - * The response message for Operations.ListOperations. - */ - export interface Schema$ListOperationsResponse { - /** - * The standard List next-page token. - */ - nextPageToken?: string; - /** - * A list of operations that matches the specified filter in the request. - */ - operations?: Schema$Operation[]; - } - /** - * Response message for the `ListProductSets` method. - */ - export interface Schema$ListProductSetsResponse { - /** - * Token to retrieve the next page of results, or empty if there are no more results in the list. - */ - nextPageToken?: string; - /** - * List of ProductSets. - */ - productSets?: Schema$ProductSet[]; - } - /** - * Response message for the `ListProductsInProductSet` method. - */ - export interface Schema$ListProductsInProductSetResponse { - /** - * Token to retrieve the next page of results, or empty if there are no more results in the list. - */ - nextPageToken?: string; - /** - * The list of Products. - */ - products?: Schema$Product[]; - } - /** - * Response message for the `ListProducts` method. - */ - export interface Schema$ListProductsResponse { - /** - * Token to retrieve the next page of results, or empty if there are no more results in the list. - */ - nextPageToken?: string; - /** - * List of products. - */ - products?: Schema$Product[]; - } - /** - * Response message for the `ListReferenceImages` method. - */ - export interface Schema$ListReferenceImagesResponse { - /** - * The next_page_token returned from a previous List request, if any. - */ - nextPageToken?: string; - /** - * The maximum number of items to return. Default 10, maximum 100. - */ - pageSize?: number; - /** - * The list of reference images. - */ - referenceImages?: Schema$ReferenceImage[]; - } - /** - * Set of detected objects with bounding boxes. - */ - export interface Schema$LocalizedObjectAnnotation { - /** - * Image region to which this object belongs. This must be populated. - */ - boundingPoly?: Schema$BoundingPoly; - /** - * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. - */ - languageCode?: string; - /** - * Object ID that should align with EntityAnnotation mid. - */ - mid?: string; - /** - * Object name, expressed in its `language_code` language. - */ - name?: string; - /** - * Score of the result. Range [0, 1]. - */ - score?: number; - } - /** - * Detected entity location information. - */ - export interface Schema$LocationInfo { - /** - * lat/long location coordinates. - */ - latLng?: Schema$LatLng; - } - /** - * A vertex represents a 2D point in the image. NOTE: the normalized vertex coordinates are relative to the original image and range from 0 to 1. - */ - export interface Schema$NormalizedVertex { - /** - * X coordinate. - */ - x?: number; - /** - * Y coordinate. - */ - y?: number; - } - /** - * This resource represents a long-running operation that is the result of a network API call. - */ - export interface Schema$Operation { - /** - * If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available. - */ - done?: boolean; - /** - * The error result of the operation in case of failure or cancellation. - */ - error?: Schema$Status; - /** - * Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any. - */ - metadata?: {[key: string]: any}; - /** - * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. - */ - name?: string; - /** - * The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. - */ - response?: {[key: string]: any}; - } - /** - * Contains metadata for the BatchAnnotateImages operation. - */ - export interface Schema$OperationMetadata { - /** - * The time when the batch request was received. - */ - createTime?: string; - /** - * Current state of the batch operation. - */ - state?: string; - /** - * The time when the operation result was last updated. - */ - updateTime?: string; - } - /** - * The desired output location and metadata. - */ - export interface Schema$OutputConfig { - /** - * The max number of response protos to put into each output JSON file on Google Cloud Storage. The valid range is [1, 100]. If not specified, the default value is 20. For example, for one pdf file with 100 pages, 100 response protos will be generated. If `batch_size` = 20, then 5 json files each containing 20 response protos will be written under the prefix `gcs_destination`.`uri`. Currently, batch_size only applies to GcsDestination, with potential future support for other output configurations. - */ - batchSize?: number; - /** - * The Google Cloud Storage location to write the output(s) to. - */ - gcsDestination?: Schema$GcsDestination; - } - /** - * Detected page from OCR. - */ - export interface Schema$Page { - /** - * List of blocks of text, images etc on this page. - */ - blocks?: Schema$Block[]; - /** - * Confidence of the OCR results on the page. Range [0, 1]. - */ - confidence?: number; - /** - * Page height. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. - */ - height?: number; - /** - * Additional information detected on the page. - */ - property?: Schema$TextProperty; - /** - * Page width. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. - */ - width?: number; - } - /** - * Structural unit of text representing a number of words in certain order. - */ - export interface Schema$Paragraph { - /** - * The bounding box for the paragraph. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$BoundingPoly; - /** - * Confidence of the OCR results for the paragraph. Range [0, 1]. - */ - confidence?: number; - /** - * Additional information detected for the paragraph. - */ - property?: Schema$TextProperty; - /** - * List of words in this paragraph. - */ - words?: Schema$Word[]; - } - /** - * A 3D position in the image, used primarily for Face detection landmarks. A valid Position must have both x and y coordinates. The position coordinates are in the same scale as the original image. - */ - export interface Schema$Position { - /** - * X coordinate. - */ - x?: number; - /** - * Y coordinate. - */ - y?: number; - /** - * Z coordinate (or depth). - */ - z?: number; - } - /** - * A Product contains ReferenceImages. - */ - export interface Schema$Product { - /** - * User-provided metadata to be stored with this product. Must be at most 4096 characters long. - */ - description?: string; - /** - * The user-provided name for this Product. Must not be empty. Must be at most 4096 characters long. - */ - displayName?: string; - /** - * The resource name of the product. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`. This field is ignored when creating a product. - */ - name?: string; - /** - * The category for the product identified by the reference image. This should be either "homegoods-v2", "apparel-v2", or "toys-v2". The legacy categories "homegoods", "apparel", and "toys" are still supported, but these should not be used for new products. This field is immutable. - */ - productCategory?: string; - /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. - */ - productLabels?: Schema$KeyValue[]; - } - /** - * Parameters for a product search request. - */ - export interface Schema$ProductSearchParams { - /** - * The bounding polygon around the area of interest in the image. Optional. If it is not specified, system discretion will be applied. - */ - boundingPoly?: Schema$BoundingPoly; - /** - * The filtering expression. This can be used to restrict search results based on Product labels. We currently support an AND of OR of key-value expressions, where each expression within an OR must have the same key. An '=' should be used to connect the key and value. For example, "(color = red OR color = blue) AND brand = Google" is acceptable, but "(color = red OR brand = Google)" is not acceptable. "color: red" is not acceptable because it uses a ':' instead of an '='. - */ - filter?: string; - /** - * The list of product categories to search in. Currently, we only consider the first category, and either "homegoods-v2", "apparel-v2", or "toys-v2" should be specified. The legacy categories "homegoods", "apparel", and "toys" are still supported but will be deprecated. For new products, please use "homegoods-v2", "apparel-v2", or "toys-v2" for better product search accuracy. It is recommended to migrate existing products to these categories as well. - */ - productCategories?: string[]; - /** - * The resource name of a ProductSet to be searched for similar images. Format is: `projects/PROJECT_ID/locations/LOC_ID/productSets/PRODUCT_SET_ID`. - */ - productSet?: string; - } - /** - * Results for a product search request. - */ - export interface Schema$ProductSearchResults { - /** - * Timestamp of the index which provided these results. Products added to the product set and products removed from the product set after this time are not reflected in the current results. - */ - indexTime?: string; - /** - * List of results grouped by products detected in the query image. Each entry corresponds to one bounding polygon in the query image, and contains the matching products specific to that region. There may be duplicate product matches in the union of all the per-product results. - */ - productGroupedResults?: Schema$GroupedResult[]; - /** - * List of results, one for each product match. - */ - results?: Schema$Result[]; - } - /** - * A ProductSet contains Products. A ProductSet can contain a maximum of 1 million reference images. If the limit is exceeded, periodic indexing will fail. - */ - export interface Schema$ProductSet { - /** - * The user-provided name for this ProductSet. Must not be empty. Must be at most 4096 characters long. - */ - displayName?: string; - /** - * Output only. If there was an error with indexing the product set, the field is populated. This field is ignored when creating a ProductSet. - */ - indexError?: Schema$Status; - /** - * Output only. The time at which this ProductSet was last indexed. Query results will reflect all updates before this time. If this ProductSet has never been indexed, this timestamp is the default value "1970-01-01T00:00:00Z". This field is ignored when creating a ProductSet. - */ - indexTime?: string; - /** - * The resource name of the ProductSet. Format is: `projects/PROJECT_ID/locations/LOC_ID/productSets/PRODUCT_SET_ID`. This field is ignored when creating a ProductSet. - */ - name?: string; - } - /** - * A `Property` consists of a user-supplied name/value pair. - */ - export interface Schema$Property { - /** - * Name of the property. - */ - name?: string; - /** - * Value of numeric properties. - */ - uint64Value?: string; - /** - * Value of the property. - */ - value?: string; - } - /** - * A `ReferenceImage` represents a product image and its associated metadata, such as bounding boxes. - */ - export interface Schema$ReferenceImage { - /** - * Bounding polygons around the areas of interest in the reference image. Optional. If this field is empty, the system will try to detect regions of interest. At most 10 bounding polygons will be used. The provided shape is converted into a non-rotated rectangle. Once converted, the small edge of the rectangle must be greater than or equal to 300 pixels. The aspect ratio must be 1:4 or less (i.e. 1:3 is ok; 1:5 is not). - */ - boundingPolys?: Schema$BoundingPoly[]; - /** - * The resource name of the reference image. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`. This field is ignored when creating a reference image. - */ - name?: string; - /** - * The Google Cloud Storage URI of the reference image. The URI must start with `gs://`. Required. - */ - uri?: string; - } - /** - * Request message for the `RemoveProductFromProductSet` method. - */ - export interface Schema$RemoveProductFromProductSetRequest { - /** - * The resource name for the Product to be removed from this ProductSet. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID` - */ - product?: string; - } - /** - * Information about a product. - */ - export interface Schema$Result { - /** - * The resource name of the image from the product that is the closest match to the query. - */ - image?: string; - /** - * The Product. - */ - product?: Schema$Product; - /** - * A confidence level on the match, ranging from 0 (no confidence) to 1 (full confidence). - */ - score?: number; - } - /** - * Set of features pertaining to the image, computed by computer vision methods over safe-search verticals (for example, adult, spoof, medical, violence). - */ - export interface Schema$SafeSearchAnnotation { - /** - * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. - */ - adult?: string; - /** - * Likelihood that this is a medical image. - */ - medical?: string; - /** - * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. - */ - racy?: string; - /** - * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. - */ - spoof?: string; - /** - * Likelihood that this image contains violent content. - */ - violence?: string; - } - /** - * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). - */ - export interface Schema$Status { - /** - * The status code, which should be an enum value of google.rpc.Code. - */ - code?: number; - /** - * A list of messages that carry the error details. There is a common set of message types for APIs to use. - */ - details?: Array<{[key: string]: any}>; - /** - * A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. - */ - message?: string; - } - /** - * A single symbol representation. - */ - export interface Schema$Symbol { - /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$BoundingPoly; - /** - * Confidence of the OCR results for the symbol. Range [0, 1]. - */ - confidence?: number; - /** - * Additional information detected for the symbol. - */ - property?: Schema$TextProperty; - /** - * The actual UTF-8 representation of the symbol. - */ - text?: string; - } - /** - * TextAnnotation contains a structured representation of OCR extracted text. The hierarchy of an OCR extracted text structure is like this: TextAnnotation -> Page -> Block -> Paragraph -> Word -> Symbol Each structural component, starting from Page, may further have their own properties. Properties describe detected languages, breaks etc.. Please refer to the TextAnnotation.TextProperty message definition below for more detail. - */ - export interface Schema$TextAnnotation { - /** - * List of pages detected by OCR. - */ - pages?: Schema$Page[]; - /** - * UTF-8 text detected on the pages. - */ - text?: string; - } - /** - * Additional information detected on the structural component. - */ - export interface Schema$TextProperty { - /** - * Detected start or end of a text segment. - */ - detectedBreak?: Schema$DetectedBreak; - /** - * A list of detected languages together with confidence. - */ - detectedLanguages?: Schema$DetectedLanguage[]; - } - /** - * A vertex represents a 2D point in the image. NOTE: the vertex coordinates are in the same scale as the original image. - */ - export interface Schema$Vertex { - /** - * X coordinate. - */ - x?: number; - /** - * Y coordinate. - */ - y?: number; - } - /** - * Relevant information for the image from the Internet. - */ - export interface Schema$WebDetection { - /** - * The service's best guess as to the topic of the request image. Inferred from similar images on the open web. - */ - bestGuessLabels?: Schema$WebLabel[]; - /** - * Fully matching images from the Internet. Can include resized copies of the query image. - */ - fullMatchingImages?: Schema$WebImage[]; - /** - * Web pages containing the matching images from the Internet. - */ - pagesWithMatchingImages?: Schema$WebPage[]; - /** - * Partial matching images from the Internet. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. - */ - partialMatchingImages?: Schema$WebImage[]; - /** - * The visually similar image results. - */ - visuallySimilarImages?: Schema$WebImage[]; - /** - * Deduced entities from similar images on the Internet. - */ - webEntities?: Schema$WebEntity[]; - } - /** - * Parameters for web detection request. - */ - export interface Schema$WebDetectionParams { - /** - * Whether to include results derived from the geo information in the image. - */ - includeGeoResults?: boolean; - } - /** - * Entity deduced from similar images on the Internet. - */ - export interface Schema$WebEntity { - /** - * Canonical description of the entity, in English. - */ - description?: string; - /** - * Opaque entity ID. - */ - entityId?: string; - /** - * Overall relevancy score for the entity. Not normalized and not comparable across different image queries. - */ - score?: number; - } - /** - * Metadata for online images. - */ - export interface Schema$WebImage { - /** - * (Deprecated) Overall relevancy score for the image. - */ - score?: number; - /** - * The result image URL. - */ - url?: string; - } - /** - * Label to provide extra metadata for the web detection. - */ - export interface Schema$WebLabel { - /** - * Label for extra metadata. - */ - label?: string; + + export class Resource$Locations$Operations { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + /** - * The BCP-47 language code for `label`, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + * vision.locations.operations.get + * @desc 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. + * @example + * * // BEFORE RUNNING: + * // --------------- + * // 1. If not already done, enable the Cloud Vision API + * // and check the quota for your project at + * // https://console.developers.google.com/apis/api/vision + * // 2. This sample uses Application Default Credentials for authentication. + * // If not already done, install the gcloud CLI from + * // https://cloud.google.com/sdk and run + * // `gcloud beta auth application-default login`. + * // For more information, see + * // https://developers.google.com/identity/protocols/application-default-credentials + * // 3. Install the Node.js client library by running + * // `npm install googleapis --save` + * + * const {google} = require('googleapis'); + * var vision = google.vision('v1'); + * + * authorize(function(authClient) { + * var request = { + * // The name of the operation resource. + * name: 'locations/my-location/operations/my-operation', // TODO: Update placeholder value. + * + * auth: authClient, + * }; + * + * vision.locations.operations.get(request, function(err, response) { + * if (err) { + * console.error(err); + * return; + * } + * + * // TODO: Change code below to process the `response` object: + * console.log(JSON.stringify(response, null, 2)); + * }); + * }); + * + * function authorize(callback) { + * google.auth.getClient({ + * scopes: ['https://www.googleapis.com/auth/cloud-platform'] + * }).then(client => { + * callback(client); + * }).catch(err => { + * console.error('authentication failed: ', err); + * }); + * } + * @alias vision.locations.operations.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The name of the operation resource. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - languageCode?: string; + get( + params?: Params$Resource$Locations$Operations$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Locations$Operations$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Locations$Operations$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Locations$Operations$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Locations$Operations$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Locations$Operations$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } - /** - * Metadata for web pages. - */ - export interface Schema$WebPage { - /** - * Fully matching images on the page. Can include resized copies of the query image. - */ - fullMatchingImages?: Schema$WebImage[]; - /** - * Title for the web page, may contain HTML markups. - */ - pageTitle?: string; - /** - * Partial matching images on the page. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. - */ - partialMatchingImages?: Schema$WebImage[]; + + export interface Params$Resource$Locations$Operations$Get + extends StandardParameters { /** - * (Deprecated) Overall relevancy score for the web page. + * Auth client or API Key for the request */ - score?: number; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * The result web page URL. + * The name of the operation resource. */ - url?: string; + name?: string; } - /** - * A word representation. - */ - export interface Schema$Word { - /** - * The bounding box for the word. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$BoundingPoly; - /** - * Confidence of the OCR results for the word. Range [0, 1]. - */ - confidence?: number; + + export class Resource$Operations { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + /** - * Additional information detected for the word. + * vision.operations.cancel + * @desc Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`. + * @example + * * // BEFORE RUNNING: + * // --------------- + * // 1. If not already done, enable the Cloud Vision API + * // and check the quota for your project at + * // https://console.developers.google.com/apis/api/vision + * // 2. This sample uses Application Default Credentials for authentication. + * // If not already done, install the gcloud CLI from + * // https://cloud.google.com/sdk and run + * // `gcloud beta auth application-default login`. + * // For more information, see + * // https://developers.google.com/identity/protocols/application-default-credentials + * // 3. Install the Node.js client library by running + * // `npm install googleapis --save` + * + * const {google} = require('googleapis'); + * var vision = google.vision('v1'); + * + * authorize(function(authClient) { + * var request = { + * // The name of the operation resource to be cancelled. + * name: 'operations/my-operation', // TODO: Update placeholder value. + * + * resource: { + * // TODO: Add desired properties to the request body. + * }, + * + * auth: authClient, + * }; + * + * vision.operations.cancel(request, function(err) { + * if (err) { + * console.error(err); + * return; + * } + * }); + * }); + * + * function authorize(callback) { + * google.auth.getClient({ + * scopes: ['https://www.googleapis.com/auth/cloud-platform'] + * }).then(client => { + * callback(client); + * }).catch(err => { + * console.error('authentication failed: ', err); + * }); + * } + * @alias vision.operations.cancel + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The name of the operation resource to be cancelled. + * @param {().CancelOperationRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - property?: Schema$TextProperty; + cancel( + params?: Params$Resource$Operations$Cancel, + options?: MethodOptions + ): GaxiosPromise; + cancel( + params: Params$Resource$Operations$Cancel, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + cancel( + params: Params$Resource$Operations$Cancel, + callback: BodyResponseCallback + ): void; + cancel(callback: BodyResponseCallback): void; + cancel( + paramsOrCallback?: + | Params$Resource$Operations$Cancel + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Operations$Cancel; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Operations$Cancel; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}:cancel').replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + /** - * List of symbols in the word. The order of the symbols follows the natural reading order. + * vision.operations.delete + * @desc Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. + * @example + * * // BEFORE RUNNING: + * // --------------- + * // 1. If not already done, enable the Cloud Vision API + * // and check the quota for your project at + * // https://console.developers.google.com/apis/api/vision + * // 2. This sample uses Application Default Credentials for authentication. + * // If not already done, install the gcloud CLI from + * // https://cloud.google.com/sdk and run + * // `gcloud beta auth application-default login`. + * // For more information, see + * // https://developers.google.com/identity/protocols/application-default-credentials + * // 3. Install the Node.js client library by running + * // `npm install googleapis --save` + * + * const {google} = require('googleapis'); + * var vision = google.vision('v1'); + * + * authorize(function(authClient) { + * var request = { + * // The name of the operation resource to be deleted. + * name: 'operations/my-operation', // TODO: Update placeholder value. + * + * auth: authClient, + * }; + * + * vision.operations.delete(request, function(err) { + * if (err) { + * console.error(err); + * return; + * } + * }); + * }); + * + * function authorize(callback) { + * google.auth.getClient({ + * scopes: ['https://www.googleapis.com/auth/cloud-platform'] + * }).then(client => { + * callback(client); + * }).catch(err => { + * console.error('authentication failed: ', err); + * }); + * } + * @alias vision.operations.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The name of the operation resource to be deleted. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - symbols?: Schema$Symbol[]; - } + delete( + params?: Params$Resource$Operations$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Operations$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Operations$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Operations$Delete + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Operations$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; - export class Resource$Files { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Operations$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } } /** - * vision.files.annotate - * @desc Service that performs image detection and annotation for a batch of files. Now only "application/pdf", "image/tiff" and "image/gif" are supported. This service will extract at most 5 (customers can specify which 5 in AnnotateFileRequest.pages) frames (gif) or pages (pdf or tiff) from each file provided and perform detection and annotation for each image extracted. + * vision.operations.get + * @desc 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. * @example * * // BEFORE RUNNING: * // --------------- @@ -6873,14 +7186,13 @@ export namespace vision_v1 { * * authorize(function(authClient) { * var request = { - * resource: { - * // TODO: Add desired properties to the request body. - * }, + * // The name of the operation resource. + * name: 'operations/my-operation', // TODO: Update placeholder value. * * auth: authClient, * }; * - * vision.files.annotate(request, function(err, response) { + * vision.operations.get(request, function(err, response) { * if (err) { * console.error(err); * return; @@ -6900,48 +7212,44 @@ export namespace vision_v1 { * console.error('authentication failed: ', err); * }); * } - * @alias vision.files.annotate + * @alias vision.operations.get * @memberOf! () * * @param {object} params Parameters for request - * @param {().BatchAnnotateFilesRequest} params.resource Request body data + * @param {string} params.name The name of the operation resource. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - annotate( - params?: Params$Resource$Files$Annotate, + get( + params?: Params$Resource$Operations$Get, options?: MethodOptions - ): GaxiosPromise; - annotate( - params: Params$Resource$Files$Annotate, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback - ): void; - annotate( - params: Params$Resource$Files$Annotate, - callback: BodyResponseCallback + ): GaxiosPromise; + get( + params: Params$Resource$Operations$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback ): void; - annotate( - callback: BodyResponseCallback + get( + params: Params$Resource$Operations$Get, + callback: BodyResponseCallback ): void; - annotate( + get(callback: BodyResponseCallback): void; + get( paramsOrCallback?: - | Params$Resource$Files$Annotate - | BodyResponseCallback, + | Params$Resource$Operations$Get + | BodyResponseCallback, optionsOrCallback?: | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Files$Annotate; + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Operations$Get; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Files$Annotate; + params = {} as Params$Resource$Operations$Get; options = {}; } @@ -6954,29 +7262,26 @@ export namespace vision_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/files:annotate').replace(/([^:]\/)\/+/g, '$1'), - method: 'POST', + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', }, options ), params, - requiredParams: [], - pathParams: [], + requiredParams: ['name'], + pathParams: ['name'], context: this.context, }; if (callback) { - createAPIRequest( - parameters, - callback - ); + createAPIRequest(parameters, callback); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } /** - * vision.files.asyncBatchAnnotate - * @desc Run asynchronous image detection and annotation for a list of generic files, such as PDF files, which may contain multiple pages and multiple images per page. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results). + * vision.operations.list + * @desc Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/x/operations`. To override the binding, API services can add a binding such as `"/v1/{name=users/x}/operations"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id. * @example * * // BEFORE RUNNING: * // --------------- @@ -6997,22 +7302,34 @@ export namespace vision_v1 { * * authorize(function(authClient) { * var request = { - * resource: { - * // TODO: Add desired properties to the request body. - * }, + * // The name of the operation's parent resource. + * name: 'operations', // TODO: Update placeholder value. * * auth: authClient, * }; * - * vision.files.asyncBatchAnnotate(request, function(err, response) { + * var handlePage = function(err, response) { * if (err) { * console.error(err); * return; * } * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); - * }); + * var operationsPage = response['operations']; + * if (!operationsPage) { + * return; + * } + * for (var i = 0; i < operationsPage.length; i++) { + * // TODO: Change code below to process each resource in `operationsPage`: + * console.log(JSON.stringify(operationsPage[i], null, 2)); + * } + * + * if (response.nextPageToken) { + * request.pageToken = response.nextPageToken; + * vision.operations.list(request, handlePage); + * } + * }; + * + * vision.operations.list(request, handlePage); * }); * * function authorize(callback) { @@ -7024,45 +7341,49 @@ export namespace vision_v1 { * console.error('authentication failed: ', err); * }); * } - * @alias vision.files.asyncBatchAnnotate + * @alias vision.operations.list * @memberOf! () * * @param {object} params Parameters for request - * @param {().AsyncBatchAnnotateFilesRequest} params.resource Request body data + * @param {string=} params.filter The standard list filter. + * @param {string} params.name The name of the operation's parent resource. + * @param {integer=} params.pageSize The standard list page size. + * @param {string=} params.pageToken The standard list page token. * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - asyncBatchAnnotate( - params?: Params$Resource$Files$Asyncbatchannotate, + list( + params?: Params$Resource$Operations$List, options?: MethodOptions - ): GaxiosPromise; - asyncBatchAnnotate( - params: Params$Resource$Files$Asyncbatchannotate, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + list( + params: Params$Resource$Operations$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback ): void; - asyncBatchAnnotate( - params: Params$Resource$Files$Asyncbatchannotate, - callback: BodyResponseCallback + list( + params: Params$Resource$Operations$List, + callback: BodyResponseCallback ): void; - asyncBatchAnnotate(callback: BodyResponseCallback): void; - asyncBatchAnnotate( + list(callback: BodyResponseCallback): void; + list( paramsOrCallback?: - | Params$Resource$Files$Asyncbatchannotate - | BodyResponseCallback, + | Params$Resource$Operations$List + | BodyResponseCallback, optionsOrCallback?: | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || - {}) as Params$Resource$Files$Asyncbatchannotate; + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Operations$List; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Files$Asyncbatchannotate; + params = {} as Params$Resource$Operations$List; options = {}; } @@ -7075,149 +7396,156 @@ export namespace vision_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/files:asyncBatchAnnotate').replace( - /([^:]\/)\/+/g, - '$1' - ), - method: 'POST', + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', }, options ), params, - requiredParams: [], - pathParams: [], + requiredParams: ['name'], + pathParams: ['name'], context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest(parameters, callback); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } } - export interface Params$Resource$Files$Annotate extends StandardParameters { + export interface Params$Resource$Operations$Cancel + extends StandardParameters { /** * Auth client or API Key for the request */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * The name of the operation resource to be cancelled. + */ + name?: string; + /** * Request body metadata */ - requestBody?: Schema$BatchAnnotateFilesRequest; + requestBody?: Schema$CancelOperationRequest; } - export interface Params$Resource$Files$Asyncbatchannotate + export interface Params$Resource$Operations$Delete extends StandardParameters { /** * Auth client or API Key for the request */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The name of the operation resource to be deleted. + */ + name?: string; + } + export interface Params$Resource$Operations$Get extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The name of the operation resource. + */ + name?: string; + } + export interface Params$Resource$Operations$List extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The standard list filter. + */ + filter?: string; + /** + * The name of the operation's parent resource. + */ + name?: string; + /** + * The standard list page size. + */ + pageSize?: number; /** - * Request body metadata + * The standard list page token. */ - requestBody?: Schema$AsyncBatchAnnotateFilesRequest; + pageToken?: string; } - export class Resource$Images { + export class Resource$Projects { + context: APIRequestContext; + files: Resource$Projects$Files; + images: Resource$Projects$Images; + locations: Resource$Projects$Locations; + operations: Resource$Projects$Operations; + constructor(context: APIRequestContext) { + this.context = context; + this.files = new Resource$Projects$Files(this.context); + this.images = new Resource$Projects$Images(this.context); + this.locations = new Resource$Projects$Locations(this.context); + this.operations = new Resource$Projects$Operations(this.context); + } + } + + export class Resource$Projects$Files { context: APIRequestContext; constructor(context: APIRequestContext) { this.context = context; } /** - * vision.images.annotate - * @desc Run image detection and annotation for a batch of images. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Vision API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/vision - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var vision = google.vision('v1'); - * - * authorize(function(authClient) { - * var request = { - * resource: { - * // TODO: Add desired properties to the request body. - * }, - * - * auth: authClient, - * }; - * - * vision.images.annotate(request, function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); - * }); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias vision.images.annotate + * vision.projects.files.annotate + * @desc Service that performs image detection and annotation for a batch of files. Now only "application/pdf", "image/tiff" and "image/gif" are supported. This service will extract at most 5 (customers can specify which 5 in AnnotateFileRequest.pages) frames (gif) or pages (pdf or tiff) from each file provided and perform detection and annotation for each image extracted. + * @alias vision.projects.files.annotate * @memberOf! () * * @param {object} params Parameters for request - * @param {().BatchAnnotateImagesRequest} params.resource Request body data + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().BatchAnnotateFilesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ annotate( - params?: Params$Resource$Images$Annotate, + params?: Params$Resource$Projects$Files$Annotate, options?: MethodOptions - ): GaxiosPromise; + ): GaxiosPromise; annotate( - params: Params$Resource$Images$Annotate, + params: Params$Resource$Projects$Files$Annotate, options: | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback + | BodyResponseCallback, + callback: BodyResponseCallback ): void; annotate( - params: Params$Resource$Images$Annotate, - callback: BodyResponseCallback + params: Params$Resource$Projects$Files$Annotate, + callback: BodyResponseCallback ): void; annotate( - callback: BodyResponseCallback + callback: BodyResponseCallback ): void; annotate( paramsOrCallback?: - | Params$Resource$Images$Annotate - | BodyResponseCallback, + | Params$Resource$Projects$Files$Annotate + | BodyResponseCallback, optionsOrCallback?: | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Images$Annotate; + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Files$Annotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Images$Annotate; + params = {} as Params$Resource$Projects$Files$Annotate; options = {}; } @@ -7230,7 +7558,7 @@ export namespace vision_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/images:annotate').replace( + url: (rootUrl + '/v1/{+parent}/files:annotate').replace( /([^:]\/)\/+/g, '$1' ), @@ -7239,96 +7567,50 @@ export namespace vision_v1 { options ), params, - requiredParams: [], - pathParams: [], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { - createAPIRequest( + createAPIRequest( parameters, callback ); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } /** - * vision.images.asyncBatchAnnotate - * @desc Run asynchronous image detection and annotation for a list of images. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateImagesResponse` (results). This service will write image annotation outputs to json files in customer GCS bucket, each json file containing BatchAnnotateImagesResponse proto. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Vision API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/vision - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var vision = google.vision('v1'); - * - * authorize(function(authClient) { - * var request = { - * resource: { - * // TODO: Add desired properties to the request body. - * }, - * - * auth: authClient, - * }; - * - * vision.images.asyncBatchAnnotate(request, function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); - * }); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias vision.images.asyncBatchAnnotate + * vision.projects.files.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of generic files, such as PDF files, which may contain multiple pages and multiple images per page. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results). + * @alias vision.projects.files.asyncBatchAnnotate * @memberOf! () * * @param {object} params Parameters for request - * @param {().AsyncBatchAnnotateImagesRequest} params.resource Request body data + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().AsyncBatchAnnotateFilesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ asyncBatchAnnotate( - params?: Params$Resource$Images$Asyncbatchannotate, + params?: Params$Resource$Projects$Files$Asyncbatchannotate, options?: MethodOptions ): GaxiosPromise; asyncBatchAnnotate( - params: Params$Resource$Images$Asyncbatchannotate, + params: Params$Resource$Projects$Files$Asyncbatchannotate, options: MethodOptions | BodyResponseCallback, callback: BodyResponseCallback ): void; asyncBatchAnnotate( - params: Params$Resource$Images$Asyncbatchannotate, + params: Params$Resource$Projects$Files$Asyncbatchannotate, callback: BodyResponseCallback ): void; asyncBatchAnnotate(callback: BodyResponseCallback): void; asyncBatchAnnotate( paramsOrCallback?: - | Params$Resource$Images$Asyncbatchannotate + | Params$Resource$Projects$Files$Asyncbatchannotate | BodyResponseCallback, optionsOrCallback?: | MethodOptions @@ -7336,12 +7618,12 @@ export namespace vision_v1 { callback?: BodyResponseCallback ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Images$Asyncbatchannotate; + {}) as Params$Resource$Projects$Files$Asyncbatchannotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Images$Asyncbatchannotate; + params = {} as Params$Resource$Projects$Files$Asyncbatchannotate; options = {}; } @@ -7354,7 +7636,7 @@ export namespace vision_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/images:asyncBatchAnnotate').replace( + url: (rootUrl + '/v1/{+parent}/files:asyncBatchAnnotate').replace( /([^:]\/)\/+/g, '$1' ), @@ -7363,8 +7645,8 @@ export namespace vision_v1 { options ), params, - requiredParams: [], - pathParams: [], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { @@ -7375,18 +7657,24 @@ export namespace vision_v1 { } } - export interface Params$Resource$Images$Annotate extends StandardParameters { + export interface Params$Resource$Projects$Files$Annotate + extends StandardParameters { /** * Auth client or API Key for the request */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + /** * Request body metadata */ - requestBody?: Schema$BatchAnnotateImagesRequest; + requestBody?: Schema$BatchAnnotateFilesRequest; } - export interface Params$Resource$Images$Asyncbatchannotate + export interface Params$Resource$Projects$Files$Asyncbatchannotate extends StandardParameters { /** * Auth client or API Key for the request @@ -7394,114 +7682,69 @@ export namespace vision_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * Request body metadata + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. */ - requestBody?: Schema$AsyncBatchAnnotateImagesRequest; - } + parent?: string; - export class Resource$Locations { - context: APIRequestContext; - operations: Resource$Locations$Operations; - constructor(context: APIRequestContext) { - this.context = context; - this.operations = new Resource$Locations$Operations(this.context); - } + /** + * Request body metadata + */ + requestBody?: Schema$AsyncBatchAnnotateFilesRequest; } - export class Resource$Locations$Operations { + export class Resource$Projects$Images { context: APIRequestContext; constructor(context: APIRequestContext) { this.context = context; } /** - * vision.locations.operations.get - * @desc 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. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Vision API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/vision - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var vision = google.vision('v1'); - * - * authorize(function(authClient) { - * var request = { - * // The name of the operation resource. - * name: 'locations/my-location/operations/my-operation', // TODO: Update placeholder value. - * - * auth: authClient, - * }; - * - * vision.locations.operations.get(request, function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); - * }); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias vision.locations.operations.get + * vision.projects.images.annotate + * @desc Run image detection and annotation for a batch of images. + * @alias vision.projects.images.annotate * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name The name of the operation resource. + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().BatchAnnotateImagesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - get( - params?: Params$Resource$Locations$Operations$Get, + annotate( + params?: Params$Resource$Projects$Images$Annotate, options?: MethodOptions - ): GaxiosPromise; - get( - params: Params$Resource$Locations$Operations$Get, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + annotate( + params: Params$Resource$Projects$Images$Annotate, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback ): void; - get( - params: Params$Resource$Locations$Operations$Get, - callback: BodyResponseCallback + annotate( + params: Params$Resource$Projects$Images$Annotate, + callback: BodyResponseCallback ): void; - get(callback: BodyResponseCallback): void; - get( + annotate( + callback: BodyResponseCallback + ): void; + annotate( paramsOrCallback?: - | Params$Resource$Locations$Operations$Get - | BodyResponseCallback, + | Params$Resource$Projects$Images$Annotate + | BodyResponseCallback, optionsOrCallback?: | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Locations$Operations$Get; + {}) as Params$Resource$Projects$Images$Annotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Locations$Operations$Get; + params = {} as Params$Resource$Projects$Images$Annotate; options = {}; } @@ -7514,131 +7757,72 @@ export namespace vision_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', + url: (rootUrl + '/v1/{+parent}/images:annotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', }, options ), params, - requiredParams: ['name'], - pathParams: ['name'], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest( + parameters, + callback + ); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } - } - - export interface Params$Resource$Locations$Operations$Get - extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the operation resource. - */ - name?: string; - } - - export class Resource$Operations { - context: APIRequestContext; - constructor(context: APIRequestContext) { - this.context = context; - } /** - * vision.operations.cancel - * @desc Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Vision API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/vision - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var vision = google.vision('v1'); - * - * authorize(function(authClient) { - * var request = { - * // The name of the operation resource to be cancelled. - * name: 'operations/my-operation', // TODO: Update placeholder value. - * - * resource: { - * // TODO: Add desired properties to the request body. - * }, - * - * auth: authClient, - * }; - * - * vision.operations.cancel(request, function(err) { - * if (err) { - * console.error(err); - * return; - * } - * }); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias vision.operations.cancel + * vision.projects.images.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of images. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateImagesResponse` (results). This service will write image annotation outputs to json files in customer GCS bucket, each json file containing BatchAnnotateImagesResponse proto. + * @alias vision.projects.images.asyncBatchAnnotate * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name The name of the operation resource to be cancelled. - * @param {().CancelOperationRequest} params.resource Request body data + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().AsyncBatchAnnotateImagesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - cancel( - params?: Params$Resource$Operations$Cancel, + asyncBatchAnnotate( + params?: Params$Resource$Projects$Images$Asyncbatchannotate, options?: MethodOptions - ): GaxiosPromise; - cancel( - params: Params$Resource$Operations$Cancel, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + asyncBatchAnnotate( + params: Params$Resource$Projects$Images$Asyncbatchannotate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback ): void; - cancel( - params: Params$Resource$Operations$Cancel, - callback: BodyResponseCallback + asyncBatchAnnotate( + params: Params$Resource$Projects$Images$Asyncbatchannotate, + callback: BodyResponseCallback ): void; - cancel(callback: BodyResponseCallback): void; - cancel( + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( paramsOrCallback?: - | Params$Resource$Operations$Cancel - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | Params$Resource$Projects$Images$Asyncbatchannotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Operations$Cancel; + {}) as Params$Resource$Projects$Images$Asyncbatchannotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Operations$Cancel; + params = {} as Params$Resource$Projects$Images$Asyncbatchannotate; options = {}; } @@ -7651,106 +7835,136 @@ export namespace vision_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+name}:cancel').replace(/([^:]\/)\/+/g, '$1'), + url: (rootUrl + '/v1/{+parent}/images:asyncBatchAnnotate').replace( + /([^:]\/)\/+/g, + '$1' + ), method: 'POST', }, options ), params, - requiredParams: ['name'], - pathParams: ['name'], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest(parameters, callback); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } + } + export interface Params$Resource$Projects$Images$Annotate + extends StandardParameters { /** - * vision.operations.delete - * @desc Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Vision API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/vision - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var vision = google.vision('v1'); - * - * authorize(function(authClient) { - * var request = { - * // The name of the operation resource to be deleted. - * name: 'operations/my-operation', // TODO: Update placeholder value. - * - * auth: authClient, - * }; - * - * vision.operations.delete(request, function(err) { - * if (err) { - * console.error(err); - * return; - * } - * }); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias vision.operations.delete + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$BatchAnnotateImagesRequest; + } + export interface Params$Resource$Projects$Images$Asyncbatchannotate + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$AsyncBatchAnnotateImagesRequest; + } + + export class Resource$Projects$Locations { + context: APIRequestContext; + files: Resource$Projects$Locations$Files; + images: Resource$Projects$Locations$Images; + operations: Resource$Projects$Locations$Operations; + products: Resource$Projects$Locations$Products; + productSets: Resource$Projects$Locations$Productsets; + constructor(context: APIRequestContext) { + this.context = context; + this.files = new Resource$Projects$Locations$Files(this.context); + this.images = new Resource$Projects$Locations$Images(this.context); + this.operations = new Resource$Projects$Locations$Operations( + this.context + ); + this.products = new Resource$Projects$Locations$Products(this.context); + this.productSets = new Resource$Projects$Locations$Productsets( + this.context + ); + } + } + + export class Resource$Projects$Locations$Files { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * vision.projects.locations.files.annotate + * @desc Service that performs image detection and annotation for a batch of files. Now only "application/pdf", "image/tiff" and "image/gif" are supported. This service will extract at most 5 (customers can specify which 5 in AnnotateFileRequest.pages) frames (gif) or pages (pdf or tiff) from each file provided and perform detection and annotation for each image extracted. + * @alias vision.projects.locations.files.annotate * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name The name of the operation resource to be deleted. + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().BatchAnnotateFilesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - delete( - params?: Params$Resource$Operations$Delete, + annotate( + params?: Params$Resource$Projects$Locations$Files$Annotate, options?: MethodOptions - ): GaxiosPromise; - delete( - params: Params$Resource$Operations$Delete, - options: MethodOptions | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + annotate( + params: Params$Resource$Projects$Locations$Files$Annotate, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback ): void; - delete( - params: Params$Resource$Operations$Delete, - callback: BodyResponseCallback + annotate( + params: Params$Resource$Projects$Locations$Files$Annotate, + callback: BodyResponseCallback ): void; - delete(callback: BodyResponseCallback): void; - delete( + annotate( + callback: BodyResponseCallback + ): void; + annotate( paramsOrCallback?: - | Params$Resource$Operations$Delete - | BodyResponseCallback, - optionsOrCallback?: MethodOptions | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { + | Params$Resource$Projects$Locations$Files$Annotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Operations$Delete; + {}) as Params$Resource$Projects$Locations$Files$Annotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Operations$Delete; + params = {} as Params$Resource$Projects$Locations$Files$Annotate; options = {}; } @@ -7763,110 +7977,72 @@ export namespace vision_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), - method: 'DELETE', + url: (rootUrl + '/v1/{+parent}/files:annotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', }, options ), params, - requiredParams: ['name'], - pathParams: ['name'], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest( + parameters, + callback + ); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } /** - * vision.operations.get - * @desc 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. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Vision API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/vision - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var vision = google.vision('v1'); - * - * authorize(function(authClient) { - * var request = { - * // The name of the operation resource. - * name: 'operations/my-operation', // TODO: Update placeholder value. - * - * auth: authClient, - * }; - * - * vision.operations.get(request, function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * // TODO: Change code below to process the `response` object: - * console.log(JSON.stringify(response, null, 2)); - * }); - * }); - * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias vision.operations.get + * vision.projects.locations.files.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of generic files, such as PDF files, which may contain multiple pages and multiple images per page. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results). + * @alias vision.projects.locations.files.asyncBatchAnnotate * @memberOf! () * * @param {object} params Parameters for request - * @param {string} params.name The name of the operation resource. + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().AsyncBatchAnnotateFilesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - get( - params?: Params$Resource$Operations$Get, + asyncBatchAnnotate( + params?: Params$Resource$Projects$Locations$Files$Asyncbatchannotate, options?: MethodOptions ): GaxiosPromise; - get( - params: Params$Resource$Operations$Get, + asyncBatchAnnotate( + params: Params$Resource$Projects$Locations$Files$Asyncbatchannotate, options: MethodOptions | BodyResponseCallback, callback: BodyResponseCallback ): void; - get( - params: Params$Resource$Operations$Get, + asyncBatchAnnotate( + params: Params$Resource$Projects$Locations$Files$Asyncbatchannotate, callback: BodyResponseCallback ): void; - get(callback: BodyResponseCallback): void; - get( + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( paramsOrCallback?: - | Params$Resource$Operations$Get + | Params$Resource$Projects$Locations$Files$Asyncbatchannotate | BodyResponseCallback, optionsOrCallback?: | MethodOptions | BodyResponseCallback, callback?: BodyResponseCallback ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Operations$Get; + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Files$Asyncbatchannotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Operations$Get; + params = {} as Params$Resource$Projects$Locations$Files$Asyncbatchannotate; options = {}; } @@ -7879,14 +8055,17 @@ export namespace vision_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', + url: (rootUrl + '/v1/{+parent}/files:asyncBatchAnnotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', }, options ), params, - requiredParams: ['name'], - pathParams: ['name'], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { @@ -7895,112 +8074,174 @@ export namespace vision_v1 { return createAPIRequest(parameters); } } + } + export interface Params$Resource$Projects$Locations$Files$Annotate + extends StandardParameters { /** - * vision.operations.list - * @desc Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/x/operations`. To override the binding, API services can add a binding such as `"/v1/{name=users/x}/operations"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id. - * @example - * * // BEFORE RUNNING: - * // --------------- - * // 1. If not already done, enable the Cloud Vision API - * // and check the quota for your project at - * // https://console.developers.google.com/apis/api/vision - * // 2. This sample uses Application Default Credentials for authentication. - * // If not already done, install the gcloud CLI from - * // https://cloud.google.com/sdk and run - * // `gcloud beta auth application-default login`. - * // For more information, see - * // https://developers.google.com/identity/protocols/application-default-credentials - * // 3. Install the Node.js client library by running - * // `npm install googleapis --save` - * - * const {google} = require('googleapis'); - * var vision = google.vision('v1'); - * - * authorize(function(authClient) { - * var request = { - * // The name of the operation's parent resource. - * name: 'operations', // TODO: Update placeholder value. - * - * auth: authClient, - * }; - * - * var handlePage = function(err, response) { - * if (err) { - * console.error(err); - * return; - * } - * - * var operationsPage = response['operations']; - * if (!operationsPage) { - * return; - * } - * for (var i = 0; i < operationsPage.length; i++) { - * // TODO: Change code below to process each resource in `operationsPage`: - * console.log(JSON.stringify(operationsPage[i], null, 2)); - * } - * - * if (response.nextPageToken) { - * request.pageToken = response.nextPageToken; - * vision.operations.list(request, handlePage); - * } - * }; - * - * vision.operations.list(request, handlePage); - * }); + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$BatchAnnotateFilesRequest; + } + export interface Params$Resource$Projects$Locations$Files$Asyncbatchannotate + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$AsyncBatchAnnotateFilesRequest; + } + + export class Resource$Projects$Locations$Images { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * vision.projects.locations.images.annotate + * @desc Run image detection and annotation for a batch of images. + * @alias vision.projects.locations.images.annotate + * @memberOf! () * - * function authorize(callback) { - * google.auth.getClient({ - * scopes: ['https://www.googleapis.com/auth/cloud-platform'] - * }).then(client => { - * callback(client); - * }).catch(err => { - * console.error('authentication failed: ', err); - * }); - * } - * @alias vision.operations.list + * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().BatchAnnotateImagesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + annotate( + params?: Params$Resource$Projects$Locations$Images$Annotate, + options?: MethodOptions + ): GaxiosPromise; + annotate( + params: Params$Resource$Projects$Locations$Images$Annotate, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + annotate( + params: Params$Resource$Projects$Locations$Images$Annotate, + callback: BodyResponseCallback + ): void; + annotate( + callback: BodyResponseCallback + ): void; + annotate( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Images$Annotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Images$Annotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Images$Annotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+parent}/images:annotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest(parameters); + } + } + + /** + * vision.projects.locations.images.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of images. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateImagesResponse` (results). This service will write image annotation outputs to json files in customer GCS bucket, each json file containing BatchAnnotateImagesResponse proto. + * @alias vision.projects.locations.images.asyncBatchAnnotate * @memberOf! () * * @param {object} params Parameters for request - * @param {string=} params.filter The standard list filter. - * @param {string} params.name The name of the operation's parent resource. - * @param {integer=} params.pageSize The standard list page size. - * @param {string=} params.pageToken The standard list page token. + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().AsyncBatchAnnotateImagesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ - list( - params?: Params$Resource$Operations$List, + asyncBatchAnnotate( + params?: Params$Resource$Projects$Locations$Images$Asyncbatchannotate, options?: MethodOptions - ): GaxiosPromise; - list( - params: Params$Resource$Operations$List, - options: - | MethodOptions - | BodyResponseCallback, - callback: BodyResponseCallback + ): GaxiosPromise; + asyncBatchAnnotate( + params: Params$Resource$Projects$Locations$Images$Asyncbatchannotate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback ): void; - list( - params: Params$Resource$Operations$List, - callback: BodyResponseCallback + asyncBatchAnnotate( + params: Params$Resource$Projects$Locations$Images$Asyncbatchannotate, + callback: BodyResponseCallback ): void; - list(callback: BodyResponseCallback): void; - list( + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( paramsOrCallback?: - | Params$Resource$Operations$List - | BodyResponseCallback, + | Params$Resource$Projects$Locations$Images$Asyncbatchannotate + | BodyResponseCallback, optionsOrCallback?: | MethodOptions - | BodyResponseCallback, - callback?: BodyResponseCallback - ): void | GaxiosPromise { - let params = (paramsOrCallback || {}) as Params$Resource$Operations$List; + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Images$Asyncbatchannotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Operations$List; + params = {} as Params$Resource$Projects$Locations$Images$Asyncbatchannotate; options = {}; } @@ -8013,25 +8254,28 @@ export namespace vision_v1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), - method: 'GET', + url: (rootUrl + '/v1/{+parent}/images:asyncBatchAnnotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', }, options ), params, - requiredParams: ['name'], - pathParams: ['name'], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { - createAPIRequest(parameters, callback); + createAPIRequest(parameters, callback); } else { - return createAPIRequest(parameters); + return createAPIRequest(parameters); } } } - export interface Params$Resource$Operations$Cancel + export interface Params$Resource$Projects$Locations$Images$Annotate extends StandardParameters { /** * Auth client or API Key for the request @@ -8039,16 +8283,16 @@ export namespace vision_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The name of the operation resource to be cancelled. + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. */ - name?: string; + parent?: string; /** * Request body metadata */ - requestBody?: Schema$CancelOperationRequest; + requestBody?: Schema$BatchAnnotateImagesRequest; } - export interface Params$Resource$Operations$Delete + export interface Params$Resource$Projects$Locations$Images$Asyncbatchannotate extends StandardParameters { /** * Auth client or API Key for the request @@ -8056,71 +8300,14 @@ export namespace vision_v1 { auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; /** - * The name of the operation resource to be deleted. - */ - name?: string; - } - export interface Params$Resource$Operations$Get extends StandardParameters { - /** - * Auth client or API Key for the request - */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; - - /** - * The name of the operation resource. - */ - name?: string; - } - export interface Params$Resource$Operations$List extends StandardParameters { - /** - * Auth client or API Key for the request + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. */ - auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + parent?: string; /** - * The standard list filter. - */ - filter?: string; - /** - * The name of the operation's parent resource. - */ - name?: string; - /** - * The standard list page size. - */ - pageSize?: number; - /** - * The standard list page token. + * Request body metadata */ - pageToken?: string; - } - - export class Resource$Projects { - context: APIRequestContext; - locations: Resource$Projects$Locations; - operations: Resource$Projects$Operations; - constructor(context: APIRequestContext) { - this.context = context; - this.locations = new Resource$Projects$Locations(this.context); - this.operations = new Resource$Projects$Operations(this.context); - } - } - - export class Resource$Projects$Locations { - context: APIRequestContext; - operations: Resource$Projects$Locations$Operations; - products: Resource$Projects$Locations$Products; - productSets: Resource$Projects$Locations$Productsets; - constructor(context: APIRequestContext) { - this.context = context; - this.operations = new Resource$Projects$Locations$Operations( - this.context - ); - this.products = new Resource$Projects$Locations$Products(this.context); - this.productSets = new Resource$Projects$Locations$Productsets( - this.context - ); - } + requestBody?: Schema$AsyncBatchAnnotateImagesRequest; } export class Resource$Projects$Locations$Operations { @@ -8890,6 +9077,81 @@ export namespace vision_v1 { return createAPIRequest(parameters); } } + + /** + * vision.projects.locations.products.purge + * @desc Asynchronous API to delete all Products in a ProductSet or all Products that are in no ProductSet. If a Product is a member of the specified ProductSet in addition to other ProductSets, the Product will still be deleted. It is recommended to not delete the specified ProductSet until after this operation has completed. It is also recommended to not add any of the Products involved in the batch delete to a new ProductSet while this operation is running because those Products may still end up deleted. It's not possible to undo the PurgeProducts operation. Therefore, it is recommended to keep the csv files used in ImportProductSets (if that was how you originally built the Product Set) before starting PurgeProducts, in case you need to re-import the data after deletion. If the plan is to purge all of the Products from a ProductSet and then re-use the empty ProductSet to re-import new Products into the empty ProductSet, you must wait until the PurgeProducts operation has finished for that ProductSet. The google.longrunning.Operation API can be used to keep track of the progress and results of the request. `Operation.metadata` contains `BatchOperationMetadata`. (progress) + * @alias vision.projects.locations.products.purge + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent The project and location in which the Products should be deleted. Format is `projects/PROJECT_ID/locations/LOC_ID`. + * @param {().PurgeProductsRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + purge( + params?: Params$Resource$Projects$Locations$Products$Purge, + options?: MethodOptions + ): GaxiosPromise; + purge( + params: Params$Resource$Projects$Locations$Products$Purge, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + purge( + params: Params$Resource$Projects$Locations$Products$Purge, + callback: BodyResponseCallback + ): void; + purge(callback: BodyResponseCallback): void; + purge( + paramsOrCallback?: + | Params$Resource$Projects$Locations$Products$Purge + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Products$Purge; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Locations$Products$Purge; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+parent}/products:purge').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } export interface Params$Resource$Projects$Locations$Products$Create @@ -8978,6 +9240,23 @@ export namespace vision_v1 { */ requestBody?: Schema$Product; } + export interface Params$Resource$Projects$Locations$Products$Purge + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The project and location in which the Products should be deleted. Format is `projects/PROJECT_ID/locations/LOC_ID`. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$PurgeProductsRequest; + } export class Resource$Projects$Locations$Products$Referenceimages { context: APIRequestContext; diff --git a/src/apis/vision/v1p1beta1.ts b/src/apis/vision/v1p1beta1.ts index e4603ad898d..5261f7bea50 100644 --- a/src/apis/vision/v1p1beta1.ts +++ b/src/apis/vision/v1p1beta1.ts @@ -107,6 +107,7 @@ export namespace vision_v1p1beta1 { context: APIRequestContext; files: Resource$Files; images: Resource$Images; + projects: Resource$Projects; constructor(options: GlobalOptions, google?: GoogleConfigurable) { this.context = { @@ -116,6 +117,7 @@ export namespace vision_v1p1beta1 { this.files = new Resource$Files(this.context); this.images = new Resource$Images(this.context); + this.projects = new Resource$Projects(this.context); } } @@ -123,12 +125,16 @@ export namespace vision_v1p1beta1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$AnnotateImageResponse[]; /** @@ -536,12 +542,16 @@ export namespace vision_v1p1beta1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p1beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p1beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p1beta1AnnotateImageResponse[]; /** @@ -661,6 +671,10 @@ export namespace vision_v1p1beta1 { * Multiple async file annotation requests are batched into a single service call. */ export interface Schema$GoogleCloudVisionV1p1beta1AsyncBatchAnnotateFilesRequest { + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; /** * Individual async file annotation requests for this batch. */ @@ -683,6 +697,10 @@ export namespace vision_v1p1beta1 { * Required. The desired output location and metadata (e.g. format). */ outputConfig?: Schema$GoogleCloudVisionV1p1beta1OutputConfig; + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; /** * Individual image annotation requests for this batch. */ @@ -692,6 +710,10 @@ export namespace vision_v1p1beta1 { * A list of requests to annotate files using the BatchAnnotateFiles API. */ export interface Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesRequest { + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; /** * The list of file annotation requests. Right now we support only one AnnotateFileRequest in BatchAnnotateFilesRequest. */ @@ -710,6 +732,10 @@ export namespace vision_v1p1beta1 { * Multiple image annotation requests are batched into a single service call. */ export interface Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesRequest { + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; /** * Individual image annotation requests for this batch. */ @@ -1199,7 +1225,7 @@ export namespace vision_v1p1beta1 { */ property?: Schema$GoogleCloudVisionV1p1beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p1beta1Word[]; } @@ -1241,7 +1267,7 @@ export namespace vision_v1p1beta1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p1beta1ProductKeyValue[]; } @@ -1304,11 +1330,36 @@ export namespace vision_v1p1beta1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p1beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p1beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p1beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p1beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -1373,7 +1424,7 @@ export namespace vision_v1p1beta1 { */ export interface Schema$GoogleCloudVisionV1p1beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p1beta1BoundingPoly; /** @@ -1585,12 +1636,16 @@ export namespace vision_v1p1beta1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p2beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p2beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p2beta1AnnotateImageResponse[]; /** @@ -2062,7 +2117,7 @@ export namespace vision_v1p1beta1 { */ property?: Schema$GoogleCloudVisionV1p2beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p2beta1Word[]; } @@ -2104,7 +2159,7 @@ export namespace vision_v1p1beta1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p2beta1ProductKeyValue[]; } @@ -2146,11 +2201,36 @@ export namespace vision_v1p1beta1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p2beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p2beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p2beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p2beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -2215,7 +2295,7 @@ export namespace vision_v1p1beta1 { */ export interface Schema$GoogleCloudVisionV1p2beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p2beta1BoundingPoly; /** @@ -2418,12 +2498,16 @@ export namespace vision_v1p1beta1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p3beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p3beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p3beta1AnnotateImageResponse[]; /** @@ -2925,7 +3009,7 @@ export namespace vision_v1p1beta1 { */ property?: Schema$GoogleCloudVisionV1p3beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p3beta1Word[]; } @@ -2967,7 +3051,7 @@ export namespace vision_v1p1beta1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p3beta1ProductKeyValue[]; } @@ -3009,11 +3093,36 @@ export namespace vision_v1p1beta1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p3beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p3beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p3beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p3beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -3095,7 +3204,7 @@ export namespace vision_v1p1beta1 { */ export interface Schema$GoogleCloudVisionV1p3beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p3beta1BoundingPoly; /** @@ -3298,12 +3407,16 @@ export namespace vision_v1p1beta1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p4beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p4beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p4beta1AnnotateImageResponse[]; /** @@ -3339,6 +3452,10 @@ export namespace vision_v1p1beta1 { * If present, image properties were extracted successfully. */ imagePropertiesAnnotation?: Schema$GoogleCloudVisionV1p4beta1ImageProperties; + /** + * If present, image quality calculation has completed successfully. + */ + imageQualityAnnotation?: Schema$GoogleCloudVisionV1p4beta1ImageQuality; /** * If present, label detection has completed successfully. */ @@ -3359,6 +3476,10 @@ export namespace vision_v1p1beta1 { * If present, product search has completed successfully. */ productSearchResults?: Schema$GoogleCloudVisionV1p4beta1ProductSearchResults; + /** + * If present, image quality optimization has completed successfully. + */ + qualityOptimizationResult?: Schema$GoogleCloudVisionV1p4beta1QualityOptimizationResult; /** * If present, safe-search annotation has completed successfully. */ @@ -3674,6 +3795,15 @@ export namespace vision_v1p1beta1 { */ dominantColors?: Schema$GoogleCloudVisionV1p4beta1DominantColorsAnnotation; } + /** + * Stores image quality scores, could be aesthetic quality or technical quality. + */ + export interface Schema$GoogleCloudVisionV1p4beta1ImageQuality { + /** + * A score representing the aesthetic/technical quality of the image. The score is in range [0, 1]. Higher value corresponds to more professional looking photos. 0 means the image looks very bad, 1 means the image with very high quality. + */ + qualityScore?: number; + } /** * Response message for the `ImportProductSets` method. This message is returned by the google.longrunning.Operations.GetOperation method in the returned google.longrunning.Operation.response field. */ @@ -3823,7 +3953,7 @@ export namespace vision_v1p1beta1 { */ property?: Schema$GoogleCloudVisionV1p4beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p4beta1Word[]; } @@ -3865,7 +3995,7 @@ export namespace vision_v1p1beta1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p4beta1ProductKeyValue[]; } @@ -3907,11 +4037,36 @@ export namespace vision_v1p1beta1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p4beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p4beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p4beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p4beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -3946,6 +4101,23 @@ export namespace vision_v1p1beta1 { */ value?: string; } + /** + * Stores enhanced image bytes. + */ + export interface Schema$GoogleCloudVisionV1p4beta1QualityOptimizationResult { + /** + * Optimized image bytes. + */ + image?: string; + /** + * Mime type of the output image. + */ + mimeType?: string; + /** + * Required optimization type. + */ + qualityOptimizationType?: string; + } /** * A `ReferenceImage` represents a product image and its associated metadata, such as bounding boxes. */ @@ -3971,29 +4143,53 @@ export namespace vision_v1p1beta1 { * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. */ adult?: string; + /** + * Confidence of adult_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + adultConfidence?: number; /** * Likelihood that this is a medical image. */ medical?: string; + /** + * Confidence of medical_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + medicalConfidence?: number; + /** + * Confidence of nsfw_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + nsfwConfidence?: number; /** * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. */ racy?: string; + /** + * Confidence of racy_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + racyConfidence?: number; /** * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. */ spoof?: string; + /** + * Confidence of spoof_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + spoofConfidence?: number; /** * Likelihood that this image contains violent content. */ violence?: string; + /** + * Confidence of violence_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + violenceConfidence?: number; } /** * A single symbol representation. */ export interface Schema$GoogleCloudVisionV1p4beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p4beta1BoundingPoly; /** @@ -4196,12 +4392,16 @@ export namespace vision_v1p1beta1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p5beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p5beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p5beta1AnnotateImageResponse[]; /** @@ -4766,7 +4966,7 @@ export namespace vision_v1p1beta1 { */ property?: Schema$GoogleCloudVisionV1p5beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p5beta1Word[]; } @@ -4808,7 +5008,7 @@ export namespace vision_v1p1beta1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p5beta1ProductKeyValue[]; } @@ -4850,11 +5050,36 @@ export namespace vision_v1p1beta1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p5beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p5beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p5beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p5beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -4914,29 +5139,53 @@ export namespace vision_v1p1beta1 { * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. */ adult?: string; + /** + * Confidence of adult_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + adultConfidence?: number; /** * Likelihood that this is a medical image. */ medical?: string; + /** + * Confidence of medical_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + medicalConfidence?: number; + /** + * Confidence of nsfw_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + nsfwConfidence?: number; /** * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. */ racy?: string; + /** + * Confidence of racy_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + racyConfidence?: number; /** * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. */ spoof?: string; + /** + * Confidence of spoof_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + spoofConfidence?: number; /** * Likelihood that this image contains violent content. */ violence?: string; + /** + * Confidence of violence_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + violenceConfidence?: number; } /** * A single symbol representation. */ export interface Schema$GoogleCloudVisionV1p5beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p5beta1BoundingPoly; /** @@ -5183,558 +5432,509 @@ export namespace vision_v1p1beta1 { symbols?: Schema$GoogleCloudVisionV1p5beta1Symbol[]; } /** - * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. + * Information about the products similar to a single product in a query image. */ - export interface Schema$GoogleCloudVisionV1p6beta1AnnotateFileResponse { + export interface Schema$GroupedResult { /** - * Information about the file for which this response is generated. + * The bounding polygon around the product detected in the query image. */ - inputConfig?: Schema$GoogleCloudVisionV1p6beta1InputConfig; + boundingPoly?: Schema$BoundingPoly; /** - * Individual responses to images found within the file. + * List of generic predictions for the object in the bounding box. */ - responses?: Schema$GoogleCloudVisionV1p6beta1AnnotateImageResponse[]; + objectAnnotations?: Schema$ObjectAnnotation[]; /** - * This field gives the total number of pages in the file. + * List of results, one for each product match. */ - totalPages?: number; + results?: Schema$Result[]; } /** - * Response to an image annotation request. + * If an image was produced from a file (e.g. a PDF), this message gives information about the source of that image. */ - export interface Schema$GoogleCloudVisionV1p6beta1AnnotateImageResponse { + export interface Schema$ImageAnnotationContext { /** - * If present, contextual information is needed to understand where this image comes from. + * If the file was a PDF or TIFF, this field gives the page number within the file used to produce the image. */ - context?: Schema$GoogleCloudVisionV1p6beta1ImageAnnotationContext; + pageNumber?: number; /** - * If present, crop hints have completed successfully. + * The URI of the file used to produce the image. */ - cropHintsAnnotation?: Schema$GoogleCloudVisionV1p6beta1CropHintsAnnotation; + uri?: string; + } + /** + * Stores image properties, such as dominant colors. + */ + export interface Schema$ImageProperties { /** - * If set, represents the error message for the operation. Note that filled-in image annotations are guaranteed to be correct, even when `error` is set. + * If present, dominant colors completed successfully. */ - error?: Schema$Status; + dominantColors?: Schema$DominantColorsAnnotation; + } + /** + * Response message for the `ImportProductSets` method. This message is returned by the google.longrunning.Operations.GetOperation method in the returned google.longrunning.Operation.response field. + */ + export interface Schema$ImportProductSetsResponse { /** - * If present, face detection has completed successfully. + * The list of reference_images that are imported successfully. */ - faceAnnotations?: Schema$GoogleCloudVisionV1p6beta1FaceAnnotation[]; + referenceImages?: Schema$ReferenceImage[]; /** - * If present, text (OCR) detection or document (OCR) text detection has completed successfully. This annotation provides the structural hierarchy for the OCR detected text. + * The rpc status for each ImportProductSet request, including both successes and errors. The number of statuses here matches the number of lines in the csv file, and statuses[i] stores the success or failure status of processing the i-th line of the csv, starting from line 0. */ - fullTextAnnotation?: Schema$GoogleCloudVisionV1p6beta1TextAnnotation; + statuses?: Schema$Status[]; + } + /** + * The desired input location and metadata. + */ + export interface Schema$InputConfig { /** - * If present, image properties were extracted successfully. + * File content, represented as a stream of bytes. Note: As with all `bytes` fields, protobuffers use a pure binary representation, whereas JSON representations use base64. Currently, this field only works for BatchAnnotateFiles requests. It does not work for AsyncBatchAnnotateFiles requests. */ - imagePropertiesAnnotation?: Schema$GoogleCloudVisionV1p6beta1ImageProperties; + content?: string; /** - * If present, image quality calculation has completed successfully. + * The Google Cloud Storage location to read the input from. */ - imageQualityAnnotation?: Schema$GoogleCloudVisionV1p6beta1ImageQuality; + gcsSource?: Schema$GcsSource; /** - * If present, label detection has completed successfully. + * The type of the file. Currently only "application/pdf", "image/tiff" and "image/gif" are supported. Wildcards are not supported. */ - labelAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; + mimeType?: string; + } + /** + * A product label represented as a key-value pair. + */ + export interface Schema$KeyValue { /** - * If present, landmark detection has completed successfully. + * The key of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. */ - landmarkAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; + key?: string; /** - * If present, localized object detection has completed successfully. This will be sorted descending by confidence score. + * The value of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. */ - localizedObjectAnnotations?: Schema$GoogleCloudVisionV1p6beta1LocalizedObjectAnnotation[]; + value?: string; + } + /** + * A face-specific landmark (for example, a face feature). + */ + export interface Schema$Landmark { /** - * If present, logo detection has completed successfully. + * Face landmark position. */ - logoAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; + position?: Schema$Position; /** - * If present, objects attributes calculation has completed successfully. The attributes value will be filled in the EntityAnnotation.properties. Example: object_attribute_annotations { properties { name: "color" value: "blue" confidence: 0.1 } properties { name: "color" value: "white" confidence: 0.2 } properties { name: "material" value: "silk" confidence: 0.3 } } + * Face landmark type. */ - objectAttributeAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; - /** - * If present, product search has completed successfully. - */ - productSearchResults?: Schema$GoogleCloudVisionV1p6beta1ProductSearchResults; + type?: string; + } + /** + * An object representing a latitude/longitude pair. This is expressed as a pair of doubles representing degrees latitude and degrees longitude. Unless specified otherwise, this must conform to the <a href="http://www.unoosa.org/pdf/icg/2012/template/WGS_84.pdf">WGS84 standard</a>. Values must be within normalized ranges. + */ + export interface Schema$LatLng { /** - * If present, image quality optimization has completed successfully. + * The latitude in degrees. It must be in the range [-90.0, +90.0]. */ - qualityOptimizationResult?: Schema$GoogleCloudVisionV1p6beta1QualityOptimizationResult; + latitude?: number; /** - * If present, safe-search annotation has completed successfully. + * The longitude in degrees. It must be in the range [-180.0, +180.0]. */ - safeSearchAnnotation?: Schema$GoogleCloudVisionV1p6beta1SafeSearchAnnotation; + longitude?: number; + } + /** + * Set of detected objects with bounding boxes. + */ + export interface Schema$LocalizedObjectAnnotation { /** - * If present, text (OCR) detection has completed successfully. + * Image region to which this object belongs. This must be populated. */ - textAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; + boundingPoly?: Schema$BoundingPoly; /** - * If present, web detection has completed successfully. + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */ - webDetection?: Schema$GoogleCloudVisionV1p6beta1WebDetection; - } - /** - * The response for a single offline file annotation request. - */ - export interface Schema$GoogleCloudVisionV1p6beta1AsyncAnnotateFileResponse { + languageCode?: string; /** - * The output location and metadata from AsyncAnnotateFileRequest. + * Object ID that should align with EntityAnnotation mid. */ - outputConfig?: Schema$GoogleCloudVisionV1p6beta1OutputConfig; - } - /** - * Response to an async batch file annotation request. - */ - export interface Schema$GoogleCloudVisionV1p6beta1AsyncBatchAnnotateFilesResponse { + mid?: string; /** - * The list of file annotation responses, one for each request in AsyncBatchAnnotateFilesRequest. + * Object name, expressed in its `language_code` language. */ - responses?: Schema$GoogleCloudVisionV1p6beta1AsyncAnnotateFileResponse[]; - } - /** - * Response to an async batch image annotation request. - */ - export interface Schema$GoogleCloudVisionV1p6beta1AsyncBatchAnnotateImagesResponse { + name?: string; /** - * The output location and metadata from AsyncBatchAnnotateImagesRequest. + * Score of the result. Range [0, 1]. */ - outputConfig?: Schema$GoogleCloudVisionV1p6beta1OutputConfig; + score?: number; } /** - * A list of file annotation responses. + * Detected entity location information. */ - export interface Schema$GoogleCloudVisionV1p6beta1BatchAnnotateFilesResponse { + export interface Schema$LocationInfo { /** - * The list of file annotation responses, each response corresponding to each AnnotateFileRequest in BatchAnnotateFilesRequest. + * lat/long location coordinates. */ - responses?: Schema$GoogleCloudVisionV1p6beta1AnnotateFileResponse[]; + latLng?: Schema$LatLng; } /** - * Metadata for the batch operations such as the current state. This is included in the `metadata` field of the `Operation` returned by the `GetOperation` call of the `google::longrunning::Operations` service. + * A vertex represents a 2D point in the image. NOTE: the normalized vertex coordinates are relative to the original image and range from 0 to 1. */ - export interface Schema$GoogleCloudVisionV1p6beta1BatchOperationMetadata { - /** - * The time when the batch request is finished and google.longrunning.Operation.done is set to true. - */ - endTime?: string; + export interface Schema$NormalizedVertex { /** - * The current state of the batch operation. + * X coordinate. */ - state?: string; + x?: number; /** - * The time when the batch request was submitted to the server. + * Y coordinate. */ - submitTime?: string; + y?: number; } /** - * Logical element on the page. + * Prediction for what the object in the bounding box is. */ - export interface Schema$GoogleCloudVisionV1p6beta1Block { - /** - * Detected block type (text, image etc) for this block. - */ - blockType?: string; + export interface Schema$ObjectAnnotation { /** - * The bounding box for the block. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */ - boundingBox?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + languageCode?: string; /** - * Confidence of the OCR results on the block. Range [0, 1]. + * Object ID that should align with EntityAnnotation mid. */ - confidence?: number; + mid?: string; /** - * List of paragraphs in this block (if this blocks is of type text). + * Object name, expressed in its `language_code` language. */ - paragraphs?: Schema$GoogleCloudVisionV1p6beta1Paragraph[]; + name?: string; /** - * Additional information detected for the block. + * Score of the result. Range [0, 1]. */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + score?: number; } /** - * A bounding polygon for the detected image annotation. + * This resource represents a long-running operation that is the result of a network API call. */ - export interface Schema$GoogleCloudVisionV1p6beta1BoundingPoly { + export interface Schema$Operation { /** - * The bounding polygon normalized vertices. + * If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available. */ - normalizedVertices?: Schema$GoogleCloudVisionV1p6beta1NormalizedVertex[]; + done?: boolean; /** - * The bounding polygon vertices. + * The error result of the operation in case of failure or cancellation. */ - vertices?: Schema$GoogleCloudVisionV1p6beta1Vertex[]; - } - /** - * Color information consists of RGB channels, score, and the fraction of the image that the color occupies in the image. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ColorInfo { + error?: Schema$Status; /** - * RGB components of the color. + * Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any. */ - color?: Schema$Color; + metadata?: {[key: string]: any}; /** - * The fraction of pixels the color occupies in the image. Value in range [0, 1]. + * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. */ - pixelFraction?: number; + name?: string; /** - * Image-specific score for this color. Value in range [0, 1]. + * The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. */ - score?: number; + response?: {[key: string]: any}; } /** - * Single crop hint that is used to generate a new crop when serving an image. + * Contains metadata for the BatchAnnotateImages operation. */ - export interface Schema$GoogleCloudVisionV1p6beta1CropHint { + export interface Schema$OperationMetadata { /** - * The bounding polygon for the crop region. The coordinates of the bounding box are in the original image's scale. + * The time when the batch request was received. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + createTime?: string; /** - * Confidence of this being a salient region. Range [0, 1]. + * Current state of the batch operation. */ - confidence?: number; + state?: string; /** - * Fraction of importance of this salient region with respect to the original image. + * The time when the operation result was last updated. */ - importanceFraction?: number; + updateTime?: string; } /** - * Set of crop hints that are used to generate new crops when serving images. + * The desired output location and metadata. */ - export interface Schema$GoogleCloudVisionV1p6beta1CropHintsAnnotation { + export interface Schema$OutputConfig { /** - * Crop hint results. + * The max number of response protos to put into each output JSON file on Google Cloud Storage. The valid range is [1, 100]. If not specified, the default value is 20. For example, for one pdf file with 100 pages, 100 response protos will be generated. If `batch_size` = 20, then 5 json files each containing 20 response protos will be written under the prefix `gcs_destination`.`uri`. Currently, batch_size only applies to GcsDestination, with potential future support for other output configurations. */ - cropHints?: Schema$GoogleCloudVisionV1p6beta1CropHint[]; - } - /** - * Set of dominant colors and their corresponding scores. - */ - export interface Schema$GoogleCloudVisionV1p6beta1DominantColorsAnnotation { + batchSize?: number; /** - * RGB color values with their score and pixel fraction. + * The Google Cloud Storage location to write the output(s) to. */ - colors?: Schema$GoogleCloudVisionV1p6beta1ColorInfo[]; + gcsDestination?: Schema$GcsDestination; } /** - * Set of detected entity features. + * Detected page from OCR. */ - export interface Schema$GoogleCloudVisionV1p6beta1EntityAnnotation { + export interface Schema$Page { /** - * Image region to which this entity belongs. Not produced for `LABEL_DETECTION` features. + * List of blocks of text, images etc on this page. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + blocks?: Schema$Block[]; /** - * **Deprecated. Use `score` instead.** The accuracy of the entity detection in an image. For example, for an image in which the "Eiffel Tower" entity is detected, this field represents the confidence that there is a tower in the query image. Range [0, 1]. + * Confidence of the OCR results on the page. Range [0, 1]. */ confidence?: number; /** - * Entity textual description, expressed in its `locale` language. + * Page height. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. */ - description?: string; + height?: number; /** - * The language code for the locale in which the entity textual `description` is expressed. + * Additional information detected on the page. */ - locale?: string; + property?: Schema$TextProperty; /** - * The location information for the detected entity. Multiple `LocationInfo` elements can be present because one location may indicate the location of the scene in the image, and another location may indicate the location of the place where the image was taken. Location information is usually present for landmarks. + * Page width. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. */ - locations?: Schema$GoogleCloudVisionV1p6beta1LocationInfo[]; + width?: number; + } + /** + * Structural unit of text representing a number of words in certain order. + */ + export interface Schema$Paragraph { /** - * Opaque entity ID. Some IDs may be available in [Google Knowledge Graph Search API](https://developers.google.com/knowledge-graph/). + * The bounding box for the paragraph. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ - mid?: string; + boundingBox?: Schema$BoundingPoly; /** - * Some entities may have optional user-supplied `Property` (name/value) fields, such a score or string that qualifies the entity. + * Confidence of the OCR results for the paragraph. Range [0, 1]. */ - properties?: Schema$GoogleCloudVisionV1p6beta1Property[]; + confidence?: number; /** - * Overall score of the result. Range [0, 1]. + * Additional information detected for the paragraph. */ - score?: number; + property?: Schema$TextProperty; /** - * The relevancy of the ICA (Image Content Annotation) label to the image. For example, the relevancy of "tower" is likely higher to an image containing the detected "Eiffel Tower" than to an image containing a detected distant towering building, even though the confidence that there is a tower in each image may be the same. Range [0, 1]. + * List of all words in this paragraph. */ - topicality?: number; + words?: Schema$Word[]; } /** - * A face annotation object contains the results of face detection. + * A 3D position in the image, used primarily for Face detection landmarks. A valid Position must have both x and y coordinates. The position coordinates are in the same scale as the original image. */ - export interface Schema$GoogleCloudVisionV1p6beta1FaceAnnotation { - /** - * Anger likelihood. - */ - angerLikelihood?: string; + export interface Schema$Position { /** - * Blurred likelihood. + * X coordinate. */ - blurredLikelihood?: string; + x?: number; /** - * The bounding polygon around the face. The coordinates of the bounding box are in the original image's scale. The bounding box is computed to "frame" the face in accordance with human expectations. It is based on the landmarker results. Note that one or more x and/or y coordinates may not be generated in the `BoundingPoly` (the polygon will be unbounded) if only a partial face appears in the image to be annotated. + * Y coordinate. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + y?: number; /** - * Detection confidence. Range [0, 1]. + * Z coordinate (or depth). */ - detectionConfidence?: number; + z?: number; + } + /** + * A Product contains ReferenceImages. + */ + export interface Schema$Product { /** - * The `fd_bounding_poly` bounding polygon is tighter than the `boundingPoly`, and encloses only the skin part of the face. Typically, it is used to eliminate the face from any image analysis that detects the "amount of skin" visible in an image. It is not based on the landmarker results, only on the initial face detection, hence the <code>fd</code> (face detection) prefix. + * User-provided metadata to be stored with this product. Must be at most 4096 characters long. */ - fdBoundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + description?: string; /** - * Headwear likelihood. + * The user-provided name for this Product. Must not be empty. Must be at most 4096 characters long. */ - headwearLikelihood?: string; + displayName?: string; /** - * Joy likelihood. + * The resource name of the product. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`. This field is ignored when creating a product. */ - joyLikelihood?: string; + name?: string; /** - * Face landmarking confidence. Range [0, 1]. + * The category for the product identified by the reference image. This should be either "homegoods-v2", "apparel-v2", or "toys-v2". The legacy categories "homegoods", "apparel", and "toys" are still supported, but these should not be used for new products. This field is immutable. */ - landmarkingConfidence?: number; + productCategory?: string; /** - * Detected face landmarks. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ - landmarks?: Schema$GoogleCloudVisionV1p6beta1FaceAnnotationLandmark[]; + productLabels?: Schema$KeyValue[]; + } + /** + * Results for a product search request. + */ + export interface Schema$ProductSearchResults { /** - * Yaw angle, which indicates the leftward/rightward angle that the face is pointing relative to the vertical plane perpendicular to the image. Range [-180,180]. + * Timestamp of the index which provided these results. Products added to the product set and products removed from the product set after this time are not reflected in the current results. */ - panAngle?: number; + indexTime?: string; /** - * Roll angle, which indicates the amount of clockwise/anti-clockwise rotation of the face relative to the image vertical about the axis perpendicular to the face. Range [-180,180]. + * List of results grouped by products detected in the query image. Each entry corresponds to one bounding polygon in the query image, and contains the matching products specific to that region. There may be duplicate product matches in the union of all the per-product results. */ - rollAngle?: number; + productGroupedResults?: Schema$GroupedResult[]; /** - * Sorrow likelihood. + * List of results, one for each product match. */ - sorrowLikelihood?: string; + results?: Schema$Result[]; + } + /** + * A `Property` consists of a user-supplied name/value pair. + */ + export interface Schema$Property { /** - * Surprise likelihood. + * Name of the property. */ - surpriseLikelihood?: string; + name?: string; /** - * Pitch angle, which indicates the upwards/downwards angle that the face is pointing relative to the image's horizontal plane. Range [-180,180]. + * Value of numeric properties. */ - tiltAngle?: number; + uint64Value?: string; /** - * Under-exposed likelihood. + * Value of the property. */ - underExposedLikelihood?: string; + value?: string; } /** - * A face-specific landmark (for example, a face feature). + * A `ReferenceImage` represents a product image and its associated metadata, such as bounding boxes. */ - export interface Schema$GoogleCloudVisionV1p6beta1FaceAnnotationLandmark { + export interface Schema$ReferenceImage { /** - * Face landmark position. + * Bounding polygons around the areas of interest in the reference image. Optional. If this field is empty, the system will try to detect regions of interest. At most 10 bounding polygons will be used. The provided shape is converted into a non-rotated rectangle. Once converted, the small edge of the rectangle must be greater than or equal to 300 pixels. The aspect ratio must be 1:4 or less (i.e. 1:3 is ok; 1:5 is not). */ - position?: Schema$GoogleCloudVisionV1p6beta1Position; + boundingPolys?: Schema$BoundingPoly[]; /** - * Face landmark type. + * The resource name of the reference image. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`. This field is ignored when creating a reference image. */ - type?: string; - } - /** - * The Google Cloud Storage location where the output will be written to. - */ - export interface Schema$GoogleCloudVisionV1p6beta1GcsDestination { + name?: string; /** - * Google Cloud Storage URI prefix where the results will be stored. Results will be in JSON format and preceded by its corresponding input URI prefix. This field can either represent a gcs file prefix or gcs directory. In either case, the uri should be unique because in order to get all of the output files, you will need to do a wildcard gcs search on the uri prefix you provide. Examples: * File Prefix: gs://bucket-name/here/filenameprefix The output files will be created in gs://bucket-name/here/ and the names of the output files will begin with "filenameprefix". * Directory Prefix: gs://bucket-name/some/location/ The output files will be created in gs://bucket-name/some/location/ and the names of the output files could be anything because there was no filename prefix specified. If multiple outputs, each response is still AnnotateFileResponse, each of which contains some subset of the full list of AnnotateImageResponse. Multiple outputs can happen if, for example, the output JSON is too large and overflows into multiple sharded files. + * The Google Cloud Storage URI of the reference image. The URI must start with `gs://`. Required. */ uri?: string; } /** - * The Google Cloud Storage location where the input will be read from. + * Information about a product. */ - export interface Schema$GoogleCloudVisionV1p6beta1GcsSource { + export interface Schema$Result { /** - * Google Cloud Storage URI for the input file. This must only be a Google Cloud Storage object. Wildcards are not currently supported. + * The resource name of the image from the product that is the closest match to the query. */ - uri?: string; - } - /** - * If an image was produced from a file (e.g. a PDF), this message gives information about the source of that image. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ImageAnnotationContext { + image?: string; /** - * If the file was a PDF or TIFF, this field gives the page number within the file used to produce the image. + * The Product. */ - pageNumber?: number; + product?: Schema$Product; /** - * The URI of the file used to produce the image. + * A confidence level on the match, ranging from 0 (no confidence) to 1 (full confidence). */ - uri?: string; + score?: number; } /** - * Stores image properties, such as dominant colors. + * Set of features pertaining to the image, computed by computer vision methods over safe-search verticals (for example, adult, spoof, medical, violence). */ - export interface Schema$GoogleCloudVisionV1p6beta1ImageProperties { + export interface Schema$SafeSearchAnnotation { /** - * If present, dominant colors completed successfully. + * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. */ - dominantColors?: Schema$GoogleCloudVisionV1p6beta1DominantColorsAnnotation; - } - /** - * Stores image quality scores, could be aesthetic quality or technical quality. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ImageQuality {} - /** - * Response message for the `ImportProductSets` method. This message is returned by the google.longrunning.Operations.GetOperation method in the returned google.longrunning.Operation.response field. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ImportProductSetsResponse { + adult?: string; /** - * The list of reference_images that are imported successfully. + * Confidence of adult_score. Range [0, 1]. 0 means not confident, 1 means very confident. */ - referenceImages?: Schema$GoogleCloudVisionV1p6beta1ReferenceImage[]; + adultConfidence?: number; /** - * The rpc status for each ImportProductSet request, including both successes and errors. The number of statuses here matches the number of lines in the csv file, and statuses[i] stores the success or failure status of processing the i-th line of the csv, starting from line 0. + * Likelihood that this is a medical image. */ - statuses?: Schema$Status[]; - } - /** - * The desired input location and metadata. - */ - export interface Schema$GoogleCloudVisionV1p6beta1InputConfig { + medical?: string; /** - * File content, represented as a stream of bytes. Note: As with all `bytes` fields, protobuffers use a pure binary representation, whereas JSON representations use base64. Currently, this field only works for BatchAnnotateFiles requests. It does not work for AsyncBatchAnnotateFiles requests. + * Confidence of medical_score. Range [0, 1]. 0 means not confident, 1 means very confident. */ - content?: string; + medicalConfidence?: number; /** - * The Google Cloud Storage location to read the input from. + * Confidence of nsfw_score. Range [0, 1]. 0 means not confident, 1 means very confident. */ - gcsSource?: Schema$GoogleCloudVisionV1p6beta1GcsSource; + nsfwConfidence?: number; /** - * The type of the file. Currently only "application/pdf", "image/tiff" and "image/gif" are supported. Wildcards are not supported. + * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. */ - mimeType?: string; - } - /** - * Set of detected objects with bounding boxes. - */ - export interface Schema$GoogleCloudVisionV1p6beta1LocalizedObjectAnnotation { + racy?: string; /** - * Image region to which this object belongs. This must be populated. + * Confidence of racy_score. Range [0, 1]. 0 means not confident, 1 means very confident. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + racyConfidence?: number; /** - * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. */ - languageCode?: string; + spoof?: string; /** - * Object ID that should align with EntityAnnotation mid. + * Confidence of spoof_score. Range [0, 1]. 0 means not confident, 1 means very confident. */ - mid?: string; + spoofConfidence?: number; /** - * Object name, expressed in its `language_code` language. + * Likelihood that this image contains violent content. */ - name?: string; + violence?: string; /** - * Score of the result. Range [0, 1]. + * Confidence of violence_score. Range [0, 1]. 0 means not confident, 1 means very confident. */ - score?: number; + violenceConfidence?: number; } /** - * Detected entity location information. + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). */ - export interface Schema$GoogleCloudVisionV1p6beta1LocationInfo { + export interface Schema$Status { /** - * lat/long location coordinates. + * The status code, which should be an enum value of google.rpc.Code. */ - latLng?: Schema$LatLng; - } - /** - * A vertex represents a 2D point in the image. NOTE: the normalized vertex coordinates are relative to the original image and range from 0 to 1. - */ - export interface Schema$GoogleCloudVisionV1p6beta1NormalizedVertex { + code?: number; /** - * X coordinate. + * A list of messages that carry the error details. There is a common set of message types for APIs to use. */ - x?: number; + details?: Array<{[key: string]: any}>; /** - * Y coordinate. + * A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. */ - y?: number; + message?: string; } /** - * Contains metadata for the BatchAnnotateImages operation. + * A single symbol representation. */ - export interface Schema$GoogleCloudVisionV1p6beta1OperationMetadata { - /** - * The time when the batch request was received. - */ - createTime?: string; + export interface Schema$Symbol { /** - * Current state of the batch operation. + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ - state?: string; + boundingBox?: Schema$BoundingPoly; /** - * The time when the operation result was last updated. + * Confidence of the OCR results for the symbol. Range [0, 1]. */ - updateTime?: string; - } - /** - * The desired output location and metadata. - */ - export interface Schema$GoogleCloudVisionV1p6beta1OutputConfig { + confidence?: number; /** - * The max number of response protos to put into each output JSON file on Google Cloud Storage. The valid range is [1, 100]. If not specified, the default value is 20. For example, for one pdf file with 100 pages, 100 response protos will be generated. If `batch_size` = 20, then 5 json files each containing 20 response protos will be written under the prefix `gcs_destination`.`uri`. Currently, batch_size only applies to GcsDestination, with potential future support for other output configurations. + * Additional information detected for the symbol. */ - batchSize?: number; + property?: Schema$TextProperty; /** - * The Google Cloud Storage location to write the output(s) to. + * The actual UTF-8 representation of the symbol. */ - gcsDestination?: Schema$GoogleCloudVisionV1p6beta1GcsDestination; + text?: string; } /** - * Detected page from OCR. + * TextAnnotation contains a structured representation of OCR extracted text. The hierarchy of an OCR extracted text structure is like this: TextAnnotation -> Page -> Block -> Paragraph -> Word -> Symbol Each structural component, starting from Page, may further have their own properties. Properties describe detected languages, breaks etc.. Please refer to the TextAnnotation.TextProperty message definition below for more detail. */ - export interface Schema$GoogleCloudVisionV1p6beta1Page { - /** - * List of blocks of text, images etc on this page. - */ - blocks?: Schema$GoogleCloudVisionV1p6beta1Block[]; - /** - * Confidence of the OCR results on the page. Range [0, 1]. - */ - confidence?: number; - /** - * Page height. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. - */ - height?: number; + export interface Schema$TextAnnotation { /** - * Additional information detected on the page. + * List of pages detected by OCR. */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + pages?: Schema$Page[]; /** - * Page width. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. + * UTF-8 text detected on the pages. */ - width?: number; + text?: string; } /** - * Structural unit of text representing a number of words in certain order. + * Additional information detected on the structural component. */ - export interface Schema$GoogleCloudVisionV1p6beta1Paragraph { - /** - * The bounding box for the paragraph. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; - /** - * Confidence of the OCR results for the paragraph. Range [0, 1]. - */ - confidence?: number; + export interface Schema$TextProperty { /** - * Additional information detected for the paragraph. + * Detected start or end of a text segment. */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + detectedBreak?: Schema$DetectedBreak; /** - * List of words in this paragraph. + * A list of detected languages together with confidence. */ - words?: Schema$GoogleCloudVisionV1p6beta1Word[]; + detectedLanguages?: Schema$DetectedLanguage[]; } /** - * A 3D position in the image, used primarily for Face detection landmarks. A valid Position must have both x and y coordinates. The position coordinates are in the same scale as the original image. + * A vertex represents a 2D point in the image. NOTE: the vertex coordinates are in the same scale as the original image. */ - export interface Schema$GoogleCloudVisionV1p6beta1Position { + export interface Schema$Vertex { /** * X coordinate. */ @@ -5743,993 +5943,1019 @@ export namespace vision_v1p1beta1 { * Y coordinate. */ y?: number; - /** - * Z coordinate (or depth). - */ - z?: number; } /** - * A Product contains ReferenceImages. + * Relevant information for the image from the Internet. */ - export interface Schema$GoogleCloudVisionV1p6beta1Product { - /** - * User-provided metadata to be stored with this product. Must be at most 4096 characters long. - */ - description?: string; + export interface Schema$WebDetection { /** - * The user-provided name for this Product. Must not be empty. Must be at most 4096 characters long. + * The service's best guess as to the topic of the request image. Inferred from similar images on the open web. */ - displayName?: string; + bestGuessLabels?: Schema$WebLabel[]; /** - * The resource name of the product. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`. This field is ignored when creating a product. + * Fully matching images from the Internet. Can include resized copies of the query image. */ - name?: string; + fullMatchingImages?: Schema$WebImage[]; /** - * The category for the product identified by the reference image. This should be either "homegoods-v2", "apparel-v2", or "toys-v2". The legacy categories "homegoods", "apparel", and "toys" are still supported, but these should not be used for new products. This field is immutable. + * Web pages containing the matching images from the Internet. */ - productCategory?: string; + pagesWithMatchingImages?: Schema$WebPage[]; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Partial matching images from the Internet. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. */ - productLabels?: Schema$GoogleCloudVisionV1p6beta1ProductKeyValue[]; - } - /** - * A product label represented as a key-value pair. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ProductKeyValue { + partialMatchingImages?: Schema$WebImage[]; /** - * The key of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. + * The visually similar image results. */ - key?: string; + visuallySimilarImages?: Schema$WebImage[]; /** - * The value of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. + * Deduced entities from similar images on the Internet. */ - value?: string; + webEntities?: Schema$WebEntity[]; } /** - * Results for a product search request. + * Entity deduced from similar images on the Internet. */ - export interface Schema$GoogleCloudVisionV1p6beta1ProductSearchResults { + export interface Schema$WebEntity { /** - * Timestamp of the index which provided these results. Products added to the product set and products removed from the product set after this time are not reflected in the current results. + * Canonical description of the entity, in English. */ - indexTime?: string; + description?: string; /** - * List of results grouped by products detected in the query image. Each entry corresponds to one bounding polygon in the query image, and contains the matching products specific to that region. There may be duplicate product matches in the union of all the per-product results. + * Opaque entity ID. */ - productGroupedResults?: Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsGroupedResult[]; + entityId?: string; /** - * List of results, one for each product match. + * Overall relevancy score for the entity. Not normalized and not comparable across different image queries. */ - results?: Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsResult[]; + score?: number; } /** - * Information about the products similar to a single product in a query image. + * Metadata for online images. */ - export interface Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsGroupedResult { + export interface Schema$WebImage { /** - * The bounding polygon around the product detected in the query image. + * (Deprecated) Overall relevancy score for the image. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + score?: number; /** - * List of results, one for each product match. + * The result image URL. */ - results?: Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsResult[]; + url?: string; } /** - * Information about a product. + * Label to provide extra metadata for the web detection. */ - export interface Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsResult { - /** - * The resource name of the image from the product that is the closest match to the query. - */ - image?: string; + export interface Schema$WebLabel { /** - * The Product. + * Label for extra metadata. */ - product?: Schema$GoogleCloudVisionV1p6beta1Product; + label?: string; /** - * A confidence level on the match, ranging from 0 (no confidence) to 1 (full confidence). + * The BCP-47 language code for `label`, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */ - score?: number; + languageCode?: string; } /** - * A `Property` consists of a user-supplied name/value pair. + * Metadata for web pages. */ - export interface Schema$GoogleCloudVisionV1p6beta1Property { + export interface Schema$WebPage { /** - * Value in range [0..1]. Confidence of this property value. + * Fully matching images on the page. Can include resized copies of the query image. */ - confidence?: number; + fullMatchingImages?: Schema$WebImage[]; /** - * Opaque property value ID. Some IDs may be available in [Google Knowledge Graph Search API](https://developers.google.com/knowledge-graph/). An example property for a blue coat would be: Property { name: 'color' value: 'blue' mid: '/m/01g5v' // For color blue } + * Title for the web page, may contain HTML markups. */ - mid?: string; + pageTitle?: string; /** - * Name of the property. + * Partial matching images on the page. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. */ - name?: string; + partialMatchingImages?: Schema$WebImage[]; /** - * Value of numeric properties. + * (Deprecated) Overall relevancy score for the web page. */ - uint64Value?: string; + score?: number; /** - * Value of the property. + * The result web page URL. */ - value?: string; + url?: string; } /** - * Stores enhanced image bytes. + * A word representation. */ - export interface Schema$GoogleCloudVisionV1p6beta1QualityOptimizationResult { + export interface Schema$Word { /** - * Optimized image bytes. - */ - image?: string; - /** - * Mime type of the output image. - */ - mimeType?: string; - /** - * Required optimization type. + * The bounding box for the word. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ - qualityOptimizationType?: string; - } - /** - * A `ReferenceImage` represents a product image and its associated metadata, such as bounding boxes. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ReferenceImage { + boundingBox?: Schema$BoundingPoly; /** - * Bounding polygons around the areas of interest in the reference image. Optional. If this field is empty, the system will try to detect regions of interest. At most 10 bounding polygons will be used. The provided shape is converted into a non-rotated rectangle. Once converted, the small edge of the rectangle must be greater than or equal to 300 pixels. The aspect ratio must be 1:4 or less (i.e. 1:3 is ok; 1:5 is not). + * Confidence of the OCR results for the word. Range [0, 1]. */ - boundingPolys?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly[]; + confidence?: number; /** - * The resource name of the reference image. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`. This field is ignored when creating a reference image. + * Additional information detected for the word. */ - name?: string; + property?: Schema$TextProperty; /** - * The Google Cloud Storage URI of the reference image. The URI must start with `gs://`. Required. + * List of symbols in the word. The order of the symbols follows the natural reading order. */ - uri?: string; + symbols?: Schema$Symbol[]; } - /** - * Set of features pertaining to the image, computed by computer vision methods over safe-search verticals (for example, adult, spoof, medical, violence). - */ - export interface Schema$GoogleCloudVisionV1p6beta1SafeSearchAnnotation { - /** - * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. - */ - adult?: string; - /** - * Likelihood that this is a medical image. - */ - medical?: string; - /** - * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. - */ - racy?: string; + + export class Resource$Files { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + /** - * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. + * vision.files.annotate + * @desc Service that performs image detection and annotation for a batch of files. Now only "application/pdf", "image/tiff" and "image/gif" are supported. This service will extract at most 5 (customers can specify which 5 in AnnotateFileRequest.pages) frames (gif) or pages (pdf or tiff) from each file provided and perform detection and annotation for each image extracted. + * @alias vision.files.annotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().GoogleCloudVisionV1p1beta1BatchAnnotateFilesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - spoof?: string; + annotate( + params?: Params$Resource$Files$Annotate, + options?: MethodOptions + ): GaxiosPromise< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + >; + annotate( + params: Params$Resource$Files$Annotate, + options: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + >, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + > + ): void; + annotate( + params: Params$Resource$Files$Annotate, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + > + ): void; + annotate( + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + > + ): void; + annotate( + paramsOrCallback?: + | Params$Resource$Files$Annotate + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + >, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + >, + callback?: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + > + ): void | GaxiosPromise< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + > { + let params = (paramsOrCallback || {}) as Params$Resource$Files$Annotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Files$Annotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1p1beta1/files:annotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + >(parameters, callback); + } else { + return createAPIRequest< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + >(parameters); + } + } + /** - * Likelihood that this image contains violent content. + * vision.files.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of generic files, such as PDF files, which may contain multiple pages and multiple images per page. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results). + * @alias vision.files.asyncBatchAnnotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().GoogleCloudVisionV1p1beta1AsyncBatchAnnotateFilesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - violence?: string; + asyncBatchAnnotate( + params?: Params$Resource$Files$Asyncbatchannotate, + options?: MethodOptions + ): GaxiosPromise; + asyncBatchAnnotate( + params: Params$Resource$Files$Asyncbatchannotate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate( + params: Params$Resource$Files$Asyncbatchannotate, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( + paramsOrCallback?: + | Params$Resource$Files$Asyncbatchannotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Files$Asyncbatchannotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Files$Asyncbatchannotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1p1beta1/files:asyncBatchAnnotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } - /** - * A single symbol representation. - */ - export interface Schema$GoogleCloudVisionV1p6beta1Symbol { - /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; - /** - * Confidence of the OCR results for the symbol. Range [0, 1]. - */ - confidence?: number; + + export interface Params$Resource$Files$Annotate extends StandardParameters { /** - * Additional information detected for the symbol. + * Auth client or API Key for the request */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * The actual UTF-8 representation of the symbol. + * Request body metadata */ - text?: string; + requestBody?: Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesRequest; } - /** - * TextAnnotation contains a structured representation of OCR extracted text. The hierarchy of an OCR extracted text structure is like this: TextAnnotation -> Page -> Block -> Paragraph -> Word -> Symbol Each structural component, starting from Page, may further have their own properties. Properties describe detected languages, breaks etc.. Please refer to the TextAnnotation.TextProperty message definition below for more detail. - */ - export interface Schema$GoogleCloudVisionV1p6beta1TextAnnotation { + export interface Params$Resource$Files$Asyncbatchannotate + extends StandardParameters { /** - * List of pages detected by OCR. + * Auth client or API Key for the request */ - pages?: Schema$GoogleCloudVisionV1p6beta1Page[]; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * UTF-8 text detected on the pages. + * Request body metadata */ - text?: string; + requestBody?: Schema$GoogleCloudVisionV1p1beta1AsyncBatchAnnotateFilesRequest; } - /** - * Detected start or end of a structural component. - */ - export interface Schema$GoogleCloudVisionV1p6beta1TextAnnotationDetectedBreak { - /** - * True if break prepends the element. - */ - isPrefix?: boolean; - /** - * Detected break type. - */ - type?: string; - } - /** - * Detected language for a structural component. - */ - export interface Schema$GoogleCloudVisionV1p6beta1TextAnnotationDetectedLanguage { - /** - * Confidence of detected language. Range [0, 1]. - */ - confidence?: number; - /** - * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. - */ - languageCode?: string; - } - /** - * Additional information detected on the structural component. - */ - export interface Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty { - /** - * Detected start or end of a text segment. - */ - detectedBreak?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationDetectedBreak; - /** - * A list of detected languages together with confidence. - */ - detectedLanguages?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationDetectedLanguage[]; - } - /** - * A vertex represents a 2D point in the image. NOTE: the vertex coordinates are in the same scale as the original image. - */ - export interface Schema$GoogleCloudVisionV1p6beta1Vertex { - /** - * X coordinate. - */ - x?: number; - /** - * Y coordinate. - */ - y?: number; - } - /** - * Relevant information for the image from the Internet. - */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetection { - /** - * The service's best guess as to the topic of the request image. Inferred from similar images on the open web. - */ - bestGuessLabels?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebLabel[]; - /** - * Fully matching images from the Internet. Can include resized copies of the query image. - */ - fullMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; - /** - * Web pages containing the matching images from the Internet. - */ - pagesWithMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebPage[]; - /** - * Partial matching images from the Internet. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. - */ - partialMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; - /** - * The visually similar image results. - */ - visuallySimilarImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; - /** - * Deduced entities from similar images on the Internet. - */ - webEntities?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebEntity[]; - } - /** - * Entity deduced from similar images on the Internet. - */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetectionWebEntity { - /** - * Canonical description of the entity, in English. - */ - description?: string; - /** - * Opaque entity ID. - */ - entityId?: string; - /** - * Overall relevancy score for the entity. Not normalized and not comparable across different image queries. - */ - score?: number; - } - /** - * Metadata for online images. - */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage { - /** - * (Deprecated) Overall relevancy score for the image. - */ - score?: number; - /** - * The result image URL. - */ - url?: string; - } - /** - * Label to provide extra metadata for the web detection. - */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetectionWebLabel { - /** - * Label for extra metadata. - */ - label?: string; - /** - * The BCP-47 language code for `label`, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. - */ - languageCode?: string; - } - /** - * Metadata for web pages. - */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetectionWebPage { - /** - * Fully matching images on the page. Can include resized copies of the query image. - */ - fullMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; - /** - * Title for the web page, may contain HTML markups. - */ - pageTitle?: string; - /** - * Partial matching images on the page. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. - */ - partialMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; - /** - * (Deprecated) Overall relevancy score for the web page. - */ - score?: number; - /** - * The result web page URL. - */ - url?: string; - } - /** - * A word representation. - */ - export interface Schema$GoogleCloudVisionV1p6beta1Word { - /** - * The bounding box for the word. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; - /** - * Confidence of the OCR results for the word. Range [0, 1]. - */ - confidence?: number; - /** - * Additional information detected for the word. - */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; - /** - * List of symbols in the word. The order of the symbols follows the natural reading order. - */ - symbols?: Schema$GoogleCloudVisionV1p6beta1Symbol[]; - } - /** - * Information about the products similar to a single product in a query image. - */ - export interface Schema$GroupedResult { - /** - * The bounding polygon around the product detected in the query image. - */ - boundingPoly?: Schema$BoundingPoly; - /** - * List of results, one for each product match. - */ - results?: Schema$Result[]; - } - /** - * If an image was produced from a file (e.g. a PDF), this message gives information about the source of that image. - */ - export interface Schema$ImageAnnotationContext { - /** - * If the file was a PDF or TIFF, this field gives the page number within the file used to produce the image. - */ - pageNumber?: number; - /** - * The URI of the file used to produce the image. - */ - uri?: string; - } - /** - * Stores image properties, such as dominant colors. - */ - export interface Schema$ImageProperties { - /** - * If present, dominant colors completed successfully. - */ - dominantColors?: Schema$DominantColorsAnnotation; - } - /** - * Response message for the `ImportProductSets` method. This message is returned by the google.longrunning.Operations.GetOperation method in the returned google.longrunning.Operation.response field. - */ - export interface Schema$ImportProductSetsResponse { - /** - * The list of reference_images that are imported successfully. - */ - referenceImages?: Schema$ReferenceImage[]; - /** - * The rpc status for each ImportProductSet request, including both successes and errors. The number of statuses here matches the number of lines in the csv file, and statuses[i] stores the success or failure status of processing the i-th line of the csv, starting from line 0. - */ - statuses?: Schema$Status[]; - } - /** - * The desired input location and metadata. - */ - export interface Schema$InputConfig { - /** - * File content, represented as a stream of bytes. Note: As with all `bytes` fields, protobuffers use a pure binary representation, whereas JSON representations use base64. Currently, this field only works for BatchAnnotateFiles requests. It does not work for AsyncBatchAnnotateFiles requests. - */ - content?: string; - /** - * The Google Cloud Storage location to read the input from. - */ - gcsSource?: Schema$GcsSource; - /** - * The type of the file. Currently only "application/pdf", "image/tiff" and "image/gif" are supported. Wildcards are not supported. - */ - mimeType?: string; - } - /** - * A product label represented as a key-value pair. - */ - export interface Schema$KeyValue { - /** - * The key of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. - */ - key?: string; - /** - * The value of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. - */ - value?: string; - } - /** - * A face-specific landmark (for example, a face feature). - */ - export interface Schema$Landmark { - /** - * Face landmark position. - */ - position?: Schema$Position; - /** - * Face landmark type. - */ - type?: string; - } - /** - * An object representing a latitude/longitude pair. This is expressed as a pair of doubles representing degrees latitude and degrees longitude. Unless specified otherwise, this must conform to the <a href="http://www.unoosa.org/pdf/icg/2012/template/WGS_84.pdf">WGS84 standard</a>. Values must be within normalized ranges. - */ - export interface Schema$LatLng { - /** - * The latitude in degrees. It must be in the range [-90.0, +90.0]. - */ - latitude?: number; - /** - * The longitude in degrees. It must be in the range [-180.0, +180.0]. - */ - longitude?: number; - } - /** - * Set of detected objects with bounding boxes. - */ - export interface Schema$LocalizedObjectAnnotation { - /** - * Image region to which this object belongs. This must be populated. - */ - boundingPoly?: Schema$BoundingPoly; - /** - * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. - */ - languageCode?: string; - /** - * Object ID that should align with EntityAnnotation mid. - */ - mid?: string; - /** - * Object name, expressed in its `language_code` language. - */ - name?: string; - /** - * Score of the result. Range [0, 1]. - */ - score?: number; - } - /** - * Detected entity location information. - */ - export interface Schema$LocationInfo { - /** - * lat/long location coordinates. - */ - latLng?: Schema$LatLng; - } - /** - * A vertex represents a 2D point in the image. NOTE: the normalized vertex coordinates are relative to the original image and range from 0 to 1. - */ - export interface Schema$NormalizedVertex { - /** - * X coordinate. - */ - x?: number; - /** - * Y coordinate. - */ - y?: number; - } - /** - * This resource represents a long-running operation that is the result of a network API call. - */ - export interface Schema$Operation { - /** - * If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available. - */ - done?: boolean; - /** - * The error result of the operation in case of failure or cancellation. - */ - error?: Schema$Status; - /** - * Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any. - */ - metadata?: {[key: string]: any}; - /** - * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. - */ - name?: string; - /** - * The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. - */ - response?: {[key: string]: any}; - } - /** - * Contains metadata for the BatchAnnotateImages operation. - */ - export interface Schema$OperationMetadata { - /** - * The time when the batch request was received. - */ - createTime?: string; - /** - * Current state of the batch operation. - */ - state?: string; - /** - * The time when the operation result was last updated. - */ - updateTime?: string; - } - /** - * The desired output location and metadata. - */ - export interface Schema$OutputConfig { - /** - * The max number of response protos to put into each output JSON file on Google Cloud Storage. The valid range is [1, 100]. If not specified, the default value is 20. For example, for one pdf file with 100 pages, 100 response protos will be generated. If `batch_size` = 20, then 5 json files each containing 20 response protos will be written under the prefix `gcs_destination`.`uri`. Currently, batch_size only applies to GcsDestination, with potential future support for other output configurations. - */ - batchSize?: number; - /** - * The Google Cloud Storage location to write the output(s) to. - */ - gcsDestination?: Schema$GcsDestination; - } - /** - * Detected page from OCR. - */ - export interface Schema$Page { - /** - * List of blocks of text, images etc on this page. - */ - blocks?: Schema$Block[]; - /** - * Confidence of the OCR results on the page. Range [0, 1]. - */ - confidence?: number; - /** - * Page height. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. - */ - height?: number; - /** - * Additional information detected on the page. - */ - property?: Schema$TextProperty; - /** - * Page width. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. - */ - width?: number; - } - /** - * Structural unit of text representing a number of words in certain order. - */ - export interface Schema$Paragraph { - /** - * The bounding box for the paragraph. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$BoundingPoly; - /** - * Confidence of the OCR results for the paragraph. Range [0, 1]. - */ - confidence?: number; - /** - * Additional information detected for the paragraph. - */ - property?: Schema$TextProperty; - /** - * List of words in this paragraph. - */ - words?: Schema$Word[]; - } - /** - * A 3D position in the image, used primarily for Face detection landmarks. A valid Position must have both x and y coordinates. The position coordinates are in the same scale as the original image. - */ - export interface Schema$Position { - /** - * X coordinate. - */ - x?: number; - /** - * Y coordinate. - */ - y?: number; - /** - * Z coordinate (or depth). - */ - z?: number; - } - /** - * A Product contains ReferenceImages. - */ - export interface Schema$Product { - /** - * User-provided metadata to be stored with this product. Must be at most 4096 characters long. - */ - description?: string; - /** - * The user-provided name for this Product. Must not be empty. Must be at most 4096 characters long. - */ - displayName?: string; - /** - * The resource name of the product. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`. This field is ignored when creating a product. - */ - name?: string; - /** - * The category for the product identified by the reference image. This should be either "homegoods-v2", "apparel-v2", or "toys-v2". The legacy categories "homegoods", "apparel", and "toys" are still supported, but these should not be used for new products. This field is immutable. - */ - productCategory?: string; - /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. - */ - productLabels?: Schema$KeyValue[]; - } - /** - * Results for a product search request. - */ - export interface Schema$ProductSearchResults { - /** - * Timestamp of the index which provided these results. Products added to the product set and products removed from the product set after this time are not reflected in the current results. - */ - indexTime?: string; - /** - * List of results grouped by products detected in the query image. Each entry corresponds to one bounding polygon in the query image, and contains the matching products specific to that region. There may be duplicate product matches in the union of all the per-product results. - */ - productGroupedResults?: Schema$GroupedResult[]; - /** - * List of results, one for each product match. - */ - results?: Schema$Result[]; - } - /** - * A `Property` consists of a user-supplied name/value pair. - */ - export interface Schema$Property { - /** - * Name of the property. - */ - name?: string; - /** - * Value of numeric properties. - */ - uint64Value?: string; - /** - * Value of the property. - */ - value?: string; - } - /** - * A `ReferenceImage` represents a product image and its associated metadata, such as bounding boxes. - */ - export interface Schema$ReferenceImage { - /** - * Bounding polygons around the areas of interest in the reference image. Optional. If this field is empty, the system will try to detect regions of interest. At most 10 bounding polygons will be used. The provided shape is converted into a non-rotated rectangle. Once converted, the small edge of the rectangle must be greater than or equal to 300 pixels. The aspect ratio must be 1:4 or less (i.e. 1:3 is ok; 1:5 is not). - */ - boundingPolys?: Schema$BoundingPoly[]; - /** - * The resource name of the reference image. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`. This field is ignored when creating a reference image. - */ - name?: string; - /** - * The Google Cloud Storage URI of the reference image. The URI must start with `gs://`. Required. - */ - uri?: string; - } - /** - * Information about a product. - */ - export interface Schema$Result { - /** - * The resource name of the image from the product that is the closest match to the query. - */ - image?: string; - /** - * The Product. - */ - product?: Schema$Product; - /** - * A confidence level on the match, ranging from 0 (no confidence) to 1 (full confidence). - */ - score?: number; - } - /** - * Set of features pertaining to the image, computed by computer vision methods over safe-search verticals (for example, adult, spoof, medical, violence). - */ - export interface Schema$SafeSearchAnnotation { - /** - * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. - */ - adult?: string; - /** - * Likelihood that this is a medical image. - */ - medical?: string; - /** - * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. - */ - racy?: string; - /** - * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. - */ - spoof?: string; - /** - * Likelihood that this image contains violent content. - */ - violence?: string; - } - /** - * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). - */ - export interface Schema$Status { - /** - * The status code, which should be an enum value of google.rpc.Code. - */ - code?: number; - /** - * A list of messages that carry the error details. There is a common set of message types for APIs to use. - */ - details?: Array<{[key: string]: any}>; - /** - * A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. - */ - message?: string; - } - /** - * A single symbol representation. - */ - export interface Schema$Symbol { - /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$BoundingPoly; - /** - * Confidence of the OCR results for the symbol. Range [0, 1]. - */ - confidence?: number; + + export class Resource$Images { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + /** - * Additional information detected for the symbol. + * vision.images.annotate + * @desc Run image detection and annotation for a batch of images. + * @alias vision.images.annotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().GoogleCloudVisionV1p1beta1BatchAnnotateImagesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - property?: Schema$TextProperty; + annotate( + params?: Params$Resource$Images$Annotate, + options?: MethodOptions + ): GaxiosPromise< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + >; + annotate( + params: Params$Resource$Images$Annotate, + options: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + >, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + > + ): void; + annotate( + params: Params$Resource$Images$Annotate, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + > + ): void; + annotate( + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + > + ): void; + annotate( + paramsOrCallback?: + | Params$Resource$Images$Annotate + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + >, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + >, + callback?: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + > + ): void | GaxiosPromise< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + > { + let params = (paramsOrCallback || {}) as Params$Resource$Images$Annotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Images$Annotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1p1beta1/images:annotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + >(parameters, callback); + } else { + return createAPIRequest< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + >(parameters); + } + } + /** - * The actual UTF-8 representation of the symbol. + * vision.images.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of images. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateImagesResponse` (results). This service will write image annotation outputs to json files in customer GCS bucket, each json file containing BatchAnnotateImagesResponse proto. + * @alias vision.images.asyncBatchAnnotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().GoogleCloudVisionV1p1beta1AsyncBatchAnnotateImagesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - text?: string; + asyncBatchAnnotate( + params?: Params$Resource$Images$Asyncbatchannotate, + options?: MethodOptions + ): GaxiosPromise; + asyncBatchAnnotate( + params: Params$Resource$Images$Asyncbatchannotate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate( + params: Params$Resource$Images$Asyncbatchannotate, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( + paramsOrCallback?: + | Params$Resource$Images$Asyncbatchannotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Images$Asyncbatchannotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Images$Asyncbatchannotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1p1beta1/images:asyncBatchAnnotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } - /** - * TextAnnotation contains a structured representation of OCR extracted text. The hierarchy of an OCR extracted text structure is like this: TextAnnotation -> Page -> Block -> Paragraph -> Word -> Symbol Each structural component, starting from Page, may further have their own properties. Properties describe detected languages, breaks etc.. Please refer to the TextAnnotation.TextProperty message definition below for more detail. - */ - export interface Schema$TextAnnotation { + + export interface Params$Resource$Images$Annotate extends StandardParameters { /** - * List of pages detected by OCR. + * Auth client or API Key for the request */ - pages?: Schema$Page[]; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * UTF-8 text detected on the pages. + * Request body metadata */ - text?: string; + requestBody?: Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesRequest; } - /** - * Additional information detected on the structural component. - */ - export interface Schema$TextProperty { + export interface Params$Resource$Images$Asyncbatchannotate + extends StandardParameters { /** - * Detected start or end of a text segment. + * Auth client or API Key for the request */ - detectedBreak?: Schema$DetectedBreak; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * A list of detected languages together with confidence. + * Request body metadata */ - detectedLanguages?: Schema$DetectedLanguage[]; + requestBody?: Schema$GoogleCloudVisionV1p1beta1AsyncBatchAnnotateImagesRequest; } - /** - * A vertex represents a 2D point in the image. NOTE: the vertex coordinates are in the same scale as the original image. - */ - export interface Schema$Vertex { + + export class Resource$Projects { + context: APIRequestContext; + files: Resource$Projects$Files; + images: Resource$Projects$Images; + locations: Resource$Projects$Locations; + constructor(context: APIRequestContext) { + this.context = context; + this.files = new Resource$Projects$Files(this.context); + this.images = new Resource$Projects$Images(this.context); + this.locations = new Resource$Projects$Locations(this.context); + } + } + + export class Resource$Projects$Files { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + /** - * X coordinate. + * vision.projects.files.annotate + * @desc Service that performs image detection and annotation for a batch of files. Now only "application/pdf", "image/tiff" and "image/gif" are supported. This service will extract at most 5 (customers can specify which 5 in AnnotateFileRequest.pages) frames (gif) or pages (pdf or tiff) from each file provided and perform detection and annotation for each image extracted. + * @alias vision.projects.files.annotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().GoogleCloudVisionV1p1beta1BatchAnnotateFilesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - x?: number; + annotate( + params?: Params$Resource$Projects$Files$Annotate, + options?: MethodOptions + ): GaxiosPromise< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + >; + annotate( + params: Params$Resource$Projects$Files$Annotate, + options: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + >, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + > + ): void; + annotate( + params: Params$Resource$Projects$Files$Annotate, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + > + ): void; + annotate( + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + > + ): void; + annotate( + paramsOrCallback?: + | Params$Resource$Projects$Files$Annotate + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + >, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + >, + callback?: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + > + ): void | GaxiosPromise< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + > { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Files$Annotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Files$Annotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1p1beta1/{+parent}/files:annotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + >(parameters, callback); + } else { + return createAPIRequest< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse + >(parameters); + } + } + /** - * Y coordinate. + * vision.projects.files.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of generic files, such as PDF files, which may contain multiple pages and multiple images per page. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results). + * @alias vision.projects.files.asyncBatchAnnotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().GoogleCloudVisionV1p1beta1AsyncBatchAnnotateFilesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - y?: number; + asyncBatchAnnotate( + params?: Params$Resource$Projects$Files$Asyncbatchannotate, + options?: MethodOptions + ): GaxiosPromise; + asyncBatchAnnotate( + params: Params$Resource$Projects$Files$Asyncbatchannotate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate( + params: Params$Resource$Projects$Files$Asyncbatchannotate, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( + paramsOrCallback?: + | Params$Resource$Projects$Files$Asyncbatchannotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Files$Asyncbatchannotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Files$Asyncbatchannotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + '/v1p1beta1/{+parent}/files:asyncBatchAnnotate' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } - /** - * Relevant information for the image from the Internet. - */ - export interface Schema$WebDetection { + + export interface Params$Resource$Projects$Files$Annotate + extends StandardParameters { /** - * The service's best guess as to the topic of the request image. Inferred from similar images on the open web. + * Auth client or API Key for the request */ - bestGuessLabels?: Schema$WebLabel[]; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * Fully matching images from the Internet. Can include resized copies of the query image. + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. */ - fullMatchingImages?: Schema$WebImage[]; + parent?: string; + /** - * Web pages containing the matching images from the Internet. + * Request body metadata */ - pagesWithMatchingImages?: Schema$WebPage[]; + requestBody?: Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesRequest; + } + export interface Params$Resource$Projects$Files$Asyncbatchannotate + extends StandardParameters { /** - * Partial matching images from the Internet. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. + * Auth client or API Key for the request */ - partialMatchingImages?: Schema$WebImage[]; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * The visually similar image results. + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. */ - visuallySimilarImages?: Schema$WebImage[]; + parent?: string; + /** - * Deduced entities from similar images on the Internet. + * Request body metadata */ - webEntities?: Schema$WebEntity[]; + requestBody?: Schema$GoogleCloudVisionV1p1beta1AsyncBatchAnnotateFilesRequest; } - /** - * Entity deduced from similar images on the Internet. - */ - export interface Schema$WebEntity { - /** - * Canonical description of the entity, in English. - */ - description?: string; + + export class Resource$Projects$Images { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + /** - * Opaque entity ID. + * vision.projects.images.annotate + * @desc Run image detection and annotation for a batch of images. + * @alias vision.projects.images.annotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().GoogleCloudVisionV1p1beta1BatchAnnotateImagesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - entityId?: string; + annotate( + params?: Params$Resource$Projects$Images$Annotate, + options?: MethodOptions + ): GaxiosPromise< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + >; + annotate( + params: Params$Resource$Projects$Images$Annotate, + options: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + >, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + > + ): void; + annotate( + params: Params$Resource$Projects$Images$Annotate, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + > + ): void; + annotate( + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + > + ): void; + annotate( + paramsOrCallback?: + | Params$Resource$Projects$Images$Annotate + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + >, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + >, + callback?: BodyResponseCallback< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + > + ): void | GaxiosPromise< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + > { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Images$Annotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Images$Annotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1p1beta1/{+parent}/images:annotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + >(parameters, callback); + } else { + return createAPIRequest< + Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse + >(parameters); + } + } + /** - * Overall relevancy score for the entity. Not normalized and not comparable across different image queries. + * vision.projects.images.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of images. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateImagesResponse` (results). This service will write image annotation outputs to json files in customer GCS bucket, each json file containing BatchAnnotateImagesResponse proto. + * @alias vision.projects.images.asyncBatchAnnotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().GoogleCloudVisionV1p1beta1AsyncBatchAnnotateImagesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - score?: number; + asyncBatchAnnotate( + params?: Params$Resource$Projects$Images$Asyncbatchannotate, + options?: MethodOptions + ): GaxiosPromise; + asyncBatchAnnotate( + params: Params$Resource$Projects$Images$Asyncbatchannotate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate( + params: Params$Resource$Projects$Images$Asyncbatchannotate, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( + paramsOrCallback?: + | Params$Resource$Projects$Images$Asyncbatchannotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Images$Asyncbatchannotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Images$Asyncbatchannotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + '/v1p1beta1/{+parent}/images:asyncBatchAnnotate' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } - /** - * Metadata for online images. - */ - export interface Schema$WebImage { - /** - * (Deprecated) Overall relevancy score for the image. - */ - score?: number; + + export interface Params$Resource$Projects$Images$Annotate + extends StandardParameters { /** - * The result image URL. + * Auth client or API Key for the request */ - url?: string; - } - /** - * Label to provide extra metadata for the web detection. - */ - export interface Schema$WebLabel { + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * Label for extra metadata. + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. */ - label?: string; + parent?: string; + /** - * The BCP-47 language code for `label`, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + * Request body metadata */ - languageCode?: string; + requestBody?: Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesRequest; } - /** - * Metadata for web pages. - */ - export interface Schema$WebPage { - /** - * Fully matching images on the page. Can include resized copies of the query image. - */ - fullMatchingImages?: Schema$WebImage[]; - /** - * Title for the web page, may contain HTML markups. - */ - pageTitle?: string; + export interface Params$Resource$Projects$Images$Asyncbatchannotate + extends StandardParameters { /** - * Partial matching images on the page. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. + * Auth client or API Key for the request */ - partialMatchingImages?: Schema$WebImage[]; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * (Deprecated) Overall relevancy score for the web page. + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. */ - score?: number; + parent?: string; + /** - * The result web page URL. + * Request body metadata */ - url?: string; + requestBody?: Schema$GoogleCloudVisionV1p1beta1AsyncBatchAnnotateImagesRequest; } - /** - * A word representation. - */ - export interface Schema$Word { - /** - * The bounding box for the word. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$BoundingPoly; - /** - * Confidence of the OCR results for the word. Range [0, 1]. - */ - confidence?: number; - /** - * Additional information detected for the word. - */ - property?: Schema$TextProperty; - /** - * List of symbols in the word. The order of the symbols follows the natural reading order. - */ - symbols?: Schema$Symbol[]; + + export class Resource$Projects$Locations { + context: APIRequestContext; + files: Resource$Projects$Locations$Files; + images: Resource$Projects$Locations$Images; + constructor(context: APIRequestContext) { + this.context = context; + this.files = new Resource$Projects$Locations$Files(this.context); + this.images = new Resource$Projects$Locations$Images(this.context); + } } - export class Resource$Files { + export class Resource$Projects$Locations$Files { context: APIRequestContext; constructor(context: APIRequestContext) { this.context = context; } /** - * vision.files.annotate + * vision.projects.locations.files.annotate * @desc Service that performs image detection and annotation for a batch of files. Now only "application/pdf", "image/tiff" and "image/gif" are supported. This service will extract at most 5 (customers can specify which 5 in AnnotateFileRequest.pages) frames (gif) or pages (pdf or tiff) from each file provided and perform detection and annotation for each image extracted. - * @alias vision.files.annotate + * @alias vision.projects.locations.files.annotate * @memberOf! () * * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. * @param {().GoogleCloudVisionV1p1beta1BatchAnnotateFilesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ annotate( - params?: Params$Resource$Files$Annotate, + params?: Params$Resource$Projects$Locations$Files$Annotate, options?: MethodOptions ): GaxiosPromise< Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse >; annotate( - params: Params$Resource$Files$Annotate, + params: Params$Resource$Projects$Locations$Files$Annotate, options: | MethodOptions | BodyResponseCallback< @@ -6740,7 +6966,7 @@ export namespace vision_v1p1beta1 { > ): void; annotate( - params: Params$Resource$Files$Annotate, + params: Params$Resource$Projects$Locations$Files$Annotate, callback: BodyResponseCallback< Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse > @@ -6752,7 +6978,7 @@ export namespace vision_v1p1beta1 { ): void; annotate( paramsOrCallback?: - | Params$Resource$Files$Annotate + | Params$Resource$Projects$Locations$Files$Annotate | BodyResponseCallback< Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse >, @@ -6767,12 +6993,13 @@ export namespace vision_v1p1beta1 { ): void | GaxiosPromise< Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesResponse > { - let params = (paramsOrCallback || {}) as Params$Resource$Files$Annotate; + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Files$Annotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Files$Annotate; + params = {} as Params$Resource$Projects$Locations$Files$Annotate; options = {}; } @@ -6785,7 +7012,7 @@ export namespace vision_v1p1beta1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1p1beta1/files:annotate').replace( + url: (rootUrl + '/v1p1beta1/{+parent}/files:annotate').replace( /([^:]\/)\/+/g, '$1' ), @@ -6794,8 +7021,8 @@ export namespace vision_v1p1beta1 { options ), params, - requiredParams: [], - pathParams: [], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { @@ -6810,34 +7037,35 @@ export namespace vision_v1p1beta1 { } /** - * vision.files.asyncBatchAnnotate + * vision.projects.locations.files.asyncBatchAnnotate * @desc Run asynchronous image detection and annotation for a list of generic files, such as PDF files, which may contain multiple pages and multiple images per page. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results). - * @alias vision.files.asyncBatchAnnotate + * @alias vision.projects.locations.files.asyncBatchAnnotate * @memberOf! () * * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. * @param {().GoogleCloudVisionV1p1beta1AsyncBatchAnnotateFilesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ asyncBatchAnnotate( - params?: Params$Resource$Files$Asyncbatchannotate, + params?: Params$Resource$Projects$Locations$Files$Asyncbatchannotate, options?: MethodOptions ): GaxiosPromise; asyncBatchAnnotate( - params: Params$Resource$Files$Asyncbatchannotate, + params: Params$Resource$Projects$Locations$Files$Asyncbatchannotate, options: MethodOptions | BodyResponseCallback, callback: BodyResponseCallback ): void; asyncBatchAnnotate( - params: Params$Resource$Files$Asyncbatchannotate, + params: Params$Resource$Projects$Locations$Files$Asyncbatchannotate, callback: BodyResponseCallback ): void; asyncBatchAnnotate(callback: BodyResponseCallback): void; asyncBatchAnnotate( paramsOrCallback?: - | Params$Resource$Files$Asyncbatchannotate + | Params$Resource$Projects$Locations$Files$Asyncbatchannotate | BodyResponseCallback, optionsOrCallback?: | MethodOptions @@ -6845,12 +7073,12 @@ export namespace vision_v1p1beta1 { callback?: BodyResponseCallback ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Files$Asyncbatchannotate; + {}) as Params$Resource$Projects$Locations$Files$Asyncbatchannotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Files$Asyncbatchannotate; + params = {} as Params$Resource$Projects$Locations$Files$Asyncbatchannotate; options = {}; } @@ -6863,17 +7091,16 @@ export namespace vision_v1p1beta1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1p1beta1/files:asyncBatchAnnotate').replace( - /([^:]\/)\/+/g, - '$1' - ), + url: ( + rootUrl + '/v1p1beta1/{+parent}/files:asyncBatchAnnotate' + ).replace(/([^:]\/)\/+/g, '$1'), method: 'POST', }, options ), params, - requiredParams: [], - pathParams: [], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { @@ -6884,56 +7111,68 @@ export namespace vision_v1p1beta1 { } } - export interface Params$Resource$Files$Annotate extends StandardParameters { + export interface Params$Resource$Projects$Locations$Files$Annotate + extends StandardParameters { /** * Auth client or API Key for the request */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + /** * Request body metadata */ requestBody?: Schema$GoogleCloudVisionV1p1beta1BatchAnnotateFilesRequest; } - export interface Params$Resource$Files$Asyncbatchannotate + export interface Params$Resource$Projects$Locations$Files$Asyncbatchannotate extends StandardParameters { /** * Auth client or API Key for the request */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + /** * Request body metadata */ requestBody?: Schema$GoogleCloudVisionV1p1beta1AsyncBatchAnnotateFilesRequest; } - export class Resource$Images { + export class Resource$Projects$Locations$Images { context: APIRequestContext; constructor(context: APIRequestContext) { this.context = context; } /** - * vision.images.annotate + * vision.projects.locations.images.annotate * @desc Run image detection and annotation for a batch of images. - * @alias vision.images.annotate + * @alias vision.projects.locations.images.annotate * @memberOf! () * * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. * @param {().GoogleCloudVisionV1p1beta1BatchAnnotateImagesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ annotate( - params?: Params$Resource$Images$Annotate, + params?: Params$Resource$Projects$Locations$Images$Annotate, options?: MethodOptions ): GaxiosPromise< Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse >; annotate( - params: Params$Resource$Images$Annotate, + params: Params$Resource$Projects$Locations$Images$Annotate, options: | MethodOptions | BodyResponseCallback< @@ -6944,7 +7183,7 @@ export namespace vision_v1p1beta1 { > ): void; annotate( - params: Params$Resource$Images$Annotate, + params: Params$Resource$Projects$Locations$Images$Annotate, callback: BodyResponseCallback< Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse > @@ -6956,7 +7195,7 @@ export namespace vision_v1p1beta1 { ): void; annotate( paramsOrCallback?: - | Params$Resource$Images$Annotate + | Params$Resource$Projects$Locations$Images$Annotate | BodyResponseCallback< Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse >, @@ -6971,12 +7210,13 @@ export namespace vision_v1p1beta1 { ): void | GaxiosPromise< Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesResponse > { - let params = (paramsOrCallback || {}) as Params$Resource$Images$Annotate; + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Images$Annotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Images$Annotate; + params = {} as Params$Resource$Projects$Locations$Images$Annotate; options = {}; } @@ -6989,7 +7229,7 @@ export namespace vision_v1p1beta1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1p1beta1/images:annotate').replace( + url: (rootUrl + '/v1p1beta1/{+parent}/images:annotate').replace( /([^:]\/)\/+/g, '$1' ), @@ -6998,8 +7238,8 @@ export namespace vision_v1p1beta1 { options ), params, - requiredParams: [], - pathParams: [], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { @@ -7014,34 +7254,35 @@ export namespace vision_v1p1beta1 { } /** - * vision.images.asyncBatchAnnotate + * vision.projects.locations.images.asyncBatchAnnotate * @desc Run asynchronous image detection and annotation for a list of images. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateImagesResponse` (results). This service will write image annotation outputs to json files in customer GCS bucket, each json file containing BatchAnnotateImagesResponse proto. - * @alias vision.images.asyncBatchAnnotate + * @alias vision.projects.locations.images.asyncBatchAnnotate * @memberOf! () * * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. * @param {().GoogleCloudVisionV1p1beta1AsyncBatchAnnotateImagesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ asyncBatchAnnotate( - params?: Params$Resource$Images$Asyncbatchannotate, + params?: Params$Resource$Projects$Locations$Images$Asyncbatchannotate, options?: MethodOptions ): GaxiosPromise; asyncBatchAnnotate( - params: Params$Resource$Images$Asyncbatchannotate, + params: Params$Resource$Projects$Locations$Images$Asyncbatchannotate, options: MethodOptions | BodyResponseCallback, callback: BodyResponseCallback ): void; asyncBatchAnnotate( - params: Params$Resource$Images$Asyncbatchannotate, + params: Params$Resource$Projects$Locations$Images$Asyncbatchannotate, callback: BodyResponseCallback ): void; asyncBatchAnnotate(callback: BodyResponseCallback): void; asyncBatchAnnotate( paramsOrCallback?: - | Params$Resource$Images$Asyncbatchannotate + | Params$Resource$Projects$Locations$Images$Asyncbatchannotate | BodyResponseCallback, optionsOrCallback?: | MethodOptions @@ -7049,12 +7290,12 @@ export namespace vision_v1p1beta1 { callback?: BodyResponseCallback ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Images$Asyncbatchannotate; + {}) as Params$Resource$Projects$Locations$Images$Asyncbatchannotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Images$Asyncbatchannotate; + params = {} as Params$Resource$Projects$Locations$Images$Asyncbatchannotate; options = {}; } @@ -7067,17 +7308,16 @@ export namespace vision_v1p1beta1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1p1beta1/images:asyncBatchAnnotate').replace( - /([^:]\/)\/+/g, - '$1' - ), + url: ( + rootUrl + '/v1p1beta1/{+parent}/images:asyncBatchAnnotate' + ).replace(/([^:]\/)\/+/g, '$1'), method: 'POST', }, options ), params, - requiredParams: [], - pathParams: [], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { @@ -7088,24 +7328,35 @@ export namespace vision_v1p1beta1 { } } - export interface Params$Resource$Images$Annotate extends StandardParameters { + export interface Params$Resource$Projects$Locations$Images$Annotate + extends StandardParameters { /** * Auth client or API Key for the request */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + /** * Request body metadata */ requestBody?: Schema$GoogleCloudVisionV1p1beta1BatchAnnotateImagesRequest; } - export interface Params$Resource$Images$Asyncbatchannotate + export interface Params$Resource$Projects$Locations$Images$Asyncbatchannotate extends StandardParameters { /** * Auth client or API Key for the request */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + /** * Request body metadata */ diff --git a/src/apis/vision/v1p2beta1.ts b/src/apis/vision/v1p2beta1.ts index 6b57cee6fcc..b00eae03f8f 100644 --- a/src/apis/vision/v1p2beta1.ts +++ b/src/apis/vision/v1p2beta1.ts @@ -107,6 +107,7 @@ export namespace vision_v1p2beta1 { context: APIRequestContext; files: Resource$Files; images: Resource$Images; + projects: Resource$Projects; constructor(options: GlobalOptions, google?: GoogleConfigurable) { this.context = { @@ -116,6 +117,7 @@ export namespace vision_v1p2beta1 { this.files = new Resource$Files(this.context); this.images = new Resource$Images(this.context); + this.projects = new Resource$Projects(this.context); } } @@ -123,12 +125,16 @@ export namespace vision_v1p2beta1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$AnnotateImageResponse[]; /** @@ -515,12 +521,16 @@ export namespace vision_v1p2beta1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p1beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p1beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p1beta1AnnotateImageResponse[]; /** @@ -992,7 +1002,7 @@ export namespace vision_v1p2beta1 { */ property?: Schema$GoogleCloudVisionV1p1beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p1beta1Word[]; } @@ -1034,7 +1044,7 @@ export namespace vision_v1p2beta1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p1beta1ProductKeyValue[]; } @@ -1076,11 +1086,36 @@ export namespace vision_v1p2beta1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p1beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p1beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p1beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p1beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -1145,7 +1180,7 @@ export namespace vision_v1p2beta1 { */ export interface Schema$GoogleCloudVisionV1p1beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p1beta1BoundingPoly; /** @@ -1369,12 +1404,16 @@ export namespace vision_v1p2beta1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p2beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p2beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p2beta1AnnotateImageResponse[]; /** @@ -1494,6 +1533,10 @@ export namespace vision_v1p2beta1 { * Multiple async file annotation requests are batched into a single service call. */ export interface Schema$GoogleCloudVisionV1p2beta1AsyncBatchAnnotateFilesRequest { + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; /** * Individual async file annotation requests for this batch. */ @@ -1516,6 +1559,10 @@ export namespace vision_v1p2beta1 { * Required. The desired output location and metadata (e.g. format). */ outputConfig?: Schema$GoogleCloudVisionV1p2beta1OutputConfig; + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; /** * Individual image annotation requests for this batch. */ @@ -1525,6 +1572,10 @@ export namespace vision_v1p2beta1 { * A list of requests to annotate files using the BatchAnnotateFiles API. */ export interface Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesRequest { + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; /** * The list of file annotation requests. Right now we support only one AnnotateFileRequest in BatchAnnotateFilesRequest. */ @@ -1543,6 +1594,10 @@ export namespace vision_v1p2beta1 { * Multiple image annotation requests are batched into a single service call. */ export interface Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesRequest { + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; /** * Individual image annotation requests for this batch. */ @@ -2032,7 +2087,7 @@ export namespace vision_v1p2beta1 { */ property?: Schema$GoogleCloudVisionV1p2beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p2beta1Word[]; } @@ -2074,7 +2129,7 @@ export namespace vision_v1p2beta1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p2beta1ProductKeyValue[]; } @@ -2137,11 +2192,36 @@ export namespace vision_v1p2beta1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p2beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p2beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p2beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p2beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -2206,7 +2286,7 @@ export namespace vision_v1p2beta1 { */ export interface Schema$GoogleCloudVisionV1p2beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p2beta1BoundingPoly; /** @@ -2418,12 +2498,16 @@ export namespace vision_v1p2beta1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p3beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p3beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p3beta1AnnotateImageResponse[]; /** @@ -2925,7 +3009,7 @@ export namespace vision_v1p2beta1 { */ property?: Schema$GoogleCloudVisionV1p3beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p3beta1Word[]; } @@ -2967,7 +3051,7 @@ export namespace vision_v1p2beta1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p3beta1ProductKeyValue[]; } @@ -3009,11 +3093,36 @@ export namespace vision_v1p2beta1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p3beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p3beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p3beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p3beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -3095,7 +3204,7 @@ export namespace vision_v1p2beta1 { */ export interface Schema$GoogleCloudVisionV1p3beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p3beta1BoundingPoly; /** @@ -3298,12 +3407,16 @@ export namespace vision_v1p2beta1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p4beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p4beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p4beta1AnnotateImageResponse[]; /** @@ -3339,6 +3452,10 @@ export namespace vision_v1p2beta1 { * If present, image properties were extracted successfully. */ imagePropertiesAnnotation?: Schema$GoogleCloudVisionV1p4beta1ImageProperties; + /** + * If present, image quality calculation has completed successfully. + */ + imageQualityAnnotation?: Schema$GoogleCloudVisionV1p4beta1ImageQuality; /** * If present, label detection has completed successfully. */ @@ -3359,6 +3476,10 @@ export namespace vision_v1p2beta1 { * If present, product search has completed successfully. */ productSearchResults?: Schema$GoogleCloudVisionV1p4beta1ProductSearchResults; + /** + * If present, image quality optimization has completed successfully. + */ + qualityOptimizationResult?: Schema$GoogleCloudVisionV1p4beta1QualityOptimizationResult; /** * If present, safe-search annotation has completed successfully. */ @@ -3674,6 +3795,15 @@ export namespace vision_v1p2beta1 { */ dominantColors?: Schema$GoogleCloudVisionV1p4beta1DominantColorsAnnotation; } + /** + * Stores image quality scores, could be aesthetic quality or technical quality. + */ + export interface Schema$GoogleCloudVisionV1p4beta1ImageQuality { + /** + * A score representing the aesthetic/technical quality of the image. The score is in range [0, 1]. Higher value corresponds to more professional looking photos. 0 means the image looks very bad, 1 means the image with very high quality. + */ + qualityScore?: number; + } /** * Response message for the `ImportProductSets` method. This message is returned by the google.longrunning.Operations.GetOperation method in the returned google.longrunning.Operation.response field. */ @@ -3823,7 +3953,7 @@ export namespace vision_v1p2beta1 { */ property?: Schema$GoogleCloudVisionV1p4beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p4beta1Word[]; } @@ -3865,7 +3995,7 @@ export namespace vision_v1p2beta1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p4beta1ProductKeyValue[]; } @@ -3907,11 +4037,36 @@ export namespace vision_v1p2beta1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p4beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p4beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p4beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p4beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -3946,6 +4101,23 @@ export namespace vision_v1p2beta1 { */ value?: string; } + /** + * Stores enhanced image bytes. + */ + export interface Schema$GoogleCloudVisionV1p4beta1QualityOptimizationResult { + /** + * Optimized image bytes. + */ + image?: string; + /** + * Mime type of the output image. + */ + mimeType?: string; + /** + * Required optimization type. + */ + qualityOptimizationType?: string; + } /** * A `ReferenceImage` represents a product image and its associated metadata, such as bounding boxes. */ @@ -3971,29 +4143,53 @@ export namespace vision_v1p2beta1 { * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. */ adult?: string; + /** + * Confidence of adult_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + adultConfidence?: number; /** * Likelihood that this is a medical image. */ medical?: string; + /** + * Confidence of medical_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + medicalConfidence?: number; + /** + * Confidence of nsfw_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + nsfwConfidence?: number; /** * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. */ racy?: string; + /** + * Confidence of racy_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + racyConfidence?: number; /** * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. */ spoof?: string; + /** + * Confidence of spoof_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + spoofConfidence?: number; /** * Likelihood that this image contains violent content. */ violence?: string; + /** + * Confidence of violence_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + violenceConfidence?: number; } /** * A single symbol representation. */ export interface Schema$GoogleCloudVisionV1p4beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p4beta1BoundingPoly; /** @@ -4196,12 +4392,16 @@ export namespace vision_v1p2beta1 { * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. */ export interface Schema$GoogleCloudVisionV1p5beta1AnnotateFileResponse { + /** + * If set, represents the error message for the failed request. The `responses` field will not be set in this case. + */ + error?: Schema$Status; /** * Information about the file for which this response is generated. */ inputConfig?: Schema$GoogleCloudVisionV1p5beta1InputConfig; /** - * Individual responses to images found within the file. + * Individual responses to images found within the file. This field will be empty if the `error` field is set. */ responses?: Schema$GoogleCloudVisionV1p5beta1AnnotateImageResponse[]; /** @@ -4766,7 +4966,7 @@ export namespace vision_v1p2beta1 { */ property?: Schema$GoogleCloudVisionV1p5beta1TextAnnotationTextProperty; /** - * List of words in this paragraph. + * List of all words in this paragraph. */ words?: Schema$GoogleCloudVisionV1p5beta1Word[]; } @@ -4808,7 +5008,7 @@ export namespace vision_v1p2beta1 { */ productCategory?: string; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ productLabels?: Schema$GoogleCloudVisionV1p5beta1ProductKeyValue[]; } @@ -4850,11 +5050,36 @@ export namespace vision_v1p2beta1 { * The bounding polygon around the product detected in the query image. */ boundingPoly?: Schema$GoogleCloudVisionV1p5beta1BoundingPoly; + /** + * List of generic predictions for the object in the bounding box. + */ + objectAnnotations?: Schema$GoogleCloudVisionV1p5beta1ProductSearchResultsObjectAnnotation[]; /** * List of results, one for each product match. */ results?: Schema$GoogleCloudVisionV1p5beta1ProductSearchResultsResult[]; } + /** + * Prediction for what the object in the bounding box is. + */ + export interface Schema$GoogleCloudVisionV1p5beta1ProductSearchResultsObjectAnnotation { + /** + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + */ + languageCode?: string; + /** + * Object ID that should align with EntityAnnotation mid. + */ + mid?: string; + /** + * Object name, expressed in its `language_code` language. + */ + name?: string; + /** + * Score of the result. Range [0, 1]. + */ + score?: number; + } /** * Information about a product. */ @@ -4914,29 +5139,53 @@ export namespace vision_v1p2beta1 { * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. */ adult?: string; + /** + * Confidence of adult_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + adultConfidence?: number; /** * Likelihood that this is a medical image. */ medical?: string; + /** + * Confidence of medical_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + medicalConfidence?: number; + /** + * Confidence of nsfw_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + nsfwConfidence?: number; /** * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. */ racy?: string; + /** + * Confidence of racy_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + racyConfidence?: number; /** * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. */ spoof?: string; + /** + * Confidence of spoof_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + spoofConfidence?: number; /** * Likelihood that this image contains violent content. */ violence?: string; + /** + * Confidence of violence_score. Range [0, 1]. 0 means not confident, 1 means very confident. + */ + violenceConfidence?: number; } /** * A single symbol representation. */ export interface Schema$GoogleCloudVisionV1p5beta1Symbol { /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ boundingBox?: Schema$GoogleCloudVisionV1p5beta1BoundingPoly; /** @@ -5183,558 +5432,509 @@ export namespace vision_v1p2beta1 { symbols?: Schema$GoogleCloudVisionV1p5beta1Symbol[]; } /** - * Response to a single file annotation request. A file may contain one or more images, which individually have their own responses. + * Information about the products similar to a single product in a query image. */ - export interface Schema$GoogleCloudVisionV1p6beta1AnnotateFileResponse { + export interface Schema$GroupedResult { /** - * Information about the file for which this response is generated. + * The bounding polygon around the product detected in the query image. */ - inputConfig?: Schema$GoogleCloudVisionV1p6beta1InputConfig; + boundingPoly?: Schema$BoundingPoly; /** - * Individual responses to images found within the file. + * List of generic predictions for the object in the bounding box. */ - responses?: Schema$GoogleCloudVisionV1p6beta1AnnotateImageResponse[]; + objectAnnotations?: Schema$ObjectAnnotation[]; /** - * This field gives the total number of pages in the file. + * List of results, one for each product match. */ - totalPages?: number; + results?: Schema$Result[]; } /** - * Response to an image annotation request. + * If an image was produced from a file (e.g. a PDF), this message gives information about the source of that image. */ - export interface Schema$GoogleCloudVisionV1p6beta1AnnotateImageResponse { + export interface Schema$ImageAnnotationContext { /** - * If present, contextual information is needed to understand where this image comes from. + * If the file was a PDF or TIFF, this field gives the page number within the file used to produce the image. */ - context?: Schema$GoogleCloudVisionV1p6beta1ImageAnnotationContext; + pageNumber?: number; /** - * If present, crop hints have completed successfully. + * The URI of the file used to produce the image. */ - cropHintsAnnotation?: Schema$GoogleCloudVisionV1p6beta1CropHintsAnnotation; + uri?: string; + } + /** + * Stores image properties, such as dominant colors. + */ + export interface Schema$ImageProperties { /** - * If set, represents the error message for the operation. Note that filled-in image annotations are guaranteed to be correct, even when `error` is set. + * If present, dominant colors completed successfully. */ - error?: Schema$Status; + dominantColors?: Schema$DominantColorsAnnotation; + } + /** + * Response message for the `ImportProductSets` method. This message is returned by the google.longrunning.Operations.GetOperation method in the returned google.longrunning.Operation.response field. + */ + export interface Schema$ImportProductSetsResponse { /** - * If present, face detection has completed successfully. + * The list of reference_images that are imported successfully. */ - faceAnnotations?: Schema$GoogleCloudVisionV1p6beta1FaceAnnotation[]; + referenceImages?: Schema$ReferenceImage[]; /** - * If present, text (OCR) detection or document (OCR) text detection has completed successfully. This annotation provides the structural hierarchy for the OCR detected text. + * The rpc status for each ImportProductSet request, including both successes and errors. The number of statuses here matches the number of lines in the csv file, and statuses[i] stores the success or failure status of processing the i-th line of the csv, starting from line 0. */ - fullTextAnnotation?: Schema$GoogleCloudVisionV1p6beta1TextAnnotation; + statuses?: Schema$Status[]; + } + /** + * The desired input location and metadata. + */ + export interface Schema$InputConfig { /** - * If present, image properties were extracted successfully. + * File content, represented as a stream of bytes. Note: As with all `bytes` fields, protobuffers use a pure binary representation, whereas JSON representations use base64. Currently, this field only works for BatchAnnotateFiles requests. It does not work for AsyncBatchAnnotateFiles requests. */ - imagePropertiesAnnotation?: Schema$GoogleCloudVisionV1p6beta1ImageProperties; + content?: string; /** - * If present, image quality calculation has completed successfully. + * The Google Cloud Storage location to read the input from. */ - imageQualityAnnotation?: Schema$GoogleCloudVisionV1p6beta1ImageQuality; + gcsSource?: Schema$GcsSource; /** - * If present, label detection has completed successfully. + * The type of the file. Currently only "application/pdf", "image/tiff" and "image/gif" are supported. Wildcards are not supported. */ - labelAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; + mimeType?: string; + } + /** + * A product label represented as a key-value pair. + */ + export interface Schema$KeyValue { /** - * If present, landmark detection has completed successfully. + * The key of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. */ - landmarkAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; + key?: string; /** - * If present, localized object detection has completed successfully. This will be sorted descending by confidence score. + * The value of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. */ - localizedObjectAnnotations?: Schema$GoogleCloudVisionV1p6beta1LocalizedObjectAnnotation[]; + value?: string; + } + /** + * A face-specific landmark (for example, a face feature). + */ + export interface Schema$Landmark { /** - * If present, logo detection has completed successfully. + * Face landmark position. */ - logoAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; + position?: Schema$Position; /** - * If present, objects attributes calculation has completed successfully. The attributes value will be filled in the EntityAnnotation.properties. Example: object_attribute_annotations { properties { name: "color" value: "blue" confidence: 0.1 } properties { name: "color" value: "white" confidence: 0.2 } properties { name: "material" value: "silk" confidence: 0.3 } } + * Face landmark type. */ - objectAttributeAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; - /** - * If present, product search has completed successfully. - */ - productSearchResults?: Schema$GoogleCloudVisionV1p6beta1ProductSearchResults; + type?: string; + } + /** + * An object representing a latitude/longitude pair. This is expressed as a pair of doubles representing degrees latitude and degrees longitude. Unless specified otherwise, this must conform to the <a href="http://www.unoosa.org/pdf/icg/2012/template/WGS_84.pdf">WGS84 standard</a>. Values must be within normalized ranges. + */ + export interface Schema$LatLng { /** - * If present, image quality optimization has completed successfully. + * The latitude in degrees. It must be in the range [-90.0, +90.0]. */ - qualityOptimizationResult?: Schema$GoogleCloudVisionV1p6beta1QualityOptimizationResult; + latitude?: number; /** - * If present, safe-search annotation has completed successfully. + * The longitude in degrees. It must be in the range [-180.0, +180.0]. */ - safeSearchAnnotation?: Schema$GoogleCloudVisionV1p6beta1SafeSearchAnnotation; + longitude?: number; + } + /** + * Set of detected objects with bounding boxes. + */ + export interface Schema$LocalizedObjectAnnotation { /** - * If present, text (OCR) detection has completed successfully. + * Image region to which this object belongs. This must be populated. */ - textAnnotations?: Schema$GoogleCloudVisionV1p6beta1EntityAnnotation[]; + boundingPoly?: Schema$BoundingPoly; /** - * If present, web detection has completed successfully. + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */ - webDetection?: Schema$GoogleCloudVisionV1p6beta1WebDetection; - } - /** - * The response for a single offline file annotation request. - */ - export interface Schema$GoogleCloudVisionV1p6beta1AsyncAnnotateFileResponse { + languageCode?: string; /** - * The output location and metadata from AsyncAnnotateFileRequest. + * Object ID that should align with EntityAnnotation mid. */ - outputConfig?: Schema$GoogleCloudVisionV1p6beta1OutputConfig; - } - /** - * Response to an async batch file annotation request. - */ - export interface Schema$GoogleCloudVisionV1p6beta1AsyncBatchAnnotateFilesResponse { + mid?: string; /** - * The list of file annotation responses, one for each request in AsyncBatchAnnotateFilesRequest. + * Object name, expressed in its `language_code` language. */ - responses?: Schema$GoogleCloudVisionV1p6beta1AsyncAnnotateFileResponse[]; - } - /** - * Response to an async batch image annotation request. - */ - export interface Schema$GoogleCloudVisionV1p6beta1AsyncBatchAnnotateImagesResponse { + name?: string; /** - * The output location and metadata from AsyncBatchAnnotateImagesRequest. + * Score of the result. Range [0, 1]. */ - outputConfig?: Schema$GoogleCloudVisionV1p6beta1OutputConfig; + score?: number; } /** - * A list of file annotation responses. + * Detected entity location information. */ - export interface Schema$GoogleCloudVisionV1p6beta1BatchAnnotateFilesResponse { + export interface Schema$LocationInfo { /** - * The list of file annotation responses, each response corresponding to each AnnotateFileRequest in BatchAnnotateFilesRequest. + * lat/long location coordinates. */ - responses?: Schema$GoogleCloudVisionV1p6beta1AnnotateFileResponse[]; + latLng?: Schema$LatLng; } /** - * Metadata for the batch operations such as the current state. This is included in the `metadata` field of the `Operation` returned by the `GetOperation` call of the `google::longrunning::Operations` service. + * A vertex represents a 2D point in the image. NOTE: the normalized vertex coordinates are relative to the original image and range from 0 to 1. */ - export interface Schema$GoogleCloudVisionV1p6beta1BatchOperationMetadata { - /** - * The time when the batch request is finished and google.longrunning.Operation.done is set to true. - */ - endTime?: string; + export interface Schema$NormalizedVertex { /** - * The current state of the batch operation. + * X coordinate. */ - state?: string; + x?: number; /** - * The time when the batch request was submitted to the server. + * Y coordinate. */ - submitTime?: string; + y?: number; } /** - * Logical element on the page. + * Prediction for what the object in the bounding box is. */ - export interface Schema$GoogleCloudVisionV1p6beta1Block { - /** - * Detected block type (text, image etc) for this block. - */ - blockType?: string; + export interface Schema$ObjectAnnotation { /** - * The bounding box for the block. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). + * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */ - boundingBox?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + languageCode?: string; /** - * Confidence of the OCR results on the block. Range [0, 1]. + * Object ID that should align with EntityAnnotation mid. */ - confidence?: number; + mid?: string; /** - * List of paragraphs in this block (if this blocks is of type text). + * Object name, expressed in its `language_code` language. */ - paragraphs?: Schema$GoogleCloudVisionV1p6beta1Paragraph[]; + name?: string; /** - * Additional information detected for the block. + * Score of the result. Range [0, 1]. */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + score?: number; } /** - * A bounding polygon for the detected image annotation. + * This resource represents a long-running operation that is the result of a network API call. */ - export interface Schema$GoogleCloudVisionV1p6beta1BoundingPoly { + export interface Schema$Operation { /** - * The bounding polygon normalized vertices. + * If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available. */ - normalizedVertices?: Schema$GoogleCloudVisionV1p6beta1NormalizedVertex[]; + done?: boolean; /** - * The bounding polygon vertices. + * The error result of the operation in case of failure or cancellation. */ - vertices?: Schema$GoogleCloudVisionV1p6beta1Vertex[]; - } - /** - * Color information consists of RGB channels, score, and the fraction of the image that the color occupies in the image. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ColorInfo { + error?: Schema$Status; /** - * RGB components of the color. + * Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any. */ - color?: Schema$Color; + metadata?: {[key: string]: any}; /** - * The fraction of pixels the color occupies in the image. Value in range [0, 1]. + * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. */ - pixelFraction?: number; + name?: string; /** - * Image-specific score for this color. Value in range [0, 1]. + * The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. */ - score?: number; + response?: {[key: string]: any}; } /** - * Single crop hint that is used to generate a new crop when serving an image. + * Contains metadata for the BatchAnnotateImages operation. */ - export interface Schema$GoogleCloudVisionV1p6beta1CropHint { + export interface Schema$OperationMetadata { /** - * The bounding polygon for the crop region. The coordinates of the bounding box are in the original image's scale. + * The time when the batch request was received. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + createTime?: string; /** - * Confidence of this being a salient region. Range [0, 1]. + * Current state of the batch operation. */ - confidence?: number; + state?: string; /** - * Fraction of importance of this salient region with respect to the original image. + * The time when the operation result was last updated. */ - importanceFraction?: number; + updateTime?: string; } /** - * Set of crop hints that are used to generate new crops when serving images. + * The desired output location and metadata. */ - export interface Schema$GoogleCloudVisionV1p6beta1CropHintsAnnotation { + export interface Schema$OutputConfig { /** - * Crop hint results. + * The max number of response protos to put into each output JSON file on Google Cloud Storage. The valid range is [1, 100]. If not specified, the default value is 20. For example, for one pdf file with 100 pages, 100 response protos will be generated. If `batch_size` = 20, then 5 json files each containing 20 response protos will be written under the prefix `gcs_destination`.`uri`. Currently, batch_size only applies to GcsDestination, with potential future support for other output configurations. */ - cropHints?: Schema$GoogleCloudVisionV1p6beta1CropHint[]; - } - /** - * Set of dominant colors and their corresponding scores. - */ - export interface Schema$GoogleCloudVisionV1p6beta1DominantColorsAnnotation { + batchSize?: number; /** - * RGB color values with their score and pixel fraction. + * The Google Cloud Storage location to write the output(s) to. */ - colors?: Schema$GoogleCloudVisionV1p6beta1ColorInfo[]; + gcsDestination?: Schema$GcsDestination; } /** - * Set of detected entity features. + * Detected page from OCR. */ - export interface Schema$GoogleCloudVisionV1p6beta1EntityAnnotation { + export interface Schema$Page { /** - * Image region to which this entity belongs. Not produced for `LABEL_DETECTION` features. + * List of blocks of text, images etc on this page. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + blocks?: Schema$Block[]; /** - * **Deprecated. Use `score` instead.** The accuracy of the entity detection in an image. For example, for an image in which the "Eiffel Tower" entity is detected, this field represents the confidence that there is a tower in the query image. Range [0, 1]. + * Confidence of the OCR results on the page. Range [0, 1]. */ confidence?: number; /** - * Entity textual description, expressed in its `locale` language. + * Page height. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. */ - description?: string; + height?: number; /** - * The language code for the locale in which the entity textual `description` is expressed. + * Additional information detected on the page. */ - locale?: string; + property?: Schema$TextProperty; /** - * The location information for the detected entity. Multiple `LocationInfo` elements can be present because one location may indicate the location of the scene in the image, and another location may indicate the location of the place where the image was taken. Location information is usually present for landmarks. + * Page width. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. */ - locations?: Schema$GoogleCloudVisionV1p6beta1LocationInfo[]; + width?: number; + } + /** + * Structural unit of text representing a number of words in certain order. + */ + export interface Schema$Paragraph { /** - * Opaque entity ID. Some IDs may be available in [Google Knowledge Graph Search API](https://developers.google.com/knowledge-graph/). + * The bounding box for the paragraph. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ - mid?: string; + boundingBox?: Schema$BoundingPoly; /** - * Some entities may have optional user-supplied `Property` (name/value) fields, such a score or string that qualifies the entity. + * Confidence of the OCR results for the paragraph. Range [0, 1]. */ - properties?: Schema$GoogleCloudVisionV1p6beta1Property[]; + confidence?: number; /** - * Overall score of the result. Range [0, 1]. + * Additional information detected for the paragraph. */ - score?: number; + property?: Schema$TextProperty; /** - * The relevancy of the ICA (Image Content Annotation) label to the image. For example, the relevancy of "tower" is likely higher to an image containing the detected "Eiffel Tower" than to an image containing a detected distant towering building, even though the confidence that there is a tower in each image may be the same. Range [0, 1]. + * List of all words in this paragraph. */ - topicality?: number; + words?: Schema$Word[]; } /** - * A face annotation object contains the results of face detection. + * A 3D position in the image, used primarily for Face detection landmarks. A valid Position must have both x and y coordinates. The position coordinates are in the same scale as the original image. */ - export interface Schema$GoogleCloudVisionV1p6beta1FaceAnnotation { - /** - * Anger likelihood. - */ - angerLikelihood?: string; + export interface Schema$Position { /** - * Blurred likelihood. + * X coordinate. */ - blurredLikelihood?: string; + x?: number; /** - * The bounding polygon around the face. The coordinates of the bounding box are in the original image's scale. The bounding box is computed to "frame" the face in accordance with human expectations. It is based on the landmarker results. Note that one or more x and/or y coordinates may not be generated in the `BoundingPoly` (the polygon will be unbounded) if only a partial face appears in the image to be annotated. + * Y coordinate. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + y?: number; /** - * Detection confidence. Range [0, 1]. + * Z coordinate (or depth). */ - detectionConfidence?: number; + z?: number; + } + /** + * A Product contains ReferenceImages. + */ + export interface Schema$Product { /** - * The `fd_bounding_poly` bounding polygon is tighter than the `boundingPoly`, and encloses only the skin part of the face. Typically, it is used to eliminate the face from any image analysis that detects the "amount of skin" visible in an image. It is not based on the landmarker results, only on the initial face detection, hence the <code>fd</code> (face detection) prefix. + * User-provided metadata to be stored with this product. Must be at most 4096 characters long. */ - fdBoundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + description?: string; /** - * Headwear likelihood. + * The user-provided name for this Product. Must not be empty. Must be at most 4096 characters long. */ - headwearLikelihood?: string; + displayName?: string; /** - * Joy likelihood. + * The resource name of the product. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`. This field is ignored when creating a product. */ - joyLikelihood?: string; + name?: string; /** - * Face landmarking confidence. Range [0, 1]. + * The category for the product identified by the reference image. This should be either "homegoods-v2", "apparel-v2", or "toys-v2". The legacy categories "homegoods", "apparel", and "toys" are still supported, but these should not be used for new products. This field is immutable. */ - landmarkingConfidence?: number; + productCategory?: string; /** - * Detected face landmarks. + * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 500 product_labels. Notice that the total number of distinct product_labels over all products in one ProductSet cannot exceed 1M, otherwise the product search pipeline will refuse to work for that ProductSet. */ - landmarks?: Schema$GoogleCloudVisionV1p6beta1FaceAnnotationLandmark[]; + productLabels?: Schema$KeyValue[]; + } + /** + * Results for a product search request. + */ + export interface Schema$ProductSearchResults { /** - * Yaw angle, which indicates the leftward/rightward angle that the face is pointing relative to the vertical plane perpendicular to the image. Range [-180,180]. + * Timestamp of the index which provided these results. Products added to the product set and products removed from the product set after this time are not reflected in the current results. */ - panAngle?: number; + indexTime?: string; /** - * Roll angle, which indicates the amount of clockwise/anti-clockwise rotation of the face relative to the image vertical about the axis perpendicular to the face. Range [-180,180]. + * List of results grouped by products detected in the query image. Each entry corresponds to one bounding polygon in the query image, and contains the matching products specific to that region. There may be duplicate product matches in the union of all the per-product results. */ - rollAngle?: number; + productGroupedResults?: Schema$GroupedResult[]; /** - * Sorrow likelihood. + * List of results, one for each product match. */ - sorrowLikelihood?: string; + results?: Schema$Result[]; + } + /** + * A `Property` consists of a user-supplied name/value pair. + */ + export interface Schema$Property { /** - * Surprise likelihood. + * Name of the property. */ - surpriseLikelihood?: string; + name?: string; /** - * Pitch angle, which indicates the upwards/downwards angle that the face is pointing relative to the image's horizontal plane. Range [-180,180]. + * Value of numeric properties. */ - tiltAngle?: number; + uint64Value?: string; /** - * Under-exposed likelihood. + * Value of the property. */ - underExposedLikelihood?: string; + value?: string; } /** - * A face-specific landmark (for example, a face feature). + * A `ReferenceImage` represents a product image and its associated metadata, such as bounding boxes. */ - export interface Schema$GoogleCloudVisionV1p6beta1FaceAnnotationLandmark { + export interface Schema$ReferenceImage { /** - * Face landmark position. + * Bounding polygons around the areas of interest in the reference image. Optional. If this field is empty, the system will try to detect regions of interest. At most 10 bounding polygons will be used. The provided shape is converted into a non-rotated rectangle. Once converted, the small edge of the rectangle must be greater than or equal to 300 pixels. The aspect ratio must be 1:4 or less (i.e. 1:3 is ok; 1:5 is not). */ - position?: Schema$GoogleCloudVisionV1p6beta1Position; + boundingPolys?: Schema$BoundingPoly[]; /** - * Face landmark type. + * The resource name of the reference image. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`. This field is ignored when creating a reference image. */ - type?: string; - } - /** - * The Google Cloud Storage location where the output will be written to. - */ - export interface Schema$GoogleCloudVisionV1p6beta1GcsDestination { + name?: string; /** - * Google Cloud Storage URI prefix where the results will be stored. Results will be in JSON format and preceded by its corresponding input URI prefix. This field can either represent a gcs file prefix or gcs directory. In either case, the uri should be unique because in order to get all of the output files, you will need to do a wildcard gcs search on the uri prefix you provide. Examples: * File Prefix: gs://bucket-name/here/filenameprefix The output files will be created in gs://bucket-name/here/ and the names of the output files will begin with "filenameprefix". * Directory Prefix: gs://bucket-name/some/location/ The output files will be created in gs://bucket-name/some/location/ and the names of the output files could be anything because there was no filename prefix specified. If multiple outputs, each response is still AnnotateFileResponse, each of which contains some subset of the full list of AnnotateImageResponse. Multiple outputs can happen if, for example, the output JSON is too large and overflows into multiple sharded files. + * The Google Cloud Storage URI of the reference image. The URI must start with `gs://`. Required. */ uri?: string; } /** - * The Google Cloud Storage location where the input will be read from. + * Information about a product. */ - export interface Schema$GoogleCloudVisionV1p6beta1GcsSource { + export interface Schema$Result { /** - * Google Cloud Storage URI for the input file. This must only be a Google Cloud Storage object. Wildcards are not currently supported. + * The resource name of the image from the product that is the closest match to the query. */ - uri?: string; - } - /** - * If an image was produced from a file (e.g. a PDF), this message gives information about the source of that image. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ImageAnnotationContext { + image?: string; /** - * If the file was a PDF or TIFF, this field gives the page number within the file used to produce the image. + * The Product. */ - pageNumber?: number; + product?: Schema$Product; /** - * The URI of the file used to produce the image. + * A confidence level on the match, ranging from 0 (no confidence) to 1 (full confidence). */ - uri?: string; + score?: number; } /** - * Stores image properties, such as dominant colors. + * Set of features pertaining to the image, computed by computer vision methods over safe-search verticals (for example, adult, spoof, medical, violence). */ - export interface Schema$GoogleCloudVisionV1p6beta1ImageProperties { + export interface Schema$SafeSearchAnnotation { /** - * If present, dominant colors completed successfully. + * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. */ - dominantColors?: Schema$GoogleCloudVisionV1p6beta1DominantColorsAnnotation; - } - /** - * Stores image quality scores, could be aesthetic quality or technical quality. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ImageQuality {} - /** - * Response message for the `ImportProductSets` method. This message is returned by the google.longrunning.Operations.GetOperation method in the returned google.longrunning.Operation.response field. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ImportProductSetsResponse { + adult?: string; /** - * The list of reference_images that are imported successfully. + * Confidence of adult_score. Range [0, 1]. 0 means not confident, 1 means very confident. */ - referenceImages?: Schema$GoogleCloudVisionV1p6beta1ReferenceImage[]; + adultConfidence?: number; /** - * The rpc status for each ImportProductSet request, including both successes and errors. The number of statuses here matches the number of lines in the csv file, and statuses[i] stores the success or failure status of processing the i-th line of the csv, starting from line 0. + * Likelihood that this is a medical image. */ - statuses?: Schema$Status[]; - } - /** - * The desired input location and metadata. - */ - export interface Schema$GoogleCloudVisionV1p6beta1InputConfig { + medical?: string; /** - * File content, represented as a stream of bytes. Note: As with all `bytes` fields, protobuffers use a pure binary representation, whereas JSON representations use base64. Currently, this field only works for BatchAnnotateFiles requests. It does not work for AsyncBatchAnnotateFiles requests. + * Confidence of medical_score. Range [0, 1]. 0 means not confident, 1 means very confident. */ - content?: string; + medicalConfidence?: number; /** - * The Google Cloud Storage location to read the input from. + * Confidence of nsfw_score. Range [0, 1]. 0 means not confident, 1 means very confident. */ - gcsSource?: Schema$GoogleCloudVisionV1p6beta1GcsSource; + nsfwConfidence?: number; /** - * The type of the file. Currently only "application/pdf", "image/tiff" and "image/gif" are supported. Wildcards are not supported. + * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. */ - mimeType?: string; - } - /** - * Set of detected objects with bounding boxes. - */ - export interface Schema$GoogleCloudVisionV1p6beta1LocalizedObjectAnnotation { + racy?: string; /** - * Image region to which this object belongs. This must be populated. + * Confidence of racy_score. Range [0, 1]. 0 means not confident, 1 means very confident. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + racyConfidence?: number; /** - * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. */ - languageCode?: string; + spoof?: string; /** - * Object ID that should align with EntityAnnotation mid. + * Confidence of spoof_score. Range [0, 1]. 0 means not confident, 1 means very confident. */ - mid?: string; + spoofConfidence?: number; /** - * Object name, expressed in its `language_code` language. + * Likelihood that this image contains violent content. */ - name?: string; + violence?: string; /** - * Score of the result. Range [0, 1]. + * Confidence of violence_score. Range [0, 1]. 0 means not confident, 1 means very confident. */ - score?: number; + violenceConfidence?: number; } /** - * Detected entity location information. + * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). */ - export interface Schema$GoogleCloudVisionV1p6beta1LocationInfo { + export interface Schema$Status { /** - * lat/long location coordinates. + * The status code, which should be an enum value of google.rpc.Code. */ - latLng?: Schema$LatLng; - } - /** - * A vertex represents a 2D point in the image. NOTE: the normalized vertex coordinates are relative to the original image and range from 0 to 1. - */ - export interface Schema$GoogleCloudVisionV1p6beta1NormalizedVertex { + code?: number; /** - * X coordinate. + * A list of messages that carry the error details. There is a common set of message types for APIs to use. */ - x?: number; + details?: Array<{[key: string]: any}>; /** - * Y coordinate. + * A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. */ - y?: number; + message?: string; } /** - * Contains metadata for the BatchAnnotateImages operation. + * A single symbol representation. */ - export interface Schema$GoogleCloudVisionV1p6beta1OperationMetadata { - /** - * The time when the batch request was received. - */ - createTime?: string; + export interface Schema$Symbol { /** - * Current state of the batch operation. + * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ - state?: string; + boundingBox?: Schema$BoundingPoly; /** - * The time when the operation result was last updated. + * Confidence of the OCR results for the symbol. Range [0, 1]. */ - updateTime?: string; - } - /** - * The desired output location and metadata. - */ - export interface Schema$GoogleCloudVisionV1p6beta1OutputConfig { + confidence?: number; /** - * The max number of response protos to put into each output JSON file on Google Cloud Storage. The valid range is [1, 100]. If not specified, the default value is 20. For example, for one pdf file with 100 pages, 100 response protos will be generated. If `batch_size` = 20, then 5 json files each containing 20 response protos will be written under the prefix `gcs_destination`.`uri`. Currently, batch_size only applies to GcsDestination, with potential future support for other output configurations. + * Additional information detected for the symbol. */ - batchSize?: number; + property?: Schema$TextProperty; /** - * The Google Cloud Storage location to write the output(s) to. + * The actual UTF-8 representation of the symbol. */ - gcsDestination?: Schema$GoogleCloudVisionV1p6beta1GcsDestination; + text?: string; } /** - * Detected page from OCR. + * TextAnnotation contains a structured representation of OCR extracted text. The hierarchy of an OCR extracted text structure is like this: TextAnnotation -> Page -> Block -> Paragraph -> Word -> Symbol Each structural component, starting from Page, may further have their own properties. Properties describe detected languages, breaks etc.. Please refer to the TextAnnotation.TextProperty message definition below for more detail. */ - export interface Schema$GoogleCloudVisionV1p6beta1Page { - /** - * List of blocks of text, images etc on this page. - */ - blocks?: Schema$GoogleCloudVisionV1p6beta1Block[]; - /** - * Confidence of the OCR results on the page. Range [0, 1]. - */ - confidence?: number; - /** - * Page height. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. - */ - height?: number; + export interface Schema$TextAnnotation { /** - * Additional information detected on the page. + * List of pages detected by OCR. */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + pages?: Schema$Page[]; /** - * Page width. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. + * UTF-8 text detected on the pages. */ - width?: number; + text?: string; } /** - * Structural unit of text representing a number of words in certain order. + * Additional information detected on the structural component. */ - export interface Schema$GoogleCloudVisionV1p6beta1Paragraph { - /** - * The bounding box for the paragraph. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; - /** - * Confidence of the OCR results for the paragraph. Range [0, 1]. - */ - confidence?: number; + export interface Schema$TextProperty { /** - * Additional information detected for the paragraph. + * Detected start or end of a text segment. */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + detectedBreak?: Schema$DetectedBreak; /** - * List of words in this paragraph. + * A list of detected languages together with confidence. */ - words?: Schema$GoogleCloudVisionV1p6beta1Word[]; + detectedLanguages?: Schema$DetectedLanguage[]; } /** - * A 3D position in the image, used primarily for Face detection landmarks. A valid Position must have both x and y coordinates. The position coordinates are in the same scale as the original image. + * A vertex represents a 2D point in the image. NOTE: the vertex coordinates are in the same scale as the original image. */ - export interface Schema$GoogleCloudVisionV1p6beta1Position { + export interface Schema$Vertex { /** * X coordinate. */ @@ -5743,993 +5943,1019 @@ export namespace vision_v1p2beta1 { * Y coordinate. */ y?: number; - /** - * Z coordinate (or depth). - */ - z?: number; } /** - * A Product contains ReferenceImages. + * Relevant information for the image from the Internet. */ - export interface Schema$GoogleCloudVisionV1p6beta1Product { - /** - * User-provided metadata to be stored with this product. Must be at most 4096 characters long. - */ - description?: string; + export interface Schema$WebDetection { /** - * The user-provided name for this Product. Must not be empty. Must be at most 4096 characters long. + * The service's best guess as to the topic of the request image. Inferred from similar images on the open web. */ - displayName?: string; + bestGuessLabels?: Schema$WebLabel[]; /** - * The resource name of the product. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`. This field is ignored when creating a product. + * Fully matching images from the Internet. Can include resized copies of the query image. */ - name?: string; + fullMatchingImages?: Schema$WebImage[]; /** - * The category for the product identified by the reference image. This should be either "homegoods-v2", "apparel-v2", or "toys-v2". The legacy categories "homegoods", "apparel", and "toys" are still supported, but these should not be used for new products. This field is immutable. + * Web pages containing the matching images from the Internet. */ - productCategory?: string; + pagesWithMatchingImages?: Schema$WebPage[]; /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. + * Partial matching images from the Internet. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. */ - productLabels?: Schema$GoogleCloudVisionV1p6beta1ProductKeyValue[]; - } - /** - * A product label represented as a key-value pair. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ProductKeyValue { + partialMatchingImages?: Schema$WebImage[]; /** - * The key of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. + * The visually similar image results. */ - key?: string; + visuallySimilarImages?: Schema$WebImage[]; /** - * The value of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. + * Deduced entities from similar images on the Internet. */ - value?: string; + webEntities?: Schema$WebEntity[]; } /** - * Results for a product search request. + * Entity deduced from similar images on the Internet. */ - export interface Schema$GoogleCloudVisionV1p6beta1ProductSearchResults { + export interface Schema$WebEntity { /** - * Timestamp of the index which provided these results. Products added to the product set and products removed from the product set after this time are not reflected in the current results. + * Canonical description of the entity, in English. */ - indexTime?: string; + description?: string; /** - * List of results grouped by products detected in the query image. Each entry corresponds to one bounding polygon in the query image, and contains the matching products specific to that region. There may be duplicate product matches in the union of all the per-product results. + * Opaque entity ID. */ - productGroupedResults?: Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsGroupedResult[]; + entityId?: string; /** - * List of results, one for each product match. + * Overall relevancy score for the entity. Not normalized and not comparable across different image queries. */ - results?: Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsResult[]; + score?: number; } /** - * Information about the products similar to a single product in a query image. + * Metadata for online images. */ - export interface Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsGroupedResult { + export interface Schema$WebImage { /** - * The bounding polygon around the product detected in the query image. + * (Deprecated) Overall relevancy score for the image. */ - boundingPoly?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; + score?: number; /** - * List of results, one for each product match. + * The result image URL. */ - results?: Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsResult[]; + url?: string; } /** - * Information about a product. + * Label to provide extra metadata for the web detection. */ - export interface Schema$GoogleCloudVisionV1p6beta1ProductSearchResultsResult { - /** - * The resource name of the image from the product that is the closest match to the query. - */ - image?: string; + export interface Schema$WebLabel { /** - * The Product. + * Label for extra metadata. */ - product?: Schema$GoogleCloudVisionV1p6beta1Product; + label?: string; /** - * A confidence level on the match, ranging from 0 (no confidence) to 1 (full confidence). + * The BCP-47 language code for `label`, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. */ - score?: number; + languageCode?: string; } /** - * A `Property` consists of a user-supplied name/value pair. + * Metadata for web pages. */ - export interface Schema$GoogleCloudVisionV1p6beta1Property { + export interface Schema$WebPage { /** - * Value in range [0..1]. Confidence of this property value. + * Fully matching images on the page. Can include resized copies of the query image. */ - confidence?: number; + fullMatchingImages?: Schema$WebImage[]; /** - * Opaque property value ID. Some IDs may be available in [Google Knowledge Graph Search API](https://developers.google.com/knowledge-graph/). An example property for a blue coat would be: Property { name: 'color' value: 'blue' mid: '/m/01g5v' // For color blue } + * Title for the web page, may contain HTML markups. */ - mid?: string; + pageTitle?: string; /** - * Name of the property. + * Partial matching images on the page. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. */ - name?: string; + partialMatchingImages?: Schema$WebImage[]; /** - * Value of numeric properties. + * (Deprecated) Overall relevancy score for the web page. */ - uint64Value?: string; + score?: number; /** - * Value of the property. + * The result web page URL. */ - value?: string; + url?: string; } /** - * Stores enhanced image bytes. + * A word representation. */ - export interface Schema$GoogleCloudVisionV1p6beta1QualityOptimizationResult { + export interface Schema$Word { /** - * Optimized image bytes. - */ - image?: string; - /** - * Mime type of the output image. - */ - mimeType?: string; - /** - * Required optimization type. + * The bounding box for the word. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). */ - qualityOptimizationType?: string; - } - /** - * A `ReferenceImage` represents a product image and its associated metadata, such as bounding boxes. - */ - export interface Schema$GoogleCloudVisionV1p6beta1ReferenceImage { + boundingBox?: Schema$BoundingPoly; /** - * Bounding polygons around the areas of interest in the reference image. Optional. If this field is empty, the system will try to detect regions of interest. At most 10 bounding polygons will be used. The provided shape is converted into a non-rotated rectangle. Once converted, the small edge of the rectangle must be greater than or equal to 300 pixels. The aspect ratio must be 1:4 or less (i.e. 1:3 is ok; 1:5 is not). + * Confidence of the OCR results for the word. Range [0, 1]. */ - boundingPolys?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly[]; + confidence?: number; /** - * The resource name of the reference image. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`. This field is ignored when creating a reference image. + * Additional information detected for the word. */ - name?: string; + property?: Schema$TextProperty; /** - * The Google Cloud Storage URI of the reference image. The URI must start with `gs://`. Required. + * List of symbols in the word. The order of the symbols follows the natural reading order. */ - uri?: string; + symbols?: Schema$Symbol[]; } - /** - * Set of features pertaining to the image, computed by computer vision methods over safe-search verticals (for example, adult, spoof, medical, violence). - */ - export interface Schema$GoogleCloudVisionV1p6beta1SafeSearchAnnotation { - /** - * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. - */ - adult?: string; - /** - * Likelihood that this is a medical image. - */ - medical?: string; - /** - * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. - */ - racy?: string; + + export class Resource$Files { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + /** - * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. + * vision.files.annotate + * @desc Service that performs image detection and annotation for a batch of files. Now only "application/pdf", "image/tiff" and "image/gif" are supported. This service will extract at most 5 (customers can specify which 5 in AnnotateFileRequest.pages) frames (gif) or pages (pdf or tiff) from each file provided and perform detection and annotation for each image extracted. + * @alias vision.files.annotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().GoogleCloudVisionV1p2beta1BatchAnnotateFilesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - spoof?: string; + annotate( + params?: Params$Resource$Files$Annotate, + options?: MethodOptions + ): GaxiosPromise< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + >; + annotate( + params: Params$Resource$Files$Annotate, + options: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + >, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + > + ): void; + annotate( + params: Params$Resource$Files$Annotate, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + > + ): void; + annotate( + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + > + ): void; + annotate( + paramsOrCallback?: + | Params$Resource$Files$Annotate + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + >, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + >, + callback?: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + > + ): void | GaxiosPromise< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + > { + let params = (paramsOrCallback || {}) as Params$Resource$Files$Annotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Files$Annotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1p2beta1/files:annotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + >(parameters, callback); + } else { + return createAPIRequest< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + >(parameters); + } + } + /** - * Likelihood that this image contains violent content. + * vision.files.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of generic files, such as PDF files, which may contain multiple pages and multiple images per page. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results). + * @alias vision.files.asyncBatchAnnotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().GoogleCloudVisionV1p2beta1AsyncBatchAnnotateFilesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - violence?: string; + asyncBatchAnnotate( + params?: Params$Resource$Files$Asyncbatchannotate, + options?: MethodOptions + ): GaxiosPromise; + asyncBatchAnnotate( + params: Params$Resource$Files$Asyncbatchannotate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate( + params: Params$Resource$Files$Asyncbatchannotate, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( + paramsOrCallback?: + | Params$Resource$Files$Asyncbatchannotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Files$Asyncbatchannotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Files$Asyncbatchannotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1p2beta1/files:asyncBatchAnnotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } - /** - * A single symbol representation. - */ - export interface Schema$GoogleCloudVisionV1p6beta1Symbol { - /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; - /** - * Confidence of the OCR results for the symbol. Range [0, 1]. - */ - confidence?: number; + + export interface Params$Resource$Files$Annotate extends StandardParameters { /** - * Additional information detected for the symbol. + * Auth client or API Key for the request */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * The actual UTF-8 representation of the symbol. + * Request body metadata */ - text?: string; + requestBody?: Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesRequest; } - /** - * TextAnnotation contains a structured representation of OCR extracted text. The hierarchy of an OCR extracted text structure is like this: TextAnnotation -> Page -> Block -> Paragraph -> Word -> Symbol Each structural component, starting from Page, may further have their own properties. Properties describe detected languages, breaks etc.. Please refer to the TextAnnotation.TextProperty message definition below for more detail. - */ - export interface Schema$GoogleCloudVisionV1p6beta1TextAnnotation { + export interface Params$Resource$Files$Asyncbatchannotate + extends StandardParameters { /** - * List of pages detected by OCR. + * Auth client or API Key for the request */ - pages?: Schema$GoogleCloudVisionV1p6beta1Page[]; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * UTF-8 text detected on the pages. + * Request body metadata */ - text?: string; + requestBody?: Schema$GoogleCloudVisionV1p2beta1AsyncBatchAnnotateFilesRequest; } - /** - * Detected start or end of a structural component. - */ - export interface Schema$GoogleCloudVisionV1p6beta1TextAnnotationDetectedBreak { - /** - * True if break prepends the element. - */ - isPrefix?: boolean; - /** - * Detected break type. - */ - type?: string; - } - /** - * Detected language for a structural component. - */ - export interface Schema$GoogleCloudVisionV1p6beta1TextAnnotationDetectedLanguage { - /** - * Confidence of detected language. Range [0, 1]. - */ - confidence?: number; - /** - * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. - */ - languageCode?: string; - } - /** - * Additional information detected on the structural component. - */ - export interface Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty { - /** - * Detected start or end of a text segment. - */ - detectedBreak?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationDetectedBreak; - /** - * A list of detected languages together with confidence. - */ - detectedLanguages?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationDetectedLanguage[]; - } - /** - * A vertex represents a 2D point in the image. NOTE: the vertex coordinates are in the same scale as the original image. - */ - export interface Schema$GoogleCloudVisionV1p6beta1Vertex { - /** - * X coordinate. - */ - x?: number; - /** - * Y coordinate. - */ - y?: number; - } - /** - * Relevant information for the image from the Internet. - */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetection { - /** - * The service's best guess as to the topic of the request image. Inferred from similar images on the open web. - */ - bestGuessLabels?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebLabel[]; - /** - * Fully matching images from the Internet. Can include resized copies of the query image. - */ - fullMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; - /** - * Web pages containing the matching images from the Internet. - */ - pagesWithMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebPage[]; - /** - * Partial matching images from the Internet. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. - */ - partialMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; - /** - * The visually similar image results. - */ - visuallySimilarImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; - /** - * Deduced entities from similar images on the Internet. - */ - webEntities?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebEntity[]; - } - /** - * Entity deduced from similar images on the Internet. - */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetectionWebEntity { - /** - * Canonical description of the entity, in English. - */ - description?: string; - /** - * Opaque entity ID. - */ - entityId?: string; - /** - * Overall relevancy score for the entity. Not normalized and not comparable across different image queries. - */ - score?: number; - } - /** - * Metadata for online images. - */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage { - /** - * (Deprecated) Overall relevancy score for the image. - */ - score?: number; - /** - * The result image URL. - */ - url?: string; - } - /** - * Label to provide extra metadata for the web detection. - */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetectionWebLabel { - /** - * Label for extra metadata. - */ - label?: string; - /** - * The BCP-47 language code for `label`, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. - */ - languageCode?: string; - } - /** - * Metadata for web pages. - */ - export interface Schema$GoogleCloudVisionV1p6beta1WebDetectionWebPage { - /** - * Fully matching images on the page. Can include resized copies of the query image. - */ - fullMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; - /** - * Title for the web page, may contain HTML markups. - */ - pageTitle?: string; - /** - * Partial matching images on the page. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. - */ - partialMatchingImages?: Schema$GoogleCloudVisionV1p6beta1WebDetectionWebImage[]; - /** - * (Deprecated) Overall relevancy score for the web page. - */ - score?: number; - /** - * The result web page URL. - */ - url?: string; - } - /** - * A word representation. - */ - export interface Schema$GoogleCloudVisionV1p6beta1Word { - /** - * The bounding box for the word. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$GoogleCloudVisionV1p6beta1BoundingPoly; - /** - * Confidence of the OCR results for the word. Range [0, 1]. - */ - confidence?: number; - /** - * Additional information detected for the word. - */ - property?: Schema$GoogleCloudVisionV1p6beta1TextAnnotationTextProperty; - /** - * List of symbols in the word. The order of the symbols follows the natural reading order. - */ - symbols?: Schema$GoogleCloudVisionV1p6beta1Symbol[]; - } - /** - * Information about the products similar to a single product in a query image. - */ - export interface Schema$GroupedResult { - /** - * The bounding polygon around the product detected in the query image. - */ - boundingPoly?: Schema$BoundingPoly; - /** - * List of results, one for each product match. - */ - results?: Schema$Result[]; - } - /** - * If an image was produced from a file (e.g. a PDF), this message gives information about the source of that image. - */ - export interface Schema$ImageAnnotationContext { - /** - * If the file was a PDF or TIFF, this field gives the page number within the file used to produce the image. - */ - pageNumber?: number; - /** - * The URI of the file used to produce the image. - */ - uri?: string; - } - /** - * Stores image properties, such as dominant colors. - */ - export interface Schema$ImageProperties { - /** - * If present, dominant colors completed successfully. - */ - dominantColors?: Schema$DominantColorsAnnotation; - } - /** - * Response message for the `ImportProductSets` method. This message is returned by the google.longrunning.Operations.GetOperation method in the returned google.longrunning.Operation.response field. - */ - export interface Schema$ImportProductSetsResponse { - /** - * The list of reference_images that are imported successfully. - */ - referenceImages?: Schema$ReferenceImage[]; - /** - * The rpc status for each ImportProductSet request, including both successes and errors. The number of statuses here matches the number of lines in the csv file, and statuses[i] stores the success or failure status of processing the i-th line of the csv, starting from line 0. - */ - statuses?: Schema$Status[]; - } - /** - * The desired input location and metadata. - */ - export interface Schema$InputConfig { - /** - * File content, represented as a stream of bytes. Note: As with all `bytes` fields, protobuffers use a pure binary representation, whereas JSON representations use base64. Currently, this field only works for BatchAnnotateFiles requests. It does not work for AsyncBatchAnnotateFiles requests. - */ - content?: string; - /** - * The Google Cloud Storage location to read the input from. - */ - gcsSource?: Schema$GcsSource; - /** - * The type of the file. Currently only "application/pdf", "image/tiff" and "image/gif" are supported. Wildcards are not supported. - */ - mimeType?: string; - } - /** - * A product label represented as a key-value pair. - */ - export interface Schema$KeyValue { - /** - * The key of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. - */ - key?: string; - /** - * The value of the label attached to the product. Cannot be empty and cannot exceed 128 bytes. - */ - value?: string; - } - /** - * A face-specific landmark (for example, a face feature). - */ - export interface Schema$Landmark { - /** - * Face landmark position. - */ - position?: Schema$Position; - /** - * Face landmark type. - */ - type?: string; - } - /** - * An object representing a latitude/longitude pair. This is expressed as a pair of doubles representing degrees latitude and degrees longitude. Unless specified otherwise, this must conform to the <a href="http://www.unoosa.org/pdf/icg/2012/template/WGS_84.pdf">WGS84 standard</a>. Values must be within normalized ranges. - */ - export interface Schema$LatLng { - /** - * The latitude in degrees. It must be in the range [-90.0, +90.0]. - */ - latitude?: number; - /** - * The longitude in degrees. It must be in the range [-180.0, +180.0]. - */ - longitude?: number; - } - /** - * Set of detected objects with bounding boxes. - */ - export interface Schema$LocalizedObjectAnnotation { - /** - * Image region to which this object belongs. This must be populated. - */ - boundingPoly?: Schema$BoundingPoly; - /** - * The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. - */ - languageCode?: string; - /** - * Object ID that should align with EntityAnnotation mid. - */ - mid?: string; - /** - * Object name, expressed in its `language_code` language. - */ - name?: string; - /** - * Score of the result. Range [0, 1]. - */ - score?: number; - } - /** - * Detected entity location information. - */ - export interface Schema$LocationInfo { - /** - * lat/long location coordinates. - */ - latLng?: Schema$LatLng; - } - /** - * A vertex represents a 2D point in the image. NOTE: the normalized vertex coordinates are relative to the original image and range from 0 to 1. - */ - export interface Schema$NormalizedVertex { - /** - * X coordinate. - */ - x?: number; - /** - * Y coordinate. - */ - y?: number; - } - /** - * This resource represents a long-running operation that is the result of a network API call. - */ - export interface Schema$Operation { - /** - * If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available. - */ - done?: boolean; - /** - * The error result of the operation in case of failure or cancellation. - */ - error?: Schema$Status; - /** - * Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any. - */ - metadata?: {[key: string]: any}; - /** - * The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`. - */ - name?: string; - /** - * The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. - */ - response?: {[key: string]: any}; - } - /** - * Contains metadata for the BatchAnnotateImages operation. - */ - export interface Schema$OperationMetadata { - /** - * The time when the batch request was received. - */ - createTime?: string; - /** - * Current state of the batch operation. - */ - state?: string; - /** - * The time when the operation result was last updated. - */ - updateTime?: string; - } - /** - * The desired output location and metadata. - */ - export interface Schema$OutputConfig { - /** - * The max number of response protos to put into each output JSON file on Google Cloud Storage. The valid range is [1, 100]. If not specified, the default value is 20. For example, for one pdf file with 100 pages, 100 response protos will be generated. If `batch_size` = 20, then 5 json files each containing 20 response protos will be written under the prefix `gcs_destination`.`uri`. Currently, batch_size only applies to GcsDestination, with potential future support for other output configurations. - */ - batchSize?: number; - /** - * The Google Cloud Storage location to write the output(s) to. - */ - gcsDestination?: Schema$GcsDestination; - } - /** - * Detected page from OCR. - */ - export interface Schema$Page { - /** - * List of blocks of text, images etc on this page. - */ - blocks?: Schema$Block[]; - /** - * Confidence of the OCR results on the page. Range [0, 1]. - */ - confidence?: number; - /** - * Page height. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. - */ - height?: number; - /** - * Additional information detected on the page. - */ - property?: Schema$TextProperty; - /** - * Page width. For PDFs the unit is points. For images (including TIFFs) the unit is pixels. - */ - width?: number; - } - /** - * Structural unit of text representing a number of words in certain order. - */ - export interface Schema$Paragraph { - /** - * The bounding box for the paragraph. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$BoundingPoly; - /** - * Confidence of the OCR results for the paragraph. Range [0, 1]. - */ - confidence?: number; - /** - * Additional information detected for the paragraph. - */ - property?: Schema$TextProperty; - /** - * List of words in this paragraph. - */ - words?: Schema$Word[]; - } - /** - * A 3D position in the image, used primarily for Face detection landmarks. A valid Position must have both x and y coordinates. The position coordinates are in the same scale as the original image. - */ - export interface Schema$Position { - /** - * X coordinate. - */ - x?: number; - /** - * Y coordinate. - */ - y?: number; - /** - * Z coordinate (or depth). - */ - z?: number; - } - /** - * A Product contains ReferenceImages. - */ - export interface Schema$Product { - /** - * User-provided metadata to be stored with this product. Must be at most 4096 characters long. - */ - description?: string; - /** - * The user-provided name for this Product. Must not be empty. Must be at most 4096 characters long. - */ - displayName?: string; - /** - * The resource name of the product. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`. This field is ignored when creating a product. - */ - name?: string; - /** - * The category for the product identified by the reference image. This should be either "homegoods-v2", "apparel-v2", or "toys-v2". The legacy categories "homegoods", "apparel", and "toys" are still supported, but these should not be used for new products. This field is immutable. - */ - productCategory?: string; - /** - * Key-value pairs that can be attached to a product. At query time, constraints can be specified based on the product_labels. Note that integer values can be provided as strings, e.g. "1199". Only strings with integer values can match a range-based restriction which is to be supported soon. Multiple values can be assigned to the same key. One product may have up to 100 product_labels. - */ - productLabels?: Schema$KeyValue[]; - } - /** - * Results for a product search request. - */ - export interface Schema$ProductSearchResults { - /** - * Timestamp of the index which provided these results. Products added to the product set and products removed from the product set after this time are not reflected in the current results. - */ - indexTime?: string; - /** - * List of results grouped by products detected in the query image. Each entry corresponds to one bounding polygon in the query image, and contains the matching products specific to that region. There may be duplicate product matches in the union of all the per-product results. - */ - productGroupedResults?: Schema$GroupedResult[]; - /** - * List of results, one for each product match. - */ - results?: Schema$Result[]; - } - /** - * A `Property` consists of a user-supplied name/value pair. - */ - export interface Schema$Property { - /** - * Name of the property. - */ - name?: string; - /** - * Value of numeric properties. - */ - uint64Value?: string; - /** - * Value of the property. - */ - value?: string; - } - /** - * A `ReferenceImage` represents a product image and its associated metadata, such as bounding boxes. - */ - export interface Schema$ReferenceImage { - /** - * Bounding polygons around the areas of interest in the reference image. Optional. If this field is empty, the system will try to detect regions of interest. At most 10 bounding polygons will be used. The provided shape is converted into a non-rotated rectangle. Once converted, the small edge of the rectangle must be greater than or equal to 300 pixels. The aspect ratio must be 1:4 or less (i.e. 1:3 is ok; 1:5 is not). - */ - boundingPolys?: Schema$BoundingPoly[]; - /** - * The resource name of the reference image. Format is: `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`. This field is ignored when creating a reference image. - */ - name?: string; - /** - * The Google Cloud Storage URI of the reference image. The URI must start with `gs://`. Required. - */ - uri?: string; - } - /** - * Information about a product. - */ - export interface Schema$Result { - /** - * The resource name of the image from the product that is the closest match to the query. - */ - image?: string; - /** - * The Product. - */ - product?: Schema$Product; - /** - * A confidence level on the match, ranging from 0 (no confidence) to 1 (full confidence). - */ - score?: number; - } - /** - * Set of features pertaining to the image, computed by computer vision methods over safe-search verticals (for example, adult, spoof, medical, violence). - */ - export interface Schema$SafeSearchAnnotation { - /** - * Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities. - */ - adult?: string; - /** - * Likelihood that this is a medical image. - */ - medical?: string; - /** - * Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas. - */ - racy?: string; - /** - * Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive. - */ - spoof?: string; - /** - * Likelihood that this image contains violent content. - */ - violence?: string; - } - /** - * The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). - */ - export interface Schema$Status { - /** - * The status code, which should be an enum value of google.rpc.Code. - */ - code?: number; - /** - * A list of messages that carry the error details. There is a common set of message types for APIs to use. - */ - details?: Array<{[key: string]: any}>; - /** - * A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. - */ - message?: string; - } - /** - * A single symbol representation. - */ - export interface Schema$Symbol { - /** - * The bounding box for the symbol. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertice order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$BoundingPoly; - /** - * Confidence of the OCR results for the symbol. Range [0, 1]. - */ - confidence?: number; + + export class Resource$Images { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + /** - * Additional information detected for the symbol. + * vision.images.annotate + * @desc Run image detection and annotation for a batch of images. + * @alias vision.images.annotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().GoogleCloudVisionV1p2beta1BatchAnnotateImagesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - property?: Schema$TextProperty; + annotate( + params?: Params$Resource$Images$Annotate, + options?: MethodOptions + ): GaxiosPromise< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + >; + annotate( + params: Params$Resource$Images$Annotate, + options: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + >, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + > + ): void; + annotate( + params: Params$Resource$Images$Annotate, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + > + ): void; + annotate( + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + > + ): void; + annotate( + paramsOrCallback?: + | Params$Resource$Images$Annotate + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + >, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + >, + callback?: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + > + ): void | GaxiosPromise< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + > { + let params = (paramsOrCallback || {}) as Params$Resource$Images$Annotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Images$Annotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1p2beta1/images:annotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + >(parameters, callback); + } else { + return createAPIRequest< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + >(parameters); + } + } + /** - * The actual UTF-8 representation of the symbol. + * vision.images.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of images. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateImagesResponse` (results). This service will write image annotation outputs to json files in customer GCS bucket, each json file containing BatchAnnotateImagesResponse proto. + * @alias vision.images.asyncBatchAnnotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {().GoogleCloudVisionV1p2beta1AsyncBatchAnnotateImagesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - text?: string; + asyncBatchAnnotate( + params?: Params$Resource$Images$Asyncbatchannotate, + options?: MethodOptions + ): GaxiosPromise; + asyncBatchAnnotate( + params: Params$Resource$Images$Asyncbatchannotate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate( + params: Params$Resource$Images$Asyncbatchannotate, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( + paramsOrCallback?: + | Params$Resource$Images$Asyncbatchannotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Images$Asyncbatchannotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Images$Asyncbatchannotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1p2beta1/images:asyncBatchAnnotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: [], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } - /** - * TextAnnotation contains a structured representation of OCR extracted text. The hierarchy of an OCR extracted text structure is like this: TextAnnotation -> Page -> Block -> Paragraph -> Word -> Symbol Each structural component, starting from Page, may further have their own properties. Properties describe detected languages, breaks etc.. Please refer to the TextAnnotation.TextProperty message definition below for more detail. - */ - export interface Schema$TextAnnotation { + + export interface Params$Resource$Images$Annotate extends StandardParameters { /** - * List of pages detected by OCR. + * Auth client or API Key for the request */ - pages?: Schema$Page[]; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * UTF-8 text detected on the pages. + * Request body metadata */ - text?: string; + requestBody?: Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesRequest; } - /** - * Additional information detected on the structural component. - */ - export interface Schema$TextProperty { + export interface Params$Resource$Images$Asyncbatchannotate + extends StandardParameters { /** - * Detected start or end of a text segment. + * Auth client or API Key for the request */ - detectedBreak?: Schema$DetectedBreak; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * A list of detected languages together with confidence. + * Request body metadata */ - detectedLanguages?: Schema$DetectedLanguage[]; + requestBody?: Schema$GoogleCloudVisionV1p2beta1AsyncBatchAnnotateImagesRequest; } - /** - * A vertex represents a 2D point in the image. NOTE: the vertex coordinates are in the same scale as the original image. - */ - export interface Schema$Vertex { + + export class Resource$Projects { + context: APIRequestContext; + files: Resource$Projects$Files; + images: Resource$Projects$Images; + locations: Resource$Projects$Locations; + constructor(context: APIRequestContext) { + this.context = context; + this.files = new Resource$Projects$Files(this.context); + this.images = new Resource$Projects$Images(this.context); + this.locations = new Resource$Projects$Locations(this.context); + } + } + + export class Resource$Projects$Files { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + /** - * X coordinate. + * vision.projects.files.annotate + * @desc Service that performs image detection and annotation for a batch of files. Now only "application/pdf", "image/tiff" and "image/gif" are supported. This service will extract at most 5 (customers can specify which 5 in AnnotateFileRequest.pages) frames (gif) or pages (pdf or tiff) from each file provided and perform detection and annotation for each image extracted. + * @alias vision.projects.files.annotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().GoogleCloudVisionV1p2beta1BatchAnnotateFilesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - x?: number; + annotate( + params?: Params$Resource$Projects$Files$Annotate, + options?: MethodOptions + ): GaxiosPromise< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + >; + annotate( + params: Params$Resource$Projects$Files$Annotate, + options: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + >, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + > + ): void; + annotate( + params: Params$Resource$Projects$Files$Annotate, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + > + ): void; + annotate( + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + > + ): void; + annotate( + paramsOrCallback?: + | Params$Resource$Projects$Files$Annotate + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + >, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + >, + callback?: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + > + ): void | GaxiosPromise< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + > { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Files$Annotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Files$Annotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1p2beta1/{+parent}/files:annotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + >(parameters, callback); + } else { + return createAPIRequest< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse + >(parameters); + } + } + /** - * Y coordinate. + * vision.projects.files.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of generic files, such as PDF files, which may contain multiple pages and multiple images per page. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results). + * @alias vision.projects.files.asyncBatchAnnotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().GoogleCloudVisionV1p2beta1AsyncBatchAnnotateFilesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - y?: number; + asyncBatchAnnotate( + params?: Params$Resource$Projects$Files$Asyncbatchannotate, + options?: MethodOptions + ): GaxiosPromise; + asyncBatchAnnotate( + params: Params$Resource$Projects$Files$Asyncbatchannotate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate( + params: Params$Resource$Projects$Files$Asyncbatchannotate, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( + paramsOrCallback?: + | Params$Resource$Projects$Files$Asyncbatchannotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Files$Asyncbatchannotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Files$Asyncbatchannotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + '/v1p2beta1/{+parent}/files:asyncBatchAnnotate' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } - /** - * Relevant information for the image from the Internet. - */ - export interface Schema$WebDetection { + + export interface Params$Resource$Projects$Files$Annotate + extends StandardParameters { /** - * The service's best guess as to the topic of the request image. Inferred from similar images on the open web. + * Auth client or API Key for the request */ - bestGuessLabels?: Schema$WebLabel[]; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * Fully matching images from the Internet. Can include resized copies of the query image. + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. */ - fullMatchingImages?: Schema$WebImage[]; + parent?: string; + /** - * Web pages containing the matching images from the Internet. + * Request body metadata */ - pagesWithMatchingImages?: Schema$WebPage[]; + requestBody?: Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesRequest; + } + export interface Params$Resource$Projects$Files$Asyncbatchannotate + extends StandardParameters { /** - * Partial matching images from the Internet. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. + * Auth client or API Key for the request */ - partialMatchingImages?: Schema$WebImage[]; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * The visually similar image results. + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. */ - visuallySimilarImages?: Schema$WebImage[]; + parent?: string; + /** - * Deduced entities from similar images on the Internet. + * Request body metadata */ - webEntities?: Schema$WebEntity[]; + requestBody?: Schema$GoogleCloudVisionV1p2beta1AsyncBatchAnnotateFilesRequest; } - /** - * Entity deduced from similar images on the Internet. - */ - export interface Schema$WebEntity { - /** - * Canonical description of the entity, in English. - */ - description?: string; + + export class Resource$Projects$Images { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + /** - * Opaque entity ID. + * vision.projects.images.annotate + * @desc Run image detection and annotation for a batch of images. + * @alias vision.projects.images.annotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().GoogleCloudVisionV1p2beta1BatchAnnotateImagesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - entityId?: string; + annotate( + params?: Params$Resource$Projects$Images$Annotate, + options?: MethodOptions + ): GaxiosPromise< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + >; + annotate( + params: Params$Resource$Projects$Images$Annotate, + options: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + >, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + > + ): void; + annotate( + params: Params$Resource$Projects$Images$Annotate, + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + > + ): void; + annotate( + callback: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + > + ): void; + annotate( + paramsOrCallback?: + | Params$Resource$Projects$Images$Annotate + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + >, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + >, + callback?: BodyResponseCallback< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + > + ): void | GaxiosPromise< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + > { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Images$Annotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Images$Annotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1p2beta1/{+parent}/images:annotate').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + >(parameters, callback); + } else { + return createAPIRequest< + Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse + >(parameters); + } + } + /** - * Overall relevancy score for the entity. Not normalized and not comparable across different image queries. + * vision.projects.images.asyncBatchAnnotate + * @desc Run asynchronous image detection and annotation for a list of images. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateImagesResponse` (results). This service will write image annotation outputs to json files in customer GCS bucket, each json file containing BatchAnnotateImagesResponse proto. + * @alias vision.projects.images.asyncBatchAnnotate + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + * @param {().GoogleCloudVisionV1p2beta1AsyncBatchAnnotateImagesRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object */ - score?: number; + asyncBatchAnnotate( + params?: Params$Resource$Projects$Images$Asyncbatchannotate, + options?: MethodOptions + ): GaxiosPromise; + asyncBatchAnnotate( + params: Params$Resource$Projects$Images$Asyncbatchannotate, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate( + params: Params$Resource$Projects$Images$Asyncbatchannotate, + callback: BodyResponseCallback + ): void; + asyncBatchAnnotate(callback: BodyResponseCallback): void; + asyncBatchAnnotate( + paramsOrCallback?: + | Params$Resource$Projects$Images$Asyncbatchannotate + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Images$Asyncbatchannotate; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Images$Asyncbatchannotate; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://vision.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: ( + rootUrl + '/v1p2beta1/{+parent}/images:asyncBatchAnnotate' + ).replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } } - /** - * Metadata for online images. - */ - export interface Schema$WebImage { - /** - * (Deprecated) Overall relevancy score for the image. - */ - score?: number; + + export interface Params$Resource$Projects$Images$Annotate + extends StandardParameters { /** - * The result image URL. + * Auth client or API Key for the request */ - url?: string; - } - /** - * Label to provide extra metadata for the web detection. - */ - export interface Schema$WebLabel { + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * Label for extra metadata. + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. */ - label?: string; + parent?: string; + /** - * The BCP-47 language code for `label`, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. + * Request body metadata */ - languageCode?: string; + requestBody?: Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesRequest; } - /** - * Metadata for web pages. - */ - export interface Schema$WebPage { - /** - * Fully matching images on the page. Can include resized copies of the query image. - */ - fullMatchingImages?: Schema$WebImage[]; - /** - * Title for the web page, may contain HTML markups. - */ - pageTitle?: string; + export interface Params$Resource$Projects$Images$Asyncbatchannotate + extends StandardParameters { /** - * Partial matching images on the page. Those images are similar enough to share some key-point features. For example an original image will likely have partial matching for its crops. + * Auth client or API Key for the request */ - partialMatchingImages?: Schema$WebImage[]; + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** - * (Deprecated) Overall relevancy score for the web page. + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. */ - score?: number; + parent?: string; + /** - * The result web page URL. + * Request body metadata */ - url?: string; + requestBody?: Schema$GoogleCloudVisionV1p2beta1AsyncBatchAnnotateImagesRequest; } - /** - * A word representation. - */ - export interface Schema$Word { - /** - * The bounding box for the word. The vertices are in the order of top-left, top-right, bottom-right, bottom-left. When a rotation of the bounding box is detected the rotation is represented as around the top-left corner as defined when the text is read in the 'natural' orientation. For example: * when the text is horizontal it might look like: 0----1 | | 3----2 * when it's rotated 180 degrees around the top-left corner it becomes: 2----3 | | 1----0 and the vertex order will still be (0, 1, 2, 3). - */ - boundingBox?: Schema$BoundingPoly; - /** - * Confidence of the OCR results for the word. Range [0, 1]. - */ - confidence?: number; - /** - * Additional information detected for the word. - */ - property?: Schema$TextProperty; - /** - * List of symbols in the word. The order of the symbols follows the natural reading order. - */ - symbols?: Schema$Symbol[]; + + export class Resource$Projects$Locations { + context: APIRequestContext; + files: Resource$Projects$Locations$Files; + images: Resource$Projects$Locations$Images; + constructor(context: APIRequestContext) { + this.context = context; + this.files = new Resource$Projects$Locations$Files(this.context); + this.images = new Resource$Projects$Locations$Images(this.context); + } } - export class Resource$Files { + export class Resource$Projects$Locations$Files { context: APIRequestContext; constructor(context: APIRequestContext) { this.context = context; } /** - * vision.files.annotate + * vision.projects.locations.files.annotate * @desc Service that performs image detection and annotation for a batch of files. Now only "application/pdf", "image/tiff" and "image/gif" are supported. This service will extract at most 5 (customers can specify which 5 in AnnotateFileRequest.pages) frames (gif) or pages (pdf or tiff) from each file provided and perform detection and annotation for each image extracted. - * @alias vision.files.annotate + * @alias vision.projects.locations.files.annotate * @memberOf! () * * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. * @param {().GoogleCloudVisionV1p2beta1BatchAnnotateFilesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ annotate( - params?: Params$Resource$Files$Annotate, + params?: Params$Resource$Projects$Locations$Files$Annotate, options?: MethodOptions ): GaxiosPromise< Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse >; annotate( - params: Params$Resource$Files$Annotate, + params: Params$Resource$Projects$Locations$Files$Annotate, options: | MethodOptions | BodyResponseCallback< @@ -6740,7 +6966,7 @@ export namespace vision_v1p2beta1 { > ): void; annotate( - params: Params$Resource$Files$Annotate, + params: Params$Resource$Projects$Locations$Files$Annotate, callback: BodyResponseCallback< Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse > @@ -6752,7 +6978,7 @@ export namespace vision_v1p2beta1 { ): void; annotate( paramsOrCallback?: - | Params$Resource$Files$Annotate + | Params$Resource$Projects$Locations$Files$Annotate | BodyResponseCallback< Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse >, @@ -6767,12 +6993,13 @@ export namespace vision_v1p2beta1 { ): void | GaxiosPromise< Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesResponse > { - let params = (paramsOrCallback || {}) as Params$Resource$Files$Annotate; + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Files$Annotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Files$Annotate; + params = {} as Params$Resource$Projects$Locations$Files$Annotate; options = {}; } @@ -6785,7 +7012,7 @@ export namespace vision_v1p2beta1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1p2beta1/files:annotate').replace( + url: (rootUrl + '/v1p2beta1/{+parent}/files:annotate').replace( /([^:]\/)\/+/g, '$1' ), @@ -6794,8 +7021,8 @@ export namespace vision_v1p2beta1 { options ), params, - requiredParams: [], - pathParams: [], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { @@ -6810,34 +7037,35 @@ export namespace vision_v1p2beta1 { } /** - * vision.files.asyncBatchAnnotate + * vision.projects.locations.files.asyncBatchAnnotate * @desc Run asynchronous image detection and annotation for a list of generic files, such as PDF files, which may contain multiple pages and multiple images per page. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results). - * @alias vision.files.asyncBatchAnnotate + * @alias vision.projects.locations.files.asyncBatchAnnotate * @memberOf! () * * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. * @param {().GoogleCloudVisionV1p2beta1AsyncBatchAnnotateFilesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ asyncBatchAnnotate( - params?: Params$Resource$Files$Asyncbatchannotate, + params?: Params$Resource$Projects$Locations$Files$Asyncbatchannotate, options?: MethodOptions ): GaxiosPromise; asyncBatchAnnotate( - params: Params$Resource$Files$Asyncbatchannotate, + params: Params$Resource$Projects$Locations$Files$Asyncbatchannotate, options: MethodOptions | BodyResponseCallback, callback: BodyResponseCallback ): void; asyncBatchAnnotate( - params: Params$Resource$Files$Asyncbatchannotate, + params: Params$Resource$Projects$Locations$Files$Asyncbatchannotate, callback: BodyResponseCallback ): void; asyncBatchAnnotate(callback: BodyResponseCallback): void; asyncBatchAnnotate( paramsOrCallback?: - | Params$Resource$Files$Asyncbatchannotate + | Params$Resource$Projects$Locations$Files$Asyncbatchannotate | BodyResponseCallback, optionsOrCallback?: | MethodOptions @@ -6845,12 +7073,12 @@ export namespace vision_v1p2beta1 { callback?: BodyResponseCallback ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Files$Asyncbatchannotate; + {}) as Params$Resource$Projects$Locations$Files$Asyncbatchannotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Files$Asyncbatchannotate; + params = {} as Params$Resource$Projects$Locations$Files$Asyncbatchannotate; options = {}; } @@ -6863,17 +7091,16 @@ export namespace vision_v1p2beta1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1p2beta1/files:asyncBatchAnnotate').replace( - /([^:]\/)\/+/g, - '$1' - ), + url: ( + rootUrl + '/v1p2beta1/{+parent}/files:asyncBatchAnnotate' + ).replace(/([^:]\/)\/+/g, '$1'), method: 'POST', }, options ), params, - requiredParams: [], - pathParams: [], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { @@ -6884,56 +7111,68 @@ export namespace vision_v1p2beta1 { } } - export interface Params$Resource$Files$Annotate extends StandardParameters { + export interface Params$Resource$Projects$Locations$Files$Annotate + extends StandardParameters { /** * Auth client or API Key for the request */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + /** * Request body metadata */ requestBody?: Schema$GoogleCloudVisionV1p2beta1BatchAnnotateFilesRequest; } - export interface Params$Resource$Files$Asyncbatchannotate + export interface Params$Resource$Projects$Locations$Files$Asyncbatchannotate extends StandardParameters { /** * Auth client or API Key for the request */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + /** * Request body metadata */ requestBody?: Schema$GoogleCloudVisionV1p2beta1AsyncBatchAnnotateFilesRequest; } - export class Resource$Images { + export class Resource$Projects$Locations$Images { context: APIRequestContext; constructor(context: APIRequestContext) { this.context = context; } /** - * vision.images.annotate + * vision.projects.locations.images.annotate * @desc Run image detection and annotation for a batch of images. - * @alias vision.images.annotate + * @alias vision.projects.locations.images.annotate * @memberOf! () * * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. * @param {().GoogleCloudVisionV1p2beta1BatchAnnotateImagesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ annotate( - params?: Params$Resource$Images$Annotate, + params?: Params$Resource$Projects$Locations$Images$Annotate, options?: MethodOptions ): GaxiosPromise< Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse >; annotate( - params: Params$Resource$Images$Annotate, + params: Params$Resource$Projects$Locations$Images$Annotate, options: | MethodOptions | BodyResponseCallback< @@ -6944,7 +7183,7 @@ export namespace vision_v1p2beta1 { > ): void; annotate( - params: Params$Resource$Images$Annotate, + params: Params$Resource$Projects$Locations$Images$Annotate, callback: BodyResponseCallback< Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse > @@ -6956,7 +7195,7 @@ export namespace vision_v1p2beta1 { ): void; annotate( paramsOrCallback?: - | Params$Resource$Images$Annotate + | Params$Resource$Projects$Locations$Images$Annotate | BodyResponseCallback< Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse >, @@ -6971,12 +7210,13 @@ export namespace vision_v1p2beta1 { ): void | GaxiosPromise< Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesResponse > { - let params = (paramsOrCallback || {}) as Params$Resource$Images$Annotate; + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Locations$Images$Annotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Images$Annotate; + params = {} as Params$Resource$Projects$Locations$Images$Annotate; options = {}; } @@ -6989,7 +7229,7 @@ export namespace vision_v1p2beta1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1p2beta1/images:annotate').replace( + url: (rootUrl + '/v1p2beta1/{+parent}/images:annotate').replace( /([^:]\/)\/+/g, '$1' ), @@ -6998,8 +7238,8 @@ export namespace vision_v1p2beta1 { options ), params, - requiredParams: [], - pathParams: [], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { @@ -7014,34 +7254,35 @@ export namespace vision_v1p2beta1 { } /** - * vision.images.asyncBatchAnnotate + * vision.projects.locations.images.asyncBatchAnnotate * @desc Run asynchronous image detection and annotation for a list of images. Progress and results can be retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateImagesResponse` (results). This service will write image annotation outputs to json files in customer GCS bucket, each json file containing BatchAnnotateImagesResponse proto. - * @alias vision.images.asyncBatchAnnotate + * @alias vision.projects.locations.images.asyncBatchAnnotate * @memberOf! () * * @param {object} params Parameters for request + * @param {string} params.parent Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. * @param {().GoogleCloudVisionV1p2beta1AsyncBatchAnnotateImagesRequest} params.resource Request body data * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. * @param {callback} callback The callback that handles the response. * @return {object} Request object */ asyncBatchAnnotate( - params?: Params$Resource$Images$Asyncbatchannotate, + params?: Params$Resource$Projects$Locations$Images$Asyncbatchannotate, options?: MethodOptions ): GaxiosPromise; asyncBatchAnnotate( - params: Params$Resource$Images$Asyncbatchannotate, + params: Params$Resource$Projects$Locations$Images$Asyncbatchannotate, options: MethodOptions | BodyResponseCallback, callback: BodyResponseCallback ): void; asyncBatchAnnotate( - params: Params$Resource$Images$Asyncbatchannotate, + params: Params$Resource$Projects$Locations$Images$Asyncbatchannotate, callback: BodyResponseCallback ): void; asyncBatchAnnotate(callback: BodyResponseCallback): void; asyncBatchAnnotate( paramsOrCallback?: - | Params$Resource$Images$Asyncbatchannotate + | Params$Resource$Projects$Locations$Images$Asyncbatchannotate | BodyResponseCallback, optionsOrCallback?: | MethodOptions @@ -7049,12 +7290,12 @@ export namespace vision_v1p2beta1 { callback?: BodyResponseCallback ): void | GaxiosPromise { let params = (paramsOrCallback || - {}) as Params$Resource$Images$Asyncbatchannotate; + {}) as Params$Resource$Projects$Locations$Images$Asyncbatchannotate; let options = (optionsOrCallback || {}) as MethodOptions; if (typeof paramsOrCallback === 'function') { callback = paramsOrCallback; - params = {} as Params$Resource$Images$Asyncbatchannotate; + params = {} as Params$Resource$Projects$Locations$Images$Asyncbatchannotate; options = {}; } @@ -7067,17 +7308,16 @@ export namespace vision_v1p2beta1 { const parameters = { options: Object.assign( { - url: (rootUrl + '/v1p2beta1/images:asyncBatchAnnotate').replace( - /([^:]\/)\/+/g, - '$1' - ), + url: ( + rootUrl + '/v1p2beta1/{+parent}/images:asyncBatchAnnotate' + ).replace(/([^:]\/)\/+/g, '$1'), method: 'POST', }, options ), params, - requiredParams: [], - pathParams: [], + requiredParams: ['parent'], + pathParams: ['parent'], context: this.context, }; if (callback) { @@ -7088,24 +7328,35 @@ export namespace vision_v1p2beta1 { } } - export interface Params$Resource$Images$Annotate extends StandardParameters { + export interface Params$Resource$Projects$Locations$Images$Annotate + extends StandardParameters { /** * Auth client or API Key for the request */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + /** * Request body metadata */ requestBody?: Schema$GoogleCloudVisionV1p2beta1BatchAnnotateImagesRequest; } - export interface Params$Resource$Images$Asyncbatchannotate + export interface Params$Resource$Projects$Locations$Images$Asyncbatchannotate extends StandardParameters { /** * Auth client or API Key for the request */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + /** + * Optional. Target project and location to make a call. Format: `projects/{project-id}/locations/{location-id}`. If no parent is specified, a region will be chosen automatically. Supported location-ids: `us`: USA country only, `asia`: East asia areas, like Japan, Taiwan, `eu`: The European Union. Example: `projects/project-A/locations/eu`. + */ + parent?: string; + /** * Request body metadata */ diff --git a/src/apis/websecurityscanner/v1.ts b/src/apis/websecurityscanner/v1.ts index d8e7749bd6f..29907843e79 100644 --- a/src/apis/websecurityscanner/v1.ts +++ b/src/apis/websecurityscanner/v1.ts @@ -105,12 +105,1730 @@ export namespace websecurityscanner_v1 { */ export class Websecurityscanner { context: APIRequestContext; + projects: Resource$Projects; constructor(options: GlobalOptions, google?: GoogleConfigurable) { this.context = { _options: options || {}, google, }; + + this.projects = new Resource$Projects(this.context); } } + + /** + * Scan authentication configuration. + */ + export interface Schema$Authentication { + /** + * Authentication using a custom account. + */ + customAccount?: Schema$CustomAccount; + /** + * Authentication using a Google account. + */ + googleAccount?: Schema$GoogleAccount; + } + /** + * A CrawledUrl resource represents a URL that was crawled during a ScanRun. Web Security Scanner Service crawls the web applications, following all links within the scope of sites, to find the URLs to test against. + */ + export interface Schema$CrawledUrl { + /** + * Output only. The body of the request that was used to visit the URL. + */ + body?: string; + /** + * Output only. The http method of the request that was used to visit the URL, in uppercase. + */ + httpMethod?: string; + /** + * Output only. The URL that was crawled. + */ + url?: string; + } + /** + * Describes authentication configuration that uses a custom account. + */ + export interface Schema$CustomAccount { + /** + * Required. The login form URL of the website. + */ + loginUrl?: string; + /** + * Required. Input only. The password of the custom account. The credential is stored encrypted and not returned in any response nor included in audit logs. + */ + password?: string; + /** + * Required. The user name of the custom account. + */ + username?: string; + } + /** + * A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`. + */ + export interface Schema$Empty {} + /** + * A Finding resource represents a vulnerability instance identified during a ScanRun. + */ + export interface Schema$Finding { + /** + * Output only. The body of the request that triggered the vulnerability. + */ + body?: string; + /** + * Output only. The description of the vulnerability. + */ + description?: string; + /** + * Output only. The URL where the browser lands when the vulnerability is detected. + */ + finalUrl?: string; + /** + * Output only. The type of the Finding. Detailed and up-to-date information on findings can be found here: https://cloud.google.com/security-scanner/docs/scan-result-details + */ + findingType?: string; + /** + * Output only. An addon containing information reported for a vulnerability with an HTML form, if any. + */ + form?: Schema$Form; + /** + * Output only. If the vulnerability was originated from nested IFrame, the immediate parent IFrame is reported. + */ + frameUrl?: string; + /** + * Output only. The URL produced by the server-side fuzzer and used in the request that triggered the vulnerability. + */ + fuzzedUrl?: string; + /** + * Output only. The http method of the request that triggered the vulnerability, in uppercase. + */ + httpMethod?: string; + /** + * Output only. The resource name of the Finding. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}/scanruns/{scanRunId}/findings/{findingId}'. The finding IDs are generated by the system. + */ + name?: string; + /** + * Output only. An addon containing information about outdated libraries. + */ + outdatedLibrary?: Schema$OutdatedLibrary; + /** + * Output only. The URL containing human-readable payload that user can leverage to reproduce the vulnerability. + */ + reproductionUrl?: string; + /** + * Output only. The tracking ID uniquely identifies a vulnerability instance across multiple ScanRuns. + */ + trackingId?: string; + /** + * Output only. An addon containing detailed information regarding any resource causing the vulnerability such as JavaScript sources, image, audio files, etc. + */ + violatingResource?: Schema$ViolatingResource; + /** + * Output only. An addon containing information about vulnerable or missing HTTP headers. + */ + vulnerableHeaders?: Schema$VulnerableHeaders; + /** + * Output only. An addon containing information about request parameters which were found to be vulnerable. + */ + vulnerableParameters?: Schema$VulnerableParameters; + /** + * Output only. An addon containing information reported for an XSS, if any. + */ + xss?: Schema$Xss; + } + /** + * A FindingTypeStats resource represents stats regarding a specific FindingType of Findings under a given ScanRun. + */ + export interface Schema$FindingTypeStats { + /** + * Output only. The count of findings belonging to this finding type. + */ + findingCount?: number; + /** + * Output only. The finding type associated with the stats. + */ + findingType?: string; + } + /** + * ! Information about a vulnerability with an HTML. + */ + export interface Schema$Form { + /** + * ! The URI where to send the form when it's submitted. + */ + actionUri?: string; + /** + * ! The names of form fields related to the vulnerability. + */ + fields?: string[]; + } + /** + * Describes authentication configuration that uses a Google account. + */ + export interface Schema$GoogleAccount { + /** + * Required. Input only. The password of the Google account. The credential is stored encrypted and not returned in any response nor included in audit logs. + */ + password?: string; + /** + * Required. The user name of the Google account. + */ + username?: string; + } + /** + * Describes a HTTP Header. + */ + export interface Schema$Header { + /** + * Header name. + */ + name?: string; + /** + * Header value. + */ + value?: string; + } + /** + * Response for the `ListCrawledUrls` method. + */ + export interface Schema$ListCrawledUrlsResponse { + /** + * The list of CrawledUrls returned. + */ + crawledUrls?: Schema$CrawledUrl[]; + /** + * Token to retrieve the next page of results, or empty if there are no more results in the list. + */ + nextPageToken?: string; + } + /** + * Response for the `ListFindings` method. + */ + export interface Schema$ListFindingsResponse { + /** + * The list of Findings returned. + */ + findings?: Schema$Finding[]; + /** + * Token to retrieve the next page of results, or empty if there are no more results in the list. + */ + nextPageToken?: string; + } + /** + * Response for the `ListFindingTypeStats` method. + */ + export interface Schema$ListFindingTypeStatsResponse { + /** + * The list of FindingTypeStats returned. + */ + findingTypeStats?: Schema$FindingTypeStats[]; + } + /** + * Response for the `ListScanConfigs` method. + */ + export interface Schema$ListScanConfigsResponse { + /** + * Token to retrieve the next page of results, or empty if there are no more results in the list. + */ + nextPageToken?: string; + /** + * The list of ScanConfigs returned. + */ + scanConfigs?: Schema$ScanConfig[]; + } + /** + * Response for the `ListScanRuns` method. + */ + export interface Schema$ListScanRunsResponse { + /** + * Token to retrieve the next page of results, or empty if there are no more results in the list. + */ + nextPageToken?: string; + /** + * The list of ScanRuns returned. + */ + scanRuns?: Schema$ScanRun[]; + } + /** + * Information reported for an outdated library. + */ + export interface Schema$OutdatedLibrary { + /** + * URLs to learn more information about the vulnerabilities in the library. + */ + learnMoreUrls?: string[]; + /** + * The name of the outdated library. + */ + libraryName?: string; + /** + * The version number. + */ + version?: string; + } + /** + * A ScanConfig resource contains the configurations to launch a scan. + */ + export interface Schema$ScanConfig { + /** + * The authentication configuration. If specified, service will use the authentication configuration during scanning. + */ + authentication?: Schema$Authentication; + /** + * The blacklist URL patterns as described in https://cloud.google.com/security-scanner/docs/excluded-urls + */ + blacklistPatterns?: string[]; + /** + * Required. The user provided display name of the ScanConfig. + */ + displayName?: string; + /** + * Controls export of scan configurations and results to Cloud Security Command Center. + */ + exportToSecurityCommandCenter?: string; + /** + * The maximum QPS during scanning. A valid value ranges from 5 to 20 inclusively. If the field is unspecified or its value is set 0, server will default to 15. Other values outside of [5, 20] range will be rejected with INVALID_ARGUMENT error. + */ + maxQps?: number; + /** + * The resource name of the ScanConfig. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. The ScanConfig IDs are generated by the system. + */ + name?: string; + /** + * The risk level selected for the scan + */ + riskLevel?: string; + /** + * The schedule of the ScanConfig. + */ + schedule?: Schema$Schedule; + /** + * Required. The starting URLs from which the scanner finds site pages. + */ + startingUrls?: string[]; + /** + * The user agent used during scanning. + */ + userAgent?: string; + } + /** + * Defines a custom error message used by CreateScanConfig and UpdateScanConfig APIs when scan configuration validation fails. It is also reported as part of a ScanRunErrorTrace message if scan validation fails due to a scan configuration error. + */ + export interface Schema$ScanConfigError { + /** + * Output only. Indicates the reason code for a configuration failure. + */ + code?: string; + /** + * Output only. Indicates the full name of the ScanConfig field that triggers this error, for example "scan_config.max_qps". This field is provided for troubleshooting purposes only and its actual value can change in the future. + */ + fieldName?: string; + } + /** + * A ScanRun is a output-only resource representing an actual run of the scan. Next id: 12 + */ + export interface Schema$ScanRun { + /** + * Output only. The time at which the ScanRun reached termination state - that the ScanRun is either finished or stopped by user. + */ + endTime?: string; + /** + * Output only. If result_state is an ERROR, this field provides the primary reason for scan's termination and more details, if such are available. + */ + errorTrace?: Schema$ScanRunErrorTrace; + /** + * Output only. The execution state of the ScanRun. + */ + executionState?: string; + /** + * Output only. Whether the scan run has found any vulnerabilities. + */ + hasVulnerabilities?: boolean; + /** + * Output only. The resource name of the ScanRun. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. The ScanRun IDs are generated by the system. + */ + name?: string; + /** + * Output only. The percentage of total completion ranging from 0 to 100. If the scan is in queue, the value is 0. If the scan is running, the value ranges from 0 to 100. If the scan is finished, the value is 100. + */ + progressPercent?: number; + /** + * Output only. The result state of the ScanRun. This field is only available after the execution state reaches "FINISHED". + */ + resultState?: string; + /** + * Output only. The time at which the ScanRun started. + */ + startTime?: string; + /** + * Output only. The number of URLs crawled during this ScanRun. If the scan is in progress, the value represents the number of URLs crawled up to now. + */ + urlsCrawledCount?: string; + /** + * Output only. The number of URLs tested during this ScanRun. If the scan is in progress, the value represents the number of URLs tested up to now. The number of URLs tested is usually larger than the number URLS crawled because typically a crawled URL is tested with multiple test payloads. + */ + urlsTestedCount?: string; + /** + * Output only. A list of warnings, if such are encountered during this scan run. + */ + warningTraces?: Schema$ScanRunWarningTrace[]; + } + /** + * Output only. Defines an error trace message for a ScanRun. + */ + export interface Schema$ScanRunErrorTrace { + /** + * Output only. Indicates the error reason code. + */ + code?: string; + /** + * Output only. If the scan encounters TOO_MANY_HTTP_ERRORS, this field indicates the most common HTTP error code, if such is available. For example, if this code is 404, the scan has encountered too many NOT_FOUND responses. + */ + mostCommonHttpErrorCode?: number; + /** + * Output only. If the scan encounters SCAN_CONFIG_ISSUE error, this field has the error message encountered during scan configuration validation that is performed before each scan run. + */ + scanConfigError?: Schema$ScanConfigError; + } + /** + * Output only. Defines a warning trace message for ScanRun. Warning traces provide customers with useful information that helps make the scanning process more effective. + */ + export interface Schema$ScanRunWarningTrace { + /** + * Output only. Indicates the warning code. + */ + code?: string; + } + /** + * Scan schedule configuration. + */ + export interface Schema$Schedule { + /** + * Required. The duration of time between executions in days. + */ + intervalDurationDays?: number; + /** + * A timestamp indicates when the next run will be scheduled. The value is refreshed by the server after each run. If unspecified, it will default to current server time, which means the scan will be scheduled to start immediately. + */ + scheduleTime?: string; + } + /** + * Request for the `StartScanRun` method. + */ + export interface Schema$StartScanRunRequest {} + /** + * Request for the `StopScanRun` method. + */ + export interface Schema$StopScanRunRequest {} + /** + * Information regarding any resource causing the vulnerability such as JavaScript sources, image, audio files, etc. + */ + export interface Schema$ViolatingResource { + /** + * The MIME type of this resource. + */ + contentType?: string; + /** + * URL of this violating resource. + */ + resourceUrl?: string; + } + /** + * Information about vulnerable or missing HTTP Headers. + */ + export interface Schema$VulnerableHeaders { + /** + * List of vulnerable headers. + */ + headers?: Schema$Header[]; + /** + * List of missing headers. + */ + missingHeaders?: Schema$Header[]; + } + /** + * Information about vulnerable request parameters. + */ + export interface Schema$VulnerableParameters { + /** + * The vulnerable parameter names. + */ + parameterNames?: string[]; + } + /** + * Information reported for an XSS. + */ + export interface Schema$Xss { + /** + * The attack vector of the payload triggering this XSS. + */ + attackVector?: string; + /** + * An error message generated by a javascript breakage. + */ + errorMessage?: string; + /** + * Stack traces leading to the point where the XSS occurred. + */ + stackTraces?: string[]; + /** + * The reproduction url for the seeding POST request of a Stored XSS. + */ + storedXssSeedingUrl?: string; + } + + export class Resource$Projects { + context: APIRequestContext; + scanConfigs: Resource$Projects$Scanconfigs; + constructor(context: APIRequestContext) { + this.context = context; + this.scanConfigs = new Resource$Projects$Scanconfigs(this.context); + } + } + + export class Resource$Projects$Scanconfigs { + context: APIRequestContext; + scanRuns: Resource$Projects$Scanconfigs$Scanruns; + constructor(context: APIRequestContext) { + this.context = context; + this.scanRuns = new Resource$Projects$Scanconfigs$Scanruns(this.context); + } + + /** + * websecurityscanner.projects.scanConfigs.create + * @desc Creates a new ScanConfig. + * @alias websecurityscanner.projects.scanConfigs.create + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Required. The parent resource name where the scan is created, which should be a project resource name in the format 'projects/{projectId}'. + * @param {().ScanConfig} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + create( + params?: Params$Resource$Projects$Scanconfigs$Create, + options?: MethodOptions + ): GaxiosPromise; + create( + params: Params$Resource$Projects$Scanconfigs$Create, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + create( + params: Params$Resource$Projects$Scanconfigs$Create, + callback: BodyResponseCallback + ): void; + create(callback: BodyResponseCallback): void; + create( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$Create + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$Create; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$Create; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+parent}/scanConfigs').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'POST', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * websecurityscanner.projects.scanConfigs.delete + * @desc Deletes an existing ScanConfig and its child resources. + * @alias websecurityscanner.projects.scanConfigs.delete + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Required. The resource name of the ScanConfig to be deleted. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + delete( + params?: Params$Resource$Projects$Scanconfigs$Delete, + options?: MethodOptions + ): GaxiosPromise; + delete( + params: Params$Resource$Projects$Scanconfigs$Delete, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + delete( + params: Params$Resource$Projects$Scanconfigs$Delete, + callback: BodyResponseCallback + ): void; + delete(callback: BodyResponseCallback): void; + delete( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$Delete + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$Delete; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$Delete; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'DELETE', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * websecurityscanner.projects.scanConfigs.get + * @desc Gets a ScanConfig. + * @alias websecurityscanner.projects.scanConfigs.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Required. The resource name of the ScanConfig to be returned. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Projects$Scanconfigs$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Projects$Scanconfigs$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Projects$Scanconfigs$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$Get + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * websecurityscanner.projects.scanConfigs.list + * @desc Lists ScanConfigs under a given project. + * @alias websecurityscanner.projects.scanConfigs.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {integer=} params.pageSize The maximum number of ScanConfigs to return, can be limited by server. If not specified or not positive, the implementation will select a reasonable value. + * @param {string=} params.pageToken A token identifying a page of results to be returned. This should be a `next_page_token` value returned from a previous List request. If unspecified, the first page of results is returned. + * @param {string} params.parent Required. The parent resource name, which should be a project resource name in the format 'projects/{projectId}'. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Scanconfigs$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Scanconfigs$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Scanconfigs$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+parent}/scanConfigs').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * websecurityscanner.projects.scanConfigs.patch + * @desc Updates a ScanConfig. This method support partial update of a ScanConfig. + * @alias websecurityscanner.projects.scanConfigs.patch + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name The resource name of the ScanConfig. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. The ScanConfig IDs are generated by the system. + * @param {string=} params.updateMask Required. The update mask applies to the resource. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + * @param {().ScanConfig} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + patch( + params?: Params$Resource$Projects$Scanconfigs$Patch, + options?: MethodOptions + ): GaxiosPromise; + patch( + params: Params$Resource$Projects$Scanconfigs$Patch, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + patch( + params: Params$Resource$Projects$Scanconfigs$Patch, + callback: BodyResponseCallback + ): void; + patch(callback: BodyResponseCallback): void; + patch( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$Patch + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$Patch; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$Patch; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'PATCH', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * websecurityscanner.projects.scanConfigs.start + * @desc Start a ScanRun according to the given ScanConfig. + * @alias websecurityscanner.projects.scanConfigs.start + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Required. The resource name of the ScanConfig to be used. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. + * @param {().StartScanRunRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + start( + params?: Params$Resource$Projects$Scanconfigs$Start, + options?: MethodOptions + ): GaxiosPromise; + start( + params: Params$Resource$Projects$Scanconfigs$Start, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + start( + params: Params$Resource$Projects$Scanconfigs$Start, + callback: BodyResponseCallback + ): void; + start(callback: BodyResponseCallback): void; + start( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$Start + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$Start; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$Start; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}:start').replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Projects$Scanconfigs$Create + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The parent resource name where the scan is created, which should be a project resource name in the format 'projects/{projectId}'. + */ + parent?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$ScanConfig; + } + export interface Params$Resource$Projects$Scanconfigs$Delete + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The resource name of the ScanConfig to be deleted. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. + */ + name?: string; + } + export interface Params$Resource$Projects$Scanconfigs$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The resource name of the ScanConfig to be returned. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. + */ + name?: string; + } + export interface Params$Resource$Projects$Scanconfigs$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The maximum number of ScanConfigs to return, can be limited by server. If not specified or not positive, the implementation will select a reasonable value. + */ + pageSize?: number; + /** + * A token identifying a page of results to be returned. This should be a `next_page_token` value returned from a previous List request. If unspecified, the first page of results is returned. + */ + pageToken?: string; + /** + * Required. The parent resource name, which should be a project resource name in the format 'projects/{projectId}'. + */ + parent?: string; + } + export interface Params$Resource$Projects$Scanconfigs$Patch + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The resource name of the ScanConfig. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. The ScanConfig IDs are generated by the system. + */ + name?: string; + /** + * Required. The update mask applies to the resource. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + */ + updateMask?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$ScanConfig; + } + export interface Params$Resource$Projects$Scanconfigs$Start + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The resource name of the ScanConfig to be used. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. + */ + name?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$StartScanRunRequest; + } + + export class Resource$Projects$Scanconfigs$Scanruns { + context: APIRequestContext; + crawledUrls: Resource$Projects$Scanconfigs$Scanruns$Crawledurls; + findings: Resource$Projects$Scanconfigs$Scanruns$Findings; + findingTypeStats: Resource$Projects$Scanconfigs$Scanruns$Findingtypestats; + constructor(context: APIRequestContext) { + this.context = context; + this.crawledUrls = new Resource$Projects$Scanconfigs$Scanruns$Crawledurls( + this.context + ); + this.findings = new Resource$Projects$Scanconfigs$Scanruns$Findings( + this.context + ); + this.findingTypeStats = new Resource$Projects$Scanconfigs$Scanruns$Findingtypestats( + this.context + ); + } + + /** + * websecurityscanner.projects.scanConfigs.scanRuns.get + * @desc Gets a ScanRun. + * @alias websecurityscanner.projects.scanConfigs.scanRuns.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Required. The resource name of the ScanRun to be returned. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Projects$Scanconfigs$Scanruns$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Projects$Scanconfigs$Scanruns$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Projects$Scanconfigs$Scanruns$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$Scanruns$Get + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$Scanruns$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$Scanruns$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * websecurityscanner.projects.scanConfigs.scanRuns.list + * @desc Lists ScanRuns under a given ScanConfig, in descending order of ScanRun stop time. + * @alias websecurityscanner.projects.scanConfigs.scanRuns.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {integer=} params.pageSize The maximum number of ScanRuns to return, can be limited by server. If not specified or not positive, the implementation will select a reasonable value. + * @param {string=} params.pageToken A token identifying a page of results to be returned. This should be a `next_page_token` value returned from a previous List request. If unspecified, the first page of results is returned. + * @param {string} params.parent Required. The parent resource name, which should be a scan resource name in the format 'projects/{projectId}/scanConfigs/{scanConfigId}'. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Scanconfigs$Scanruns$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Scanconfigs$Scanruns$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Scanconfigs$Scanruns$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$Scanruns$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$Scanruns$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$Scanruns$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+parent}/scanRuns').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * websecurityscanner.projects.scanConfigs.scanRuns.stop + * @desc Stops a ScanRun. The stopped ScanRun is returned. + * @alias websecurityscanner.projects.scanConfigs.scanRuns.stop + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Required. The resource name of the ScanRun to be stopped. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + * @param {().StopScanRunRequest} params.resource Request body data + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + stop( + params?: Params$Resource$Projects$Scanconfigs$Scanruns$Stop, + options?: MethodOptions + ): GaxiosPromise; + stop( + params: Params$Resource$Projects$Scanconfigs$Scanruns$Stop, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + stop( + params: Params$Resource$Projects$Scanconfigs$Scanruns$Stop, + callback: BodyResponseCallback + ): void; + stop(callback: BodyResponseCallback): void; + stop( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$Scanruns$Stop + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$Scanruns$Stop; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$Scanruns$Stop; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}:stop').replace(/([^:]\/)\/+/g, '$1'), + method: 'POST', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Projects$Scanconfigs$Scanruns$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The resource name of the ScanRun to be returned. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + */ + name?: string; + } + export interface Params$Resource$Projects$Scanconfigs$Scanruns$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The maximum number of ScanRuns to return, can be limited by server. If not specified or not positive, the implementation will select a reasonable value. + */ + pageSize?: number; + /** + * A token identifying a page of results to be returned. This should be a `next_page_token` value returned from a previous List request. If unspecified, the first page of results is returned. + */ + pageToken?: string; + /** + * Required. The parent resource name, which should be a scan resource name in the format 'projects/{projectId}/scanConfigs/{scanConfigId}'. + */ + parent?: string; + } + export interface Params$Resource$Projects$Scanconfigs$Scanruns$Stop + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The resource name of the ScanRun to be stopped. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + */ + name?: string; + + /** + * Request body metadata + */ + requestBody?: Schema$StopScanRunRequest; + } + + export class Resource$Projects$Scanconfigs$Scanruns$Crawledurls { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * websecurityscanner.projects.scanConfigs.scanRuns.crawledUrls.list + * @desc List CrawledUrls under a given ScanRun. + * @alias websecurityscanner.projects.scanConfigs.scanRuns.crawledUrls.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {integer=} params.pageSize The maximum number of CrawledUrls to return, can be limited by server. If not specified or not positive, the implementation will select a reasonable value. + * @param {string=} params.pageToken A token identifying a page of results to be returned. This should be a `next_page_token` value returned from a previous List request. If unspecified, the first page of results is returned. + * @param {string} params.parent Required. The parent resource name, which should be a scan run resource name in the format 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Scanconfigs$Scanruns$Crawledurls$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Scanconfigs$Scanruns$Crawledurls$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Scanconfigs$Scanruns$Crawledurls$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$Scanruns$Crawledurls$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$Scanruns$Crawledurls$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$Scanruns$Crawledurls$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+parent}/crawledUrls').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Projects$Scanconfigs$Scanruns$Crawledurls$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The maximum number of CrawledUrls to return, can be limited by server. If not specified or not positive, the implementation will select a reasonable value. + */ + pageSize?: number; + /** + * A token identifying a page of results to be returned. This should be a `next_page_token` value returned from a previous List request. If unspecified, the first page of results is returned. + */ + pageToken?: string; + /** + * Required. The parent resource name, which should be a scan run resource name in the format 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + */ + parent?: string; + } + + export class Resource$Projects$Scanconfigs$Scanruns$Findings { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * websecurityscanner.projects.scanConfigs.scanRuns.findings.get + * @desc Gets a Finding. + * @alias websecurityscanner.projects.scanConfigs.scanRuns.findings.get + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.name Required. The resource name of the Finding to be returned. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}/findings/{findingId}'. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + get( + params?: Params$Resource$Projects$Scanconfigs$Scanruns$Findings$Get, + options?: MethodOptions + ): GaxiosPromise; + get( + params: Params$Resource$Projects$Scanconfigs$Scanruns$Findings$Get, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + get( + params: Params$Resource$Projects$Scanconfigs$Scanruns$Findings$Get, + callback: BodyResponseCallback + ): void; + get(callback: BodyResponseCallback): void; + get( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$Scanruns$Findings$Get + | BodyResponseCallback, + optionsOrCallback?: MethodOptions | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$Scanruns$Findings$Get; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$Scanruns$Findings$Get; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'), + method: 'GET', + }, + options + ), + params, + requiredParams: ['name'], + pathParams: ['name'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + + /** + * websecurityscanner.projects.scanConfigs.scanRuns.findings.list + * @desc List Findings under a given ScanRun. + * @alias websecurityscanner.projects.scanConfigs.scanRuns.findings.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.filter The filter expression. The expression must be in the format: . Supported field: 'finding_type'. Supported operator: '='. + * @param {integer=} params.pageSize The maximum number of Findings to return, can be limited by server. If not specified or not positive, the implementation will select a reasonable value. + * @param {string=} params.pageToken A token identifying a page of results to be returned. This should be a `next_page_token` value returned from a previous List request. If unspecified, the first page of results is returned. + * @param {string} params.parent Required. The parent resource name, which should be a scan run resource name in the format 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Scanconfigs$Scanruns$Findings$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Scanconfigs$Scanruns$Findings$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Scanconfigs$Scanruns$Findings$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$Scanruns$Findings$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$Scanruns$Findings$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$Scanruns$Findings$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+parent}/findings').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Projects$Scanconfigs$Scanruns$Findings$Get + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The resource name of the Finding to be returned. The name follows the format of 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}/findings/{findingId}'. + */ + name?: string; + } + export interface Params$Resource$Projects$Scanconfigs$Scanruns$Findings$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The filter expression. The expression must be in the format: . Supported field: 'finding_type'. Supported operator: '='. + */ + filter?: string; + /** + * The maximum number of Findings to return, can be limited by server. If not specified or not positive, the implementation will select a reasonable value. + */ + pageSize?: number; + /** + * A token identifying a page of results to be returned. This should be a `next_page_token` value returned from a previous List request. If unspecified, the first page of results is returned. + */ + pageToken?: string; + /** + * Required. The parent resource name, which should be a scan run resource name in the format 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + */ + parent?: string; + } + + export class Resource$Projects$Scanconfigs$Scanruns$Findingtypestats { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * websecurityscanner.projects.scanConfigs.scanRuns.findingTypeStats.list + * @desc List all FindingTypeStats under a given ScanRun. + * @alias websecurityscanner.projects.scanConfigs.scanRuns.findingTypeStats.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.parent Required. The parent resource name, which should be a scan run resource name in the format 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Projects$Scanconfigs$Scanruns$Findingtypestats$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Projects$Scanconfigs$Scanruns$Findingtypestats$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Projects$Scanconfigs$Scanruns$Findingtypestats$List, + callback: BodyResponseCallback + ): void; + list( + callback: BodyResponseCallback + ): void; + list( + paramsOrCallback?: + | Params$Resource$Projects$Scanconfigs$Scanruns$Findingtypestats$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Projects$Scanconfigs$Scanruns$Findingtypestats$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Projects$Scanconfigs$Scanruns$Findingtypestats$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = + options.rootUrl || 'https://websecurityscanner.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/v1/{+parent}/findingTypeStats').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['parent'], + pathParams: ['parent'], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest( + parameters + ); + } + } + } + + export interface Params$Resource$Projects$Scanconfigs$Scanruns$Findingtypestats$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * Required. The parent resource name, which should be a scan run resource name in the format 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + */ + parent?: string; + } } diff --git a/src/apis/youtube/v3.ts b/src/apis/youtube/v3.ts index d0d8db1c613..722dd264bb6 100644 --- a/src/apis/youtube/v3.ts +++ b/src/apis/youtube/v3.ts @@ -104,6 +104,8 @@ export namespace youtube_v3 { liveChatMessages: Resource$Livechatmessages; liveChatModerators: Resource$Livechatmoderators; liveStreams: Resource$Livestreams; + members: Resource$Members; + membershipsLevels: Resource$Membershipslevels; playlistItems: Resource$Playlistitems; playlists: Resource$Playlists; search: Resource$Search; @@ -137,6 +139,8 @@ export namespace youtube_v3 { this.liveChatMessages = new Resource$Livechatmessages(this.context); this.liveChatModerators = new Resource$Livechatmoderators(this.context); this.liveStreams = new Resource$Livestreams(this.context); + this.members = new Resource$Members(this.context); + this.membershipsLevels = new Resource$Membershipslevels(this.context); this.playlistItems = new Resource$Playlistitems(this.context); this.playlists = new Resource$Playlists(this.context); this.search = new Resource$Search(this.context); @@ -1307,7 +1311,7 @@ export namespace youtube_v3 { videoId?: string; } /** - * Ratings schemes. The country-specific ratings are mostly for movies and shows. NEXT_ID: 71 + * Ratings schemes. The country-specific ratings are mostly for movies and shows. NEXT_ID: 72 */ export interface Schema$ContentRating { /** @@ -1542,6 +1546,7 @@ export namespace youtube_v3 { * The video's rating from the Nacionãlais Kino centrs (National Film Centre of Latvia). */ nkclvRating?: string; + nmcRating?: string; /** * The video's Office of Film and Literature Classification (OFLC - New Zealand) rating. */ @@ -1954,6 +1959,9 @@ export namespace youtube_v3 { export interface Schema$LanguageTag { value?: string; } + export interface Schema$LevelDetails { + displayName?: string; + } /** * A liveBroadcast resource represents an event that will be streamed, via live video, on YouTube. */ @@ -2088,6 +2096,7 @@ export namespace youtube_v3 { * The date and time that the broadcast actually started. This information is only available once the broadcast's state is live. The value is specified in ISO 8601 (YYYY-MM-DDThh:mm:ss.sZ) format. */ actualStartTime?: string; + broadcastType?: string; /** * The ID that YouTube uses to uniquely identify the channel that is publishing the broadcast. */ @@ -2665,6 +2674,145 @@ export namespace youtube_v3 { language?: string; value?: string; } + /** + * A member resource represents a member for a YouTube channel. A member provides recurring monetary support to a creator and receives special benefits. + */ + export interface Schema$Member { + /** + * Etag of this resource. + */ + etag?: string; + /** + * The ID that YouTube assigns to uniquely identify the member. + */ + id?: string; + /** + * Identifies what kind of resource this is. Value: the fixed string "youtube#member". + */ + kind?: string; + /** + * The snippet object contains basic details about the member. + */ + snippet?: Schema$MemberSnippet; + } + export interface Schema$MemberListResponse { + /** + * Etag of this resource. + */ + etag?: string; + /** + * Serialized EventId of the request which produced this response. + */ + eventId?: string; + /** + * A list of members that match the request criteria. + */ + items?: Schema$Member[]; + /** + * Identifies what kind of resource this is. Value: the fixed string "youtube#memberListResponse". + */ + kind?: string; + /** + * The token that can be used as the value of the pageToken parameter to retrieve the next page in the result set. + */ + nextPageToken?: string; + pageInfo?: Schema$PageInfo; + tokenPagination?: Schema$TokenPagination; + /** + * The visitorId identifies the visitor. + */ + visitorId?: string; + } + export interface Schema$MembershipsDetails { + /** + * All levels that the user has access to. This includes the purchased level and all other levels that are included because of a higher purchase. + */ + accessibleLevels?: string[]; + /** + * The date and time when the user became a continuous member across all levels. + */ + memberSince?: string; + /** + * The date and time when the user started to continuously have access to the currently highest level. + */ + memberSinceCurrentLevel?: string; + /** + * The cumulative time the user has been a member across all levels in complete months (the time is rounded down to the nearest integer). + */ + memberTotalDuration?: number; + /** + * The cumulative time the user has had access to the currently highest level in complete months (the time is rounded down to the nearest integer). + */ + memberTotalDurationCurrentLevel?: number; + /** + * The highest level the user has access to at the moment. + */ + purchasedLevel?: string; + } + /** + * A membershipsLevel resource represents an offer made by YouTube creators for their fans. Users can become members of the channel by joining one of the available levels. They will provide recurring monetary support and receives special benefits. + */ + export interface Schema$MembershipsLevel { + /** + * Etag of this resource. + */ + etag?: string; + /** + * The ID that YouTube assigns to uniquely identify the memberships level. + */ + id?: string; + /** + * Identifies what kind of resource this is. Value: the fixed string "youtube#membershipsLevel". + */ + kind?: string; + /** + * The snippet object contains basic details about the level. + */ + snippet?: Schema$MembershipsLevelSnippet; + } + export interface Schema$MembershipsLevelListResponse { + /** + * Etag of this resource. + */ + etag?: string; + /** + * Serialized EventId of the request which produced this response. + */ + eventId?: string; + /** + * A list of pricing levels offered by a creator to the fans. + */ + items?: Schema$MembershipsLevel[]; + /** + * Identifies what kind of resource this is. Value: the fixed string "youtube#membershipsLevelListResponse". + */ + kind?: string; + /** + * The visitorId identifies the visitor. + */ + visitorId?: string; + } + export interface Schema$MembershipsLevelSnippet { + /** + * The id of the channel that's offering channel memberships. + */ + creatorChannelId?: string; + levelDetails?: Schema$LevelDetails; + } + export interface Schema$MemberSnippet { + /** + * The id of the channel that's offering memberships. + */ + creatorChannelId?: string; + /** + * Details about the member. + */ + memberDetails?: Schema$ChannelProfileDetails; + /** + * Details about the user's membership. + */ + membershipsDetails?: Schema$MembershipsDetails; + } /** * Settings and Info of the monitor stream */ @@ -9050,6 +9198,221 @@ export namespace youtube_v3 { requestBody?: Schema$LiveStream; } + export class Resource$Members { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * youtube.members.list + * @desc Lists members for a channel. + * @alias youtube.members.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string=} params.hasAccessToLevel The hasAccessToLevel parameter specifies, when set, the ID of a pricing level that members from the results set should have access to. When not set, all members will be considered, regardless of their active pricing level. + * @param {integer=} params.maxResults The maxResults parameter specifies the maximum number of items that should be returned in the result set. + * @param {string=} params.mode The mode parameter specifies which channel members to return. + * @param {string=} params.pageToken The pageToken parameter identifies a specific page in the result set that should be returned. In an API response, the nextPageToken and prevPageToken properties identify other pages that could be retrieved. + * @param {string} params.part The part parameter specifies the member resource parts that the API response will include. Supported values are id and snippet. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Members$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Members$List, + options: MethodOptions | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Members$List, + callback: BodyResponseCallback + ): void; + list(callback: BodyResponseCallback): void; + list( + paramsOrCallback?: + | Params$Resource$Members$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || {}) as Params$Resource$Members$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Members$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/youtube/v3/members').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['part'], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest(parameters, callback); + } else { + return createAPIRequest(parameters); + } + } + } + + export interface Params$Resource$Members$List extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The hasAccessToLevel parameter specifies, when set, the ID of a pricing level that members from the results set should have access to. When not set, all members will be considered, regardless of their active pricing level. + */ + hasAccessToLevel?: string; + /** + * The maxResults parameter specifies the maximum number of items that should be returned in the result set. + */ + maxResults?: number; + /** + * The mode parameter specifies which channel members to return. + */ + mode?: string; + /** + * The pageToken parameter identifies a specific page in the result set that should be returned. In an API response, the nextPageToken and prevPageToken properties identify other pages that could be retrieved. + */ + pageToken?: string; + /** + * The part parameter specifies the member resource parts that the API response will include. Supported values are id and snippet. + */ + part?: string; + } + + export class Resource$Membershipslevels { + context: APIRequestContext; + constructor(context: APIRequestContext) { + this.context = context; + } + + /** + * youtube.membershipsLevels.list + * @desc Lists pricing levels for a channel. + * @alias youtube.membershipsLevels.list + * @memberOf! () + * + * @param {object} params Parameters for request + * @param {string} params.part The part parameter specifies the membershipsLevel resource parts that the API response will include. Supported values are id and snippet. + * @param {object} [options] Optionally override request options, such as `url`, `method`, and `encoding`. + * @param {callback} callback The callback that handles the response. + * @return {object} Request object + */ + list( + params?: Params$Resource$Membershipslevels$List, + options?: MethodOptions + ): GaxiosPromise; + list( + params: Params$Resource$Membershipslevels$List, + options: + | MethodOptions + | BodyResponseCallback, + callback: BodyResponseCallback + ): void; + list( + params: Params$Resource$Membershipslevels$List, + callback: BodyResponseCallback + ): void; + list( + callback: BodyResponseCallback + ): void; + list( + paramsOrCallback?: + | Params$Resource$Membershipslevels$List + | BodyResponseCallback, + optionsOrCallback?: + | MethodOptions + | BodyResponseCallback, + callback?: BodyResponseCallback + ): void | GaxiosPromise { + let params = (paramsOrCallback || + {}) as Params$Resource$Membershipslevels$List; + let options = (optionsOrCallback || {}) as MethodOptions; + + if (typeof paramsOrCallback === 'function') { + callback = paramsOrCallback; + params = {} as Params$Resource$Membershipslevels$List; + options = {}; + } + + if (typeof optionsOrCallback === 'function') { + callback = optionsOrCallback; + options = {}; + } + + const rootUrl = options.rootUrl || 'https://www.googleapis.com/'; + const parameters = { + options: Object.assign( + { + url: (rootUrl + '/youtube/v3/membershipsLevels').replace( + /([^:]\/)\/+/g, + '$1' + ), + method: 'GET', + }, + options + ), + params, + requiredParams: ['part'], + pathParams: [], + context: this.context, + }; + if (callback) { + createAPIRequest( + parameters, + callback + ); + } else { + return createAPIRequest( + parameters + ); + } + } + } + + export interface Params$Resource$Membershipslevels$List + extends StandardParameters { + /** + * Auth client or API Key for the request + */ + auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient; + + /** + * The part parameter specifies the membershipsLevel resource parts that the API response will include. Supported values are id and snippet. + */ + part?: string; + } + export class Resource$Playlistitems { context: APIRequestContext; constructor(context: APIRequestContext) { diff --git a/src/generator/templates/package.json.njk b/src/generator/templates/package.json.njk index a7a74318ab3..2eac412ac6c 100644 --- a/src/generator/templates/package.json.njk +++ b/src/generator/templates/package.json.njk @@ -29,14 +29,14 @@ "webpack": "webpack" }, "dependencies": { - "googleapis-common": "^2.0.4" + "googleapis-common": "^3.0.0" }, "devDependencies": { "gts": "^1.0.0", "null-loader": "^3.0.0", "ts-loader": "^6.0.4", "typedoc": "^0.15.0", - "typescript": "~3.5.3", + "typescript": "~3.6.0", "webpack": "^4.35.3", "webpack-cli": "^3.3.5" } diff --git a/src/index.ts b/src/index.ts index dfcd4cda0e7..ed6445f01f5 100644 --- a/src/index.ts +++ b/src/index.ts @@ -52,9 +52,12 @@ export {appengine_v1} from './apis/appengine/v1'; export {appengine_v1alpha} from './apis/appengine/v1alpha'; export {appengine_v1beta} from './apis/appengine/v1beta'; export {appsactivity_v1} from './apis/appsactivity/v1'; -export {appstate_v1} from './apis/appstate/v1'; export {bigquery_v2} from './apis/bigquery/v2'; export {bigquerydatatransfer_v1} from './apis/bigquerydatatransfer/v1'; +export {bigqueryreservation_v1} from './apis/bigqueryreservation/v1'; +export { + bigqueryreservation_v1alpha2, +} from './apis/bigqueryreservation/v1alpha2'; export {bigtableadmin_v1} from './apis/bigtableadmin/v1'; export {bigtableadmin_v2} from './apis/bigtableadmin/v2'; export {binaryauthorization_v1beta1} from './apis/binaryauthorization/v1beta1'; @@ -104,7 +107,6 @@ export {cloudtrace_v2} from './apis/cloudtrace/v2'; export {commentanalyzer_v1alpha1} from './apis/commentanalyzer/v1alpha1'; export {composer_v1} from './apis/composer/v1'; export {composer_v1beta1} from './apis/composer/v1beta1'; -export {compute_alpha} from './apis/compute/alpha'; export {compute_beta} from './apis/compute/beta'; export {compute_v1} from './apis/compute/v1'; export {container_v1} from './apis/container/v1'; @@ -136,6 +138,7 @@ export {dns_v1} from './apis/dns/v1'; export {dns_v1beta2} from './apis/dns/v1beta2'; export {dns_v2beta1} from './apis/dns/v2beta1'; export {docs_v1} from './apis/docs/v1'; +export {domainsrdap_v1} from './apis/domainsrdap/v1'; export {doubleclickbidmanager_v1} from './apis/doubleclickbidmanager/v1'; export {doubleclicksearch_v2} from './apis/doubleclicksearch/v2'; export {drive_v2} from './apis/drive/v2'; @@ -170,6 +173,7 @@ export {groupsmigration_v1} from './apis/groupsmigration/v1'; export {groupssettings_v1} from './apis/groupssettings/v1'; export {healthcare_v1alpha2} from './apis/healthcare/v1alpha2'; export {healthcare_v1beta1} from './apis/healthcare/v1beta1'; +export {homegraph_v1} from './apis/homegraph/v1'; export {iam_v1} from './apis/iam/v1'; export {iamcredentials_v1} from './apis/iamcredentials/v1'; export {iap_v1} from './apis/iap/v1'; @@ -219,7 +223,6 @@ export {replicapool_v1beta1} from './apis/replicapool/v1beta1'; export {reseller_v1} from './apis/reseller/v1'; export {run_v1} from './apis/run/v1'; export {run_v1alpha1} from './apis/run/v1alpha1'; -export {run_v1beta1} from './apis/run/v1beta1'; export {runtimeconfig_v1} from './apis/runtimeconfig/v1'; export {runtimeconfig_v1beta1} from './apis/runtimeconfig/v1beta1'; export {safebrowsing_v4} from './apis/safebrowsing/v4'; @@ -247,6 +250,7 @@ export {sourcerepo_v1} from './apis/sourcerepo/v1'; export {spanner_v1} from './apis/spanner/v1'; export {speech_v1} from './apis/speech/v1'; export {speech_v1p1beta1} from './apis/speech/v1p1beta1'; +export {speech_v2beta} from './apis/speech/v2beta'; export {sqladmin_v1beta4} from './apis/sqladmin/v1beta4'; export {storage_v1} from './apis/storage/v1'; export {storage_v1beta1} from './apis/storage/v1beta1'; @@ -264,8 +268,10 @@ export {toolresults_v1beta3} from './apis/toolresults/v1beta3'; export {tpu_v1} from './apis/tpu/v1'; export {tpu_v1alpha1} from './apis/tpu/v1alpha1'; export {translate_v2} from './apis/translate/v2'; +export {translate_v3beta1} from './apis/translate/v3beta1'; export {urlshortener_v1} from './apis/urlshortener/v1'; export {vault_v1} from './apis/vault/v1'; +export {verifiedaccess_v1} from './apis/verifiedaccess/v1'; export {videointelligence_v1} from './apis/videointelligence/v1'; export {videointelligence_v1beta2} from './apis/videointelligence/v1beta2'; export {videointelligence_v1p1beta1} from './apis/videointelligence/v1p1beta1'; diff --git a/test/test.query.ts b/test/test.query.ts index d1f7ff28156..184b1bc7b61 100644 --- a/test/test.query.ts +++ b/test/test.query.ts @@ -141,7 +141,7 @@ describe('Query params', () => { it('should be set if params passed are falsy', async () => { const computeRemoteUrl = 'https://compute.googleapis.com'; - const r1 = nock(Utils.baseUrl) + const r1 = nock(computeRemoteUrl) .post( '/compute/v1/projects//zones//instances//setDiskAutoDelete?autoDelete=false&deviceName=' ) @@ -168,7 +168,7 @@ describe('Query params', () => { }); assert.strictEqual(Utils.getQs(res2), 'autoDelete=false&deviceName='); - const r3 = nock(Utils.baseUrl) + const r3 = nock(computeRemoteUrl) .post('/compute/v1/projects//zones//instanceGroupManagers//resize?size=0') .reply(200); const res3 = await localCompute.instanceGroupManagers.resize({