From 5e22af79ded6bba210da899c4103417efa45852c Mon Sep 17 00:00:00 2001 From: Justin Beckwith Date: Tue, 25 Apr 2017 13:09:30 -0700 Subject: [PATCH] First step to TypeScript upgrade (#731) --- .gitignore | 4 ++ .travis.yml | 3 ++ .../acceleratedmobilepageurl/{v1.js => v1.ts} | 2 +- apis/adexchangebuyer/{v1.2.js => v1.2.ts} | 2 +- apis/adexchangebuyer/{v1.3.js => v1.3.ts} | 2 +- apis/adexchangebuyer/{v1.4.js => v1.4.ts} | 2 +- .../{v2beta1.js => v2beta1.ts} | 2 +- apis/adexchangeseller/{v1.1.js => v1.1.ts} | 2 +- apis/adexchangeseller/{v1.js => v1.ts} | 2 +- apis/adexchangeseller/{v2.0.js => v2.0.ts} | 2 +- ...{datatransfer_v1.js => datatransfer_v1.ts} | 2 +- .../{directory_v1.js => directory_v1.ts} | 2 +- apis/admin/{reports_v1.js => reports_v1.ts} | 2 +- apis/adsense/{v1.3.js => v1.3.ts} | 2 +- apis/adsense/{v1.4.js => v1.4.ts} | 2 +- apis/adsensehost/{v4.1.js => v4.1.ts} | 2 +- apis/analytics/{v2.4.js => v2.4.ts} | 2 +- apis/analytics/{v3.js => v3.ts} | 2 +- apis/analyticsreporting/{v4.js => v4.ts} | 2 +- apis/androidenterprise/{v1.js => v1.ts} | 2 +- apis/androidpublisher/{v1.1.js => v1.1.ts} | 2 +- apis/androidpublisher/{v1.js => v1.ts} | 2 +- apis/androidpublisher/{v2.js => v2.ts} | 2 +- apis/appengine/{v1.js => v1.ts} | 2 +- apis/appengine/{v1alpha.js => v1alpha.ts} | 2 +- apis/appengine/{v1beta.js => v1beta.ts} | 2 +- apis/appengine/{v1beta4.js => v1beta4.ts} | 2 +- apis/appengine/{v1beta5.js => v1beta5.ts} | 2 +- apis/appsactivity/{v1.js => v1.ts} | 2 +- apis/appstate/{v1.js => v1.ts} | 2 +- apis/bigquery/{v2.js => v2.ts} | 2 +- apis/blogger/{v2.js => v2.ts} | 2 +- apis/blogger/{v3.js => v3.ts} | 2 +- apis/books/{v1.js => v1.ts} | 2 +- apis/calendar/{v3.js => v3.ts} | 2 +- apis/civicinfo/{v2.js => v2.ts} | 2 +- apis/classroom/{v1.js => v1.ts} | 2 +- apis/cloudbilling/{v1.js => v1.ts} | 2 +- apis/cloudbuild/{v1.js => v1.ts} | 2 +- apis/clouddebugger/{v2.js => v2.ts} | 2 +- .../{v1beta1.js => v1beta1.ts} | 2 +- apis/cloudfunctions/{v1.js => v1.ts} | 2 +- .../cloudfunctions/{v1beta2.js => v1beta2.ts} | 2 +- apis/cloudkms/{v1.js => v1.ts} | 2 +- .../{v2beta2.js => v2beta2.ts} | 2 +- apis/cloudresourcemanager/{v1.js => v1.ts} | 2 +- .../{v1beta1.js => v1beta1.ts} | 2 +- apis/cloudtrace/{v1.js => v1.ts} | 2 +- apis/clouduseraccounts/{alpha.js => alpha.ts} | 2 +- apis/clouduseraccounts/{beta.js => beta.ts} | 2 +- .../{vm_alpha.js => vm_alpha.ts} | 2 +- .../{vm_beta.js => vm_beta.ts} | 2 +- apis/compute/{alpha.js => alpha.ts} | 2 +- apis/compute/{beta.js => beta.ts} | 2 +- apis/compute/{v1.js => v1.ts} | 2 +- apis/consumersurveys/{v2.js => v2.ts} | 2 +- apis/container/{v1.js => v1.ts} | 2 +- apis/content/{v2.js => v2.ts} | 2 +- apis/content/{v2sandbox.js => v2sandbox.ts} | 2 +- apis/customsearch/{v1.js => v1.ts} | 2 +- apis/dataflow/{v1b3.js => v1b3.ts} | 2 +- apis/dataproc/{v1.js => v1.ts} | 2 +- apis/dataproc/{v1alpha1.js => v1alpha1.ts} | 2 +- apis/dataproc/{v1beta1.js => v1beta1.ts} | 2 +- apis/datastore/{v1.js => v1.ts} | 2 +- apis/datastore/{v1beta1.js => v1beta1.ts} | 2 +- apis/datastore/{v1beta2.js => v1beta2.ts} | 2 +- apis/datastore/{v1beta3.js => v1beta3.ts} | 2 +- apis/deploymentmanager/{alpha.js => alpha.ts} | 2 +- apis/deploymentmanager/{v2.js => v2.ts} | 2 +- .../{v2beta.js => v2beta.ts} | 2 +- apis/dfareporting/{v2.6.js => v2.6.ts} | 2 +- apis/dfareporting/{v2.7.js => v2.7.ts} | 2 +- apis/discovery/{v1.js => v1.ts} | 2 +- apis/dlp/{v2beta1.js => v2beta1.ts} | 2 +- apis/dns/{v1.js => v1.ts} | 2 +- apis/dns/{v2beta1.js => v2beta1.ts} | 2 +- apis/doubleclickbidmanager/{v1.js => v1.ts} | 2 +- apis/doubleclicksearch/{v2.js => v2.ts} | 2 +- apis/drive/{v2.js => v2.ts} | 2 +- apis/drive/{v3.js => v3.ts} | 2 +- apis/firebasedynamiclinks/{v1.js => v1.ts} | 2 +- apis/firebaserules/{v1.js => v1.ts} | 2 +- apis/fitness/{v1.js => v1.ts} | 2 +- apis/fusiontables/{v1.js => v1.ts} | 2 +- apis/fusiontables/{v2.js => v2.ts} | 2 +- apis/games/{v1.js => v1.ts} | 2 +- ...{v1configuration.js => v1configuration.ts} | 2 +- .../{v1management.js => v1management.ts} | 2 +- apis/genomics/{v1.js => v1.ts} | 2 +- apis/genomics/{v1alpha2.js => v1alpha2.ts} | 2 +- apis/gmail/{v1.js => v1.ts} | 2 +- apis/groupsmigration/{v1.js => v1.ts} | 2 +- apis/groupssettings/{v1.js => v1.ts} | 2 +- apis/iam/{v1.js => v1.ts} | 2 +- apis/identitytoolkit/{v3.js => v3.ts} | 2 +- apis/kgsearch/{v1.js => v1.ts} | 2 +- apis/language/{v1.js => v1.ts} | 2 +- apis/language/{v1beta1.js => v1beta1.ts} | 2 +- apis/language/{v1beta2.js => v1beta2.ts} | 2 +- apis/licensing/{v1.js => v1.ts} | 2 +- apis/logging/{v2.js => v2.ts} | 2 +- apis/logging/{v2beta1.js => v2beta1.ts} | 2 +- apis/manufacturers/{v1.js => v1.ts} | 2 +- apis/mirror/{v1.js => v1.ts} | 2 +- apis/ml/{v1.js => v1.ts} | 2 +- apis/ml/{v1beta1.js => v1beta1.ts} | 2 +- apis/monitoring/{v3.js => v3.ts} | 2 +- apis/oauth2/{v1.js => v1.ts} | 2 +- apis/oauth2/{v2.js => v2.ts} | 2 +- apis/pagespeedonline/{v1.js => v1.ts} | 2 +- apis/pagespeedonline/{v2.js => v2.ts} | 2 +- apis/partners/{v2.js => v2.ts} | 2 +- apis/people/{v1.js => v1.ts} | 2 +- apis/playmoviespartner/{v1.js => v1.ts} | 2 +- apis/plus/{v1.js => v1.ts} | 2 +- apis/plusDomains/{v1.js => v1.ts} | 2 +- apis/prediction/{v1.2.js => v1.2.ts} | 2 +- apis/prediction/{v1.3.js => v1.3.ts} | 2 +- apis/prediction/{v1.4.js => v1.4.ts} | 2 +- apis/prediction/{v1.5.js => v1.5.ts} | 2 +- apis/prediction/{v1.6.js => v1.6.ts} | 2 +- .../{v1beta1.js => v1beta1.ts} | 2 +- apis/pubsub/{v1.js => v1.ts} | 2 +- apis/pubsub/{v1beta1a.js => v1beta1a.ts} | 2 +- apis/pubsub/{v1beta2.js => v1beta2.ts} | 2 +- apis/qpxExpress/{v1.js => v1.ts} | 2 +- apis/replicapool/{v1beta1.js => v1beta1.ts} | 2 +- apis/replicapool/{v1beta2.js => v1beta2.ts} | 2 +- .../{v1beta1.js => v1beta1.ts} | 2 +- apis/reseller/{v1.js => v1.ts} | 2 +- apis/resourceviews/{v1beta1.js => v1beta1.ts} | 2 +- apis/resourceviews/{v1beta2.js => v1beta2.ts} | 2 +- apis/runtimeconfig/{v1.js => v1.ts} | 2 +- apis/runtimeconfig/{v1beta1.js => v1beta1.ts} | 2 +- apis/safebrowsing/{v4.js => v4.ts} | 2 +- apis/script/{v1.js => v1.ts} | 2 +- apis/searchconsole/{v1.js => v1.ts} | 2 +- apis/servicecontrol/{v1.js => v1.ts} | 2 +- apis/servicemanagement/{v1.js => v1.ts} | 2 +- apis/serviceuser/{v1.js => v1.ts} | 2 +- apis/sheets/{v4.js => v4.ts} | 2 +- apis/siteVerification/{v1.js => v1.ts} | 2 +- apis/slides/{v1.js => v1.ts} | 2 +- apis/sourcerepo/{v1.js => v1.ts} | 2 +- apis/spanner/{v1.js => v1.ts} | 2 +- .../spectrum/{v1explorer.js => v1explorer.ts} | 2 +- apis/speech/{v1beta1.js => v1beta1.ts} | 2 +- apis/sqladmin/{v1beta3.js => v1beta3.ts} | 2 +- apis/sqladmin/{v1beta4.js => v1beta4.ts} | 2 +- apis/storage/{v1.js => v1.ts} | 2 +- apis/storage/{v1beta1.js => v1beta1.ts} | 2 +- apis/storage/{v1beta2.js => v1beta2.ts} | 2 +- apis/storagetransfer/{v1.js => v1.ts} | 2 +- apis/surveys/{v2.js => v2.ts} | 2 +- apis/tagmanager/{v1.js => v1.ts} | 2 +- apis/tagmanager/{v2.js => v2.ts} | 2 +- apis/taskqueue/{v1beta1.js => v1beta1.ts} | 2 +- apis/taskqueue/{v1beta2.js => v1beta2.ts} | 2 +- apis/tasks/{v1.js => v1.ts} | 2 +- apis/toolresults/{v1beta3.js => v1beta3.ts} | 2 +- ...eta3firstparty.js => v1beta3firstparty.ts} | 2 +- apis/tracing/{v2.js => v2.ts} | 2 +- apis/translate/{v2.js => v2.ts} | 2 +- apis/urlshortener/{v1.js => v1.ts} | 2 +- apis/vision/{v1.js => v1.ts} | 2 +- apis/webfonts/{v1.js => v1.ts} | 2 +- apis/webmasters/{v3.js => v3.ts} | 2 +- apis/youtube/{v3.js => v3.ts} | 2 +- apis/youtubeAnalytics/{v1.js => v1.ts} | 2 +- .../{v1beta1.js => v1beta1.ts} | 2 +- apis/youtubereporting/{v1.js => v1.ts} | 2 +- lib/{apirequest.js => apirequest.ts} | 2 +- lib/auth/{authclient.js => authclient.ts} | 0 .../{computeclient.js => computeclient.ts} | 0 lib/auth/{jwtclient.js => jwtclient.ts} | 0 lib/auth/{loginticket.js => loginticket.ts} | 0 lib/auth/{oauth2client.js => oauth2client.ts} | 0 lib/{discovery.js => discovery.ts} | 11 +++--- lib/{generator.js => generator.ts} | 6 +-- ...{generator_utils.js => generator_utils.ts} | 11 ++++-- lib/{googleapis.js => googleapis.ts} | 4 +- lib/{pemverifier.js => pemverifier.ts} | 0 lib/{transporters.js => transporters.ts} | 0 lib/{utils.js => utils.ts} | 0 package.json | 18 ++++++--- scripts/{generate.js => generate.ts} | 2 +- .../{api-endpoint.js => api-endpoint.ts} | 6 +-- .../{method-partial.js => method-partial.ts} | 0 ...esource-partial.js => resource-partial.ts} | 4 +- test/{test.apikey.js => test.apikey.ts} | 6 +-- test/{test.auth.js => test.auth.ts} | 0 test/{test.clients.js => test.clients.ts} | 38 ++++++++++--------- test/{test.discover.js => test.discover.ts} | 0 test/{test.drive.v2.js => test.drive.v2.ts} | 0 test/{test.media.js => test.media.ts} | 0 test/{test.options.js => test.options.ts} | 0 test/{test.path.js => test.path.ts} | 0 test/{test.query.js => test.query.ts} | 0 ...t.transporters.js => test.transporters.ts} | 0 ...hortener.v1.js => test.urlshortener.v1.ts} | 0 test/{utils.js => utils.ts} | 0 tsconfig.json | 14 +++++++ tsconfig.tools.json | 15 ++++++++ yarn.lock | 36 ++++++++++++------ 205 files changed, 290 insertions(+), 230 deletions(-) rename apis/acceleratedmobilepageurl/{v1.js => v1.ts} (98%) rename apis/adexchangebuyer/{v1.2.js => v1.2.ts} (99%) rename apis/adexchangebuyer/{v1.3.js => v1.3.ts} (99%) rename apis/adexchangebuyer/{v1.4.js => v1.4.ts} (99%) rename apis/adexchangebuyer2/{v2beta1.js => v2beta1.ts} (99%) rename apis/adexchangeseller/{v1.1.js => v1.1.ts} (99%) rename apis/adexchangeseller/{v1.js => v1.ts} (99%) rename apis/adexchangeseller/{v2.0.js => v2.0.ts} (99%) rename apis/admin/{datatransfer_v1.js => datatransfer_v1.ts} (99%) rename apis/admin/{directory_v1.js => directory_v1.ts} (99%) rename apis/admin/{reports_v1.js => reports_v1.ts} (99%) rename apis/adsense/{v1.3.js => v1.3.ts} (99%) rename apis/adsense/{v1.4.js => v1.4.ts} (99%) rename apis/adsensehost/{v4.1.js => v4.1.ts} (99%) rename apis/analytics/{v2.4.js => v2.4.ts} (99%) rename apis/analytics/{v3.js => v3.ts} (99%) rename apis/analyticsreporting/{v4.js => v4.ts} (99%) rename apis/androidenterprise/{v1.js => v1.ts} (99%) rename apis/androidpublisher/{v1.1.js => v1.1.ts} (99%) rename apis/androidpublisher/{v1.js => v1.ts} (99%) rename apis/androidpublisher/{v2.js => v2.ts} (99%) rename apis/appengine/{v1.js => v1.ts} (99%) rename apis/appengine/{v1alpha.js => v1alpha.ts} (99%) rename apis/appengine/{v1beta.js => v1beta.ts} (99%) rename apis/appengine/{v1beta4.js => v1beta4.ts} (99%) rename apis/appengine/{v1beta5.js => v1beta5.ts} (99%) rename apis/appsactivity/{v1.js => v1.ts} (99%) rename apis/appstate/{v1.js => v1.ts} (99%) rename apis/bigquery/{v2.js => v2.ts} (99%) rename apis/blogger/{v2.js => v2.ts} (99%) rename apis/blogger/{v3.js => v3.ts} (99%) rename apis/books/{v1.js => v1.ts} (99%) rename apis/calendar/{v3.js => v3.ts} (99%) rename apis/civicinfo/{v2.js => v2.ts} (99%) rename apis/classroom/{v1.js => v1.ts} (99%) rename apis/cloudbilling/{v1.js => v1.ts} (99%) rename apis/cloudbuild/{v1.js => v1.ts} (99%) rename apis/clouddebugger/{v2.js => v2.ts} (99%) rename apis/clouderrorreporting/{v1beta1.js => v1beta1.ts} (99%) rename apis/cloudfunctions/{v1.js => v1.ts} (97%) rename apis/cloudfunctions/{v1beta2.js => v1beta2.ts} (99%) rename apis/cloudkms/{v1.js => v1.ts} (99%) rename apis/cloudmonitoring/{v2beta2.js => v2beta2.ts} (99%) rename apis/cloudresourcemanager/{v1.js => v1.ts} (99%) rename apis/cloudresourcemanager/{v1beta1.js => v1beta1.ts} (99%) rename apis/cloudtrace/{v1.js => v1.ts} (99%) rename apis/clouduseraccounts/{alpha.js => alpha.ts} (99%) rename apis/clouduseraccounts/{beta.js => beta.ts} (99%) rename apis/clouduseraccounts/{vm_alpha.js => vm_alpha.ts} (99%) rename apis/clouduseraccounts/{vm_beta.js => vm_beta.ts} (99%) rename apis/compute/{alpha.js => alpha.ts} (99%) rename apis/compute/{beta.js => beta.ts} (99%) rename apis/compute/{v1.js => v1.ts} (99%) rename apis/consumersurveys/{v2.js => v2.ts} (99%) rename apis/container/{v1.js => v1.ts} (99%) rename apis/content/{v2.js => v2.ts} (99%) rename apis/content/{v2sandbox.js => v2sandbox.ts} (99%) rename apis/customsearch/{v1.js => v1.ts} (99%) rename apis/dataflow/{v1b3.js => v1b3.ts} (99%) rename apis/dataproc/{v1.js => v1.ts} (99%) rename apis/dataproc/{v1alpha1.js => v1alpha1.ts} (99%) rename apis/dataproc/{v1beta1.js => v1beta1.ts} (99%) rename apis/datastore/{v1.js => v1.ts} (99%) rename apis/datastore/{v1beta1.js => v1beta1.ts} (99%) rename apis/datastore/{v1beta2.js => v1beta2.ts} (99%) rename apis/datastore/{v1beta3.js => v1beta3.ts} (99%) rename apis/deploymentmanager/{alpha.js => alpha.ts} (99%) rename apis/deploymentmanager/{v2.js => v2.ts} (99%) rename apis/deploymentmanager/{v2beta.js => v2beta.ts} (99%) rename apis/dfareporting/{v2.6.js => v2.6.ts} (99%) rename apis/dfareporting/{v2.7.js => v2.7.ts} (99%) rename apis/discovery/{v1.js => v1.ts} (99%) rename apis/dlp/{v2beta1.js => v2beta1.ts} (99%) rename apis/dns/{v1.js => v1.ts} (99%) rename apis/dns/{v2beta1.js => v2beta1.ts} (99%) rename apis/doubleclickbidmanager/{v1.js => v1.ts} (99%) rename apis/doubleclicksearch/{v2.js => v2.ts} (99%) rename apis/drive/{v2.js => v2.ts} (99%) rename apis/drive/{v3.js => v3.ts} (99%) rename apis/firebasedynamiclinks/{v1.js => v1.ts} (99%) rename apis/firebaserules/{v1.js => v1.ts} (99%) rename apis/fitness/{v1.js => v1.ts} (99%) rename apis/fusiontables/{v1.js => v1.ts} (99%) rename apis/fusiontables/{v2.js => v2.ts} (99%) rename apis/games/{v1.js => v1.ts} (99%) rename apis/gamesConfiguration/{v1configuration.js => v1configuration.ts} (99%) rename apis/gamesManagement/{v1management.js => v1management.ts} (99%) rename apis/genomics/{v1.js => v1.ts} (99%) rename apis/genomics/{v1alpha2.js => v1alpha2.ts} (99%) rename apis/gmail/{v1.js => v1.ts} (99%) rename apis/groupsmigration/{v1.js => v1.ts} (98%) rename apis/groupssettings/{v1.js => v1.ts} (99%) rename apis/iam/{v1.js => v1.ts} (99%) rename apis/identitytoolkit/{v3.js => v3.ts} (99%) rename apis/kgsearch/{v1.js => v1.ts} (99%) rename apis/language/{v1.js => v1.ts} (99%) rename apis/language/{v1beta1.js => v1beta1.ts} (99%) rename apis/language/{v1beta2.js => v1beta2.ts} (99%) rename apis/licensing/{v1.js => v1.ts} (99%) rename apis/logging/{v2.js => v2.ts} (99%) rename apis/logging/{v2beta1.js => v2beta1.ts} (99%) rename apis/manufacturers/{v1.js => v1.ts} (99%) rename apis/mirror/{v1.js => v1.ts} (99%) rename apis/ml/{v1.js => v1.ts} (99%) rename apis/ml/{v1beta1.js => v1beta1.ts} (99%) rename apis/monitoring/{v3.js => v3.ts} (99%) rename apis/oauth2/{v1.js => v1.ts} (99%) rename apis/oauth2/{v2.js => v2.ts} (99%) rename apis/pagespeedonline/{v1.js => v1.ts} (99%) rename apis/pagespeedonline/{v2.js => v2.ts} (99%) rename apis/partners/{v2.js => v2.ts} (99%) rename apis/people/{v1.js => v1.ts} (99%) rename apis/playmoviespartner/{v1.js => v1.ts} (99%) rename apis/plus/{v1.js => v1.ts} (99%) rename apis/plusDomains/{v1.js => v1.ts} (99%) rename apis/prediction/{v1.2.js => v1.2.ts} (99%) rename apis/prediction/{v1.3.js => v1.3.ts} (99%) rename apis/prediction/{v1.4.js => v1.4.ts} (99%) rename apis/prediction/{v1.5.js => v1.5.ts} (99%) rename apis/prediction/{v1.6.js => v1.6.ts} (99%) rename apis/proximitybeacon/{v1beta1.js => v1beta1.ts} (99%) rename apis/pubsub/{v1.js => v1.ts} (99%) rename apis/pubsub/{v1beta1a.js => v1beta1a.ts} (99%) rename apis/pubsub/{v1beta2.js => v1beta2.ts} (99%) rename apis/qpxExpress/{v1.js => v1.ts} (99%) rename apis/replicapool/{v1beta1.js => v1beta1.ts} (99%) rename apis/replicapool/{v1beta2.js => v1beta2.ts} (99%) rename apis/replicapoolupdater/{v1beta1.js => v1beta1.ts} (99%) rename apis/reseller/{v1.js => v1.ts} (99%) rename apis/resourceviews/{v1beta1.js => v1beta1.ts} (99%) rename apis/resourceviews/{v1beta2.js => v1beta2.ts} (99%) rename apis/runtimeconfig/{v1.js => v1.ts} (99%) rename apis/runtimeconfig/{v1beta1.js => v1beta1.ts} (99%) rename apis/safebrowsing/{v4.js => v4.ts} (99%) rename apis/script/{v1.js => v1.ts} (99%) rename apis/searchconsole/{v1.js => v1.ts} (99%) rename apis/servicecontrol/{v1.js => v1.ts} (99%) rename apis/servicemanagement/{v1.js => v1.ts} (99%) rename apis/serviceuser/{v1.js => v1.ts} (99%) rename apis/sheets/{v4.js => v4.ts} (99%) rename apis/siteVerification/{v1.js => v1.ts} (99%) rename apis/slides/{v1.js => v1.ts} (99%) rename apis/sourcerepo/{v1.js => v1.ts} (99%) rename apis/spanner/{v1.js => v1.ts} (99%) rename apis/spectrum/{v1explorer.js => v1explorer.ts} (99%) rename apis/speech/{v1beta1.js => v1beta1.ts} (99%) rename apis/sqladmin/{v1beta3.js => v1beta3.ts} (99%) rename apis/sqladmin/{v1beta4.js => v1beta4.ts} (99%) rename apis/storage/{v1.js => v1.ts} (99%) rename apis/storage/{v1beta1.js => v1beta1.ts} (99%) rename apis/storage/{v1beta2.js => v1beta2.ts} (99%) rename apis/storagetransfer/{v1.js => v1.ts} (99%) rename apis/surveys/{v2.js => v2.ts} (99%) rename apis/tagmanager/{v1.js => v1.ts} (99%) rename apis/tagmanager/{v2.js => v2.ts} (99%) rename apis/taskqueue/{v1beta1.js => v1beta1.ts} (99%) rename apis/taskqueue/{v1beta2.js => v1beta2.ts} (99%) rename apis/tasks/{v1.js => v1.ts} (99%) rename apis/toolresults/{v1beta3.js => v1beta3.ts} (99%) rename apis/toolresults/{v1beta3firstparty.js => v1beta3firstparty.ts} (99%) rename apis/tracing/{v2.js => v2.ts} (99%) rename apis/translate/{v2.js => v2.ts} (99%) rename apis/urlshortener/{v1.js => v1.ts} (99%) rename apis/vision/{v1.js => v1.ts} (99%) rename apis/webfonts/{v1.js => v1.ts} (99%) rename apis/webmasters/{v3.js => v3.ts} (99%) rename apis/youtube/{v3.js => v3.ts} (99%) rename apis/youtubeAnalytics/{v1.js => v1.ts} (99%) rename apis/youtubeAnalytics/{v1beta1.js => v1beta1.ts} (99%) rename apis/youtubereporting/{v1.js => v1.ts} (99%) rename lib/{apirequest.js => apirequest.ts} (99%) rename lib/auth/{authclient.js => authclient.ts} (100%) rename lib/auth/{computeclient.js => computeclient.ts} (100%) rename lib/auth/{jwtclient.js => jwtclient.ts} (100%) rename lib/auth/{loginticket.js => loginticket.ts} (100%) rename lib/auth/{oauth2client.js => oauth2client.ts} (100%) rename lib/{discovery.js => discovery.ts} (97%) rename lib/{generator.js => generator.ts} (98%) rename lib/{generator_utils.js => generator_utils.ts} (90%) rename lib/{googleapis.js => googleapis.ts} (98%) rename lib/{pemverifier.js => pemverifier.ts} (100%) rename lib/{transporters.js => transporters.ts} (100%) rename lib/{utils.js => utils.ts} (100%) rename scripts/{generate.js => generate.ts} (98%) rename templates/{api-endpoint.js => api-endpoint.ts} (95%) rename templates/{method-partial.js => method-partial.ts} (100%) rename templates/{resource-partial.js => resource-partial.ts} (73%) rename test/{test.apikey.js => test.apikey.ts} (97%) rename test/{test.auth.js => test.auth.ts} (100%) rename test/{test.clients.js => test.clients.ts} (88%) rename test/{test.discover.js => test.discover.ts} (100%) rename test/{test.drive.v2.js => test.drive.v2.ts} (100%) rename test/{test.media.js => test.media.ts} (100%) rename test/{test.options.js => test.options.ts} (100%) rename test/{test.path.js => test.path.ts} (100%) rename test/{test.query.js => test.query.ts} (100%) rename test/{test.transporters.js => test.transporters.ts} (100%) rename test/{test.urlshortener.v1.js => test.urlshortener.v1.ts} (100%) rename test/{utils.js => utils.ts} (100%) create mode 100644 tsconfig.json create mode 100644 tsconfig.tools.json diff --git a/.gitignore b/.gitignore index 628ce3aad2..7744a933c4 100644 --- a/.gitignore +++ b/.gitignore @@ -7,3 +7,7 @@ coverage # Empty API apis/iam/v1alpha1.js .nyc_output +**/*.js +**/*.js.map +!samples/**/*.js +.vscode diff --git a/.travis.yml b/.travis.yml index ee71e0e828..0576b4f73e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -18,5 +18,8 @@ cache: before_install: - npm i -g nyc codecov +before_script: + - npm run build + after_success: - nyc report --reporter=lcov > coverage.lcov && codecov diff --git a/apis/acceleratedmobilepageurl/v1.js b/apis/acceleratedmobilepageurl/v1.ts similarity index 98% rename from apis/acceleratedmobilepageurl/v1.js rename to apis/acceleratedmobilepageurl/v1.ts index 5a83594b2f..7e229aff3c 100644 --- a/apis/acceleratedmobilepageurl/v1.js +++ b/apis/acceleratedmobilepageurl/v1.ts @@ -117,4 +117,4 @@ the cached document in the Google AMP Cache. * @property {string} errorCode The error code of an API call. * @property {string} originalUrl The original non-AMP URL. */ -module.exports = Acceleratedmobilepageurl; +export = Acceleratedmobilepageurl; diff --git a/apis/adexchangebuyer/v1.2.js b/apis/adexchangebuyer/v1.2.ts similarity index 99% rename from apis/adexchangebuyer/v1.2.js rename to apis/adexchangebuyer/v1.2.ts index fe562ea30a..827680be75 100644 --- a/apis/adexchangebuyer/v1.2.js +++ b/apis/adexchangebuyer/v1.2.ts @@ -354,4 +354,4 @@ function Adexchangebuyer(options) { // eslint-disable-line * @property {string} kind Resource type. * @property {string} nextPageToken Continuation token used to page through creatives. To retrieve the next page of results, set the next request's "pageToken" value to this. */ -module.exports = Adexchangebuyer; +export = Adexchangebuyer; diff --git a/apis/adexchangebuyer/v1.3.js b/apis/adexchangebuyer/v1.3.ts similarity index 99% rename from apis/adexchangebuyer/v1.3.js rename to apis/adexchangebuyer/v1.3.ts index 15226419ba..0d0f4f2eee 100644 --- a/apis/adexchangebuyer/v1.3.js +++ b/apis/adexchangebuyer/v1.3.ts @@ -1004,4 +1004,4 @@ function Adexchangebuyer(options) { // eslint-disable-line * @property {adexchangebuyer(v1.3).PretargetingConfig[]} items A list of pretargeting configs * @property {string} kind Resource type. */ -module.exports = Adexchangebuyer; +export = Adexchangebuyer; diff --git a/apis/adexchangebuyer/v1.4.js b/apis/adexchangebuyer/v1.4.ts similarity index 99% rename from apis/adexchangebuyer/v1.4.js rename to apis/adexchangebuyer/v1.4.ts index 422e26886a..34dc621af3 100644 --- a/apis/adexchangebuyer/v1.4.js +++ b/apis/adexchangebuyer/v1.4.ts @@ -2085,4 +2085,4 @@ function Adexchangebuyer(options) { // eslint-disable-line * @property {string} proposalRevisionNumber The current revision number of the proposal to be updated. * @property {string} updateAction The proposed action on the private auction proposal. */ -module.exports = Adexchangebuyer; +export = Adexchangebuyer; diff --git a/apis/adexchangebuyer2/v2beta1.js b/apis/adexchangebuyer2/v2beta1.ts similarity index 99% rename from apis/adexchangebuyer2/v2beta1.js rename to apis/adexchangebuyer2/v2beta1.ts index 790a4bb590..6ab0b324d0 100644 --- a/apis/adexchangebuyer2/v2beta1.js +++ b/apis/adexchangebuyer2/v2beta1.ts @@ -1139,4 +1139,4 @@ buyer. that the invited user is associated with. The value of this field is ignored in create operations. */ -module.exports = Adexchangebuyer2; +export = Adexchangebuyer2; diff --git a/apis/adexchangeseller/v1.1.js b/apis/adexchangeseller/v1.1.ts similarity index 99% rename from apis/adexchangeseller/v1.1.js rename to apis/adexchangeseller/v1.1.ts index 0872e7fca8..73130ec2d1 100644 --- a/apis/adexchangeseller/v1.1.js +++ b/apis/adexchangeseller/v1.1.ts @@ -881,4 +881,4 @@ INACTIVE: Indicates that there has been no activity on this ad unit in the last * @property {string} kind Kind of list this is, in this case adexchangeseller#urlChannels. * @property {string} nextPageToken Continuation token used to page through URL channels. To retrieve the next page of results, set the next request's "pageToken" value to this. */ -module.exports = Adexchangeseller; +export = Adexchangeseller; diff --git a/apis/adexchangeseller/v1.js b/apis/adexchangeseller/v1.ts similarity index 99% rename from apis/adexchangeseller/v1.js rename to apis/adexchangeseller/v1.ts index 611cf2e20a..d2e7162233 100644 --- a/apis/adexchangeseller/v1.js +++ b/apis/adexchangeseller/v1.ts @@ -589,4 +589,4 @@ INACTIVE: Indicates that there has been no activity on this ad unit in the last * @property {string} kind Kind of list this is, in this case adexchangeseller#urlChannels. * @property {string} nextPageToken Continuation token used to page through URL channels. To retrieve the next page of results, set the next request's "pageToken" value to this. */ -module.exports = Adexchangeseller; +export = Adexchangeseller; diff --git a/apis/adexchangeseller/v2.0.js b/apis/adexchangeseller/v2.0.ts similarity index 99% rename from apis/adexchangeseller/v2.0.js rename to apis/adexchangeseller/v2.0.ts index 108f08c235..0b0ae3ddcf 100644 --- a/apis/adexchangeseller/v2.0.js +++ b/apis/adexchangeseller/v2.0.ts @@ -749,4 +749,4 @@ function Adexchangeseller(options) { // eslint-disable-line * @property {string} kind Kind of list this is, in this case adexchangeseller#urlChannels. * @property {string} nextPageToken Continuation token used to page through URL channels. To retrieve the next page of results, set the next request's "pageToken" value to this. */ -module.exports = Adexchangeseller; +export = Adexchangeseller; diff --git a/apis/admin/datatransfer_v1.js b/apis/admin/datatransfer_v1.ts similarity index 99% rename from apis/admin/datatransfer_v1.js rename to apis/admin/datatransfer_v1.ts index 04d7dcbaa8..00053bd1f9 100644 --- a/apis/admin/datatransfer_v1.js +++ b/apis/admin/datatransfer_v1.ts @@ -287,4 +287,4 @@ function Admin(options) { // eslint-disable-line * @property {string} kind Identifies the resource as a collection of data transfer requests. * @property {string} nextPageToken Continuation token which will be used to specify next page in list API. */ -module.exports = Admin; +export = Admin; diff --git a/apis/admin/directory_v1.js b/apis/admin/directory_v1.ts similarity index 99% rename from apis/admin/directory_v1.js rename to apis/admin/directory_v1.ts index b33b233840..64f10c7280 100644 --- a/apis/admin/directory_v1.js +++ b/apis/admin/directory_v1.ts @@ -4311,4 +4311,4 @@ function Admin(options) { // eslint-disable-line * @property {admin(directory_v1).VerificationCode[]} items A list of verification code resources. * @property {string} kind The type of the resource. This is always admin#directory#verificationCodesList. */ -module.exports = Admin; +export = Admin; diff --git a/apis/admin/reports_v1.js b/apis/admin/reports_v1.ts similarity index 99% rename from apis/admin/reports_v1.js rename to apis/admin/reports_v1.ts index ede81bf057..a63a80a368 100644 --- a/apis/admin/reports_v1.js +++ b/apis/admin/reports_v1.ts @@ -316,4 +316,4 @@ function Admin(options) { // eslint-disable-line * @property {admin(reports_v1).UsageReport[]} usageReports Various application parameter records. * @property {object[]} warnings Warnings if any. */ -module.exports = Admin; +export = Admin; diff --git a/apis/adsense/v1.3.js b/apis/adsense/v1.3.ts similarity index 99% rename from apis/adsense/v1.3.js rename to apis/adsense/v1.3.ts index a6609feb36..39d69068cb 100644 --- a/apis/adsense/v1.3.js +++ b/apis/adsense/v1.3.ts @@ -1591,4 +1591,4 @@ INACTIVE: Indicates that there has been no activity on this ad unit in the last * @property {string} kind Kind of list this is, in this case adsense#urlChannels. * @property {string} nextPageToken Continuation token used to page through URL channels. To retrieve the next page of results, set the next request's "pageToken" value to this. */ -module.exports = Adsense; +export = Adsense; diff --git a/apis/adsense/v1.4.js b/apis/adsense/v1.4.ts similarity index 99% rename from apis/adsense/v1.4.js rename to apis/adsense/v1.4.ts index 7fd765d0b8..b1870994e3 100644 --- a/apis/adsense/v1.4.js +++ b/apis/adsense/v1.4.ts @@ -1760,4 +1760,4 @@ INACTIVE: Indicates that there has been no activity on this ad unit in the last * @property {string} kind Kind of list this is, in this case adsense#urlChannels. * @property {string} nextPageToken Continuation token used to page through URL channels. To retrieve the next page of results, set the next request's "pageToken" value to this. */ -module.exports = Adsense; +export = Adsense; diff --git a/apis/adsensehost/v4.1.js b/apis/adsensehost/v4.1.ts similarity index 99% rename from apis/adsensehost/v4.1.js rename to apis/adsensehost/v4.1.ts index 1d86d09ef2..731833c5b0 100644 --- a/apis/adsensehost/v4.1.js +++ b/apis/adsensehost/v4.1.ts @@ -1177,4 +1177,4 @@ INACTIVE: Indicates that there has been no activity on this ad unit in the last * @property {string} kind Kind of list this is, in this case adsensehost#urlChannels. * @property {string} nextPageToken Continuation token used to page through URL channels. To retrieve the next page of results, set the next request's "pageToken" value to this. */ -module.exports = Adsensehost; +export = Adsensehost; diff --git a/apis/analytics/v2.4.js b/apis/analytics/v2.4.ts similarity index 99% rename from apis/analytics/v2.4.js rename to apis/analytics/v2.4.ts index 99bddc2a9e..79b889d987 100644 --- a/apis/analytics/v2.4.js +++ b/apis/analytics/v2.4.ts @@ -293,4 +293,4 @@ function Analytics(options) { // eslint-disable-line }; } -module.exports = Analytics; +export = Analytics; diff --git a/apis/analytics/v3.js b/apis/analytics/v3.ts similarity index 99% rename from apis/analytics/v3.js rename to apis/analytics/v3.ts index 095f36cbbe..40c709a438 100644 --- a/apis/analytics/v3.js +++ b/apis/analytics/v3.ts @@ -4172,4 +4172,4 @@ For write (i.e., create, update, or delete) operations, you may specify a value * @property {string} updated Time this web property was last modified. * @property {string} websiteUrl Website url for this web property. */ -module.exports = Analytics; +export = Analytics; diff --git a/apis/analyticsreporting/v4.js b/apis/analyticsreporting/v4.ts similarity index 99% rename from apis/analyticsreporting/v4.js rename to apis/analyticsreporting/v4.ts index c30ee654b1..22a6c8bbb5 100644 --- a/apis/analyticsreporting/v4.js +++ b/apis/analyticsreporting/v4.ts @@ -602,4 +602,4 @@ will result in unexpected results. * @property {analyticsreporting(v4).PivotHeaderEntry[]} pivotHeaderEntries A single pivot section header. * @property {integer} totalPivotGroupsCount The total number of groups for this pivot. */ -module.exports = Analyticsreporting; +export = Analyticsreporting; diff --git a/apis/androidenterprise/v1.js b/apis/androidenterprise/v1.ts similarity index 99% rename from apis/androidenterprise/v1.js rename to apis/androidenterprise/v1.ts index 2dc20f7966..f60f9952a2 100644 --- a/apis/androidenterprise/v1.js +++ b/apis/androidenterprise/v1.ts @@ -3420,4 +3420,4 @@ No attempt is made to verify that all pages are reachable from the homepage. * @property {string} kind Identifies what kind of resource this is. Value: the fixed string "androidenterprise#usersListResponse". * @property {androidenterprise(v1).User[]} user A user of an enterprise. */ -module.exports = Androidenterprise; +export = Androidenterprise; diff --git a/apis/androidpublisher/v1.1.js b/apis/androidpublisher/v1.1.ts similarity index 99% rename from apis/androidpublisher/v1.1.js rename to apis/androidpublisher/v1.1.ts index bc92be208b..7f1aeaa94d 100644 --- a/apis/androidpublisher/v1.1.js +++ b/apis/androidpublisher/v1.1.ts @@ -183,4 +183,4 @@ function Androidpublisher(options) { // eslint-disable-line * @property {string} kind This kind represents a subscriptionPurchase object in the androidpublisher service. * @property {string} validUntilTimestampMsec Time at which the subscription will expire, in milliseconds since the Epoch. */ -module.exports = Androidpublisher; +export = Androidpublisher; diff --git a/apis/androidpublisher/v1.js b/apis/androidpublisher/v1.ts similarity index 99% rename from apis/androidpublisher/v1.js rename to apis/androidpublisher/v1.ts index 5ddbac6be0..a0986ebbc4 100644 --- a/apis/androidpublisher/v1.js +++ b/apis/androidpublisher/v1.ts @@ -128,4 +128,4 @@ function Androidpublisher(options) { // eslint-disable-line * @property {string} kind This kind represents a subscriptionPurchase object in the androidpublisher service. * @property {string} validUntilTimestampMsec Time at which the subscription will expire, in milliseconds since the Epoch. */ -module.exports = Androidpublisher; +export = Androidpublisher; diff --git a/apis/androidpublisher/v2.js b/apis/androidpublisher/v2.ts similarity index 99% rename from apis/androidpublisher/v2.js rename to apis/androidpublisher/v2.ts index 3132a915a3..ac872f894f 100644 --- a/apis/androidpublisher/v2.js +++ b/apis/androidpublisher/v2.ts @@ -2727,4 +2727,4 @@ function Androidpublisher(options) { // eslint-disable-line * @property {androidpublisher(v2).TokenPagination} tokenPagination * @property {androidpublisher(v2).VoidedPurchase[]} voidedPurchases */ -module.exports = Androidpublisher; +export = Androidpublisher; diff --git a/apis/appengine/v1.js b/apis/appengine/v1.ts similarity index 99% rename from apis/appengine/v1.js rename to apis/appengine/v1.ts index ff2a00913b..e7467e7080 100644 --- a/apis/appengine/v1.js +++ b/apis/appengine/v1.ts @@ -1313,4 +1313,4 @@ ManualScaling or BasicScaling: B1, B2, B4, B8, B4_1GDefaults to F1 for Automatic * @property {string} method API method that initiated this operation. Example: google.appengine.v1.Versions.CreateVersion.@OutputOnly * @property {string} endTime Time that this operation completed.@OutputOnly */ -module.exports = Appengine; +export = Appengine; diff --git a/apis/appengine/v1alpha.js b/apis/appengine/v1alpha.ts similarity index 99% rename from apis/appengine/v1alpha.js rename to apis/appengine/v1alpha.ts index d2747b271e..f96a9b5ddc 100644 --- a/apis/appengine/v1alpha.js +++ b/apis/appengine/v1alpha.ts @@ -303,4 +303,4 @@ function Appengine(options) { // eslint-disable-line * @property {string} name Resource name for the location, which may vary between implementations. For example: "projects/example-project/locations/us-east1" */ -module.exports = Appengine; +export = Appengine; diff --git a/apis/appengine/v1beta.js b/apis/appengine/v1beta.ts similarity index 99% rename from apis/appengine/v1beta.js rename to apis/appengine/v1beta.ts index 5bc1029ee0..5da2cb7688 100644 --- a/apis/appengine/v1beta.js +++ b/apis/appengine/v1beta.ts @@ -1802,4 +1802,4 @@ ManualScaling or BasicScaling: B1, B2, B4, B8, B4_1GDefaults to F1 for Automatic * @property {string} publicCertificate PEM encoded x.509 public key certificate. This field is set once on certificate creation. Must include the header and footer. Example: <pre> -----BEGIN CERTIFICATE----- <certificate_value> -----END CERTIFICATE----- </pre> * @property {string} privateKey Unencrypted PEM encoded RSA private key. This field is set once on certificate creation and then encrypted. The key size must be 2048 bits or fewer. Must include the header and footer. Example: <pre> -----BEGIN RSA PRIVATE KEY----- <unencrypted_key_value> -----END RSA PRIVATE KEY----- </pre> @InputOnly */ -module.exports = Appengine; +export = Appengine; diff --git a/apis/appengine/v1beta4.js b/apis/appengine/v1beta4.ts similarity index 99% rename from apis/appengine/v1beta4.js rename to apis/appengine/v1beta4.ts index 17f015ea94..7f6d44ca9e 100644 --- a/apis/appengine/v1beta4.js +++ b/apis/appengine/v1beta4.ts @@ -1244,4 +1244,4 @@ ManualScaling or BasicScaling: B1, B2, B4, B8, B4_1GDefaults to F1 for Automatic * @property {integer} targetRequestCountPerSec Target requests per second. * @property {integer} targetConcurrentRequests Target number of concurrent requests. */ -module.exports = Appengine; +export = Appengine; diff --git a/apis/appengine/v1beta5.js b/apis/appengine/v1beta5.ts similarity index 99% rename from apis/appengine/v1beta5.js rename to apis/appengine/v1beta5.ts index ca9621291f..421e5fd588 100644 --- a/apis/appengine/v1beta5.js +++ b/apis/appengine/v1beta5.ts @@ -1245,4 +1245,4 @@ ManualScaling or BasicScaling: B1, B2, B4, B8, B4_1GDefaults to F1 for Automatic * @property {appengine(v1beta5).Service[]} services The services belonging to the requested application. * @property {string} nextPageToken Continuation token for fetching the next page of results. */ -module.exports = Appengine; +export = Appengine; diff --git a/apis/appsactivity/v1.js b/apis/appsactivity/v1.ts similarity index 99% rename from apis/appsactivity/v1.js rename to apis/appsactivity/v1.ts index b3e380f53b..25c047b18d 100644 --- a/apis/appsactivity/v1.js +++ b/apis/appsactivity/v1.ts @@ -178,4 +178,4 @@ function Appsactivity(options) { // eslint-disable-line * @property {string} permissionId The permission ID associated with this user. Equivalent to the Drive API's permission ID for this user, returned as part of the Drive Permissions resource. * @property {appsactivity(v1).Photo} photo The profile photo of the user. Not present if the user has no profile photo. */ -module.exports = Appsactivity; +export = Appsactivity; diff --git a/apis/appstate/v1.js b/apis/appstate/v1.ts similarity index 99% rename from apis/appstate/v1.js rename to apis/appstate/v1.ts index 6db8e8993a..8b45338434 100644 --- a/apis/appstate/v1.js +++ b/apis/appstate/v1.ts @@ -255,4 +255,4 @@ function Appstate(options) { // eslint-disable-line * @property {string} kind Uniquely identifies the type of this resource. Value is always the fixed string appstate#writeResult. * @property {integer} stateKey The written key. */ -module.exports = Appstate; +export = Appstate; diff --git a/apis/bigquery/v2.js b/apis/bigquery/v2.ts similarity index 99% rename from apis/bigquery/v2.js rename to apis/bigquery/v2.ts index 6c74b5b85f..1d9893cf78 100644 --- a/apis/bigquery/v2.js +++ b/apis/bigquery/v2.ts @@ -2628,4 +2628,4 @@ function Bigquery(options) { // eslint-disable-line * @property {boolean} useLegacySql Specifies whether to use BigQuery's legacy SQL for this view. The default value is true. If set to false, the view will use BigQuery's standard SQL: https://cloud.google.com/bigquery/sql-reference/ Queries and views that reference this view must use the same flag value. * @property {bigquery(v2).UserDefinedFunctionResource[]} userDefinedFunctionResources Describes user-defined function resources used in the query. */ -module.exports = Bigquery; +export = Bigquery; diff --git a/apis/blogger/v2.js b/apis/blogger/v2.ts similarity index 99% rename from apis/blogger/v2.js rename to apis/blogger/v2.ts index ce32cc1258..32aa73ed3b 100644 --- a/apis/blogger/v2.js +++ b/apis/blogger/v2.ts @@ -501,4 +501,4 @@ function Blogger(options) { // eslint-disable-line * @property {string} selfLink The API REST URL to fetch this resource from. * @property {string} url The user's profile page. */ -module.exports = Blogger; +export = Blogger; diff --git a/apis/blogger/v3.js b/apis/blogger/v3.ts similarity index 99% rename from apis/blogger/v3.js rename to apis/blogger/v3.ts index e3024528c3..b4adc22824 100644 --- a/apis/blogger/v3.js +++ b/apis/blogger/v3.ts @@ -1517,4 +1517,4 @@ function Blogger(options) { // eslint-disable-line * @property {string} selfLink The API REST URL to fetch this resource from. * @property {string} url The user's profile page. */ -module.exports = Blogger; +export = Blogger; diff --git a/apis/books/v1.js b/apis/books/v1.ts similarity index 99% rename from apis/books/v1.js rename to apis/books/v1.ts index 3a20f3cdcd..477a87dbe8 100644 --- a/apis/books/v1.js +++ b/apis/books/v1.ts @@ -2346,4 +2346,4 @@ function Books(options) { // eslint-disable-line * @property {string} shortSeriesBookTitle Short book title in the context of the series. * @property {object[]} volumeSeries */ -module.exports = Books; +export = Books; diff --git a/apis/calendar/v3.js b/apis/calendar/v3.ts similarity index 99% rename from apis/calendar/v3.js rename to apis/calendar/v3.ts index 2a6eafb12f..b4581d1f6f 100644 --- a/apis/calendar/v3.js +++ b/apis/calendar/v3.ts @@ -1857,4 +1857,4 @@ For adding Google Drive file attachments use the same format as in alternateLink * @property {string} end The (exclusive) end of the time period. * @property {string} start The (inclusive) start of the time period. */ -module.exports = Calendar; +export = Calendar; diff --git a/apis/civicinfo/v2.js b/apis/civicinfo/v2.ts similarity index 99% rename from apis/civicinfo/v2.js rename to apis/civicinfo/v2.ts index dc267f8442..115417f404 100644 --- a/apis/civicinfo/v2.js +++ b/apis/civicinfo/v2.ts @@ -554,4 +554,4 @@ For example, if this division's OCD ID is ocd-division/country:us/district:d * @property {civicinfo(v2).VoterInfoRequest} request * @property {civicinfo(v2).VoterInfoResponse} response */ -module.exports = Civicinfo; +export = Civicinfo; diff --git a/apis/classroom/v1.js b/apis/classroom/v1.ts similarity index 99% rename from apis/classroom/v1.js rename to apis/classroom/v1.ts index 3a8f5463ea..bcfa40c1a6 100644 --- a/apis/classroom/v1.js +++ b/apis/classroom/v1.ts @@ -2235,4 +2235,4 @@ results are available. results are available. * @property {classroom(v1).Student[]} students Students who match the list request. */ -module.exports = Classroom; +export = Classroom; diff --git a/apis/cloudbilling/v1.js b/apis/cloudbilling/v1.ts similarity index 99% rename from apis/cloudbilling/v1.js rename to apis/cloudbilling/v1.ts index 2e8b0793fa..b980dc86d1 100644 --- a/apis/cloudbilling/v1.js +++ b/apis/cloudbilling/v1.ts @@ -573,4 +573,4 @@ therefore projects associated with it will be unable to use paid services. `billingAccounts/012345-567890-ABCDEF` would be the resource name for billing account `012345-567890-ABCDEF`. */ -module.exports = Cloudbilling; +export = Cloudbilling; diff --git a/apis/cloudbuild/v1.js b/apis/cloudbuild/v1.ts similarity index 99% rename from apis/cloudbuild/v1.js rename to apis/cloudbuild/v1.ts index 61205cca8b..5bd3d3141a 100644 --- a/apis/cloudbuild/v1.js +++ b/apis/cloudbuild/v1.ts @@ -770,4 +770,4 @@ build. * @property {cloudbuild(v1).BuiltImage[]} images Images that were built as a part of the build. * @property {string[]} buildStepImages List of build step digests, in order corresponding to build step indices. */ -module.exports = Cloudbuild; +export = Cloudbuild; diff --git a/apis/clouddebugger/v2.js b/apis/clouddebugger/v2.ts similarity index 99% rename from apis/clouddebugger/v2.js rename to apis/clouddebugger/v2.ts index cbc05f8b90..989f11608a 100644 --- a/apis/clouddebugger/v2.js +++ b/apis/clouddebugger/v2.ts @@ -1120,4 +1120,4 @@ The field `id` is guaranteed to be set (in addition to the echoed fileds). * @property {clouddebugger(v2).Breakpoint} breakpoint Updated breakpoint information. The field 'id' must be set. */ -module.exports = Clouddebugger; +export = Clouddebugger; diff --git a/apis/clouderrorreporting/v1beta1.js b/apis/clouderrorreporting/v1beta1.ts similarity index 99% rename from apis/clouderrorreporting/v1beta1.js rename to apis/clouderrorreporting/v1beta1.ts index 8ab84d47ce..0fe18c954d 100644 --- a/apis/clouderrorreporting/v1beta1.js +++ b/apis/clouderrorreporting/v1beta1.ts @@ -489,4 +489,4 @@ and contain the result of [`(string)$exception`](http://php.net/manual/en/except If not provided, the time when the event was received by the Error Reporting system will be used. */ -module.exports = Clouderrorreporting; +export = Clouderrorreporting; diff --git a/apis/cloudfunctions/v1.js b/apis/cloudfunctions/v1.ts similarity index 97% rename from apis/cloudfunctions/v1.js rename to apis/cloudfunctions/v1.ts index d060339288..032f188294 100644 --- a/apis/cloudfunctions/v1.js +++ b/apis/cloudfunctions/v1.ts @@ -51,4 +51,4 @@ function Cloudfunctions(options) { // eslint-disable-line projects/project-1/locations/region-1/functions/function-1 * @property {object} request The original request that started the operation. */ -module.exports = Cloudfunctions; +export = Cloudfunctions; diff --git a/apis/cloudfunctions/v1beta2.js b/apis/cloudfunctions/v1beta2.ts similarity index 99% rename from apis/cloudfunctions/v1beta2.js rename to apis/cloudfunctions/v1beta2.ts index 9babbe2f05..49bca56313 100644 --- a/apis/cloudfunctions/v1beta2.js +++ b/apis/cloudfunctions/v1beta2.ts @@ -509,4 +509,4 @@ Google Cloud Pub/Sub `providers/cloud.pubsub/eventTypes/topic.publish` * @type object * @property {string} url Output only. The deployed url for the function. */ -module.exports = Cloudfunctions; +export = Cloudfunctions; diff --git a/apis/cloudkms/v1.js b/apis/cloudkms/v1.ts similarity index 99% rename from apis/cloudkms/v1.js rename to apis/cloudkms/v1.ts index 70741c8ec4..1a1fb4ab4e 100644 --- a/apis/cloudkms/v1.js +++ b/apis/cloudkms/v1.ts @@ -1238,4 +1238,4 @@ allowed. * @memberOf! cloudkms(v1) * @type object */ -module.exports = Cloudkms; +export = Cloudkms; diff --git a/apis/cloudmonitoring/v2beta2.js b/apis/cloudmonitoring/v2beta2.ts similarity index 99% rename from apis/cloudmonitoring/v2beta2.js rename to apis/cloudmonitoring/v2beta2.ts index 42ac843ea7..4bb216fad2 100644 --- a/apis/cloudmonitoring/v2beta2.js +++ b/apis/cloudmonitoring/v2beta2.ts @@ -450,4 +450,4 @@ function Cloudmonitoring(options) { // eslint-disable-line * @type object * @property {string} kind Identifies what kind of resource this is. Value: the fixed string "cloudmonitoring#writeTimeseriesResponse". */ -module.exports = Cloudmonitoring; +export = Cloudmonitoring; diff --git a/apis/cloudresourcemanager/v1.js b/apis/cloudresourcemanager/v1.ts similarity index 99% rename from apis/cloudresourcemanager/v1.js rename to apis/cloudresourcemanager/v1.ts index e7ba22f775..70b25f29a0 100644 --- a/apis/cloudresourcemanager/v1.js +++ b/apis/cloudresourcemanager/v1.ts @@ -2925,4 +2925,4 @@ common set of message types for APIs to use. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. Required */ -module.exports = Cloudresourcemanager; +export = Cloudresourcemanager; diff --git a/apis/cloudresourcemanager/v1beta1.js b/apis/cloudresourcemanager/v1beta1.ts similarity index 99% rename from apis/cloudresourcemanager/v1beta1.js rename to apis/cloudresourcemanager/v1beta1.ts index 5baf177aa1..77ac7eb92c 100644 --- a/apis/cloudresourcemanager/v1beta1.js +++ b/apis/cloudresourcemanager/v1beta1.ts @@ -1797,4 +1797,4 @@ Read-only. Example: <code>415104041262</code> Read-only. */ -module.exports = Cloudresourcemanager; +export = Cloudresourcemanager; diff --git a/apis/cloudtrace/v1.js b/apis/cloudtrace/v1.ts similarity index 99% rename from apis/cloudtrace/v1.js rename to apis/cloudtrace/v1.ts index abd7d25a4a..56b471177d 100644 --- a/apis/cloudtrace/v1.js +++ b/apis/cloudtrace/v1.ts @@ -384,4 +384,4 @@ numeric value formatted as a 32-byte hex string. * @type object * @property {cloudtrace(v1).Trace[]} traces List of traces. */ -module.exports = Cloudtrace; +export = Cloudtrace; diff --git a/apis/clouduseraccounts/alpha.js b/apis/clouduseraccounts/alpha.ts similarity index 99% rename from apis/clouduseraccounts/alpha.js rename to apis/clouduseraccounts/alpha.ts index d1165273cd..a348782072 100644 --- a/apis/clouduseraccounts/alpha.js +++ b/apis/clouduseraccounts/alpha.ts @@ -1151,4 +1151,4 @@ If no `etag` is provided in the call to `setIamPolicy`, then the existing policy * @property {string} nextPageToken [Output Only] A token used to continue a truncated list request. * @property {string} selfLink [Output Only] Server defined URL for this resource. */ -module.exports = Clouduseraccounts; +export = Clouduseraccounts; diff --git a/apis/clouduseraccounts/beta.js b/apis/clouduseraccounts/beta.ts similarity index 99% rename from apis/clouduseraccounts/beta.js rename to apis/clouduseraccounts/beta.ts index 4e24b2a469..cdebead97f 100644 --- a/apis/clouduseraccounts/beta.js +++ b/apis/clouduseraccounts/beta.ts @@ -1814,4 +1814,4 @@ function Clouduseraccounts(options) { // eslint-disable-line * @property {string} nextPageToken [Output Only] A token used to continue a truncated list request. * @property {string} selfLink [Output Only] Server defined URL for this resource. */ -module.exports = Clouduseraccounts; +export = Clouduseraccounts; diff --git a/apis/clouduseraccounts/vm_alpha.js b/apis/clouduseraccounts/vm_alpha.ts similarity index 99% rename from apis/clouduseraccounts/vm_alpha.js rename to apis/clouduseraccounts/vm_alpha.ts index 2e5f51f382..d9a1446187 100644 --- a/apis/clouduseraccounts/vm_alpha.js +++ b/apis/clouduseraccounts/vm_alpha.ts @@ -1151,4 +1151,4 @@ If no `etag` is provided in the call to `setIamPolicy`, then the existing policy * @property {string} nextPageToken [Output Only] A token used to continue a truncated list request. * @property {string} selfLink [Output Only] Server defined URL for this resource. */ -module.exports = Clouduseraccounts; +export = Clouduseraccounts; diff --git a/apis/clouduseraccounts/vm_beta.js b/apis/clouduseraccounts/vm_beta.ts similarity index 99% rename from apis/clouduseraccounts/vm_beta.js rename to apis/clouduseraccounts/vm_beta.ts index 0d49d1d034..eb36a7173e 100644 --- a/apis/clouduseraccounts/vm_beta.js +++ b/apis/clouduseraccounts/vm_beta.ts @@ -842,4 +842,4 @@ function Clouduseraccounts(options) { // eslint-disable-line * @property {string} nextPageToken [Output Only] A token used to continue a truncated list request. * @property {string} selfLink [Output Only] Server defined URL for this resource. */ -module.exports = Clouduseraccounts; +export = Clouduseraccounts; diff --git a/apis/compute/alpha.js b/apis/compute/alpha.ts similarity index 99% rename from apis/compute/alpha.js rename to apis/compute/alpha.ts index dadac0b3f2..ad9bc668ba 100644 --- a/apis/compute/alpha.js +++ b/apis/compute/alpha.ts @@ -18301,4 +18301,4 @@ To see the latest fingerprint, make a get() request to retrieve a VpnTunnel. * @property {string} labelFingerprint 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. * @property {object} labels The labels to set for this resource. */ -module.exports = Compute; +export = Compute; diff --git a/apis/compute/beta.js b/apis/compute/beta.ts similarity index 99% rename from apis/compute/beta.js rename to apis/compute/beta.ts index 1cefd82ab1..20caaad45b 100644 --- a/apis/compute/beta.js +++ b/apis/compute/beta.ts @@ -34906,4 +34906,4 @@ CLIENT_IP_PROTO: Connections from the same client IP with the same IP protocol w * @property {string} labelFingerprint 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. * @property {object} labels The labels to set for this resource. */ -module.exports = Compute; +export = Compute; diff --git a/apis/compute/v1.js b/apis/compute/v1.ts similarity index 99% rename from apis/compute/v1.js rename to apis/compute/v1.ts index edcb9811ed..803c770976 100644 --- a/apis/compute/v1.js +++ b/apis/compute/v1.ts @@ -27616,4 +27616,4 @@ CLIENT_IP_PROTO: Connections from the same client IP with the same IP protocol w * @property {string} nextPageToken [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. * @property {string} selfLink [Output Only] Server-defined URL for this resource. */ -module.exports = Compute; +export = Compute; diff --git a/apis/consumersurveys/v2.js b/apis/consumersurveys/v2.ts similarity index 99% rename from apis/consumersurveys/v2.js rename to apis/consumersurveys/v2.ts index b538db0187..e41aed3489 100644 --- a/apis/consumersurveys/v2.js +++ b/apis/consumersurveys/v2.ts @@ -618,4 +618,4 @@ function Consumersurveys(options) { // eslint-disable-line * @property {string} nextPageToken * @property {string} previousPageToken */ -module.exports = Consumersurveys; +export = Consumersurveys; diff --git a/apis/container/v1.js b/apis/container/v1.ts similarity index 99% rename from apis/container/v1.js rename to apis/container/v1.ts index 86e10d59f2..9e1ce85f72 100644 --- a/apis/container/v1.js +++ b/apis/container/v1.ts @@ -1733,4 +1733,4 @@ function Container(options) { // eslint-disable-line * @type object * @property {container(v1).NodeManagement} management NodeManagement configuration for the node pool. */ -module.exports = Container; +export = Container; diff --git a/apis/content/v2.js b/apis/content/v2.ts similarity index 99% rename from apis/content/v2.js rename to apis/content/v2.ts index c108eabac9..6e0a5e6d8c 100644 --- a/apis/content/v2.js +++ b/apis/content/v2.ts @@ -3618,4 +3618,4 @@ Acceptable values are: * @property {string} unit The weight unit. * @property {string} value The weight represented as a number. */ -module.exports = Content; +export = Content; diff --git a/apis/content/v2sandbox.js b/apis/content/v2sandbox.ts similarity index 99% rename from apis/content/v2sandbox.js rename to apis/content/v2sandbox.ts index f0465f88da..070557a347 100644 --- a/apis/content/v2sandbox.js +++ b/apis/content/v2sandbox.ts @@ -1153,4 +1153,4 @@ Start date and end date are separated by a forward slash (/). The start date is * @property {string} predefinedBillingAddress The billing address. * @property {string} type The type of instrument. Note that real orders might have different values than the four values accepted by createTestOrder. */ -module.exports = Content; +export = Content; diff --git a/apis/customsearch/v1.js b/apis/customsearch/v1.ts similarity index 99% rename from apis/customsearch/v1.js rename to apis/customsearch/v1.ts index 73e9c93423..03afbb70f6 100644 --- a/apis/customsearch/v1.js +++ b/apis/customsearch/v1.ts @@ -204,4 +204,4 @@ function Customsearch(options) { // eslint-disable-line * @property {object} spelling * @property {object} url */ -module.exports = Customsearch; +export = Customsearch; diff --git a/apis/dataflow/v1b3.js b/apis/dataflow/v1b3.ts similarity index 99% rename from apis/dataflow/v1b3.js rename to apis/dataflow/v1b3.ts index 9c4bf6d216..3c5b6465ac 100644 --- a/apis/dataflow/v1b3.js +++ b/apis/dataflow/v1b3.ts @@ -2689,4 +2689,4 @@ to have failed. is completed, contains the result of the operation. * @property {dataflow(v1b3).ApproximateProgress} progress DEPRECATED in favor of reported_progress. */ -module.exports = Dataflow; +export = Dataflow; diff --git a/apis/dataproc/v1.js b/apis/dataproc/v1.ts similarity index 99% rename from apis/dataproc/v1.js rename to apis/dataproc/v1.ts index 78b0eb3f8e..020ff3e21e 100644 --- a/apis/dataproc/v1.js +++ b/apis/dataproc/v1.ts @@ -1924,4 +1924,4 @@ roles/storage.objectAdmin(see https://cloud.google.com/compute/docs/access/servi * @property {string} projectId Required The ID of the Google Cloud Platform project that the job belongs to. * @property {string} jobId Optional The job ID, which must be unique within the project. The job ID is generated by the server upon job submission or provided by the user as a means to perform retries without creating duplicate jobs. The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), or hyphens (-). The maximum length is 100 characters. */ -module.exports = Dataproc; +export = Dataproc; diff --git a/apis/dataproc/v1alpha1.js b/apis/dataproc/v1alpha1.ts similarity index 99% rename from apis/dataproc/v1alpha1.js rename to apis/dataproc/v1alpha1.ts index 3e3ddf976c..584bd6d933 100644 --- a/apis/dataproc/v1alpha1.js +++ b/apis/dataproc/v1alpha1.ts @@ -1603,4 +1603,4 @@ roles/storage.objectAdmin(see https://cloud.google.com/compute/docs/access/servi * @property {string} state A message containing the operation state. * @property {string} details A message containing any operation metadata details. */ -module.exports = Dataproc; +export = Dataproc; diff --git a/apis/dataproc/v1beta1.js b/apis/dataproc/v1beta1.ts similarity index 99% rename from apis/dataproc/v1beta1.js rename to apis/dataproc/v1beta1.ts index ccf7e5bc66..dcc04f028f 100644 --- a/apis/dataproc/v1beta1.js +++ b/apis/dataproc/v1beta1.ts @@ -1029,4 +1029,4 @@ roles/storage.objectAdmin(see https://cloud.google.com/compute/docs/access/servi * @type object * @property {dataproc(v1beta1).Job} job Required The job resource. */ -module.exports = Dataproc; +export = Dataproc; diff --git a/apis/datastore/v1.js b/apis/datastore/v1.ts similarity index 99% rename from apis/datastore/v1.js rename to apis/datastore/v1.ts index 5cd55cecee..b8f8f92d2d 100644 --- a/apis/datastore/v1.js +++ b/apis/datastore/v1.ts @@ -662,4 +662,4 @@ Queries are scoped to a single partition. * @property {string} name The name of the property. If name includes "."s, it may be interpreted as a property name path. */ -module.exports = Datastore; +export = Datastore; diff --git a/apis/datastore/v1beta1.js b/apis/datastore/v1beta1.ts similarity index 99% rename from apis/datastore/v1beta1.js rename to apis/datastore/v1beta1.ts index d9ea6bed31..31ca8bdc14 100644 --- a/apis/datastore/v1beta1.js +++ b/apis/datastore/v1beta1.ts @@ -577,4 +577,4 @@ The indexed property may be set for a null value. When indexed is true, stringVa * @property {integer} meaning The meaning field is reserved and should not be used. * @property {string} stringValue A UTF-8 encoded string value. When indexed is true, may have at most 500 characters. */ -module.exports = Datastore; +export = Datastore; diff --git a/apis/datastore/v1beta2.js b/apis/datastore/v1beta2.ts similarity index 99% rename from apis/datastore/v1beta2.js rename to apis/datastore/v1beta2.ts index 0099a5efa5..7292285ce2 100644 --- a/apis/datastore/v1beta2.js +++ b/apis/datastore/v1beta2.ts @@ -542,4 +542,4 @@ The indexed property may be set for a null value. When indexed is true, stringVa * @property {integer} meaning The meaning field is reserved and should not be used. * @property {string} stringValue A UTF-8 encoded string value. When indexed is true, may have at most 500 characters. */ -module.exports = Datastore; +export = Datastore; diff --git a/apis/datastore/v1beta3.js b/apis/datastore/v1beta3.ts similarity index 99% rename from apis/datastore/v1beta3.js rename to apis/datastore/v1beta3.ts index 62f1c27855..a981731660 100644 --- a/apis/datastore/v1beta3.js +++ b/apis/datastore/v1beta3.ts @@ -662,4 +662,4 @@ result batches. * @type object * @property {string} transaction The transaction identifier (always present). */ -module.exports = Datastore; +export = Datastore; diff --git a/apis/deploymentmanager/alpha.js b/apis/deploymentmanager/alpha.ts similarity index 99% rename from apis/deploymentmanager/alpha.js rename to apis/deploymentmanager/alpha.ts index f8304c4659..7cc8d75fa3 100644 --- a/apis/deploymentmanager/alpha.js +++ b/apis/deploymentmanager/alpha.ts @@ -1902,4 +1902,4 @@ If no `etag` is provided in the call to `setIamPolicy`, then the existing policy * @property {string} schemaValidation Customize how deployment manager will validate the resource against schema errors. * @property {string} undeclaredProperties Specify what to do with extra properties when executing a request. */ -module.exports = Deploymentmanager; +export = Deploymentmanager; diff --git a/apis/deploymentmanager/v2.js b/apis/deploymentmanager/v2.ts similarity index 99% rename from apis/deploymentmanager/v2.js rename to apis/deploymentmanager/v2.ts index d58952aefa..a85029e8df 100644 --- a/apis/deploymentmanager/v2.js +++ b/apis/deploymentmanager/v2.ts @@ -2098,4 +2098,4 @@ If no `etag` is provided in the call to `setIamPolicy`, then the existing policy * @property {string} nextPageToken A token used to continue a truncated list request. * @property {deploymentmanager(v2).Type[]} types [Output Only] A list of resource types supported by Deployment Manager. */ -module.exports = Deploymentmanager; +export = Deploymentmanager; diff --git a/apis/deploymentmanager/v2beta.js b/apis/deploymentmanager/v2beta.ts similarity index 99% rename from apis/deploymentmanager/v2beta.js rename to apis/deploymentmanager/v2beta.ts index 052b8a66cd..9457896956 100644 --- a/apis/deploymentmanager/v2beta.js +++ b/apis/deploymentmanager/v2beta.ts @@ -1720,4 +1720,4 @@ If no `etag` is provided in the call to `setIamPolicy`, then the existing policy * @property {string} schemaValidation Customize how deployment manager will validate the resource against schema errors. * @property {string} undeclaredProperties Specify what to do with extra properties when executing a request. */ -module.exports = Deploymentmanager; +export = Deploymentmanager; diff --git a/apis/dfareporting/v2.6.js b/apis/dfareporting/v2.6.ts similarity index 99% rename from apis/dfareporting/v2.6.js rename to apis/dfareporting/v2.6.ts index 1c4b74692e..223becdcb7 100644 --- a/apis/dfareporting/v2.6.js +++ b/apis/dfareporting/v2.6.ts @@ -20787,4 +20787,4 @@ Acceptable values are: * @property {string} nextPageToken Pagination token to be used for the next list operation. * @property {dfareporting(v2.6).UserRole[]} userRoles User role collection. */ -module.exports = Dfareporting; +export = Dfareporting; diff --git a/apis/dfareporting/v2.7.js b/apis/dfareporting/v2.7.ts similarity index 99% rename from apis/dfareporting/v2.7.js rename to apis/dfareporting/v2.7.ts index a4efc0bff3..5e03484af0 100644 --- a/apis/dfareporting/v2.7.js +++ b/apis/dfareporting/v2.7.ts @@ -21046,4 +21046,4 @@ Acceptable values are: * @property {dfareporting(v2.7).SkippableSetting} skippableSettings Settings for the skippability of video creatives served to this placement. If this object is provided, the creative-level skippable settings will be overridden. * @property {dfareporting(v2.7).TranscodeSetting} transcodeSettings Settings for the transcodes of video creatives served to this placement. If this object is provided, the creative-level transcode settings will be overridden. */ -module.exports = Dfareporting; +export = Dfareporting; diff --git a/apis/discovery/v1.js b/apis/discovery/v1.ts similarity index 99% rename from apis/discovery/v1.js rename to apis/discovery/v1.ts index f0e93f9d2d..24c77500b0 100644 --- a/apis/discovery/v1.js +++ b/apis/discovery/v1.ts @@ -212,4 +212,4 @@ function Discovery(options) { // eslint-disable-line * @property {object} methods Methods on this resource. * @property {object} resources Sub-resources on this resource. */ -module.exports = Discovery; +export = Discovery; diff --git a/apis/dlp/v2beta1.js b/apis/dlp/v2beta1.ts similarity index 99% rename from apis/dlp/v2beta1.js rename to apis/dlp/v2beta1.ts index 6efa39c30e..268b644f00 100644 --- a/apis/dlp/v2beta1.js +++ b/apis/dlp/v2beta1.ts @@ -737,4 +737,4 @@ If name includes "."s, it may be interpreted as a property name path. * @type object * @property {dlp(v2beta1).PropertyReference} property The property to project. */ -module.exports = Dlp; +export = Dlp; diff --git a/apis/dns/v1.js b/apis/dns/v1.ts similarity index 99% rename from apis/dns/v1.js rename to apis/dns/v1.ts index 0b61039dec..d6ee1ffd0c 100644 --- a/apis/dns/v1.js +++ b/apis/dns/v1.ts @@ -1001,4 +1001,4 @@ In this way you can retrieve the complete contents of even very large collection In this way you can retrieve the complete contents of even very large collections one page at a time. However, if the contents of the collection change between the first and last paginated list request, the set of all elements returned will be an inconsistent view of the collection. There is no way to retrieve a consistent snapshot of a collection larger than the maximum page size. * @property {dns(v1).ResourceRecordSet[]} rrsets The resource record set resources. */ -module.exports = Dns; +export = Dns; diff --git a/apis/dns/v2beta1.js b/apis/dns/v2beta1.ts similarity index 99% rename from apis/dns/v2beta1.js rename to apis/dns/v2beta1.ts index 641126576d..4c45e81234 100644 --- a/apis/dns/v2beta1.js +++ b/apis/dns/v2beta1.ts @@ -1725,4 +1725,4 @@ In this way you can retrieve the complete contents of even very large collection * @type object * @property {string} operationId For mutating operation requests that completed successfully. This is the client_operation_id if the client specified it, otherwise it is generated by the server (output only). */ -module.exports = Dns; +export = Dns; diff --git a/apis/doubleclickbidmanager/v1.js b/apis/doubleclickbidmanager/v1.ts similarity index 99% rename from apis/doubleclickbidmanager/v1.js rename to apis/doubleclickbidmanager/v1.ts index 2cd6556109..a78c65889c 100644 --- a/apis/doubleclickbidmanager/v1.js +++ b/apis/doubleclickbidmanager/v1.ts @@ -556,4 +556,4 @@ An locale string not in the list above will generate reports in English. * @property {string[]} errors Reasons why upload can't be completed. * @property {doubleclickbidmanager(v1).RowStatus[]} rowStatus Per-row upload status. */ -module.exports = Doubleclickbidmanager; +export = Doubleclickbidmanager; diff --git a/apis/doubleclicksearch/v2.js b/apis/doubleclicksearch/v2.ts similarity index 99% rename from apis/doubleclicksearch/v2.js rename to apis/doubleclicksearch/v2.ts index 35306c2ad0..7df87925c2 100644 --- a/apis/doubleclicksearch/v2.js +++ b/apis/doubleclicksearch/v2.ts @@ -578,4 +578,4 @@ If used in a conversion report, returns the value of the specified custom dimens * @type object * @property {doubleclicksearch(v2).Availability[]} availabilities The availabilities being returned. */ -module.exports = Doubleclicksearch; +export = Doubleclicksearch; diff --git a/apis/drive/v2.js b/apis/drive/v2.ts similarity index 99% rename from apis/drive/v2.js rename to apis/drive/v2.ts index b5937505ea..62d8f9ff42 100644 --- a/apis/drive/v2.js +++ b/apis/drive/v2.ts @@ -3089,4 +3089,4 @@ Setting this field will put the file in all of the provided folders. On insert, * @property {string} permissionId The user's ID as visible in the permissions collection. * @property {object} picture The user's profile picture. */ -module.exports = Drive; +export = Drive; diff --git a/apis/drive/v3.js b/apis/drive/v3.ts similarity index 99% rename from apis/drive/v3.js rename to apis/drive/v3.ts index bb96713494..0f0aed1966 100644 --- a/apis/drive/v3.js +++ b/apis/drive/v3.ts @@ -1835,4 +1835,4 @@ This field is only applicable to files with binary content in Drive. * @property {string} permissionId The user's ID as visible in Permission resources. * @property {string} photoLink A link to the user's profile photo, if available. */ -module.exports = Drive; +export = Drive; diff --git a/apis/firebasedynamiclinks/v1.js b/apis/firebasedynamiclinks/v1.ts similarity index 99% rename from apis/firebasedynamiclinks/v1.js rename to apis/firebasedynamiclinks/v1.ts index 4a64cd9abc..f46afcdbf4 100644 --- a/apis/firebasedynamiclinks/v1.js +++ b/apis/firebasedynamiclinks/v1.ts @@ -210,4 +210,4 @@ Connect. * @property {string} socialTitle Title to be displayed. Optional. * @property {string} socialImageLink An image url string. Optional. */ -module.exports = Firebasedynamiclinks; +export = Firebasedynamiclinks; diff --git a/apis/firebaserules/v1.js b/apis/firebaserules/v1.ts similarity index 99% rename from apis/firebaserules/v1.js rename to apis/firebaserules/v1.ts index b23d70b6a7..642f0e8c48 100644 --- a/apis/firebaserules/v1.js +++ b/apis/firebaserules/v1.ts @@ -559,4 +559,4 @@ E.g. `error_position { line: 19 column: 37 }` empty, no further results remain. * @property {firebaserules(v1).Ruleset[]} rulesets List of `Ruleset` instances. */ -module.exports = Firebaserules; +export = Firebaserules; diff --git a/apis/fitness/v1.js b/apis/fitness/v1.ts similarity index 99% rename from apis/fitness/v1.js rename to apis/fitness/v1.ts index 75504c2aa7..0825d7cbd5 100644 --- a/apis/fitness/v1.js +++ b/apis/fitness/v1.ts @@ -743,4 +743,4 @@ Finally, the developer project number is obfuscated when read by any REST or And * @property {string} key * @property {fitness(v1).MapValue} value */ -module.exports = Fitness; +export = Fitness; diff --git a/apis/fusiontables/v1.js b/apis/fusiontables/v1.ts similarity index 99% rename from apis/fusiontables/v1.js rename to apis/fusiontables/v1.ts index 18973b402f..a0943a3f31 100644 --- a/apis/fusiontables/v1.js +++ b/apis/fusiontables/v1.ts @@ -1440,4 +1440,4 @@ function Fusiontables(options) { // eslint-disable-line * @property {string} nextPageToken Token used to access the next page of this result. No token is displayed if there are no more pages left. * @property {integer} totalItems Total number of templates for the table. */ -module.exports = Fusiontables; +export = Fusiontables; diff --git a/apis/fusiontables/v2.js b/apis/fusiontables/v2.ts similarity index 99% rename from apis/fusiontables/v2.js rename to apis/fusiontables/v2.ts index a61fb5a0c9..a28787b711 100644 --- a/apis/fusiontables/v2.js +++ b/apis/fusiontables/v2.ts @@ -1495,4 +1495,4 @@ See W3C Graph-based Data Model. * @property {string} nextPageToken Token used to access the next page of this result. No token is displayed if there are no more pages left. * @property {integer} totalItems Total number of templates for the table. */ -module.exports = Fusiontables; +export = Fusiontables; diff --git a/apis/games/v1.js b/apis/games/v1.ts similarity index 99% rename from apis/games/v1.js rename to apis/games/v1.ts index 6d7587cb4e..426c4b9ed7 100644 --- a/apis/games/v1.js +++ b/apis/games/v1.ts @@ -3222,4 +3222,4 @@ Possible values are: * @property {string} pendingParticipantId The ID of the participant who should take their turn next. May be set to the current player's participant ID to update match state without changing the turn. If not set, the match will wait for other player(s) to join via automatching; this is only valid if automatch criteria is set on the match with remaining slots for automatched players. * @property {games(v1).ParticipantResult[]} results The match results for the participants in the match. */ -module.exports = Games; +export = Games; diff --git a/apis/gamesConfiguration/v1configuration.js b/apis/gamesConfiguration/v1configuration.ts similarity index 99% rename from apis/gamesConfiguration/v1configuration.js rename to apis/gamesConfiguration/v1configuration.ts index 7b170df525..5bd65deba2 100644 --- a/apis/gamesConfiguration/v1configuration.js +++ b/apis/gamesConfiguration/v1configuration.ts @@ -644,4 +644,4 @@ Possible values are: * @property {string} kind Uniquely identifies the type of this resource. Value is always the fixed string gamesConfiguration#localizedStringBundle. * @property {gamesConfiguration(v1configuration).LocalizedString[]} translations The locale strings. */ -module.exports = Gamesconfiguration; +export = Gamesconfiguration; diff --git a/apis/gamesManagement/v1management.js b/apis/gamesManagement/v1management.ts similarity index 99% rename from apis/gamesManagement/v1management.js rename to apis/gamesManagement/v1management.ts index ab420cd848..a1060d94b9 100644 --- a/apis/gamesManagement/v1management.js +++ b/apis/gamesManagement/v1management.ts @@ -1141,4 +1141,4 @@ Possible values are: * @property {string} kind Uniquely identifies the type of this resource. Value is always the fixed string gamesManagement#scoresResetMultipleForAllRequest. * @property {string[]} leaderboard_ids The IDs of leaderboards to reset. */ -module.exports = Gamesmanagement; +export = Gamesmanagement; diff --git a/apis/genomics/v1.js b/apis/genomics/v1.ts similarity index 99% rename from apis/genomics/v1.js rename to apis/genomics/v1.ts index ff302baae2..1cf9d73306 100644 --- a/apis/genomics/v1.js +++ b/apis/genomics/v1.ts @@ -6078,4 +6078,4 @@ This field is repeated for compatibility with the API](https://github.com/ga4gh/schemas/blob/v0.5.1/src/main/resources/avro/variants.avdl#L76). * @property {string} id The server-generated call set ID, unique across all call sets. */ -module.exports = Genomics; +export = Genomics; diff --git a/apis/genomics/v1alpha2.js b/apis/genomics/v1alpha2.ts similarity index 99% rename from apis/genomics/v1alpha2.js rename to apis/genomics/v1alpha2.ts index 19b4c959a7..3b63df51df 100644 --- a/apis/genomics/v1alpha2.js +++ b/apis/genomics/v1alpha2.ts @@ -1268,4 +1268,4 @@ used, and the user must ensure that logs are not overwritten. Stdout and stderr logs from the run are also generated and output as `-stdout.log` and `-stderr.log`. */ -module.exports = Genomics; +export = Genomics; diff --git a/apis/gmail/v1.js b/apis/gmail/v1.ts similarity index 99% rename from apis/gmail/v1.js rename to apis/gmail/v1.ts index b1f2ee46c7..8cd517e130 100644 --- a/apis/gmail/v1.js +++ b/apis/gmail/v1.ts @@ -2697,4 +2697,4 @@ Note that the "my-project-identifier" portion must exactly match your * @property {string} expiration When Gmail will stop sending notifications for mailbox updates (epoch millis). Call watch again before this time to renew the watch. * @property {string} historyId The ID of the mailbox's current history record. */ -module.exports = Gmail; +export = Gmail; diff --git a/apis/groupsmigration/v1.js b/apis/groupsmigration/v1.ts similarity index 98% rename from apis/groupsmigration/v1.js rename to apis/groupsmigration/v1.ts index 1ff74dc64e..09f6afe49d 100644 --- a/apis/groupsmigration/v1.js +++ b/apis/groupsmigration/v1.ts @@ -91,4 +91,4 @@ function Groupsmigration(options) { // eslint-disable-line * @property {string} kind The kind of insert resource this is. * @property {string} responseCode The status of the insert request. */ -module.exports = Groupsmigration; +export = Groupsmigration; diff --git a/apis/groupssettings/v1.js b/apis/groupssettings/v1.ts similarity index 99% rename from apis/groupssettings/v1.js rename to apis/groupssettings/v1.ts index 37c6d1cf69..adf5992952 100644 --- a/apis/groupssettings/v1.js +++ b/apis/groupssettings/v1.ts @@ -188,4 +188,4 @@ function Groupssettings(options) { // eslint-disable-line * @property {string} whoCanViewGroup Permissions to view group. Possible values are: ANYONE_CAN_VIEW ALL_IN_DOMAIN_CAN_VIEW ALL_MEMBERS_CAN_VIEW ALL_MANAGERS_CAN_VIEW * @property {string} whoCanViewMembership Permissions to view membership. Possible values are: ALL_IN_DOMAIN_CAN_VIEW ALL_MEMBERS_CAN_VIEW ALL_MANAGERS_CAN_VIEW */ -module.exports = Groupssettings; +export = Groupssettings; diff --git a/apis/iam/v1.js b/apis/iam/v1.ts similarity index 99% rename from apis/iam/v1.js rename to apis/iam/v1.ts index fde96b0d33..68ab8680cc 100644 --- a/apis/iam/v1.js +++ b/apis/iam/v1.ts @@ -831,4 +831,4 @@ The name follows the Google Cloud Platform resource format. For example, a Cloud Platform project with id `my-project` will be named `//cloudresourcemanager.googleapis.com/projects/my-project`. */ -module.exports = Iam; +export = Iam; diff --git a/apis/identitytoolkit/v3.js b/apis/identitytoolkit/v3.ts similarity index 99% rename from apis/identitytoolkit/v3.js rename to apis/identitytoolkit/v3.ts index ed4536e27d..1979bd1cbf 100644 --- a/apis/identitytoolkit/v3.js +++ b/apis/identitytoolkit/v3.ts @@ -1075,4 +1075,4 @@ function Identitytoolkit(options) { // eslint-disable-line * @property {string} refreshToken If idToken is STS id token, then this field will be refresh token. * @property {boolean} registered Whether the email is registered. */ -module.exports = Identitytoolkit; +export = Identitytoolkit; diff --git a/apis/kgsearch/v1.js b/apis/kgsearch/v1.ts similarity index 99% rename from apis/kgsearch/v1.js rename to apis/kgsearch/v1.ts index ecc95dc402..4933051cc7 100644 --- a/apis/kgsearch/v1.js +++ b/apis/kgsearch/v1.ts @@ -95,4 +95,4 @@ http://www.w3.org/TR/json-ld/#context-definitions. * @property {any[]} itemListElement The item list of search results. * @property {any} @type The schema type of top-level JSON-LD object, e.g. ItemList. */ -module.exports = Kgsearch; +export = Kgsearch; diff --git a/apis/language/v1.js b/apis/language/v1.ts similarity index 99% rename from apis/language/v1.js rename to apis/language/v1.ts index 7732672767..afbe6346bc 100644 --- a/apis/language/v1.js +++ b/apis/language/v1.ts @@ -392,4 +392,4 @@ negative). * @property {string} encodingType The encoding type used by the API to calculate offsets. * @property {language(v1).Document} document Input document. */ -module.exports = Language; +export = Language; diff --git a/apis/language/v1beta1.js b/apis/language/v1beta1.ts similarity index 99% rename from apis/language/v1beta1.js rename to apis/language/v1beta1.ts index ed0d38cac2..973f6b1eac 100644 --- a/apis/language/v1beta1.js +++ b/apis/language/v1beta1.ts @@ -395,4 +395,4 @@ google.rpc.Status.details field, or localized by the client. * @property {object[]} details A list of messages that carry the error details. There will be a common set of message types for APIs to use. */ -module.exports = Language; +export = Language; diff --git a/apis/language/v1beta2.js b/apis/language/v1beta2.ts similarity index 99% rename from apis/language/v1beta2.js rename to apis/language/v1beta2.ts index 412872b529..9b411ca79f 100644 --- a/apis/language/v1beta2.js +++ b/apis/language/v1beta2.ts @@ -452,4 +452,4 @@ document according to the EncodingType specified in the API request. * @property {language(v1beta2).DependencyEdge} dependencyEdge Dependency tree parse for this token. * @property {string} lemma [Lemma](https://en.wikipedia.org/wiki/Lemma_%28morphology%29) of the token. */ -module.exports = Language; +export = Language; diff --git a/apis/licensing/v1.js b/apis/licensing/v1.ts similarity index 99% rename from apis/licensing/v1.js rename to apis/licensing/v1.ts index e53f1a165a..3f5eff6e8a 100644 --- a/apis/licensing/v1.js +++ b/apis/licensing/v1.ts @@ -337,4 +337,4 @@ function Licensing(options) { // eslint-disable-line * @property {string} kind Identifies the resource as a collection of LicenseAssignments. * @property {string} nextPageToken The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results. */ -module.exports = Licensing; +export = Licensing; diff --git a/apis/logging/v2.js b/apis/logging/v2.ts similarity index 99% rename from apis/logging/v2.js rename to apis/logging/v2.ts index 9465987103..afd07c5a29 100644 --- a/apis/logging/v2.js +++ b/apis/logging/v2.ts @@ -1639,4 +1639,4 @@ Projects listed in the project_ids field are added to this list. * @property {string} revisionId The canonical and persistent identifier of the deployed revision. Example (git): "0035781c50ec7aa23385dc841529ce8a4b70db1b" * @property {string} repository Optional. A URI string identifying the repository. Example: "https://github.com/GoogleCloudPlatform/kubernetes.git" */ -module.exports = Logging; +export = Logging; diff --git a/apis/logging/v2beta1.js b/apis/logging/v2beta1.ts similarity index 99% rename from apis/logging/v2beta1.js rename to apis/logging/v2beta1.ts index 8f23eebd29..cfcb8877a8 100644 --- a/apis/logging/v2beta1.js +++ b/apis/logging/v2beta1.ts @@ -2116,4 +2116,4 @@ Projects listed in the project_ids field are added to this list. * @property {string} pageToken Optional. If present, then retrieve the next batch of results from the preceding call to this method. page_token must be the value of next_page_token from the previous response. The values of other method parameters should be identical to those in the previous call. * @property {integer} pageSize Optional. The maximum number of results to return from this request. Non-positive values are ignored. The presence of next_page_token in the response indicates that more results might be available. */ -module.exports = Logging; +export = Logging; diff --git a/apis/manufacturers/v1.js b/apis/manufacturers/v1.ts similarity index 99% rename from apis/manufacturers/v1.js rename to apis/manufacturers/v1.ts index abbef7c8fb..538977db14 100644 --- a/apis/manufacturers/v1.js +++ b/apis/manufacturers/v1.ts @@ -302,4 +302,4 @@ US). * @property {manufacturers(v1).Product[]} products List of the products. * @property {string} nextPageToken The token for the retrieval of the next page of product statuses. */ -module.exports = Manufacturers; +export = Manufacturers; diff --git a/apis/mirror/v1.js b/apis/mirror/v1.ts similarity index 99% rename from apis/mirror/v1.js rename to apis/mirror/v1.ts index d5a9d5ee8b..d86265c00f 100644 --- a/apis/mirror/v1.js +++ b/apis/mirror/v1.ts @@ -1211,4 +1211,4 @@ For actions of type CUSTOM, this is the ID of the custom menu item that was sele * @property {string} key * @property {string} value */ -module.exports = Mirror; +export = Mirror; diff --git a/apis/ml/v1.js b/apis/ml/v1.ts similarity index 99% rename from apis/ml/v1.js rename to apis/ml/v1.ts index 8f8589b1e7..32cd54e2f4 100644 --- a/apis/ml/v1.js +++ b/apis/ml/v1.ts @@ -1201,4 +1201,4 @@ and parameter servers. * @property {string} nextPageToken Optional. Pass this token as the `page_token` field of the request for a subsequent call. */ -module.exports = Ml; +export = Ml; diff --git a/apis/ml/v1beta1.js b/apis/ml/v1beta1.ts similarity index 99% rename from apis/ml/v1beta1.js rename to apis/ml/v1beta1.ts index 5e173a29bd..5a93996ce6 100644 --- a/apis/ml/v1beta1.js +++ b/apis/ml/v1beta1.ts @@ -1201,4 +1201,4 @@ By default, "training/hptuning/metric" will be used. subsequent call. * @property {ml(v1beta1).GoogleCloudMlV1beta1__Model[]} models The list of models. */ -module.exports = Ml; +export = Ml; diff --git a/apis/monitoring/v3.js b/apis/monitoring/v3.ts similarity index 99% rename from apis/monitoring/v3.js rename to apis/monitoring/v3.ts index eeadbb3231..4b70f1da6e 100644 --- a/apis/monitoring/v3.js +++ b/apis/monitoring/v3.ts @@ -1573,4 +1573,4 @@ Knuth, "The Art of Computer Programming", Vol. 2, page 323, 3rd editio * @property {object} value The option's value packed in an Any message. If the value is a primitive, the corresponding wrapper type defined in google/protobuf/wrappers.proto should be used. If the value is an enum, it should be stored as an int32 value using the google.protobuf.Int32Value type. * @property {string} name The option's name. For protobuf built-in options (options defined in descriptor.proto), this is the short name. For example, "map_entry". For custom options, it should be the fully-qualified name. For example, "google.api.http". */ -module.exports = Monitoring; +export = Monitoring; diff --git a/apis/oauth2/v1.js b/apis/oauth2/v1.ts similarity index 99% rename from apis/oauth2/v1.js rename to apis/oauth2/v1.ts index 6fa8c67a1a..ed57b72431 100644 --- a/apis/oauth2/v1.js +++ b/apis/oauth2/v1.ts @@ -377,4 +377,4 @@ function Oauth2(options) { // eslint-disable-line * @memberOf! oauth2(v1) * @type object */ -module.exports = Oauth2; +export = Oauth2; diff --git a/apis/oauth2/v2.js b/apis/oauth2/v2.ts similarity index 99% rename from apis/oauth2/v2.js rename to apis/oauth2/v2.ts index ee035a9ea0..750cef6cd3 100644 --- a/apis/oauth2/v2.js +++ b/apis/oauth2/v2.ts @@ -225,4 +225,4 @@ function Oauth2(options) { // eslint-disable-line * @property {string} picture URL of the user's picture image. * @property {boolean} verified_email Boolean flag which is true if the email address is verified. Always verified because we only return the user's primary email address. */ -module.exports = Oauth2; +export = Oauth2; diff --git a/apis/pagespeedonline/v1.js b/apis/pagespeedonline/v1.ts similarity index 99% rename from apis/pagespeedonline/v1.js rename to apis/pagespeedonline/v1.ts index d90e70c87c..1342470f0e 100644 --- a/apis/pagespeedonline/v1.js +++ b/apis/pagespeedonline/v1.ts @@ -100,4 +100,4 @@ function Pagespeedonline(options) { // eslint-disable-line * @property {string} title Title of the page, as displayed in the browser's title bar. * @property {object} version The version of PageSpeed used to generate these results. */ -module.exports = Pagespeedonline; +export = Pagespeedonline; diff --git a/apis/pagespeedonline/v2.js b/apis/pagespeedonline/v2.ts similarity index 99% rename from apis/pagespeedonline/v2.js rename to apis/pagespeedonline/v2.ts index 3122486ec8..fbe2ca2bc6 100644 --- a/apis/pagespeedonline/v2.js +++ b/apis/pagespeedonline/v2.ts @@ -118,4 +118,4 @@ function Pagespeedonline(options) { // eslint-disable-line * @property {string} title Title of the page, as displayed in the browser's title bar. * @property {object} version The version of PageSpeed used to generate these results. */ -module.exports = Pagespeedonline; +export = Pagespeedonline; diff --git a/apis/partners/v2.js b/apis/partners/v2.ts similarity index 99% rename from apis/partners/v2.js rename to apis/partners/v2.ts index 4a2cca87cb..13f755c5c0 100644 --- a/apis/partners/v2.js +++ b/apis/partners/v2.ts @@ -1408,4 +1408,4 @@ request. These are only honored by whitelisted products. and either `email` or `phone_number` must be provided. * @property {partners(v2).RecaptchaChallenge} recaptchaChallenge <a href="https://www.google.com/recaptcha/">reCaptcha</a> challenge info. */ -module.exports = Partners; +export = Partners; diff --git a/apis/people/v1.js b/apis/people/v1.ts similarity index 99% rename from apis/people/v1.js rename to apis/people/v1.ts index 7955c6fb9a..c3d4d65d38 100644 --- a/apis/people/v1.js +++ b/apis/people/v1.ts @@ -665,4 +665,4 @@ Possible values include, but are not limited to, the following: false if the residence is a past residence. * @property {string} value The address of the residence. */ -module.exports = People; +export = People; diff --git a/apis/playmoviespartner/v1.js b/apis/playmoviespartner/v1.ts similarity index 99% rename from apis/playmoviespartner/v1.js rename to apis/playmoviespartner/v1.ts index 2f2380c62f..c4eb9cae09 100644 --- a/apis/playmoviespartner/v1.js +++ b/apis/playmoviespartner/v1.ts @@ -533,4 +533,4 @@ Example: "1". Example: "10.5240/1489-49A2-3956-4B2D-FE16-6". * @property {boolean} hasEstOffer Whether the Edit has a EST offer. */ -module.exports = Playmoviespartner; +export = Playmoviespartner; diff --git a/apis/plus/v1.js b/apis/plus/v1.ts similarity index 99% rename from apis/plus/v1.js rename to apis/plus/v1.ts index 8804113ff2..46ee058440 100644 --- a/apis/plus/v1.js +++ b/apis/plus/v1.ts @@ -552,4 +552,4 @@ function Plus(options) { // eslint-disable-line - "domain" - Access to members of the person's Google Apps domain. - "public" - Access to anyone on the web. */ -module.exports = Plus; +export = Plus; diff --git a/apis/plusDomains/v1.js b/apis/plusDomains/v1.ts similarity index 99% rename from apis/plusDomains/v1.js rename to apis/plusDomains/v1.ts index dc3a5fc61f..5edd64b031 100644 --- a/apis/plusDomains/v1.js +++ b/apis/plusDomains/v1.ts @@ -1048,4 +1048,4 @@ function Plusdomains(options) { // eslint-disable-line * @property {string} url URL of the video stream. * @property {integer} width The width, in pixels, of the video resource. */ -module.exports = Plusdomains; +export = Plusdomains; diff --git a/apis/prediction/v1.2.js b/apis/prediction/v1.2.ts similarity index 99% rename from apis/prediction/v1.2.js rename to apis/prediction/v1.2.ts index 418b6e4cf1..fcb85bd5b1 100644 --- a/apis/prediction/v1.2.js +++ b/apis/prediction/v1.2.ts @@ -297,4 +297,4 @@ function Prediction(options) { // eslint-disable-line * @property {string} classLabel The true class label of this instance * @property {any[]} csvInstance The input features for this instance */ -module.exports = Prediction; +export = Prediction; diff --git a/apis/prediction/v1.3.js b/apis/prediction/v1.3.ts similarity index 99% rename from apis/prediction/v1.3.js rename to apis/prediction/v1.3.ts index 0f9e3bc3ce..ccc320cc2a 100644 --- a/apis/prediction/v1.3.js +++ b/apis/prediction/v1.3.ts @@ -297,4 +297,4 @@ function Prediction(options) { // eslint-disable-line * @property {string} classLabel The true class label of this instance * @property {any[]} csvInstance The input features for this instance */ -module.exports = Prediction; +export = Prediction; diff --git a/apis/prediction/v1.4.js b/apis/prediction/v1.4.ts similarity index 99% rename from apis/prediction/v1.4.js rename to apis/prediction/v1.4.ts index cde956cd73..a1718cb6ed 100644 --- a/apis/prediction/v1.4.js +++ b/apis/prediction/v1.4.ts @@ -302,4 +302,4 @@ function Prediction(options) { // eslint-disable-line * @property {string} label The class label of this instance * @property {string} output The generic output value - could be regression value or class label */ -module.exports = Prediction; +export = Prediction; diff --git a/apis/prediction/v1.5.js b/apis/prediction/v1.5.ts similarity index 99% rename from apis/prediction/v1.5.js rename to apis/prediction/v1.5.ts index b0591a524e..7bc18c5718 100644 --- a/apis/prediction/v1.5.js +++ b/apis/prediction/v1.5.ts @@ -396,4 +396,4 @@ function Prediction(options) { // eslint-disable-line * @property {string} label The class label of this instance * @property {string} output The generic output value - could be regression value or class label */ -module.exports = Prediction; +export = Prediction; diff --git a/apis/prediction/v1.6.js b/apis/prediction/v1.6.ts similarity index 99% rename from apis/prediction/v1.6.js rename to apis/prediction/v1.6.ts index 9b43ebb469..c3d95e30d1 100644 --- a/apis/prediction/v1.6.js +++ b/apis/prediction/v1.6.ts @@ -867,4 +867,4 @@ function Prediction(options) { // eslint-disable-line * @property {any[]} csvInstance The input features for this instance. * @property {string} output The generic output value - could be regression or class label. */ -module.exports = Prediction; +export = Prediction; diff --git a/apis/proximitybeacon/v1beta1.js b/apis/proximitybeacon/v1beta1.ts similarity index 99% rename from apis/proximitybeacon/v1beta1.js rename to apis/proximitybeacon/v1beta1.ts index 11a8e3dede..404f18eb50 100644 --- a/apis/proximitybeacon/v1beta1.js +++ b/apis/proximitybeacon/v1beta1.ts @@ -945,4 +945,4 @@ This value is only an estimate, not an exact date. be the beacon's current EID, or the beacon's "stable" Eddystone-UID. * @property {string[]} alerts An unordered list of Alerts that the beacon has. */ -module.exports = Proximitybeacon; +export = Proximitybeacon; diff --git a/apis/pubsub/v1.js b/apis/pubsub/v1.ts similarity index 99% rename from apis/pubsub/v1.js rename to apis/pubsub/v1.ts index 0d8aa4fea6..a76602729f 100644 --- a/apis/pubsub/v1.js +++ b/apis/pubsub/v1.ts @@ -2442,4 +2442,4 @@ 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. */ -module.exports = Pubsub; +export = Pubsub; diff --git a/apis/pubsub/v1beta1a.js b/apis/pubsub/v1beta1a.ts similarity index 99% rename from apis/pubsub/v1beta1a.js rename to apis/pubsub/v1beta1a.ts index 85d8928ba3..fc338b7a52 100644 --- a/apis/pubsub/v1beta1a.js +++ b/apis/pubsub/v1beta1a.ts @@ -787,4 +787,4 @@ where "hostname" and "alphadigit" are defined as in RFC 1738 Example key: spanner.google.com/universe */ -module.exports = Pubsub; +export = Pubsub; diff --git a/apis/pubsub/v1beta2.js b/apis/pubsub/v1beta2.ts similarity index 99% rename from apis/pubsub/v1beta2.js rename to apis/pubsub/v1beta2.ts index c73621b61a..9b11336d1c 100644 --- a/apis/pubsub/v1beta2.js +++ b/apis/pubsub/v1beta2.ts @@ -1040,4 +1040,4 @@ the request; this value should be passed in a new * @type object * @property {pubsub(v1beta2).PubsubMessage[]} messages The messages to publish. */ -module.exports = Pubsub; +export = Pubsub; diff --git a/apis/qpxExpress/v1.js b/apis/qpxExpress/v1.ts similarity index 99% rename from apis/qpxExpress/v1.js rename to apis/qpxExpress/v1.ts index 7273e9cb60..0b613249a9 100644 --- a/apis/qpxExpress/v1.js +++ b/apis/qpxExpress/v1.ts @@ -336,4 +336,4 @@ function Qpxexpress(options) { // eslint-disable-line * @property {string} kind Identifies this as a QPX Express API search response resource. Value: the fixed string qpxExpress#tripsSearch. * @property {qpxExpress(v1).TripOptionsResponse} trips All possible solutions to the QPX Express search request. */ -module.exports = Qpxexpress; +export = Qpxexpress; diff --git a/apis/replicapool/v1beta1.js b/apis/replicapool/v1beta1.ts similarity index 99% rename from apis/replicapool/v1beta1.js rename to apis/replicapool/v1beta1.ts index a8422b7682..7112eadf71 100644 --- a/apis/replicapool/v1beta1.js +++ b/apis/replicapool/v1beta1.ts @@ -633,4 +633,4 @@ If this is not specified by the user, a random base instance name is generated b * @property {replicapool(v1beta1).ServiceAccount[]} serviceAccounts A list of Service Accounts to enable for this instance. * @property {replicapool(v1beta1).Tag} tags A list of tags to apply to the Google Compute Engine instance to identify resources. */ -module.exports = Replicapool; +export = Replicapool; diff --git a/apis/replicapool/v1beta2.js b/apis/replicapool/v1beta2.ts similarity index 99% rename from apis/replicapool/v1beta2.js rename to apis/replicapool/v1beta2.ts index 903584c4cd..16d444d7ca 100644 --- a/apis/replicapool/v1beta2.js +++ b/apis/replicapool/v1beta2.ts @@ -612,4 +612,4 @@ Example: 'instance-foo', 'instance-bar' * @property {string} actionType The action to perform when an instance becomes unhealthy. Possible values are RECREATE or REBOOT. RECREATE replaces an unhealthy instance with a new instance that is based on the instance template for this managed instance group. REBOOT performs a soft reboot on an instance. If the instance cannot reboot, the instance performs a hard restart. * @property {string} healthCheck The URL for the HealthCheck that signals autohealing. */ -module.exports = Replicapool; +export = Replicapool; diff --git a/apis/replicapoolupdater/v1beta1.js b/apis/replicapoolupdater/v1beta1.ts similarity index 99% rename from apis/replicapoolupdater/v1beta1.js rename to apis/replicapoolupdater/v1beta1.ts index c47e65e9f1..fce7c6100a 100644 --- a/apis/replicapoolupdater/v1beta1.js +++ b/apis/replicapoolupdater/v1beta1.ts @@ -523,4 +523,4 @@ function Replicapoolupdater(options) { // eslint-disable-line * @property {string} nextPageToken A token used to continue a truncated list request. * @property {string} selfLink [Output Only] The fully qualified URL for the resource. */ -module.exports = Replicapoolupdater; +export = Replicapoolupdater; diff --git a/apis/reseller/v1.js b/apis/reseller/v1.ts similarity index 99% rename from apis/reseller/v1.js rename to apis/reseller/v1.ts index 910ceaa7fe..cf4a01abf7 100644 --- a/apis/reseller/v1.js +++ b/apis/reseller/v1.ts @@ -785,4 +785,4 @@ Possible options include: * @property {string} nextPageToken The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results. * @property {reseller(v1).Subscription[]} subscriptions The subscriptions in this page of results. */ -module.exports = Reseller; +export = Reseller; diff --git a/apis/resourceviews/v1beta1.js b/apis/resourceviews/v1beta1.ts similarity index 99% rename from apis/resourceviews/v1beta1.js rename to apis/resourceviews/v1beta1.ts index 57074b7c02..d5ccb88d80 100644 --- a/apis/resourceviews/v1beta1.js +++ b/apis/resourceviews/v1beta1.ts @@ -663,4 +663,4 @@ function Resourceviews(options) { // eslint-disable-line * @type object * @property {string[]} resources The list of resources to be removed. */ -module.exports = Resourceviews; +export = Resourceviews; diff --git a/apis/resourceviews/v1beta2.js b/apis/resourceviews/v1beta2.ts similarity index 99% rename from apis/resourceviews/v1beta2.js rename to apis/resourceviews/v1beta2.ts index 033e8c222d..d31e985e1d 100644 --- a/apis/resourceviews/v1beta2.js +++ b/apis/resourceviews/v1beta2.ts @@ -587,4 +587,4 @@ function Resourceviews(options) { // eslint-disable-line * @property {string} fingerprint Fingerprint of the service information; a hash of the contents. This field is used for optimistic locking when updating the service entries. * @property {string} resourceName The name of the resource if user wants to update the service information of the resource. */ -module.exports = Resourceviews; +export = Resourceviews; diff --git a/apis/runtimeconfig/v1.js b/apis/runtimeconfig/v1.ts similarity index 99% rename from apis/runtimeconfig/v1.js rename to apis/runtimeconfig/v1.ts index b394569b88..dcc94adde4 100644 --- a/apis/runtimeconfig/v1.js +++ b/apis/runtimeconfig/v1.ts @@ -207,4 +207,4 @@ 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. */ -module.exports = Runtimeconfig; +export = Runtimeconfig; diff --git a/apis/runtimeconfig/v1beta1.js b/apis/runtimeconfig/v1beta1.ts similarity index 99% rename from apis/runtimeconfig/v1beta1.js rename to apis/runtimeconfig/v1beta1.ts index c511e17b64..83e96b8531 100644 --- a/apis/runtimeconfig/v1beta1.js +++ b/apis/runtimeconfig/v1beta1.ts @@ -1111,4 +1111,4 @@ common set of message types for APIs to use. user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. */ -module.exports = Runtimeconfig; +export = Runtimeconfig; diff --git a/apis/safebrowsing/v4.js b/apis/safebrowsing/v4.ts similarity index 99% rename from apis/safebrowsing/v4.js rename to apis/safebrowsing/v4.ts index ecdda919ea..a13e0ecd29 100644 --- a/apis/safebrowsing/v4.js +++ b/apis/safebrowsing/v4.ts @@ -491,4 +491,4 @@ client state that was received from the last successful list update). * @property {safebrowsing(v4).Constraints} constraints The constraints associated with this request. * @property {string} threatEntryType The types of entries present in the list. */ -module.exports = Safebrowsing; +export = Safebrowsing; diff --git a/apis/script/v1.js b/apis/script/v1.ts similarity index 99% rename from apis/script/v1.js rename to apis/script/v1.ts index 18ab625a08..cf944b28bc 100644 --- a/apis/script/v1.js +++ b/apis/script/v1.ts @@ -152,4 +152,4 @@ they can only return primitive types such as a `string`, `number`, `array`, * @property {script(v1).Status} error If a `run` call succeeds but the script function (or Apps Script itself) throws an exception, this field will contain a `Status` object. The `Status` object's `details` field will contain an array with a single `ExecutionError` object that provides information about the nature of the error. * @property {object} metadata This field is not used. */ -module.exports = Script; +export = Script; diff --git a/apis/searchconsole/v1.js b/apis/searchconsole/v1.ts similarity index 99% rename from apis/searchconsole/v1.js rename to apis/searchconsole/v1.ts index edead29a52..97cafe39f4 100644 --- a/apis/searchconsole/v1.js +++ b/apis/searchconsole/v1.ts @@ -132,4 +132,4 @@ will always be "image/png", but this might change in the future. * @property {searchconsole(v1).TestStatus} testStatus Final state of the test, can be either complete or an error. * @property {searchconsole(v1).ResourceIssue[]} resourceIssues Information about embedded resources issues. */ -module.exports = Searchconsole; +export = Searchconsole; diff --git a/apis/servicecontrol/v1.js b/apis/servicecontrol/v1.ts similarity index 99% rename from apis/servicecontrol/v1.js rename to apis/servicecontrol/v1.ts index a705dd03aa..33ebb8284e 100644 --- a/apis/servicecontrol/v1.js +++ b/apis/servicecontrol/v1.ts @@ -892,4 +892,4 @@ was granted. bigquery.googlapis.com/projects/PROJECTID/datasets/DATASETID */ -module.exports = Servicecontrol; +export = Servicecontrol; diff --git a/apis/servicemanagement/v1.js b/apis/servicemanagement/v1.ts similarity index 99% rename from apis/servicemanagement/v1.js rename to apis/servicemanagement/v1.ts index 3f7e1a9316..b3887c11f8 100644 --- a/apis/servicemanagement/v1.js +++ b/apis/servicemanagement/v1.ts @@ -2267,4 +2267,4 @@ There can be multiple producer destinations, each one must have a different monitored resource type. A log can be used in at most one producer destination. */ -module.exports = Servicemanagement; +export = Servicemanagement; diff --git a/apis/serviceuser/v1.js b/apis/serviceuser/v1.ts similarity index 99% rename from apis/serviceuser/v1.js rename to apis/serviceuser/v1.ts index bbc0395d48..b59153f0e1 100644 --- a/apis/serviceuser/v1.js +++ b/apis/serviceuser/v1.ts @@ -1276,4 +1276,4 @@ be defined in the Service.logs section. If the log name is not a domain scoped name, it will be automatically prefixed with the service name followed by "/". */ -module.exports = Serviceuser; +export = Serviceuser; diff --git a/apis/sheets/v4.js b/apis/sheets/v4.ts similarity index 99% rename from apis/sheets/v4.js rename to apis/sheets/v4.ts index 3ea6e4ac7f..99cbdf8055 100644 --- a/apis/sheets/v4.js +++ b/apis/sheets/v4.ts @@ -2647,4 +2647,4 @@ The root is the CellData; 'row.values.' should not be specified. A single `"*"` can be used as short-hand for listing every field. * @property {integer} sheetId The sheet ID to append the data to. */ -module.exports = Sheets; +export = Sheets; diff --git a/apis/siteVerification/v1.js b/apis/siteVerification/v1.ts similarity index 99% rename from apis/siteVerification/v1.js rename to apis/siteVerification/v1.ts index f6005079ce..8c8a535f88 100644 --- a/apis/siteVerification/v1.js +++ b/apis/siteVerification/v1.ts @@ -320,4 +320,4 @@ function Siteverification(options) { // eslint-disable-line * @property {string[]} owners The email addresses of all verified owners. * @property {object} site The address and type of a site that is verified or will be verified. */ -module.exports = Siteverification; +export = Siteverification; diff --git a/apis/slides/v1.js b/apis/slides/v1.ts similarity index 99% rename from apis/slides/v1.js rename to apis/slides/v1.ts index fcfdd66f56..0b55aa870b 100644 --- a/apis/slides/v1.js +++ b/apis/slides/v1.ts @@ -1745,4 +1745,4 @@ ignored. * @property {slides(v1).OutlineFill} outlineFill The fill of the outline. * @property {slides(v1).Dimension} weight The thickness of the outline. */ -module.exports = Slides; +export = Slides; diff --git a/apis/sourcerepo/v1.js b/apis/sourcerepo/v1.ts similarity index 99% rename from apis/sourcerepo/v1.js rename to apis/sourcerepo/v1.ts index e22be8f8e9..56b670fc6e 100644 --- a/apis/sourcerepo/v1.js +++ b/apis/sourcerepo/v1.ts @@ -496,4 +496,4 @@ manner: Multiple `bindings` must not be specified for the same `role`. `bindings` with no members will result in an error. */ -module.exports = Sourcerepo; +export = Sourcerepo; diff --git a/apis/spanner/v1.js b/apis/spanner/v1.ts similarity index 99% rename from apis/spanner/v1.js rename to apis/spanner/v1.ts index d859e3f844..1d4a43df26 100644 --- a/apis/spanner/v1.js +++ b/apis/spanner/v1.ts @@ -2313,4 +2313,4 @@ about them. * @memberOf! spanner(v1) * @type object */ -module.exports = Spanner; +export = Spanner; diff --git a/apis/spectrum/v1explorer.js b/apis/spectrum/v1explorer.ts similarity index 99% rename from apis/spectrum/v1explorer.js rename to apis/spectrum/v1explorer.ts index 52b59a3d71..47160ff20c 100644 --- a/apis/spectrum/v1explorer.js +++ b/apis/spectrum/v1explorer.ts @@ -613,4 +613,4 @@ Required field. * @type object * @property {string} text The text string associated with this item. For example, for an org field: ACME, inc. For an email field: smith@example.com. */ -module.exports = Spectrum; +export = Spectrum; diff --git a/apis/speech/v1beta1.js b/apis/speech/v1beta1.ts similarity index 99% rename from apis/speech/v1beta1.js rename to apis/speech/v1beta1.ts index bc367e5f96..dbf359f1e1 100644 --- a/apis/speech/v1beta1.js +++ b/apis/speech/v1beta1.ts @@ -404,4 +404,4 @@ sequential portions of audio. * @memberOf! speech(v1beta1) * @type object */ -module.exports = Speech; +export = Speech; diff --git a/apis/sqladmin/v1beta3.js b/apis/sqladmin/v1beta3.ts similarity index 99% rename from apis/sqladmin/v1beta3.js rename to apis/sqladmin/v1beta3.ts index 6f35cd59db..415f537b95 100644 --- a/apis/sqladmin/v1beta3.js +++ b/apis/sqladmin/v1beta3.ts @@ -1324,4 +1324,4 @@ ON_DEMAND: The instance is activated upon receiving requests. * @property {sqladmin(v1beta3).Tier[]} items List of tiers. * @property {string} kind This is always sql#tiersList. */ -module.exports = Sqladmin; +export = Sqladmin; diff --git a/apis/sqladmin/v1beta4.js b/apis/sqladmin/v1beta4.ts similarity index 99% rename from apis/sqladmin/v1beta4.js rename to apis/sqladmin/v1beta4.ts index 29298d7dda..f3850aaf05 100644 --- a/apis/sqladmin/v1beta4.js +++ b/apis/sqladmin/v1beta4.ts @@ -2011,4 +2011,4 @@ ON_DEMAND: The instance responds to incoming requests, and turns itself off when * @property {string} kind This is always sql#usersList. * @property {string} nextPageToken An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation. */ -module.exports = Sqladmin; +export = Sqladmin; diff --git a/apis/storage/v1.js b/apis/storage/v1.ts similarity index 99% rename from apis/storage/v1.js rename to apis/storage/v1.ts index ed0123b6f0..9cf75cdb42 100644 --- a/apis/storage/v1.js +++ b/apis/storage/v1.ts @@ -4110,4 +4110,4 @@ function Storage(options) { // eslint-disable-line - storage.objects.setIamPolicy — Update object IAM policy. - storage.objects.update — Update object metadata. */ -module.exports = Storage; +export = Storage; diff --git a/apis/storage/v1beta1.js b/apis/storage/v1beta1.ts similarity index 99% rename from apis/storage/v1beta1.js rename to apis/storage/v1beta1.ts index 3c8a2aa1cc..ef7dc2e683 100644 --- a/apis/storage/v1beta1.js +++ b/apis/storage/v1beta1.ts @@ -1060,4 +1060,4 @@ function Storage(options) { // eslint-disable-line * @property {string} nextPageToken The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results. * @property {string[]} prefixes The list of prefixes of objects matching-but-not-listed up to and including the requested delimiter. */ -module.exports = Storage; +export = Storage; diff --git a/apis/storage/v1beta2.js b/apis/storage/v1beta2.ts similarity index 99% rename from apis/storage/v1beta2.js rename to apis/storage/v1beta2.ts index a1a028f40d..ab47c8ca1c 100644 --- a/apis/storage/v1beta2.js +++ b/apis/storage/v1beta2.ts @@ -1536,4 +1536,4 @@ function Storage(options) { // eslint-disable-line * @property {string} nextPageToken The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results. * @property {string[]} prefixes The list of prefixes of objects matching-but-not-listed up to and including the requested delimiter. */ -module.exports = Storage; +export = Storage; diff --git a/apis/storagetransfer/v1.js b/apis/storagetransfer/v1.ts similarity index 99% rename from apis/storagetransfer/v1.js rename to apis/storagetransfer/v1.ts index 7ad6747cb8..50171fa086 100644 --- a/apis/storagetransfer/v1.js +++ b/apis/storagetransfer/v1.ts @@ -1355,4 +1355,4 @@ common set of message types for APIs to use. * @property {string} nextPageToken The standard List next-page token. * @property {storagetransfer(v1).Operation[]} operations A list of operations that matches the specified filter in the request. */ -module.exports = Storagetransfer; +export = Storagetransfer; diff --git a/apis/surveys/v2.js b/apis/surveys/v2.ts similarity index 99% rename from apis/surveys/v2.js rename to apis/surveys/v2.ts index 31582841d5..8bc08246ec 100644 --- a/apis/surveys/v2.js +++ b/apis/surveys/v2.ts @@ -618,4 +618,4 @@ function Surveys(options) { // eslint-disable-line * @property {string} nextPageToken * @property {string} previousPageToken */ -module.exports = Surveys; +export = Surveys; diff --git a/apis/tagmanager/v1.js b/apis/tagmanager/v1.ts similarity index 99% rename from apis/tagmanager/v1.js rename to apis/tagmanager/v1.ts index e34dd03039..474acca4f7 100644 --- a/apis/tagmanager/v1.js +++ b/apis/tagmanager/v1.ts @@ -2260,4 +2260,4 @@ function Tagmanager(options) { // eslint-disable-line * @property {string} type GTM Variable Type. * @property {string} variableId The Variable ID uniquely identifies the GTM Variable. */ -module.exports = Tagmanager; +export = Tagmanager; diff --git a/apis/tagmanager/v2.js b/apis/tagmanager/v2.ts similarity index 99% rename from apis/tagmanager/v2.js rename to apis/tagmanager/v2.ts index e1c9dc0248..8dae672461 100644 --- a/apis/tagmanager/v2.js +++ b/apis/tagmanager/v2.ts @@ -3218,4 +3218,4 @@ function Tagmanager(options) { // eslint-disable-line * @property {string} gaiaId Gaia id associated with a user, absent for the Google Tag Manager system. * @property {string} type User type distinguishes between a user and the Google Tag Manager system. */ -module.exports = Tagmanager; +export = Tagmanager; diff --git a/apis/taskqueue/v1beta1.js b/apis/taskqueue/v1beta1.ts similarity index 99% rename from apis/taskqueue/v1beta1.js rename to apis/taskqueue/v1beta1.ts index 7b17d210d3..ade7744f57 100644 --- a/apis/taskqueue/v1beta1.js +++ b/apis/taskqueue/v1beta1.ts @@ -269,4 +269,4 @@ function Taskqueue(options) { // eslint-disable-line * @property {taskqueue(v1beta1).Task[]} items The actual list of tasks currently active in the TaskQueue. * @property {string} kind The kind of object returned, a list of tasks. */ -module.exports = Taskqueue; +export = Taskqueue; diff --git a/apis/taskqueue/v1beta2.js b/apis/taskqueue/v1beta2.ts similarity index 99% rename from apis/taskqueue/v1beta2.js rename to apis/taskqueue/v1beta2.ts index ca4de6a791..e5827e4845 100644 --- a/apis/taskqueue/v1beta2.js +++ b/apis/taskqueue/v1beta2.ts @@ -388,4 +388,4 @@ function Taskqueue(options) { // eslint-disable-line * @property {taskqueue(v1beta2).Task[]} items The actual list of tasks currently active in the TaskQueue. * @property {string} kind The kind of object returned, a list of tasks. */ -module.exports = Taskqueue; +export = Taskqueue; diff --git a/apis/tasks/v1.js b/apis/tasks/v1.ts similarity index 99% rename from apis/tasks/v1.js rename to apis/tasks/v1.ts index 0700094aa7..c6ac4466a8 100644 --- a/apis/tasks/v1.js +++ b/apis/tasks/v1.ts @@ -613,4 +613,4 @@ function Tasks(options) { // eslint-disable-line * @property {string} kind Type of the resource. This is always "tasks#tasks". * @property {string} nextPageToken Token used to access the next page of this result. */ -module.exports = Tasks; +export = Tasks; diff --git a/apis/toolresults/v1beta3.js b/apis/toolresults/v1beta3.ts similarity index 99% rename from apis/toolresults/v1beta3.js rename to apis/toolresults/v1beta3.ts index fb0fe37c0d..a6997f361b 100644 --- a/apis/toolresults/v1beta3.js +++ b/apis/toolresults/v1beta3.ts @@ -1485,4 +1485,4 @@ The maximum allowed number of tool outputs per step is 1000. - In response: present if set by create/update request - In create/update request: optional */ -module.exports = Toolresults; +export = Toolresults; diff --git a/apis/toolresults/v1beta3firstparty.js b/apis/toolresults/v1beta3firstparty.ts similarity index 99% rename from apis/toolresults/v1beta3firstparty.js rename to apis/toolresults/v1beta3firstparty.ts index 3742e7faaf..64f848d1e8 100644 --- a/apis/toolresults/v1beta3firstparty.js +++ b/apis/toolresults/v1beta3firstparty.ts @@ -1485,4 +1485,4 @@ The maximum allowed number of tool outputs per step is 1000. - In response: present if set by create/update request - In create/update request: optional */ -module.exports = Toolresults; +export = Toolresults; diff --git a/apis/tracing/v2.js b/apis/tracing/v2.ts similarity index 99% rename from apis/tracing/v2.js rename to apis/tracing/v2.ts index af6aa6b60f..1de9803b1a 100644 --- a/apis/tracing/v2.js +++ b/apis/tracing/v2.ts @@ -398,4 +398,4 @@ The first occurance of a stack trace should contain both the Subsequent spans within the same request can refer to that stack trace by only setting `stackTraceHashId`. */ -module.exports = Tracing; +export = Tracing; diff --git a/apis/translate/v2.js b/apis/translate/v2.ts similarity index 99% rename from apis/translate/v2.js rename to apis/translate/v2.ts index 0ac7b71b5b..866c66de9a 100644 --- a/apis/translate/v2.js +++ b/apis/translate/v2.ts @@ -199,4 +199,4 @@ function Translate(options) { // eslint-disable-line * @property {string} detectedSourceLanguage Detected source language if source parameter is unspecified. * @property {string} translatedText The translation. */ -module.exports = Translate; +export = Translate; diff --git a/apis/urlshortener/v1.js b/apis/urlshortener/v1.ts similarity index 99% rename from apis/urlshortener/v1.js rename to apis/urlshortener/v1.ts index 56eb51f10a..86ce02b045 100644 --- a/apis/urlshortener/v1.js +++ b/apis/urlshortener/v1.ts @@ -201,4 +201,4 @@ function Urlshortener(options) { // eslint-disable-line * @property {string} nextPageToken A token to provide to get the next page of results. * @property {integer} totalItems Total number of short URLs associated with this user (may be approximate). */ -module.exports = Urlshortener; +export = Urlshortener; diff --git a/apis/vision/v1.js b/apis/vision/v1.ts similarity index 99% rename from apis/vision/v1.js rename to apis/vision/v1.ts index ea9ff313c7..cb8964084b 100644 --- a/apis/vision/v1.js +++ b/apis/vision/v1.ts @@ -607,4 +607,4 @@ error if one or more of the specified languages is not one of the * @property {vision(v1).TextProperty} property Additional information detected on the page. * @property {integer} height Page height in pixels. */ -module.exports = Vision; +export = Vision; diff --git a/apis/webfonts/v1.js b/apis/webfonts/v1.ts similarity index 99% rename from apis/webfonts/v1.js rename to apis/webfonts/v1.ts index 2614e50ad3..c48915e908 100644 --- a/apis/webfonts/v1.js +++ b/apis/webfonts/v1.ts @@ -100,4 +100,4 @@ function Webfonts(options) { // eslint-disable-line * @property {webfonts(v1).Webfont[]} items The list of fonts currently served by the Google Fonts API. * @property {string} kind This kind represents a list of webfont objects in the webfonts service. */ -module.exports = Webfonts; +export = Webfonts; diff --git a/apis/webmasters/v3.js b/apis/webmasters/v3.ts similarity index 99% rename from apis/webmasters/v3.js rename to apis/webmasters/v3.ts index 0e2cbade1e..c1f2e6a30e 100644 --- a/apis/webmasters/v3.js +++ b/apis/webmasters/v3.ts @@ -665,4 +665,4 @@ If you specify any value other than AUTO, the aggregation type in the result wil * @property {string} submitted The number of URLs in the sitemap (of the content type). * @property {string} type The specific type of content in this sitemap. For example: web. */ -module.exports = Webmasters; +export = Webmasters; diff --git a/apis/youtube/v3.js b/apis/youtube/v3.ts similarity index 99% rename from apis/youtube/v3.js rename to apis/youtube/v3.ts index 99eefbe34e..f25e9714fb 100644 --- a/apis/youtube/v3.js +++ b/apis/youtube/v3.ts @@ -4778,4 +4778,4 @@ Note that since the estimated number of parts could increase without a correspon * @property {string} featuredPlaylistId An ID that uniquely identifies a playlist that displays next to the video player. * @property {string} textColor The background color for the video watch page's branded area. */ -module.exports = Youtube; +export = Youtube; diff --git a/apis/youtubeAnalytics/v1.js b/apis/youtubeAnalytics/v1.ts similarity index 99% rename from apis/youtubeAnalytics/v1.js rename to apis/youtubeAnalytics/v1.ts index 0e23d70a01..8b15969d84 100644 --- a/apis/youtubeAnalytics/v1.js +++ b/apis/youtubeAnalytics/v1.ts @@ -397,4 +397,4 @@ function Youtubeanalytics(options) { // eslint-disable-line * @property {string} kind This value specifies the type of data included in the API response. For the query method, the kind property value will be youtubeAnalytics#resultTable. * @property {array[]} rows The list contains all rows of the result table. Each item in the list is an array that contains comma-delimited data corresponding to a single row of data. The order of the comma-delimited data fields will match the order of the columns listed in the columnHeaders field. If no data is available for the given query, the rows element will be omitted from the response. The response for a query with the day dimension will not contain rows for the most recent days. */ -module.exports = Youtubeanalytics; +export = Youtubeanalytics; diff --git a/apis/youtubeAnalytics/v1beta1.js b/apis/youtubeAnalytics/v1beta1.ts similarity index 99% rename from apis/youtubeAnalytics/v1beta1.js rename to apis/youtubeAnalytics/v1beta1.ts index a5b4e8872b..dee8979d96 100644 --- a/apis/youtubeAnalytics/v1beta1.js +++ b/apis/youtubeAnalytics/v1beta1.ts @@ -397,4 +397,4 @@ function Youtubeanalytics(options) { // eslint-disable-line * @property {string} kind This value specifies the type of data included in the API response. For the query method, the kind property value will be youtubeAnalytics#resultTable. * @property {array[]} rows The list contains all rows of the result table. Each item in the list is an array that contains comma-delimited data corresponding to a single row of data. The order of the comma-delimited data fields will match the order of the columns listed in the columnHeaders field. If no data is available for the given query, the rows element will be omitted from the response. The response for a query with the day dimension will not contain rows for the most recent days. */ -module.exports = Youtubeanalytics; +export = Youtubeanalytics; diff --git a/apis/youtubereporting/v1.js b/apis/youtubereporting/v1.ts similarity index 99% rename from apis/youtubereporting/v1.js rename to apis/youtubereporting/v1.ts index 3ded982c3d..fb3071921c 100644 --- a/apis/youtubereporting/v1.js +++ b/apis/youtubereporting/v1.ts @@ -435,4 +435,4 @@ field in the subsequent call to `ListReports` method to retrieve the next page of results. * @property {youtubereporting(v1).Report[]} reports The list of report types. */ -module.exports = Youtubereporting; +export = Youtubereporting; diff --git a/lib/apirequest.js b/lib/apirequest.ts similarity index 99% rename from lib/apirequest.js rename to lib/apirequest.ts index a7616ba09a..db32d98375 100644 --- a/lib/apirequest.js +++ b/lib/apirequest.ts @@ -192,4 +192,4 @@ function createAPIRequest (parameters, callback) { * Exports createAPIRequest * @type {Function} */ -module.exports = createAPIRequest; +export = createAPIRequest; diff --git a/lib/auth/authclient.js b/lib/auth/authclient.ts similarity index 100% rename from lib/auth/authclient.js rename to lib/auth/authclient.ts diff --git a/lib/auth/computeclient.js b/lib/auth/computeclient.ts similarity index 100% rename from lib/auth/computeclient.js rename to lib/auth/computeclient.ts diff --git a/lib/auth/jwtclient.js b/lib/auth/jwtclient.ts similarity index 100% rename from lib/auth/jwtclient.js rename to lib/auth/jwtclient.ts diff --git a/lib/auth/loginticket.js b/lib/auth/loginticket.ts similarity index 100% rename from lib/auth/loginticket.js rename to lib/auth/loginticket.ts diff --git a/lib/auth/oauth2client.js b/lib/auth/oauth2client.ts similarity index 100% rename from lib/auth/oauth2client.js rename to lib/auth/oauth2client.ts diff --git a/lib/discovery.js b/lib/discovery.ts similarity index 97% rename from lib/discovery.js rename to lib/discovery.ts index ac1cd8eded..9f9daf0d7e 100644 --- a/lib/discovery.js +++ b/lib/discovery.ts @@ -15,7 +15,6 @@ var generatorUtils = require('./generator_utils'); var DefaultTransporter = generatorUtils.DefaultTransporter; -var buildurl = generatorUtils.buildurl; var handleError = generatorUtils.handleError; var async = require('async'); var fs = require('fs'); @@ -49,7 +48,7 @@ function getPathParams (params) { */ function makeMethod (schema, method, context) { return function (params, callback) { - var url = buildurl(schema.rootUrl + schema.servicePath + method.path); + var url = generatorUtils.buildurl(schema.rootUrl + schema.servicePath + method.path); var parameters = { options: { @@ -59,13 +58,14 @@ function makeMethod (schema, method, context) { params: params, requiredParams: method.parameterOrder || [], pathParams: getPathParams(method.parameters), - context: context + context: context, + mediaUrl: null }; if (method.mediaUpload && method.mediaUpload.protocols && method.mediaUpload.protocols.simple && method.mediaUpload.protocols.simple.path) { - var mediaUrl = buildurl( + var mediaUrl = generatorUtils.buildurl( schema.rootUrl + method.mediaUpload.protocols.simple.path ); @@ -272,6 +272,7 @@ Discovery.prototype.discoverAPI = function (apiDiscoveryUrl, callback) { }, requiredParams: [], pathParams: [], + params: null, context: { google: { _options: {} @@ -289,4 +290,4 @@ Discovery.prototype.discoverAPI = function (apiDiscoveryUrl, callback) { * Export the Discovery object * @type {Discovery} */ -module.exports = Discovery; +export = Discovery; diff --git a/lib/generator.js b/lib/generator.ts similarity index 98% rename from lib/generator.js rename to lib/generator.ts index ebf0bac2bc..6c95896dc6 100644 --- a/lib/generator.js +++ b/lib/generator.ts @@ -32,7 +32,7 @@ var DISCOVERY_URL = argv['discovery-url'] ? argv['discovery-url'] : ( ); var FRAGMENT_URL = 'https://storage.googleapis.com/apisnippets-staging/public/'; -var API_TEMPLATE = './templates/api-endpoint.js'; +var API_TEMPLATE = './templates/api-endpoint.ts'; var BEAUTIFY_OPTIONS = { 'indent_size': 2, 'indent_char': ' ', @@ -258,7 +258,7 @@ Generator.prototype.generateAPI = function (apiDiscoveryUrl, callback) { ); // e.g. apis/drive/v2.js - var exportFilename = path.join(__dirname, '../apis', resp.name, resp.version + '.js'); + var exportFilename = path.join(__dirname, '../apis', resp.name, resp.version + '.ts'); var contents; async.waterfall([ @@ -306,4 +306,4 @@ Generator.prototype.generateAPI = function (apiDiscoveryUrl, callback) { * Export the Generator object * @type {Generator} */ -module.exports = Generator; +export = Generator; diff --git a/lib/generator_utils.js b/lib/generator_utils.ts similarity index 90% rename from lib/generator_utils.js rename to lib/generator_utils.ts index 5c4d68252f..3bd71d03f8 100644 --- a/lib/generator_utils.js +++ b/lib/generator_utils.ts @@ -36,7 +36,7 @@ function buildurl (input) { * Disable auto-escaping its output * @type {Boolean} */ -buildurl.safe = true; +(buildurl as any).safe = true; /** * Handle error object with callback @@ -51,6 +51,9 @@ function handleError (err, callback) { } } -exports.DefaultTransporter = require('../lib/transporters'); -exports.buildurl = buildurl; -exports.handleError = handleError; +export = { + DefaultTransporter: require('../lib/transporters'), + buildurl: buildurl, + handleError: handleError +} + diff --git a/lib/googleapis.js b/lib/googleapis.ts similarity index 98% rename from lib/googleapis.js rename to lib/googleapis.ts index 735119d7b9..02c7ee7301 100644 --- a/lib/googleapis.js +++ b/lib/googleapis.ts @@ -78,7 +78,7 @@ var GoogleAuth = require('google-auth-library'); * @class GoogleApis * @param {Object} [options] Configuration options. */ -function GoogleApis (options) { +function GoogleApis (options?) { this.options(options); this.addAPIs(apis); @@ -212,4 +212,4 @@ GoogleApis.prototype.discoverAPI = function (path, options, callback) { * @module googleapis * @type {GoogleApis} */ -module.exports = new GoogleApis(); +export = new GoogleApis(); diff --git a/lib/pemverifier.js b/lib/pemverifier.ts similarity index 100% rename from lib/pemverifier.js rename to lib/pemverifier.ts diff --git a/lib/transporters.js b/lib/transporters.ts similarity index 100% rename from lib/transporters.js rename to lib/transporters.ts diff --git a/lib/utils.js b/lib/utils.ts similarity index 100% rename from lib/utils.js rename to lib/utils.ts diff --git a/package.json b/package.json index bc80afc680..1045ce7efc 100644 --- a/package.json +++ b/package.json @@ -65,6 +65,8 @@ "string-template": "~1.0.0" }, "devDependencies": { + "@types/mocha": "^2.2.41", + "@types/node": "^7.0.13", "ink-docstrap": "1.3.0", "intelli-espower-loader": "1.0.1", "js-beautify": "1.6.12", @@ -77,16 +79,20 @@ "power-assert": "1.4.2", "rimraf": "2.6.1", "semistandard": "10.0.0", - "swig": "1.4.2" + "source-map-support": "^0.4.14", + "swig": "1.4.2", + "typescript": "^2.2.2" }, "scripts": { - "lint": "semistandard \"**/*.js\"", - "generate-apis": "node scripts/generate", + "lint": "semistandard \"samples/**/*.js\"", + "generate-apis": "npm run build-tools && node scripts/generate.js", "doc": "jsdoc -c jsdoc-conf.json", - "mocha": "mocha test/ --recursive -t 10000 -S -R spec --require intelli-espower-loader", + "mocha": "mocha test/ --recursive -t 10000 -S -R spec --require source-map-support/register --require intelli-espower-loader" , "cover": "nyc --cache mocha test/ --recursive -t 10000 -S -R spec --require intelli-espower-loader && nyc report --reporter=html", - "build": "npm run generate-apis && npm test", - "test": "npm run lint && npm run cover" + "build": "tsc", + "test": "npm run lint && npm run cover", + "build-tools": "tsc -p tsconfig.tools.json", + "clean": "find . -name '*.js.map' -type f -delete && find -E . -regex '\\./(test|lib|apis|scripts)/.*.js$' -type f -delete" }, "nyc": { "exclude": [ diff --git a/scripts/generate.js b/scripts/generate.ts similarity index 98% rename from scripts/generate.js rename to scripts/generate.ts index 8b6eefb81b..8b2f67e6c6 100644 --- a/scripts/generate.js +++ b/scripts/generate.ts @@ -19,7 +19,7 @@ var Generator = require('../lib/generator'); var rimraf = require('rimraf'); var path = require('path'); -var debug = false; +var debug = true; var argv = require('minimist')(process.argv.slice(2)); diff --git a/templates/api-endpoint.js b/templates/api-endpoint.ts similarity index 95% rename from templates/api-endpoint.js rename to templates/api-endpoint.ts index 9285f18961..b50d5cbb1e 100644 --- a/templates/api-endpoint.js +++ b/templates/api-endpoint.ts @@ -47,7 +47,7 @@ function {{ Name }} (options) { // eslint-disable-line {% if methods %} {% set globalmethods = true %} {% for mname, m in methods %} - {% include "./method-partial.js" with m %} + {% include "./method-partial.ts" with m %} {% endfor -%} {%- endif -%} @@ -56,7 +56,7 @@ function {{ Name }} (options) { // eslint-disable-line {% for rname, r in resources %} {% set ResourceNamespace = [Name, rname]|join('.') %} self.{{ rname }} = { - {% include "./resource-partial.js" with r %} + {% include "./resource-partial.ts" with r %} }; {%- endfor -%} {%- endif -%} @@ -87,4 +87,4 @@ function {{ Name }} (options) { // eslint-disable-line {%- endfor -%} -module.exports = {{ Name }}; +export = {{ Name }}; diff --git a/templates/method-partial.js b/templates/method-partial.ts similarity index 100% rename from templates/method-partial.js rename to templates/method-partial.ts diff --git a/templates/resource-partial.js b/templates/resource-partial.ts similarity index 73% rename from templates/resource-partial.js rename to templates/resource-partial.ts index 3af7c51909..c00ef9c537 100644 --- a/templates/resource-partial.js +++ b/templates/resource-partial.ts @@ -1,6 +1,6 @@ {% if r.methods %} {% for mname, m in methods -%} - {% include "./method-partial.js" with m %} + {% include "./method-partial.ts" with m %} {%- endfor -%} {%- endif -%}{%- if r.methods && r.resources -%},{%- endif -%} @@ -8,7 +8,7 @@ {%- for rname, r in resources %} {{ rname }}: { - {%- include "./resource-partial.js" with r -%} + {%- include "./resource-partial.ts" with r -%} }{%- if not loop.last -%},{%- endif -%} {%- endfor -%} {%- endif -%} diff --git a/test/test.apikey.js b/test/test.apikey.ts similarity index 97% rename from test/test.apikey.js rename to test/test.apikey.ts index 160307f3cf..dd9904f1b9 100644 --- a/test/test.apikey.js +++ b/test/test.apikey.ts @@ -27,7 +27,7 @@ function testGet (drive) { assert.equal(req.uri.query, 'key=APIKEY'); } -function testParams (drive) { +function testParams2 (drive) { var req = drive.files.get({ fileId: '123', auth: 'API KEY' @@ -95,8 +95,8 @@ describe('API key', function () { }); it('should properly escape params E.g. API KEY to API%20KEY', function () { - testParams(localDrive); - testParams(remoteDrive); + testParams2(localDrive); + testParams2(remoteDrive); }); it('should use key param over auth apikey param if both provided', function () { diff --git a/test/test.auth.js b/test/test.auth.ts similarity index 100% rename from test/test.auth.js rename to test/test.auth.ts diff --git a/test/test.clients.js b/test/test.clients.ts similarity index 88% rename from test/test.clients.js rename to test/test.clients.ts index 45a6549fd8..3738da1fe2 100644 --- a/test/test.clients.js +++ b/test/test.clients.ts @@ -94,7 +94,7 @@ describe('Clients', function () { }); it('should be able to require all api files without error', function () { - function getFiles (dir, files_) { + function getFiles (dir, files_?) { files_ = files_ || []; if (typeof files_ === 'undefined') { files_ = []; @@ -108,7 +108,9 @@ describe('Clients', function () { if (fs.statSync(name).isDirectory()) { getFiles(name, files_); } else { - files_.push(name); + if (path.extname(name) === ".js") { + files_.push(name); + } } } return files_; @@ -131,10 +133,10 @@ describe('Clients', function () { it('should support default params', function (done) { var google = new googleapis.GoogleApis(); var datastore = google.datastore({ - version: 'v1beta2', + version: 'v1beta3', params: { myParam: '123' } }); - var req = datastore.datasets.lookup({ datasetId: '123' }, utils.noop); + var req = datastore.projects.lookup({ projectId: 'test-project-id' }, utils.noop); // If the default param handling is broken, query might be undefined, thus // concealing the assertion message with some generic "cannot call .indexOf // of undefined" @@ -146,14 +148,14 @@ describe('Clients', function () { 'Default param in query' ); nock.enableNetConnect(); - utils.loadApi(google, 'datastore', 'v1beta2', { + utils.loadApi(google, 'datastore', 'v1beta3', { params: { myParam: '123' } }, function (err, datastore) { nock.disableNetConnect(); if (err) { return done(err); } - var req = datastore.datasets.lookup({ datasetId: '123' }, utils.noop); + var req = datastore.projects.lookup({ projectId: 'test-project-id' }, utils.noop); var query = req.uri.query || ''; assert.notEqual( @@ -168,12 +170,12 @@ describe('Clients', function () { it('should allow default params to be overriden per-request', function (done) { var google = new googleapis.GoogleApis(); var datastore = google.datastore({ - version: 'v1beta2', + version: 'v1beta3', params: { myParam: '123' } }); // Override the default datasetId param for this particular API call - var req = datastore.datasets.lookup({ - datasetId: '123', myParam: '456' + var req = datastore.projects.lookup({ + projectId: 'test-project-id', myParam: '456' }, utils.noop); // If the default param handling is broken, query might be undefined, thus // concealing the assertion message with some generic "cannot call .indexOf @@ -187,7 +189,7 @@ describe('Clients', function () { ); nock.enableNetConnect(); - utils.loadApi(google, 'datastore', 'v1beta2', { + utils.loadApi(google, 'datastore', 'v1beta3', { params: { myParam: '123' } }, function (err, datastore) { nock.disableNetConnect(); @@ -195,8 +197,8 @@ describe('Clients', function () { return done(err); } // Override the default datasetId param for this particular API call - var req = datastore.datasets.lookup({ - datasetId: '123', myParam: '456' + var req = datastore.projects.lookup({ + projectId: 'test-project-id', myParam: '456' }, utils.noop); // If the default param handling is broken, query might be undefined, thus // concealing the assertion message with some generic "cannot call .indexOf @@ -215,14 +217,14 @@ describe('Clients', function () { it('should include default params when only callback is provided to API call', function (done) { var google = new googleapis.GoogleApis(); var datastore = google.datastore({ - version: 'v1beta2', + version: 'v1beta3', params: { - datasetId: '123', // We must set this here - it is a required param + projectId: 'test-project-id', // We must set this here - it is a required param myParam: '123' } }); // No params given - only callback - var req = datastore.datasets.lookup(utils.noop); + var req = datastore.projects.lookup(utils.noop); // If the default param handling is broken, req or query might be undefined, thus concealing the // assertion message with some generic "cannot call .indexOf of undefined" var query = (req && req.uri.query) || ''; @@ -230,9 +232,9 @@ describe('Clients', function () { assert.notEqual(query.indexOf('myParam=123'), -1, 'Default param not found in query'); nock.enableNetConnect(); - utils.loadApi(google, 'datastore', 'v1beta2', { + utils.loadApi(google, 'datastore', 'v1beta3', { params: { - datasetId: '123', // We must set this here - it is a required param + projectId: 'test-project-id', // We must set this here - it is a required param myParam: '123' } }, function (err, datastore) { @@ -241,7 +243,7 @@ describe('Clients', function () { return done(err); } // No params given - only callback - var req = datastore.datasets.lookup(utils.noop); + var req = datastore.projects.lookup(utils.noop); // If the default param handling is broken, req or query might be // undefined, thus concealing the assertion message with some generic // "cannot call .indexOf of undefined" diff --git a/test/test.discover.js b/test/test.discover.ts similarity index 100% rename from test/test.discover.js rename to test/test.discover.ts diff --git a/test/test.drive.v2.js b/test/test.drive.v2.ts similarity index 100% rename from test/test.drive.v2.js rename to test/test.drive.v2.ts diff --git a/test/test.media.js b/test/test.media.ts similarity index 100% rename from test/test.media.js rename to test/test.media.ts diff --git a/test/test.options.js b/test/test.options.ts similarity index 100% rename from test/test.options.js rename to test/test.options.ts diff --git a/test/test.path.js b/test/test.path.ts similarity index 100% rename from test/test.path.js rename to test/test.path.ts diff --git a/test/test.query.js b/test/test.query.ts similarity index 100% rename from test/test.query.js rename to test/test.query.ts diff --git a/test/test.transporters.js b/test/test.transporters.ts similarity index 100% rename from test/test.transporters.js rename to test/test.transporters.ts diff --git a/test/test.urlshortener.v1.js b/test/test.urlshortener.v1.ts similarity index 100% rename from test/test.urlshortener.v1.js rename to test/test.urlshortener.v1.ts diff --git a/test/utils.js b/test/utils.ts similarity index 100% rename from test/utils.js rename to test/utils.ts diff --git a/tsconfig.json b/tsconfig.json new file mode 100644 index 0000000000..d6bfb01295 --- /dev/null +++ b/tsconfig.json @@ -0,0 +1,14 @@ +{ + "compilerOptions": { + "module": "commonjs", + "target": "es5", + "noImplicitAny": false, + "sourceMap": true, + "alwaysStrict": true + }, + "exclude": [ + "node_modules", + "templates", + "samples" + ] +} \ No newline at end of file diff --git a/tsconfig.tools.json b/tsconfig.tools.json new file mode 100644 index 0000000000..e966a87b65 --- /dev/null +++ b/tsconfig.tools.json @@ -0,0 +1,15 @@ +{ + "compilerOptions": { + "module": "commonjs", + "target": "es5", + "noImplicitAny": false, + "sourceMap": true, + "alwaysStrict": true + }, + "files": [ + "scripts/generate.ts", + "lib/generator.ts", + "lib/generator_utils.ts", + "lib/transporters.ts" + ] +} \ No newline at end of file diff --git a/yarn.lock b/yarn.lock index d962c74971..f08c62f4de 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,6 +2,14 @@ # yarn lockfile v1 +"@types/mocha@^2.2.41": + version "2.2.41" + resolved "https://registry.yarnpkg.com/@types/mocha/-/mocha-2.2.41.tgz#e27cf0817153eb9f2713b2d3f6c68f1e1c3ca608" + +"@types/node@^7.0.13": + version "7.0.13" + resolved "https://registry.yarnpkg.com/@types/node/-/node-7.0.13.tgz#1b0a53fe9ef9c3a5d061b126cc9b915bca43a3f5" + abbrev@1: version "1.0.9" resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.0.9.tgz#91b4792588a7738c25f35dd6f63752a2f8776135" @@ -138,9 +146,9 @@ async@^1.4.0: version "1.4.2" resolved "https://registry.yarnpkg.com/async/-/async-1.4.2.tgz#6c9edcb11ced4f0dd2f2d40db0d49a109c088aab" -async@^2.0.1: - version "2.1.4" - resolved "https://registry.yarnpkg.com/async/-/async-2.1.4.tgz#2d2160c7788032e4dd6cbe2502f1f9a2c8f6cde4" +async@^2.0.1, async@~2.3.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/async/-/async-2.3.0.tgz#1013d1051047dd320fe24e494d5c66ecaf6147d9" dependencies: lodash "^4.14.0" @@ -148,12 +156,6 @@ async@~0.2.6: version "0.2.10" resolved "https://registry.yarnpkg.com/async/-/async-0.2.10.tgz#b6bbe0b0674b9d719708ca38de8c237cb526c3d1" -async@~2.3.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/async/-/async-2.3.0.tgz#1013d1051047dd320fe24e494d5c66ecaf6147d9" - dependencies: - lodash "^4.14.0" - aws-sign2@~0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.6.0.tgz#14342dd38dbcc94d0e5b87d763cd63612c0e794f" @@ -1093,7 +1095,7 @@ glob-parent@^2.0.0: dependencies: is-glob "^2.0.0" -glob@7.0.5, glob@^7.0.0, glob@^7.0.3, glob@^7.0.5: +glob@7.0.5: version "7.0.5" resolved "https://registry.yarnpkg.com/glob/-/glob-7.0.5.tgz#b4202a69099bbb4d292a7c1b95b6682b67ebdc95" dependencies: @@ -1104,7 +1106,7 @@ glob@7.0.5, glob@^7.0.0, glob@^7.0.3, glob@^7.0.5: once "^1.3.0" path-is-absolute "^1.0.0" -glob@^7.0.6: +glob@^7.0.0, glob@^7.0.3, glob@^7.0.5, glob@^7.0.6: version "7.1.1" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.1.tgz#805211df04faaf1c63a3600306cdf5ade50b2ec8" dependencies: @@ -2489,6 +2491,12 @@ source-map-support@^0.3.0: dependencies: source-map "0.1.32" +source-map-support@^0.4.14: + version "0.4.14" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.4.14.tgz#9d4463772598b86271b4f523f6c1f4e02a7d6aef" + dependencies: + source-map "^0.5.6" + source-map@0.1.32: version "0.1.32" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.1.32.tgz#c8b6c167797ba4740a8ea33252162ff08591b266" @@ -2507,7 +2515,7 @@ source-map@^0.4.4: dependencies: amdefine ">=0.0.4" -source-map@^0.5.0, source-map@^0.5.3, source-map@~0.5.1: +source-map@^0.5.0, source-map@^0.5.3, source-map@^0.5.6, source-map@~0.5.1: version "0.5.6" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.6.tgz#75ce38f52bf0733c5a7f0c118d81334a2bb5f412" @@ -2724,6 +2732,10 @@ typedarray@~0.0.5: version "0.0.6" resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" +typescript@^2.2.2: + version "2.2.2" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-2.2.2.tgz#606022508479b55ffa368b58fee963a03dfd7b0c" + uglify-js@^2.6: version "2.7.5" resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-2.7.5.tgz#4612c0c7baaee2ba7c487de4904ae122079f2ca8"