Push before general cleanup to avoid merge errors
This commit is contained in:
399
node_modules/googleapis-common/CHANGELOG.md
generated
vendored
Normal file
399
node_modules/googleapis-common/CHANGELOG.md
generated
vendored
Normal file
@@ -0,0 +1,399 @@
|
||||
# Changelog
|
||||
|
||||
[npm history][1]
|
||||
|
||||
[1]: https://www.npmjs.com/package/nodejs-googleapis-common?activeTab=versions
|
||||
|
||||
## [6.0.3](https://github.com/googleapis/nodejs-googleapis-common/compare/v6.0.2...v6.0.3) (2022-09-08)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **deps:** Update dependency uuid to v9 ([#482](https://github.com/googleapis/nodejs-googleapis-common/issues/482)) ([267426d](https://github.com/googleapis/nodejs-googleapis-common/commit/267426dee5a8247638e35b191ee5b4e0b3694c4d))
|
||||
|
||||
## [6.0.2](https://github.com/googleapis/nodejs-googleapis-common/compare/v6.0.1...v6.0.2) (2022-08-23)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* remove pip install statements ([#1546](https://github.com/googleapis/nodejs-googleapis-common/issues/1546)) ([#478](https://github.com/googleapis/nodejs-googleapis-common/issues/478)) ([18626d8](https://github.com/googleapis/nodejs-googleapis-common/commit/18626d8d7ba03f41582aec8756e48a3c47f1a6a9))
|
||||
|
||||
## [6.0.1](https://github.com/googleapis/nodejs-googleapis-common/compare/v6.0.0...v6.0.1) (2022-08-04)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **deps:** update gaxios to 5.0.1 ([#474](https://github.com/googleapis/nodejs-googleapis-common/issues/474)) ([2ec0be4](https://github.com/googleapis/nodejs-googleapis-common/commit/2ec0be4f5e29041ce5c47e22ca00695b1adaeaa7))
|
||||
|
||||
## [6.0.0](https://github.com/googleapis/nodejs-googleapis-common/compare/v5.1.0...v6.0.0) (2022-05-10)
|
||||
|
||||
|
||||
### ⚠ BREAKING CHANGES
|
||||
|
||||
* update library to use Node 12 (#466)
|
||||
|
||||
### Build System
|
||||
|
||||
* update library to use Node 12 ([#466](https://github.com/googleapis/nodejs-googleapis-common/issues/466)) ([c7dc14f](https://github.com/googleapis/nodejs-googleapis-common/commit/c7dc14f0302db5ca99b8cb15e5e2e570d164baef))
|
||||
|
||||
## [5.1.0](https://github.com/googleapis/nodejs-googleapis-common/compare/v5.0.5...v5.1.0) (2022-02-22)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* **deps:** Update `google-auth-library` to `v7.14.0` ([#446](https://github.com/googleapis/nodejs-googleapis-common/issues/446)) ([c9369d9](https://github.com/googleapis/nodejs-googleapis-common/commit/c9369d9e95795bb974a5a7eb60d32fc4c3e94a2b))
|
||||
|
||||
### [5.0.5](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v5.0.4...v5.0.5) (2021-09-03)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **build:** migrate to main branch ([#414](https://www.github.com/googleapis/nodejs-googleapis-common/issues/414)) ([c49262d](https://www.github.com/googleapis/nodejs-googleapis-common/commit/c49262d0d2d013469b3502de5c0cb7d6753b033d))
|
||||
|
||||
### [5.0.4](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v5.0.3...v5.0.4) (2021-08-04)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **auth:** include impersonated client ([#408](https://www.github.com/googleapis/nodejs-googleapis-common/issues/408)) ([9941ad9](https://www.github.com/googleapis/nodejs-googleapis-common/commit/9941ad931d9bfd5da61b94840d9309b1ae45ddd0))
|
||||
|
||||
### [5.0.3](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v5.0.2...v5.0.3) (2021-07-07)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* mark the HTTP/2 support as stable ([#401](https://www.github.com/googleapis/nodejs-googleapis-common/issues/401)) ([1e0735b](https://www.github.com/googleapis/nodejs-googleapis-common/commit/1e0735baa4a9df24e4a9323cfbba6a82ce2e738b))
|
||||
|
||||
### [5.0.2](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v5.0.1...v5.0.2) (2021-03-24)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* export additional gaxios types ([#368](https://www.github.com/googleapis/nodejs-googleapis-common/issues/368)) ([14a99eb](https://www.github.com/googleapis/nodejs-googleapis-common/commit/14a99eb878d0d2a09773ec325769b54b2e818886))
|
||||
|
||||
### [5.0.1](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v5.0.0...v5.0.1) (2021-02-11)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* update google-auth-library to v7.0.2 ([#364](https://www.github.com/googleapis/nodejs-googleapis-common/issues/364)) ([fd4eac7](https://www.github.com/googleapis/nodejs-googleapis-common/commit/fd4eac78c10a75dd5785ac00ad827d5078c598ac))
|
||||
|
||||
## [5.0.0](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v4.4.3...v5.0.0) (2021-01-08)
|
||||
|
||||
|
||||
### ⚠ BREAKING CHANGES
|
||||
|
||||
* use WHATWG URL API to rewrite rootUrl correctly (#352)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* use WHATWG URL API to rewrite rootUrl correctly ([#352](https://www.github.com/googleapis/nodejs-googleapis-common/issues/352)) ([4c59147](https://www.github.com/googleapis/nodejs-googleapis-common/commit/4c59147fc62cc3a2098d4ce5e21555e15e946147))
|
||||
|
||||
### [4.4.3](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v4.4.2...v4.4.3) (2020-10-29)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **types:** add supportsMediaDownload flag to MethodSchema ([#345](https://www.github.com/googleapis/nodejs-googleapis-common/issues/345)) ([3f8617f](https://www.github.com/googleapis/nodejs-googleapis-common/commit/3f8617f6314778e49420094688b5324e258d2b6e))
|
||||
|
||||
### [4.4.2](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v4.4.1...v4.4.2) (2020-10-22)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **deps:** update dependency gaxios to v4 ([#339](https://www.github.com/googleapis/nodejs-googleapis-common/issues/339)) ([5943bdf](https://www.github.com/googleapis/nodejs-googleapis-common/commit/5943bdfb58d595d8c67f5c559e5992a5462d8149))
|
||||
|
||||
### [4.4.1](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v4.4.0...v4.4.1) (2020-09-30)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **deps:** gaxios ([#329](https://www.github.com/googleapis/nodejs-googleapis-common/issues/329)) ([5a15848](https://www.github.com/googleapis/nodejs-googleapis-common/commit/5a158482dd207f94ae7a19741967c5db7eb8c1ec))
|
||||
|
||||
## [4.4.0](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v4.3.0...v4.4.0) (2020-06-18)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* add experimental http/2 support ([#293](https://www.github.com/googleapis/nodejs-googleapis-common/issues/293)) ([4d33ffa](https://www.github.com/googleapis/nodejs-googleapis-common/commit/4d33ffa237e53f6beb88a4e32d6cc7f31f05a8d6))
|
||||
|
||||
## [4.3.0](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v4.2.1...v4.3.0) (2020-06-03)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* allow passing a GoogleAuth instance ([#287](https://www.github.com/googleapis/nodejs-googleapis-common/issues/287)) ([c8e9f3b](https://www.github.com/googleapis/nodejs-googleapis-common/commit/c8e9f3b9636d9b6ce176396cc7b273c107168eec))
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* expand definition of a stream ([#289](https://www.github.com/googleapis/nodejs-googleapis-common/issues/289)) ([2010721](https://www.github.com/googleapis/nodejs-googleapis-common/commit/20107219a757cf234be9432def49e0644cbd7a79))
|
||||
|
||||
### [4.2.1](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v4.2.0...v4.2.1) (2020-06-02)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* ensure options changes do not leak upstream ([#285](https://www.github.com/googleapis/nodejs-googleapis-common/issues/285)) ([8d4de8a](https://www.github.com/googleapis/nodejs-googleapis-common/commit/8d4de8a03b56d1063aac5f072436917247afc9f1))
|
||||
|
||||
## [4.2.0](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v4.1.1...v4.2.0) (2020-05-26)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* add stream method options interface ([#283](https://www.github.com/googleapis/nodejs-googleapis-common/issues/283)) ([a455680](https://www.github.com/googleapis/nodejs-googleapis-common/commit/a4556800fbb39fb7a38733ad4e433d2b0cc7fcda))
|
||||
|
||||
### [4.1.1](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v4.1.0...v4.1.1) (2020-05-04)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* provide mechanism for multipart uploads from browser context ([#274](https://www.github.com/googleapis/nodejs-googleapis-common/issues/274)) ([282bf22](https://www.github.com/googleapis/nodejs-googleapis-common/commit/282bf224471f4ba581e8fc43935411a842510180))
|
||||
* **deps:** update dependency uuid to v8 ([#278](https://www.github.com/googleapis/nodejs-googleapis-common/issues/278)) ([f242874](https://www.github.com/googleapis/nodejs-googleapis-common/commit/f242874ab03569064c3b6ce13b00465d4cb5aeb7))
|
||||
|
||||
## [4.1.0](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v4.0.0...v4.1.0) (2020-04-12)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* export additional types ([#256](https://www.github.com/googleapis/nodejs-googleapis-common/issues/256)) ([0534203](https://www.github.com/googleapis/nodejs-googleapis-common/commit/0534203a80fa88b3224bc9da22d2be4a2cb21796))
|
||||
|
||||
## [4.0.0](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v3.2.2...v4.0.0) (2020-04-05)
|
||||
|
||||
|
||||
### ⚠ BREAKING CHANGES
|
||||
|
||||
* require node 10 in engines field (see: https://github.com/googleapis/nodejs-googleapis-common/pull/239) (#240)
|
||||
|
||||
### Features
|
||||
|
||||
* require node 10 in engines field (see: https://github.com/googleapis/nodejs-googleapis-common/pull/239) ([#240](https://www.github.com/googleapis/nodejs-googleapis-common/issues/240)) ([f210ec1](https://www.github.com/googleapis/nodejs-googleapis-common/commit/f210ec13976567ed41101b3bd85f810d51faa8a8))
|
||||
|
||||
### [3.2.2](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v3.2.1...v3.2.2) (2020-02-28)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **deps:** update dependency uuid to v7 ([25a40a5](https://www.github.com/googleapis/nodejs-googleapis-common/commit/25a40a58afe3a9aa16d3c5946c362b0f1a22d6a5))
|
||||
|
||||
### [3.2.1](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v3.2.0...v3.2.1) (2020-01-09)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* support rootUrl as global option ([ca51783](https://www.github.com/googleapis/nodejs-googleapis-common/commit/ca5178382046e1f1d365cd37d60bb508febf3db8))
|
||||
|
||||
## [3.2.0](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v3.1.1...v3.2.0) (2019-12-05)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* **deps:** auth adds support for additional headers ([#195](https://www.github.com/googleapis/nodejs-googleapis-common/issues/195)) ([1e21283](https://www.github.com/googleapis/nodejs-googleapis-common/commit/1e212838695a6dab9d432e73ca7b014845929f50))
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **deps:** pin TypeScript below 3.7.0 ([1a796e7](https://www.github.com/googleapis/nodejs-googleapis-common/commit/1a796e7d1fd98f2f3c0a38a78fc4f8845b416505))
|
||||
* **docs:** add jsdoc-region-tag plugin ([#185](https://www.github.com/googleapis/nodejs-googleapis-common/issues/185)) ([eddca9f](https://www.github.com/googleapis/nodejs-googleapis-common/commit/eddca9f48a8f7024ae507f7bbce8ceb18adc8f52))
|
||||
* include user agent for global and service level options ([#193](https://www.github.com/googleapis/nodejs-googleapis-common/issues/193)) ([c878f9c](https://www.github.com/googleapis/nodejs-googleapis-common/commit/c878f9cad06f932d8849e7db44ca9b0cea4900e3))
|
||||
|
||||
### [3.1.1](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v3.1.0...v3.1.1) (2019-10-08)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* allow for resource url parameter ([#178](https://www.github.com/googleapis/nodejs-googleapis-common/issues/178)) ([a3ddd5b](https://www.github.com/googleapis/nodejs-googleapis-common/commit/a3ddd5b))
|
||||
|
||||
## [3.1.0](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v3.0.0...v3.1.0) (2019-08-12)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* populate x-goog-api-client header ([#159](https://www.github.com/googleapis/nodejs-googleapis-common/issues/159)) ([0c8558e](https://www.github.com/googleapis/nodejs-googleapis-common/commit/0c8558e))
|
||||
|
||||
## [3.0.0](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v2.0.4...v3.0.0) (2019-07-24)
|
||||
|
||||
|
||||
### ⚠ BREAKING CHANGES
|
||||
|
||||
* pulls in breaking API changes in google-auth-library. getProjectId() and getProjectId() have been modified to make the impact of these changes less noticeable on the legacy googleapis module (getClient() is idempotent, but getProjectId() will use the last configuration).
|
||||
|
||||
### Features
|
||||
|
||||
* expose GoogleAuth constructor on AuthPlus class ([#154](https://www.github.com/googleapis/nodejs-googleapis-common/issues/154)) ([7d7a961](https://www.github.com/googleapis/nodejs-googleapis-common/commit/7d7a961))
|
||||
|
||||
### [2.0.4](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v2.0.3...v2.0.4) (2019-07-01)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* added _options to topOptions parameters.context.google check ([#148](https://www.github.com/googleapis/nodejs-googleapis-common/issues/148)) ([da1e230](https://www.github.com/googleapis/nodejs-googleapis-common/commit/da1e230))
|
||||
* **deps:** bump the min required version of all deps ([#152](https://www.github.com/googleapis/nodejs-googleapis-common/issues/152)) ([7634004](https://www.github.com/googleapis/nodejs-googleapis-common/commit/7634004))
|
||||
|
||||
### [2.0.3](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v2.0.2...v2.0.3) (2019-06-26)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* remove path params when provided via API level options ([#147](https://www.github.com/googleapis/nodejs-googleapis-common/issues/147)) ([96d940a](https://www.github.com/googleapis/nodejs-googleapis-common/commit/96d940a))
|
||||
* **docs:** link to reference docs section on googleapis.dev ([#150](https://www.github.com/googleapis/nodejs-googleapis-common/issues/150)) ([3ac41da](https://www.github.com/googleapis/nodejs-googleapis-common/commit/3ac41da))
|
||||
|
||||
### [2.0.2](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v2.0.1...v2.0.2) (2019-06-14)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* use deep merge for headers ([#142](https://www.github.com/googleapis/nodejs-googleapis-common/issues/142)) ([404fd19](https://www.github.com/googleapis/nodejs-googleapis-common/commit/404fd19))
|
||||
|
||||
### [2.0.1](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v2.0.0...v2.0.1) (2019-06-14)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **deps:** bump minimum deps and remove pify ([#141](https://www.github.com/googleapis/nodejs-googleapis-common/issues/141)) ([26c3eeb](https://www.github.com/googleapis/nodejs-googleapis-common/commit/26c3eeb))
|
||||
|
||||
## [2.0.0](https://www.github.com/googleapis/nodejs-googleapis-common/compare/v1.0.0...v2.0.0) (2019-05-09)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **deps:** update dependency gaxios to v2 ([#116](https://www.github.com/googleapis/nodejs-googleapis-common/issues/116)) ([0db9055](https://www.github.com/googleapis/nodejs-googleapis-common/commit/0db9055))
|
||||
* **deps:** update dependency google-auth-library to v4 ([#127](https://www.github.com/googleapis/nodejs-googleapis-common/issues/127)) ([5f83c34](https://www.github.com/googleapis/nodejs-googleapis-common/commit/5f83c34))
|
||||
|
||||
|
||||
### Build System
|
||||
|
||||
* upgrade engines field to >=8.10.0 ([#119](https://www.github.com/googleapis/nodejs-googleapis-common/issues/119)) ([ba257e8](https://www.github.com/googleapis/nodejs-googleapis-common/commit/ba257e8))
|
||||
|
||||
|
||||
### BREAKING CHANGES
|
||||
|
||||
* upgrade engines field to >=8.10.0 (#119)
|
||||
|
||||
## v1.0.0
|
||||
|
||||
03-29-2019 11:28 PDT
|
||||
|
||||
**This release has breaking changes**. HTTP retries for a subset of requests are now enabled by default. The retry logic matches the defaults for [gaxios](https://github.com/JustinBeckwith/gaxios):
|
||||
|
||||
```js
|
||||
{
|
||||
// The amount of time to initially delay the retry
|
||||
retryDelay: 100;
|
||||
|
||||
// The HTTP Methods that will be automatically retried.
|
||||
httpMethodsToRetry: ['GET','PUT','HEAD','OPTIONS','DELETE']
|
||||
|
||||
// The HTTP response status codes that will automatically be retried.
|
||||
statusCodesToRetry: [[100, 199], [429, 429], [500, 599]];
|
||||
}
|
||||
```
|
||||
|
||||
The behavior can be disabled by setting `retry` to `false` in the request config. For more information, see https://github.com/googleapis/nodejs-googleapis-common/pull/104.
|
||||
|
||||
### New Features
|
||||
- feat: retry requests by default ([#104](https://github.com/googleapis/nodejs-googleapis-common/pull/104))
|
||||
|
||||
### Documentation
|
||||
- docs: update links in contrib guide ([#94](https://github.com/googleapis/nodejs-googleapis-common/pull/94))
|
||||
- docs: update contributing path in README ([#89](https://github.com/googleapis/nodejs-googleapis-common/pull/89))
|
||||
- docs: move CONTRIBUTING.md to root ([#88](https://github.com/googleapis/nodejs-googleapis-common/pull/88))
|
||||
- docs: add lint/fix example to contributing guide ([#86](https://github.com/googleapis/nodejs-googleapis-common/pull/86))
|
||||
|
||||
### Internal / Testing Changes
|
||||
- chore: publish to npm using wombat ([#101](https://github.com/googleapis/nodejs-googleapis-common/pull/101))
|
||||
- build: use per-repo publish token ([#100](https://github.com/googleapis/nodejs-googleapis-common/pull/100))
|
||||
- build: Add docuploader credentials to node publish jobs ([#98](https://github.com/googleapis/nodejs-googleapis-common/pull/98))
|
||||
- build: use node10 to run samples-test, system-test etc ([#97](https://github.com/googleapis/nodejs-googleapis-common/pull/97))
|
||||
- build: update release configuration
|
||||
- chore(deps): update dependency mocha to v6
|
||||
- build: use linkinator for docs test ([#92](https://github.com/googleapis/nodejs-googleapis-common/pull/92))
|
||||
- chore(deps): update dependency @types/tmp to v0.0.34 ([#93](https://github.com/googleapis/nodejs-googleapis-common/pull/93))
|
||||
- build: create docs test npm scripts ([#91](https://github.com/googleapis/nodejs-googleapis-common/pull/91))
|
||||
- build: test using @grpc/grpc-js in CI ([#90](https://github.com/googleapis/nodejs-googleapis-common/pull/90))
|
||||
|
||||
## v0.7.2
|
||||
|
||||
01-26-2019 21:18 PST
|
||||
|
||||
- fix: explicit push of finale for multipart/related streams to fix node.js 6 ([#82](https://github.com/googleapis/nodejs-googleapis-common/pull/82))
|
||||
|
||||
## v0.7.1
|
||||
|
||||
01-22-2019 11:22 PST
|
||||
|
||||
### Bug fixes
|
||||
- fix(types): allow user agent directives in global options ([#78](https://github.com/googleapis/nodejs-googleapis-common/pull/78))
|
||||
- fix(streams): reroute boundary insertion through transform stream ([#67](https://github.com/googleapis/nodejs-googleapis-common/pull/67))
|
||||
|
||||
## v0.7.0
|
||||
|
||||
01-21-2019 00:50 PST
|
||||
|
||||
### Features
|
||||
- feat: add ability to augment the user agent ([#76](https://github.com/googleapis/nodejs-googleapis-common/pull/76))
|
||||
|
||||
## v0.6.0
|
||||
|
||||
- feat: export AuthPlus ([#70](https://github.com/googleapis/nodejs-googleapis-common/pull/70))
|
||||
- feat: make it ready for use in browser ([#69](https://github.com/googleapis/nodejs-googleapis-common/pull/69))
|
||||
- build: check for 404s in the docs ([#73](https://github.com/googleapis/nodejs-googleapis-common/pull/73))
|
||||
|
||||
### New Features
|
||||
|
||||
This release makes it possible to use this library in browser.
|
||||
It was actually possible before but with some nasty warnings
|
||||
printed to JavaScript console. These warnings are now eliminated.
|
||||
|
||||
Also, now exporting `AuthPlus` and `OAuth2Client` which allows
|
||||
APIs that use this common module to drop direct dependency on
|
||||
`google-auth-library`.
|
||||
|
||||
### Internal / Testing Changes
|
||||
|
||||
Simple system tests and browser tests were added in this release.
|
||||
|
||||
## v0.4.0
|
||||
|
||||
11-02-2018 10:31 PDT
|
||||
|
||||
|
||||
### Implementation Changes
|
||||
|
||||
### New Features
|
||||
- add additionalProperties to SchemaItem ([#34](https://github.com/googleapis/nodejs-googleapis-common/pull/34))
|
||||
|
||||
### Dependencies
|
||||
- fix(deps): update dependency pify to v4 ([#23](https://github.com/googleapis/nodejs-googleapis-common/pull/23))
|
||||
- chore(deps): update dependency typescript to ~3.1.0 ([#20](https://github.com/googleapis/nodejs-googleapis-common/pull/20))
|
||||
|
||||
### Documentation
|
||||
- chore: update issue templates ([#29](https://github.com/googleapis/nodejs-googleapis-common/pull/29))
|
||||
- chore: remove old issue template ([#27](https://github.com/googleapis/nodejs-googleapis-common/pull/27))
|
||||
- chore: update issue templates
|
||||
|
||||
### Internal / Testing Changes
|
||||
- chore: update CircleCI config ([#37](https://github.com/googleapis/nodejs-googleapis-common/pull/37))
|
||||
- chore: include build in eslintignore ([#33](https://github.com/googleapis/nodejs-googleapis-common/pull/33))
|
||||
- build: run tests on node11 ([#25](https://github.com/googleapis/nodejs-googleapis-common/pull/25))
|
||||
- chore(deps): update dependency nock to v10 ([#21](https://github.com/googleapis/nodejs-googleapis-common/pull/21))
|
||||
- chores(build): run codecov on continuous builds ([#19](https://github.com/googleapis/nodejs-googleapis-common/pull/19))
|
||||
- chores(build): do not collect sponge.xml from windows builds ([#22](https://github.com/googleapis/nodejs-googleapis-common/pull/22))
|
||||
- build: fix codecov uploading on Kokoro ([#15](https://github.com/googleapis/nodejs-googleapis-common/pull/15))
|
||||
- build: bring in Kokoro cfgs ([#13](https://github.com/googleapis/nodejs-googleapis-common/pull/13))
|
||||
- Don't publish sourcemaps ([#12](https://github.com/googleapis/nodejs-googleapis-common/pull/12))
|
||||
- Enable prefer-const in the eslint config ([#11](https://github.com/googleapis/nodejs-googleapis-common/pull/11))
|
||||
- Enable no-var in eslint ([#10](https://github.com/googleapis/nodejs-googleapis-common/pull/10))
|
||||
- Retry npm install in CI ([#9](https://github.com/googleapis/nodejs-googleapis-common/pull/9))
|
||||
|
||||
## v0.3.0
|
||||
|
||||
This release uses the 2.0 release of `google-auth-library`. A summary of these changes (including breaking changes) can be found in the [release notes](https://github.com/google/google-auth-library-nodejs/releases/tag/v2.0.0).
|
||||
|
||||
### Dependencies
|
||||
- Upgrade to google-auth-library 2.0 (#6)
|
||||
|
||||
## v0.2.1
|
||||
|
||||
### Fixes
|
||||
- fix: use the latest google-auth-library (#4)
|
||||
202
node_modules/googleapis-common/LICENSE
generated
vendored
Normal file
202
node_modules/googleapis-common/LICENSE
generated
vendored
Normal file
@@ -0,0 +1,202 @@
|
||||
|
||||
Apache License
|
||||
Version 2.0, January 2004
|
||||
http://www.apache.org/licenses/
|
||||
|
||||
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||
|
||||
1. Definitions.
|
||||
|
||||
"License" shall mean the terms and conditions for use, reproduction,
|
||||
and distribution as defined by Sections 1 through 9 of this document.
|
||||
|
||||
"Licensor" shall mean the copyright owner or entity authorized by
|
||||
the copyright owner that is granting the License.
|
||||
|
||||
"Legal Entity" shall mean the union of the acting entity and all
|
||||
other entities that control, are controlled by, or are under common
|
||||
control with that entity. For the purposes of this definition,
|
||||
"control" means (i) the power, direct or indirect, to cause the
|
||||
direction or management of such entity, whether by contract or
|
||||
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||
|
||||
"You" (or "Your") shall mean an individual or Legal Entity
|
||||
exercising permissions granted by this License.
|
||||
|
||||
"Source" form shall mean the preferred form for making modifications,
|
||||
including but not limited to software source code, documentation
|
||||
source, and configuration files.
|
||||
|
||||
"Object" form shall mean any form resulting from mechanical
|
||||
transformation or translation of a Source form, including but
|
||||
not limited to compiled object code, generated documentation,
|
||||
and conversions to other media types.
|
||||
|
||||
"Work" shall mean the work of authorship, whether in Source or
|
||||
Object form, made available under the License, as indicated by a
|
||||
copyright notice that is included in or attached to the work
|
||||
(an example is provided in the Appendix below).
|
||||
|
||||
"Derivative Works" shall mean any work, whether in Source or Object
|
||||
form, that is based on (or derived from) the Work and for which the
|
||||
editorial revisions, annotations, elaborations, or other modifications
|
||||
represent, as a whole, an original work of authorship. For the purposes
|
||||
of this License, Derivative Works shall not include works that remain
|
||||
separable from, or merely link (or bind by name) to the interfaces of,
|
||||
the Work and Derivative Works thereof.
|
||||
|
||||
"Contribution" shall mean any work of authorship, including
|
||||
the original version of the Work and any modifications or additions
|
||||
to that Work or Derivative Works thereof, that is intentionally
|
||||
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||
or by an individual or Legal Entity authorized to submit on behalf of
|
||||
the copyright owner. For the purposes of this definition, "submitted"
|
||||
means any form of electronic, verbal, or written communication sent
|
||||
to the Licensor or its representatives, including but not limited to
|
||||
communication on electronic mailing lists, source code control systems,
|
||||
and issue tracking systems that are managed by, or on behalf of, the
|
||||
Licensor for the purpose of discussing and improving the Work, but
|
||||
excluding communication that is conspicuously marked or otherwise
|
||||
designated in writing by the copyright owner as "Not a Contribution."
|
||||
|
||||
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||
on behalf of whom a Contribution has been received by Licensor and
|
||||
subsequently incorporated within the Work.
|
||||
|
||||
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
copyright license to reproduce, prepare Derivative Works of,
|
||||
publicly display, publicly perform, sublicense, and distribute the
|
||||
Work and such Derivative Works in Source or Object form.
|
||||
|
||||
3. Grant of Patent License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
(except as stated in this section) patent license to make, have made,
|
||||
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||
where such license applies only to those patent claims licensable
|
||||
by such Contributor that are necessarily infringed by their
|
||||
Contribution(s) alone or by combination of their Contribution(s)
|
||||
with the Work to which such Contribution(s) was submitted. If You
|
||||
institute patent litigation against any entity (including a
|
||||
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||
or a Contribution incorporated within the Work constitutes direct
|
||||
or contributory patent infringement, then any patent licenses
|
||||
granted to You under this License for that Work shall terminate
|
||||
as of the date such litigation is filed.
|
||||
|
||||
4. Redistribution. You may reproduce and distribute copies of the
|
||||
Work or Derivative Works thereof in any medium, with or without
|
||||
modifications, and in Source or Object form, provided that You
|
||||
meet the following conditions:
|
||||
|
||||
(a) You must give any other recipients of the Work or
|
||||
Derivative Works a copy of this License; and
|
||||
|
||||
(b) You must cause any modified files to carry prominent notices
|
||||
stating that You changed the files; and
|
||||
|
||||
(c) You must retain, in the Source form of any Derivative Works
|
||||
that You distribute, all copyright, patent, trademark, and
|
||||
attribution notices from the Source form of the Work,
|
||||
excluding those notices that do not pertain to any part of
|
||||
the Derivative Works; and
|
||||
|
||||
(d) If the Work includes a "NOTICE" text file as part of its
|
||||
distribution, then any Derivative Works that You distribute must
|
||||
include a readable copy of the attribution notices contained
|
||||
within such NOTICE file, excluding those notices that do not
|
||||
pertain to any part of the Derivative Works, in at least one
|
||||
of the following places: within a NOTICE text file distributed
|
||||
as part of the Derivative Works; within the Source form or
|
||||
documentation, if provided along with the Derivative Works; or,
|
||||
within a display generated by the Derivative Works, if and
|
||||
wherever such third-party notices normally appear. The contents
|
||||
of the NOTICE file are for informational purposes only and
|
||||
do not modify the License. You may add Your own attribution
|
||||
notices within Derivative Works that You distribute, alongside
|
||||
or as an addendum to the NOTICE text from the Work, provided
|
||||
that such additional attribution notices cannot be construed
|
||||
as modifying the License.
|
||||
|
||||
You may add Your own copyright statement to Your modifications and
|
||||
may provide additional or different license terms and conditions
|
||||
for use, reproduction, or distribution of Your modifications, or
|
||||
for any such Derivative Works as a whole, provided Your use,
|
||||
reproduction, and distribution of the Work otherwise complies with
|
||||
the conditions stated in this License.
|
||||
|
||||
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||
any Contribution intentionally submitted for inclusion in the Work
|
||||
by You to the Licensor shall be under the terms and conditions of
|
||||
this License, without any additional terms or conditions.
|
||||
Notwithstanding the above, nothing herein shall supersede or modify
|
||||
the terms of any separate license agreement you may have executed
|
||||
with Licensor regarding such Contributions.
|
||||
|
||||
6. Trademarks. This License does not grant permission to use the trade
|
||||
names, trademarks, service marks, or product names of the Licensor,
|
||||
except as required for reasonable and customary use in describing the
|
||||
origin of the Work and reproducing the content of the NOTICE file.
|
||||
|
||||
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||
agreed to in writing, Licensor provides the Work (and each
|
||||
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||
implied, including, without limitation, any warranties or conditions
|
||||
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||
appropriateness of using or redistributing the Work and assume any
|
||||
risks associated with Your exercise of permissions under this License.
|
||||
|
||||
8. Limitation of Liability. In no event and under no legal theory,
|
||||
whether in tort (including negligence), contract, or otherwise,
|
||||
unless required by applicable law (such as deliberate and grossly
|
||||
negligent acts) or agreed to in writing, shall any Contributor be
|
||||
liable to You for damages, including any direct, indirect, special,
|
||||
incidental, or consequential damages of any character arising as a
|
||||
result of this License or out of the use or inability to use the
|
||||
Work (including but not limited to damages for loss of goodwill,
|
||||
work stoppage, computer failure or malfunction, or any and all
|
||||
other commercial damages or losses), even if such Contributor
|
||||
has been advised of the possibility of such damages.
|
||||
|
||||
9. Accepting Warranty or Additional Liability. While redistributing
|
||||
the Work or Derivative Works thereof, You may choose to offer,
|
||||
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||
or other liability obligations and/or rights consistent with this
|
||||
License. However, in accepting such obligations, You may act only
|
||||
on Your own behalf and on Your sole responsibility, not on behalf
|
||||
of any other Contributor, and only if You agree to indemnify,
|
||||
defend, and hold each Contributor harmless for any liability
|
||||
incurred by, or claims asserted against, such Contributor by reason
|
||||
of your accepting any such warranty or additional liability.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
APPENDIX: How to apply the Apache License to your work.
|
||||
|
||||
To apply the Apache License to your work, attach the following
|
||||
boilerplate notice, with the fields enclosed by brackets "[]"
|
||||
replaced with your own identifying information. (Don't include
|
||||
the brackets!) The text should be enclosed in the appropriate
|
||||
comment syntax for the file format. We also recommend that a
|
||||
file or class name and description of purpose be included on the
|
||||
same "printed page" as the copyright notice for easier
|
||||
identification within third-party archives.
|
||||
|
||||
Copyright [yyyy] [name of copyright owner]
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
118
node_modules/googleapis-common/README.md
generated
vendored
Normal file
118
node_modules/googleapis-common/README.md
generated
vendored
Normal file
@@ -0,0 +1,118 @@
|
||||
[//]: # "This README.md file is auto-generated, all changes to this file will be lost."
|
||||
[//]: # "To regenerate it, use `python -m synthtool`."
|
||||
<img src="https://avatars2.githubusercontent.com/u/2810941?v=3&s=96" alt="Google Cloud Platform logo" title="Google Cloud Platform" align="right" height="96" width="96"/>
|
||||
|
||||
# [Google APIs Common Module: Node.js Client](https://github.com/googleapis/nodejs-googleapis-common)
|
||||
|
||||
[](https://cloud.google.com/terms/launch-stages)
|
||||
[](https://www.npmjs.org/package/googleapis-common)
|
||||
|
||||
|
||||
|
||||
|
||||
A common tooling library used by the googleapis npm module. You probably don't want to use this directly.
|
||||
|
||||
|
||||
A comprehensive list of changes in each version may be found in
|
||||
[the CHANGELOG](https://github.com/googleapis/nodejs-googleapis-common/blob/main/CHANGELOG.md).
|
||||
|
||||
* [Google APIs Common Module Node.js Client API Reference][client-docs]
|
||||
|
||||
* [github.com/googleapis/nodejs-googleapis-common](https://github.com/googleapis/nodejs-googleapis-common)
|
||||
|
||||
Read more about the client libraries for Cloud APIs, including the older
|
||||
Google APIs Client Libraries, in [Client Libraries Explained][explained].
|
||||
|
||||
[explained]: https://cloud.google.com/apis/docs/client-libraries-explained
|
||||
|
||||
**Table of contents:**
|
||||
|
||||
|
||||
* [Quickstart](#quickstart)
|
||||
|
||||
* [Installing the client library](#installing-the-client-library)
|
||||
|
||||
|
||||
* [Versioning](#versioning)
|
||||
* [Contributing](#contributing)
|
||||
* [License](#license)
|
||||
|
||||
## Quickstart
|
||||
|
||||
### Installing the client library
|
||||
|
||||
```bash
|
||||
npm install googleapis-common
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
The [Google APIs Common Module Node.js Client API Reference][client-docs] documentation
|
||||
also contains samples.
|
||||
|
||||
## Supported Node.js Versions
|
||||
|
||||
Our client libraries follow the [Node.js release schedule](https://nodejs.org/en/about/releases/).
|
||||
Libraries are compatible with all current _active_ and _maintenance_ versions of
|
||||
Node.js.
|
||||
If you are using an end-of-life version of Node.js, we recommend that you update
|
||||
as soon as possible to an actively supported LTS version.
|
||||
|
||||
Google's client libraries support legacy versions of Node.js runtimes on a
|
||||
best-efforts basis with the following warnings:
|
||||
|
||||
* Legacy versions are not tested in continuous integration.
|
||||
* Some security patches and features cannot be backported.
|
||||
* Dependencies cannot be kept up-to-date.
|
||||
|
||||
Client libraries targeting some end-of-life versions of Node.js are available, and
|
||||
can be installed through npm [dist-tags](https://docs.npmjs.com/cli/dist-tag).
|
||||
The dist-tags follow the naming convention `legacy-(version)`.
|
||||
For example, `npm install googleapis-common@legacy-8` installs client libraries
|
||||
for versions compatible with Node.js 8.
|
||||
|
||||
## Versioning
|
||||
|
||||
This library follows [Semantic Versioning](http://semver.org/).
|
||||
|
||||
|
||||
|
||||
This library is considered to be **stable**. The code surface will not change in backwards-incompatible ways
|
||||
unless absolutely necessary (e.g. because of critical security issues) or with
|
||||
an extensive deprecation period. Issues and requests against **stable** libraries
|
||||
are addressed with the highest priority.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
More Information: [Google Cloud Platform Launch Stages][launch_stages]
|
||||
|
||||
[launch_stages]: https://cloud.google.com/terms/launch-stages
|
||||
|
||||
## Contributing
|
||||
|
||||
Contributions welcome! See the [Contributing Guide](https://github.com/googleapis/nodejs-googleapis-common/blob/main/CONTRIBUTING.md).
|
||||
|
||||
Please note that this `README.md`, the `samples/README.md`,
|
||||
and a variety of configuration files in this repository (including `.nycrc` and `tsconfig.json`)
|
||||
are generated from a central template. To edit one of these files, make an edit
|
||||
to its templates in
|
||||
[directory](https://github.com/googleapis/synthtool).
|
||||
|
||||
## License
|
||||
|
||||
Apache Version 2.0
|
||||
|
||||
See [LICENSE](https://github.com/googleapis/nodejs-googleapis-common/blob/main/LICENSE)
|
||||
|
||||
[client-docs]: https://cloud.google.com/nodejs/docs/reference/googleapis-common/latest
|
||||
|
||||
[shell_img]: https://gstatic.com/cloudssh/images/open-btn.png
|
||||
[projects]: https://console.cloud.google.com/project
|
||||
[billing]: https://support.google.com/cloud/answer/6293499#enable-billing
|
||||
|
||||
[auth]: https://cloud.google.com/docs/authentication/getting-started
|
||||
51
node_modules/googleapis-common/build/src/api.d.ts
generated
vendored
Normal file
51
node_modules/googleapis-common/build/src/api.d.ts
generated
vendored
Normal file
@@ -0,0 +1,51 @@
|
||||
import { GaxiosOptions, GaxiosResponse } from 'gaxios';
|
||||
import { OAuth2Client, GoogleAuth, BaseExternalAccountClient } from 'google-auth-library';
|
||||
import { Endpoint } from './endpoint';
|
||||
export interface APIRequestParams<T = any> {
|
||||
options: MethodOptions;
|
||||
params: T;
|
||||
requiredParams: string[];
|
||||
pathParams: string[];
|
||||
context: APIRequestContext;
|
||||
mediaUrl?: string | null;
|
||||
}
|
||||
export interface GoogleConfigurable {
|
||||
_options: GlobalOptions;
|
||||
}
|
||||
export interface APIRequestContext {
|
||||
google?: GoogleConfigurable;
|
||||
_options: GlobalOptions;
|
||||
}
|
||||
/**
|
||||
* This interface is a mix of the AxiosRequestConfig options
|
||||
* and our `auth` options.
|
||||
*/
|
||||
export interface GlobalOptions extends MethodOptions {
|
||||
auth?: GoogleAuth | OAuth2Client | BaseExternalAccountClient | string;
|
||||
}
|
||||
export interface MethodOptions extends GaxiosOptions {
|
||||
rootUrl?: string;
|
||||
http2?: boolean;
|
||||
userAgentDirectives?: UserAgentDirective[];
|
||||
}
|
||||
export interface StreamMethodOptions extends MethodOptions {
|
||||
responseType: 'stream';
|
||||
}
|
||||
/**
|
||||
* An additional directive to add to the user agent header.
|
||||
* Directives come in the form of:
|
||||
* User-Agent: <product> / <product-version> <comment>
|
||||
*
|
||||
* For more information, see:
|
||||
* https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent
|
||||
*/
|
||||
export interface UserAgentDirective {
|
||||
product: string;
|
||||
version: string;
|
||||
comment?: string;
|
||||
}
|
||||
export interface ServiceOptions extends GlobalOptions {
|
||||
version?: string;
|
||||
}
|
||||
export declare type BodyResponseCallback<T> = (err: Error | null, res?: GaxiosResponse<T> | null) => void;
|
||||
export declare type APIEndpoint = Readonly<Endpoint & any>;
|
||||
15
node_modules/googleapis-common/build/src/api.js
generated
vendored
Normal file
15
node_modules/googleapis-common/build/src/api.js
generated
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
"use strict";
|
||||
// Copyright 2020 Google LLC
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
//# sourceMappingURL=api.js.map
|
||||
4
node_modules/googleapis-common/build/src/apiIndex.d.ts
generated
vendored
Normal file
4
node_modules/googleapis-common/build/src/apiIndex.d.ts
generated
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
import { GoogleConfigurable, ServiceOptions } from '.';
|
||||
export declare function getAPI<T>(api: string, options: ServiceOptions | string, versions: {
|
||||
[index: string]: any;
|
||||
}, context?: GoogleConfigurable): T;
|
||||
41
node_modules/googleapis-common/build/src/apiIndex.js
generated
vendored
Normal file
41
node_modules/googleapis-common/build/src/apiIndex.js
generated
vendored
Normal file
@@ -0,0 +1,41 @@
|
||||
"use strict";
|
||||
// Copyright 2020 Google LLC
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.getAPI = void 0;
|
||||
function getAPI(api, options,
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
versions, context) {
|
||||
let version;
|
||||
if (typeof options === 'string') {
|
||||
version = options;
|
||||
options = {};
|
||||
}
|
||||
else if (typeof options === 'object') {
|
||||
version = options.version;
|
||||
delete options.version;
|
||||
}
|
||||
else {
|
||||
throw new Error('Argument error: Accepts only string or object');
|
||||
}
|
||||
try {
|
||||
const ctr = versions[version];
|
||||
const ep = new ctr(options, context);
|
||||
return Object.freeze(ep);
|
||||
}
|
||||
catch (e) {
|
||||
throw new Error(`Unable to load endpoint ${api}("${version}"): ${e.message}`);
|
||||
}
|
||||
}
|
||||
exports.getAPI = getAPI;
|
||||
//# sourceMappingURL=apiIndex.js.map
|
||||
9
node_modules/googleapis-common/build/src/apirequest.d.ts
generated
vendored
Normal file
9
node_modules/googleapis-common/build/src/apirequest.d.ts
generated
vendored
Normal file
@@ -0,0 +1,9 @@
|
||||
import { GaxiosPromise } from 'gaxios';
|
||||
import { APIRequestParams, BodyResponseCallback } from './api';
|
||||
/**
|
||||
* Create and send request to Google API
|
||||
* @param parameters Parameters used to form request
|
||||
* @param callback Callback when request finished or error found
|
||||
*/
|
||||
export declare function createAPIRequest<T>(parameters: APIRequestParams): GaxiosPromise<T>;
|
||||
export declare function createAPIRequest<T>(parameters: APIRequestParams, callback: BodyResponseCallback<T>): void;
|
||||
305
node_modules/googleapis-common/build/src/apirequest.js
generated
vendored
Normal file
305
node_modules/googleapis-common/build/src/apirequest.js
generated
vendored
Normal file
@@ -0,0 +1,305 @@
|
||||
"use strict";
|
||||
// Copyright 2020 Google LLC
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.createAPIRequest = void 0;
|
||||
const google_auth_library_1 = require("google-auth-library");
|
||||
const qs = require("qs");
|
||||
const stream = require("stream");
|
||||
const urlTemplate = require("url-template");
|
||||
const uuid = require("uuid");
|
||||
const extend = require("extend");
|
||||
const isbrowser_1 = require("./isbrowser");
|
||||
const h2 = require("./http2");
|
||||
// eslint-disable-next-line @typescript-eslint/no-var-requires
|
||||
const pkg = require('../../package.json');
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
function isReadableStream(obj) {
|
||||
return (obj !== null &&
|
||||
typeof obj === 'object' &&
|
||||
typeof obj.pipe === 'function' &&
|
||||
obj.readable !== false &&
|
||||
typeof obj._read === 'function' &&
|
||||
typeof obj._readableState === 'object');
|
||||
}
|
||||
function getMissingParams(params, required) {
|
||||
const missing = new Array();
|
||||
required.forEach(param => {
|
||||
// Is the required param in the params object?
|
||||
if (params[param] === undefined) {
|
||||
missing.push(param);
|
||||
}
|
||||
});
|
||||
// If there are any required params missing, return their names in array,
|
||||
// otherwise return null
|
||||
return missing.length > 0 ? missing : null;
|
||||
}
|
||||
function createAPIRequest(parameters, callback) {
|
||||
if (callback) {
|
||||
createAPIRequestAsync(parameters).then(r => callback(null, r), callback);
|
||||
}
|
||||
else {
|
||||
return createAPIRequestAsync(parameters);
|
||||
}
|
||||
}
|
||||
exports.createAPIRequest = createAPIRequest;
|
||||
async function createAPIRequestAsync(parameters) {
|
||||
var _a;
|
||||
// Combine the GaxiosOptions options passed with this specific
|
||||
// API call with the global options configured at the API Context
|
||||
// level, or at the global level.
|
||||
const options = extend(true, {}, // Ensure we don't leak settings upstream
|
||||
((_a = parameters.context.google) === null || _a === void 0 ? void 0 : _a._options) || {}, // Google level options
|
||||
parameters.context._options || {}, // Per-API options
|
||||
parameters.options // API call params
|
||||
);
|
||||
const params = extend(true, {}, // New base object
|
||||
options.params, // Combined global/per-api params
|
||||
parameters.params // API call params
|
||||
);
|
||||
options.userAgentDirectives = options.userAgentDirectives || [];
|
||||
const media = params.media || {};
|
||||
/**
|
||||
* In a previous version of this API, the request body was stuffed in a field
|
||||
* named `resource`. This caused lots of problems, because it's not uncommon
|
||||
* to have an actual named parameter required which is also named `resource`.
|
||||
* This meant that users would have to use `resource_` in those cases, which
|
||||
* pretty much nobody figures out on their own. The request body is now
|
||||
* documented as being in the `requestBody` property, but we also need to keep
|
||||
* using `resource` for reasons of back-compat. Cases that need to be covered
|
||||
* here:
|
||||
* - user provides just a `resource` with a request body
|
||||
* - user provides both a `resource` and a `resource_`
|
||||
* - user provides just a `requestBody`
|
||||
* - user provides both a `requestBody` and a `resource`
|
||||
*/
|
||||
let resource = params.requestBody;
|
||||
if (!params.requestBody &&
|
||||
params.resource &&
|
||||
(!parameters.requiredParams.includes('resource') ||
|
||||
typeof params.resource !== 'string')) {
|
||||
resource = params.resource;
|
||||
delete params.resource;
|
||||
}
|
||||
delete params.requestBody;
|
||||
let authClient = params.auth || options.auth;
|
||||
const defaultMime = typeof media.body === 'string' ? 'text/plain' : 'application/octet-stream';
|
||||
delete params.media;
|
||||
delete params.auth;
|
||||
// Grab headers from user provided options
|
||||
const headers = params.headers || {};
|
||||
populateAPIHeader(headers);
|
||||
delete params.headers;
|
||||
// Un-alias parameters that were modified due to conflicts with reserved names
|
||||
Object.keys(params).forEach(key => {
|
||||
if (key.slice(-1) === '_') {
|
||||
const newKey = key.slice(0, -1);
|
||||
params[newKey] = params[key];
|
||||
delete params[key];
|
||||
}
|
||||
});
|
||||
// Check for missing required parameters in the API request
|
||||
const missingParams = getMissingParams(params, parameters.requiredParams);
|
||||
if (missingParams) {
|
||||
// Some params are missing - stop further operations and inform the
|
||||
// developer which required params are not included in the request
|
||||
throw new Error('Missing required parameters: ' + missingParams.join(', '));
|
||||
}
|
||||
// Parse urls
|
||||
if (options.url) {
|
||||
options.url = urlTemplate.parse(options.url).expand(params);
|
||||
}
|
||||
if (parameters.mediaUrl) {
|
||||
parameters.mediaUrl = urlTemplate.parse(parameters.mediaUrl).expand(params);
|
||||
}
|
||||
// Rewrite url if rootUrl is globally set
|
||||
if (parameters.context._options.rootUrl !== undefined &&
|
||||
options.url !== undefined) {
|
||||
const originalUrl = new URL(options.url);
|
||||
const path = originalUrl.href.substr(originalUrl.origin.length);
|
||||
options.url = new URL(path, parameters.context._options.rootUrl).href;
|
||||
}
|
||||
// When forming the querystring, override the serializer so that array
|
||||
// values are serialized like this:
|
||||
// myParams: ['one', 'two'] ---> 'myParams=one&myParams=two'
|
||||
// This serializer also encodes spaces in the querystring as `%20`,
|
||||
// whereas the default serializer in gaxios encodes to a `+`.
|
||||
options.paramsSerializer = params => {
|
||||
return qs.stringify(params, { arrayFormat: 'repeat' });
|
||||
};
|
||||
// delete path params from the params object so they do not end up in query
|
||||
parameters.pathParams.forEach(param => delete params[param]);
|
||||
// if authClient is actually a string, use it as an API KEY
|
||||
if (typeof authClient === 'string') {
|
||||
params.key = params.key || authClient;
|
||||
authClient = undefined;
|
||||
}
|
||||
function multipartUpload(multipart) {
|
||||
const boundary = uuid.v4();
|
||||
const finale = `--${boundary}--`;
|
||||
const rStream = new stream.PassThrough({
|
||||
flush(callback) {
|
||||
this.push('\r\n');
|
||||
this.push(finale);
|
||||
callback();
|
||||
},
|
||||
});
|
||||
const pStream = new ProgressStream();
|
||||
const isStream = isReadableStream(multipart[1].body);
|
||||
headers['content-type'] = `multipart/related; boundary=${boundary}`;
|
||||
for (const part of multipart) {
|
||||
const preamble = `--${boundary}\r\ncontent-type: ${part['content-type']}\r\n\r\n`;
|
||||
rStream.push(preamble);
|
||||
if (typeof part.body === 'string') {
|
||||
rStream.push(part.body);
|
||||
rStream.push('\r\n');
|
||||
}
|
||||
else {
|
||||
// Gaxios does not natively support onUploadProgress in node.js.
|
||||
// Pipe through the pStream first to read the number of bytes read
|
||||
// for the purpose of tracking progress.
|
||||
pStream.on('progress', bytesRead => {
|
||||
if (options.onUploadProgress) {
|
||||
options.onUploadProgress({ bytesRead });
|
||||
}
|
||||
});
|
||||
part.body.pipe(pStream).pipe(rStream);
|
||||
}
|
||||
}
|
||||
if (!isStream) {
|
||||
rStream.push(finale);
|
||||
rStream.push(null);
|
||||
}
|
||||
options.data = rStream;
|
||||
}
|
||||
function browserMultipartUpload(multipart) {
|
||||
const boundary = uuid.v4();
|
||||
const finale = `--${boundary}--`;
|
||||
headers['content-type'] = `multipart/related; boundary=${boundary}`;
|
||||
let content = '';
|
||||
for (const part of multipart) {
|
||||
const preamble = `--${boundary}\r\ncontent-type: ${part['content-type']}\r\n\r\n`;
|
||||
content += preamble;
|
||||
if (typeof part.body === 'string') {
|
||||
content += part.body;
|
||||
content += '\r\n';
|
||||
}
|
||||
}
|
||||
content += finale;
|
||||
options.data = content;
|
||||
}
|
||||
if (parameters.mediaUrl && media.body) {
|
||||
options.url = parameters.mediaUrl;
|
||||
if (resource) {
|
||||
params.uploadType = 'multipart';
|
||||
const multipart = [
|
||||
{ 'content-type': 'application/json', body: JSON.stringify(resource) },
|
||||
{
|
||||
'content-type': media.mimeType || (resource && resource.mimeType) || defaultMime,
|
||||
body: media.body,
|
||||
},
|
||||
];
|
||||
if (!(0, isbrowser_1.isBrowser)()) {
|
||||
// gaxios doesn't support multipart/related uploads, so it has to
|
||||
// be implemented here.
|
||||
multipartUpload(multipart);
|
||||
}
|
||||
else {
|
||||
browserMultipartUpload(multipart);
|
||||
}
|
||||
}
|
||||
else {
|
||||
params.uploadType = 'media';
|
||||
Object.assign(headers, { 'content-type': media.mimeType || defaultMime });
|
||||
options.data = media.body;
|
||||
}
|
||||
}
|
||||
else {
|
||||
options.data = resource || undefined;
|
||||
}
|
||||
options.headers = extend(true, options.headers || {}, headers);
|
||||
options.params = params;
|
||||
if (!(0, isbrowser_1.isBrowser)()) {
|
||||
options.headers['Accept-Encoding'] = 'gzip';
|
||||
options.userAgentDirectives.push({
|
||||
product: 'google-api-nodejs-client',
|
||||
version: pkg.version,
|
||||
comment: 'gzip',
|
||||
});
|
||||
const userAgent = options.userAgentDirectives
|
||||
.map(d => {
|
||||
let line = `${d.product}/${d.version}`;
|
||||
if (d.comment) {
|
||||
line += ` (${d.comment})`;
|
||||
}
|
||||
return line;
|
||||
})
|
||||
.join(' ');
|
||||
options.headers['User-Agent'] = userAgent;
|
||||
}
|
||||
// By default gaxios treats any 2xx as valid, and all non 2xx status
|
||||
// codes as errors. This is a problem for HTTP 304s when used along
|
||||
// with an eTag.
|
||||
if (!options.validateStatus) {
|
||||
options.validateStatus = status => {
|
||||
return (status >= 200 && status < 300) || status === 304;
|
||||
};
|
||||
}
|
||||
// Retry by default
|
||||
options.retry = options.retry === undefined ? true : options.retry;
|
||||
delete options.auth; // is overridden by our auth code
|
||||
// Perform the HTTP request. NOTE: this function used to return a
|
||||
// mikeal/request object. Since the transition to Axios, the method is
|
||||
// now void. This may be a source of confusion for users upgrading from
|
||||
// version 24.0 -> 25.0 or up.
|
||||
if (authClient && typeof authClient === 'object') {
|
||||
if (options.http2) {
|
||||
const authHeaders = await authClient.getRequestHeaders(options.url);
|
||||
const mooOpts = Object.assign({}, options);
|
||||
mooOpts.headers = Object.assign(mooOpts.headers, authHeaders);
|
||||
return h2.request(mooOpts);
|
||||
}
|
||||
else {
|
||||
return authClient.request(options);
|
||||
}
|
||||
}
|
||||
else {
|
||||
return new google_auth_library_1.DefaultTransporter().request(options);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Basic Passthrough Stream that records the number of bytes read
|
||||
* every time the cursor is moved.
|
||||
*/
|
||||
class ProgressStream extends stream.Transform {
|
||||
constructor() {
|
||||
super(...arguments);
|
||||
this.bytesRead = 0;
|
||||
}
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
_transform(chunk, encoding, callback) {
|
||||
this.bytesRead += chunk.length;
|
||||
this.emit('progress', this.bytesRead);
|
||||
this.push(chunk);
|
||||
callback();
|
||||
}
|
||||
}
|
||||
function populateAPIHeader(headers) {
|
||||
// TODO: we should eventually think about adding browser support for this
|
||||
// populating the gl-web header (web support should also be added to
|
||||
// google-auth-library-nodejs).
|
||||
if (!(0, isbrowser_1.isBrowser)()) {
|
||||
headers['x-goog-api-client'] = `gdcl/${pkg.version} gl-node/${process.versions.node}`;
|
||||
}
|
||||
}
|
||||
//# sourceMappingURL=apirequest.js.map
|
||||
22
node_modules/googleapis-common/build/src/authplus.d.ts
generated
vendored
Normal file
22
node_modules/googleapis-common/build/src/authplus.d.ts
generated
vendored
Normal file
@@ -0,0 +1,22 @@
|
||||
import { AwsClient, BaseExternalAccountClient, Compute, ExternalAccountClient, GoogleAuth, GoogleAuthOptions, IdentityPoolClient, Impersonated, JWT, OAuth2Client, ProjectIdCallback, UserRefreshClient } from 'google-auth-library';
|
||||
export declare class AuthPlus extends GoogleAuth {
|
||||
JWT: typeof JWT;
|
||||
Compute: typeof Compute;
|
||||
OAuth2: typeof OAuth2Client;
|
||||
GoogleAuth: typeof GoogleAuth;
|
||||
AwsClient: typeof AwsClient;
|
||||
IdentityPoolClient: typeof IdentityPoolClient;
|
||||
ExternalAccountClient: typeof ExternalAccountClient;
|
||||
private _cachedAuth?;
|
||||
/**
|
||||
* Override getClient(), memoizing an instance of auth for
|
||||
* subsequent calls to getProjectId().
|
||||
*/
|
||||
getClient(options?: GoogleAuthOptions): Promise<Compute | JWT | UserRefreshClient | BaseExternalAccountClient | Impersonated>;
|
||||
/**
|
||||
* Override getProjectId(), using the most recently configured
|
||||
* auth instance when fetching projectId.
|
||||
*/
|
||||
getProjectId(): Promise<string>;
|
||||
getProjectId(callback: ProjectIdCallback): void;
|
||||
}
|
||||
50
node_modules/googleapis-common/build/src/authplus.js
generated
vendored
Normal file
50
node_modules/googleapis-common/build/src/authplus.js
generated
vendored
Normal file
@@ -0,0 +1,50 @@
|
||||
"use strict";
|
||||
// Copyright 2020 Google LLC
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.AuthPlus = void 0;
|
||||
const google_auth_library_1 = require("google-auth-library");
|
||||
class AuthPlus extends google_auth_library_1.GoogleAuth {
|
||||
constructor() {
|
||||
super(...arguments);
|
||||
this.JWT = google_auth_library_1.JWT;
|
||||
this.Compute = google_auth_library_1.Compute;
|
||||
this.OAuth2 = google_auth_library_1.OAuth2Client;
|
||||
this.GoogleAuth = google_auth_library_1.GoogleAuth;
|
||||
this.AwsClient = google_auth_library_1.AwsClient;
|
||||
this.IdentityPoolClient = google_auth_library_1.IdentityPoolClient;
|
||||
this.ExternalAccountClient = google_auth_library_1.ExternalAccountClient;
|
||||
}
|
||||
/**
|
||||
* Override getClient(), memoizing an instance of auth for
|
||||
* subsequent calls to getProjectId().
|
||||
*/
|
||||
async getClient(options) {
|
||||
this._cachedAuth = new google_auth_library_1.GoogleAuth(options);
|
||||
return this._cachedAuth.getClient();
|
||||
}
|
||||
getProjectId(callback) {
|
||||
if (callback) {
|
||||
return this._cachedAuth
|
||||
? this._cachedAuth.getProjectId(callback)
|
||||
: super.getProjectId(callback);
|
||||
}
|
||||
else {
|
||||
return this._cachedAuth
|
||||
? this._cachedAuth.getProjectId()
|
||||
: super.getProjectId();
|
||||
}
|
||||
}
|
||||
}
|
||||
exports.AuthPlus = AuthPlus;
|
||||
//# sourceMappingURL=authplus.js.map
|
||||
42
node_modules/googleapis-common/build/src/discovery.d.ts
generated
vendored
Normal file
42
node_modules/googleapis-common/build/src/discovery.d.ts
generated
vendored
Normal file
@@ -0,0 +1,42 @@
|
||||
import { GlobalOptions } from './api';
|
||||
import { Endpoint } from './endpoint';
|
||||
export declare type EndpointCreator = (options: GlobalOptions, google: {}) => Endpoint;
|
||||
export interface DiscoveryOptions {
|
||||
includePrivate?: boolean;
|
||||
debug?: boolean;
|
||||
}
|
||||
export declare class Discovery {
|
||||
private transporter;
|
||||
private options;
|
||||
/**
|
||||
* Discovery for discovering API endpoints
|
||||
*
|
||||
* @param options Options for discovery
|
||||
*/
|
||||
constructor(options: DiscoveryOptions);
|
||||
/**
|
||||
* Generate and Endpoint from an endpoint schema object.
|
||||
*
|
||||
* @param schema The schema from which to generate the Endpoint.
|
||||
* @return A function that creates an endpoint.
|
||||
*/
|
||||
private makeEndpoint;
|
||||
/**
|
||||
* Log output of generator. Works just like console.log
|
||||
*/
|
||||
private log;
|
||||
/**
|
||||
* Generate all APIs and return as in-memory object.
|
||||
* @param discoveryUrl
|
||||
*/
|
||||
discoverAllAPIs(discoveryUrl: string): Promise<{}>;
|
||||
/**
|
||||
* Generate API file given discovery URL
|
||||
*
|
||||
* @param apiDiscoveryUrl URL or filename of discovery doc for API
|
||||
* @returns A promise that resolves with a function that creates the endpoint
|
||||
*/
|
||||
discoverAPI(apiDiscoveryUrl: string | {
|
||||
url?: string;
|
||||
}): Promise<EndpointCreator>;
|
||||
}
|
||||
144
node_modules/googleapis-common/build/src/discovery.js
generated
vendored
Normal file
144
node_modules/googleapis-common/build/src/discovery.js
generated
vendored
Normal file
@@ -0,0 +1,144 @@
|
||||
"use strict";
|
||||
// Copyright 2020 Google LLC
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.Discovery = void 0;
|
||||
const fs = require("fs");
|
||||
const google_auth_library_1 = require("google-auth-library");
|
||||
const resolve = require("url");
|
||||
const util = require("util");
|
||||
const apirequest_1 = require("./apirequest");
|
||||
const endpoint_1 = require("./endpoint");
|
||||
const readFile = util.promisify(fs.readFile);
|
||||
class Discovery {
|
||||
/**
|
||||
* Discovery for discovering API endpoints
|
||||
*
|
||||
* @param options Options for discovery
|
||||
*/
|
||||
constructor(options) {
|
||||
this.transporter = new google_auth_library_1.DefaultTransporter();
|
||||
this.options = options || {};
|
||||
}
|
||||
/**
|
||||
* Generate and Endpoint from an endpoint schema object.
|
||||
*
|
||||
* @param schema The schema from which to generate the Endpoint.
|
||||
* @return A function that creates an endpoint.
|
||||
*/
|
||||
makeEndpoint(schema) {
|
||||
return (options) => {
|
||||
const ep = new endpoint_1.Endpoint(options);
|
||||
ep.applySchema(ep, schema, schema, ep);
|
||||
return ep;
|
||||
};
|
||||
}
|
||||
/**
|
||||
* Log output of generator. Works just like console.log
|
||||
*/
|
||||
log(...args) {
|
||||
if (this.options && this.options.debug) {
|
||||
console.log(...args);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Generate all APIs and return as in-memory object.
|
||||
* @param discoveryUrl
|
||||
*/
|
||||
async discoverAllAPIs(discoveryUrl) {
|
||||
const headers = this.options.includePrivate
|
||||
? {}
|
||||
: { 'X-User-Ip': '0.0.0.0' };
|
||||
const res = await this.transporter.request({
|
||||
url: discoveryUrl,
|
||||
headers,
|
||||
});
|
||||
const items = res.data.items;
|
||||
const apis = await Promise.all(items.map(async (api) => {
|
||||
const endpointCreator = await this.discoverAPI(api.discoveryRestUrl);
|
||||
return { api, endpointCreator };
|
||||
}));
|
||||
const versionIndex = {};
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
const apisIndex = {};
|
||||
for (const set of apis) {
|
||||
if (!apisIndex[set.api.name]) {
|
||||
versionIndex[set.api.name] = {};
|
||||
apisIndex[set.api.name] = (options) => {
|
||||
const type = typeof options;
|
||||
let version;
|
||||
if (type === 'string') {
|
||||
version = options;
|
||||
options = {};
|
||||
}
|
||||
else if (type === 'object') {
|
||||
version = options.version;
|
||||
delete options.version;
|
||||
}
|
||||
else {
|
||||
throw new Error('Argument error: Accepts only string or object');
|
||||
}
|
||||
try {
|
||||
const ep = set.endpointCreator(options, this);
|
||||
return Object.freeze(ep); // create new & freeze
|
||||
}
|
||||
catch (e) {
|
||||
throw new Error(util.format('Unable to load endpoint %s("%s"): %s', set.api.name, version, e.message));
|
||||
}
|
||||
};
|
||||
}
|
||||
versionIndex[set.api.name][set.api.version] = set.endpointCreator;
|
||||
}
|
||||
return apisIndex;
|
||||
}
|
||||
/**
|
||||
* Generate API file given discovery URL
|
||||
*
|
||||
* @param apiDiscoveryUrl URL or filename of discovery doc for API
|
||||
* @returns A promise that resolves with a function that creates the endpoint
|
||||
*/
|
||||
async discoverAPI(apiDiscoveryUrl) {
|
||||
if (typeof apiDiscoveryUrl === 'string') {
|
||||
const parts = resolve.parse(apiDiscoveryUrl);
|
||||
if (apiDiscoveryUrl && !parts.protocol) {
|
||||
this.log('Reading from file ' + apiDiscoveryUrl);
|
||||
const file = await readFile(apiDiscoveryUrl, { encoding: 'utf8' });
|
||||
return this.makeEndpoint(JSON.parse(file));
|
||||
}
|
||||
else {
|
||||
this.log('Requesting ' + apiDiscoveryUrl);
|
||||
const res = await this.transporter.request({
|
||||
url: apiDiscoveryUrl,
|
||||
});
|
||||
return this.makeEndpoint(res.data);
|
||||
}
|
||||
}
|
||||
else {
|
||||
const options = apiDiscoveryUrl;
|
||||
this.log('Requesting ' + options.url);
|
||||
const url = options.url;
|
||||
delete options.url;
|
||||
const parameters = {
|
||||
options: { url, method: 'GET' },
|
||||
requiredParams: [],
|
||||
pathParams: [],
|
||||
params: options,
|
||||
context: { google: { _options: {} }, _options: {} },
|
||||
};
|
||||
const res = await (0, apirequest_1.createAPIRequest)(parameters);
|
||||
return this.makeEndpoint(res.data);
|
||||
}
|
||||
}
|
||||
}
|
||||
exports.Discovery = Discovery;
|
||||
//# sourceMappingURL=discovery.js.map
|
||||
42
node_modules/googleapis-common/build/src/endpoint.d.ts
generated
vendored
Normal file
42
node_modules/googleapis-common/build/src/endpoint.d.ts
generated
vendored
Normal file
@@ -0,0 +1,42 @@
|
||||
import { APIRequestContext, GlobalOptions } from './api';
|
||||
import { Schema, SchemaResource } from './schema';
|
||||
export interface Target {
|
||||
[index: string]: {};
|
||||
}
|
||||
export declare class Endpoint implements Target, APIRequestContext {
|
||||
_options: GlobalOptions;
|
||||
google: any;
|
||||
[index: string]: {};
|
||||
constructor(options: {});
|
||||
/**
|
||||
* Given a schema, add methods and resources to a target.
|
||||
*
|
||||
* @param {object} target The target to which to apply the schema.
|
||||
* @param {object} rootSchema The top-level schema, so we don't lose track of it
|
||||
* during recursion.
|
||||
* @param {object} schema The current schema from which to extract methods and
|
||||
* resources.
|
||||
* @param {object} context The context to add to each method.
|
||||
*/
|
||||
applySchema(target: Target, rootSchema: Schema, schema: SchemaResource, context: APIRequestContext): void;
|
||||
/**
|
||||
* Given a schema, add methods to a target.
|
||||
*
|
||||
* @param {object} target The target to which to apply the methods.
|
||||
* @param {object} rootSchema The top-level schema, so we don't lose track of it
|
||||
* during recursion.
|
||||
* @param {object} schema The current schema from which to extract methods.
|
||||
* @param {object} context The context to add to each method.
|
||||
*/
|
||||
private applyMethodsFromSchema;
|
||||
/**
|
||||
* Given a method schema, add a method to a target.
|
||||
*
|
||||
* @param target The target to which to add the method.
|
||||
* @param schema The top-level schema that contains the rootUrl, etc.
|
||||
* @param method The method schema from which to generate the method.
|
||||
* @param context The context to add to the method.
|
||||
*/
|
||||
private makeMethod;
|
||||
private getPathParams;
|
||||
}
|
||||
128
node_modules/googleapis-common/build/src/endpoint.js
generated
vendored
Normal file
128
node_modules/googleapis-common/build/src/endpoint.js
generated
vendored
Normal file
@@ -0,0 +1,128 @@
|
||||
"use strict";
|
||||
// Copyright 2020 Google LLC
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.Endpoint = void 0;
|
||||
const apirequest_1 = require("./apirequest");
|
||||
class Endpoint {
|
||||
constructor(options) {
|
||||
this._options = options || {};
|
||||
}
|
||||
/**
|
||||
* Given a schema, add methods and resources to a target.
|
||||
*
|
||||
* @param {object} target The target to which to apply the schema.
|
||||
* @param {object} rootSchema The top-level schema, so we don't lose track of it
|
||||
* during recursion.
|
||||
* @param {object} schema The current schema from which to extract methods and
|
||||
* resources.
|
||||
* @param {object} context The context to add to each method.
|
||||
*/
|
||||
applySchema(target, rootSchema, schema, context) {
|
||||
this.applyMethodsFromSchema(target, rootSchema, schema, context);
|
||||
if (schema.resources) {
|
||||
for (const resourceName in schema.resources) {
|
||||
if (Object.prototype.hasOwnProperty.call(schema.resources, resourceName)) {
|
||||
const resource = schema.resources[resourceName];
|
||||
if (!target[resourceName]) {
|
||||
target[resourceName] = {};
|
||||
}
|
||||
this.applySchema(target[resourceName], rootSchema, resource, context);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Given a schema, add methods to a target.
|
||||
*
|
||||
* @param {object} target The target to which to apply the methods.
|
||||
* @param {object} rootSchema The top-level schema, so we don't lose track of it
|
||||
* during recursion.
|
||||
* @param {object} schema The current schema from which to extract methods.
|
||||
* @param {object} context The context to add to each method.
|
||||
*/
|
||||
applyMethodsFromSchema(target, rootSchema, schema, context) {
|
||||
if (schema.methods) {
|
||||
for (const name in schema.methods) {
|
||||
if (Object.prototype.hasOwnProperty.call(schema.methods, name)) {
|
||||
const method = schema.methods[name];
|
||||
target[name] = this.makeMethod(rootSchema, method, context);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Given a method schema, add a method to a target.
|
||||
*
|
||||
* @param target The target to which to add the method.
|
||||
* @param schema The top-level schema that contains the rootUrl, etc.
|
||||
* @param method The method schema from which to generate the method.
|
||||
* @param context The context to add to the method.
|
||||
*/
|
||||
makeMethod(schema, method, context) {
|
||||
return (paramsOrCallback, callback) => {
|
||||
const params = typeof paramsOrCallback === 'function' ? {} : paramsOrCallback;
|
||||
callback =
|
||||
typeof paramsOrCallback === 'function'
|
||||
? paramsOrCallback
|
||||
: callback;
|
||||
const schemaUrl = buildurl(schema.rootUrl + schema.servicePath + method.path);
|
||||
const parameters = {
|
||||
options: {
|
||||
url: schemaUrl.substring(1, schemaUrl.length - 1),
|
||||
method: method.httpMethod,
|
||||
},
|
||||
params,
|
||||
requiredParams: method.parameterOrder || [],
|
||||
pathParams: this.getPathParams(method.parameters),
|
||||
context,
|
||||
};
|
||||
if (method.mediaUpload &&
|
||||
method.mediaUpload.protocols &&
|
||||
method.mediaUpload.protocols.simple &&
|
||||
method.mediaUpload.protocols.simple.path) {
|
||||
const mediaUrl = buildurl(schema.rootUrl + method.mediaUpload.protocols.simple.path);
|
||||
parameters.mediaUrl = mediaUrl.substring(1, mediaUrl.length - 1);
|
||||
}
|
||||
if (!callback) {
|
||||
return (0, apirequest_1.createAPIRequest)(parameters);
|
||||
}
|
||||
(0, apirequest_1.createAPIRequest)(parameters, callback);
|
||||
return;
|
||||
};
|
||||
}
|
||||
getPathParams(params) {
|
||||
const pathParams = new Array();
|
||||
if (typeof params !== 'object') {
|
||||
params = {};
|
||||
}
|
||||
Object.keys(params).forEach(key => {
|
||||
if (params[key].location === 'path') {
|
||||
pathParams.push(key);
|
||||
}
|
||||
});
|
||||
return pathParams;
|
||||
}
|
||||
}
|
||||
exports.Endpoint = Endpoint;
|
||||
/**
|
||||
* Build a string used to create a URL from the discovery doc provided URL.
|
||||
* replace double slashes with single slash (except in https://)
|
||||
* @private
|
||||
* @param input URL to build from
|
||||
* @return Resulting built URL
|
||||
*/
|
||||
function buildurl(input) {
|
||||
return input ? `'${input}'`.replace(/([^:]\/)\/+/g, '$1') : '';
|
||||
}
|
||||
//# sourceMappingURL=endpoint.js.map
|
||||
27
node_modules/googleapis-common/build/src/http2.d.ts
generated
vendored
Normal file
27
node_modules/googleapis-common/build/src/http2.d.ts
generated
vendored
Normal file
@@ -0,0 +1,27 @@
|
||||
/// <reference types="node" />
|
||||
/// <reference types="node" />
|
||||
/// <reference types="node" />
|
||||
import * as http2 from 'http2';
|
||||
import { URL } from 'url';
|
||||
import { GaxiosResponse, GaxiosOptions } from 'gaxios';
|
||||
/**
|
||||
* Reference to the ClientHttp2Session and a timeout handler.
|
||||
* @private
|
||||
*/
|
||||
export interface SessionData {
|
||||
session: http2.ClientHttp2Session;
|
||||
timeoutHandle?: NodeJS.Timer;
|
||||
}
|
||||
/**
|
||||
* List of sessions current in use.
|
||||
* @private
|
||||
*/
|
||||
export declare const sessions: {
|
||||
[index: string]: SessionData;
|
||||
};
|
||||
/**
|
||||
* Public method to make an http2 request.
|
||||
* @param config - Request options.
|
||||
*/
|
||||
export declare function request<T>(config: GaxiosOptions): Promise<GaxiosResponse<T>>;
|
||||
export declare function closeSession(url: URL): Promise<void>;
|
||||
239
node_modules/googleapis-common/build/src/http2.js
generated
vendored
Normal file
239
node_modules/googleapis-common/build/src/http2.js
generated
vendored
Normal file
@@ -0,0 +1,239 @@
|
||||
"use strict";
|
||||
// Copyright 2020 Google LLC
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.closeSession = exports.request = exports.sessions = void 0;
|
||||
const http2 = require("http2");
|
||||
const zlib = require("zlib");
|
||||
const url_1 = require("url");
|
||||
const qs = require("qs");
|
||||
const extend = require("extend");
|
||||
const stream_1 = require("stream");
|
||||
const util = require("util");
|
||||
const process = require("process");
|
||||
const common_1 = require("gaxios/build/src/common");
|
||||
const { HTTP2_HEADER_CONTENT_ENCODING, HTTP2_HEADER_CONTENT_TYPE, HTTP2_HEADER_METHOD, HTTP2_HEADER_PATH, HTTP2_HEADER_STATUS, } = http2.constants;
|
||||
const DEBUG = !!process.env.HTTP2_DEBUG;
|
||||
/**
|
||||
* List of sessions current in use.
|
||||
* @private
|
||||
*/
|
||||
exports.sessions = {};
|
||||
/**
|
||||
* Public method to make an http2 request.
|
||||
* @param config - Request options.
|
||||
*/
|
||||
async function request(config) {
|
||||
const opts = extend(true, {}, config);
|
||||
opts.validateStatus = opts.validateStatus || validateStatus;
|
||||
opts.responseType = opts.responseType || 'json';
|
||||
const url = new url_1.URL(opts.url);
|
||||
// Check for an existing session to this host, or go create a new one.
|
||||
const sessionData = _getClient(url.host);
|
||||
// Since we're using this session, clear the timeout handle to ensure
|
||||
// it stays in memory and connected for a while further.
|
||||
if (sessionData.timeoutHandle !== undefined) {
|
||||
clearTimeout(sessionData.timeoutHandle);
|
||||
}
|
||||
// Assemble the querystring based on config.params. We're using the
|
||||
// `qs` module to make life a little easier.
|
||||
let pathWithQs = url.pathname;
|
||||
if (config.params && Object.keys(config.params).length > 0) {
|
||||
const q = qs.stringify(opts.params);
|
||||
pathWithQs += `?${q}`;
|
||||
}
|
||||
// Assemble the headers based on basic HTTP2 primitives (path, method) and
|
||||
// custom headers sent from the consumer. Note: I am using `Object.assign`
|
||||
// here making the assumption these objects are not deep. If it turns out
|
||||
// they are, we may need to use the `extend` npm module for deep cloning.
|
||||
const headers = Object.assign({}, opts.headers, {
|
||||
[HTTP2_HEADER_PATH]: pathWithQs,
|
||||
[HTTP2_HEADER_METHOD]: config.method || 'GET',
|
||||
});
|
||||
// NOTE: This is working around an upstream bug in `apirequest.ts`. The
|
||||
// request path assumes that the `content-type` header is going to be set in
|
||||
// the underlying HTTP Client. This hack provides bug for bug compatability
|
||||
// with this bug in gaxios:
|
||||
// https://github.com/googleapis/gaxios/blob/main/src/gaxios.ts#L202
|
||||
if (!headers[HTTP2_HEADER_CONTENT_TYPE]) {
|
||||
if (opts.responseType !== 'text') {
|
||||
headers[HTTP2_HEADER_CONTENT_TYPE] = 'application/json';
|
||||
}
|
||||
}
|
||||
const res = {
|
||||
config,
|
||||
request: {},
|
||||
headers: [],
|
||||
status: 0,
|
||||
data: {},
|
||||
statusText: '',
|
||||
};
|
||||
const chunks = [];
|
||||
const session = sessionData.session;
|
||||
let req;
|
||||
return new Promise((resolve, reject) => {
|
||||
try {
|
||||
req = session
|
||||
.request(headers)
|
||||
.on('response', headers => {
|
||||
res.headers = headers;
|
||||
res.status = Number(headers[HTTP2_HEADER_STATUS]);
|
||||
let stream = req;
|
||||
if (headers[HTTP2_HEADER_CONTENT_ENCODING] === 'gzip') {
|
||||
stream = req.pipe(zlib.createGunzip());
|
||||
}
|
||||
if (opts.responseType === 'stream') {
|
||||
res.data = stream;
|
||||
resolve(res);
|
||||
return;
|
||||
}
|
||||
stream
|
||||
.on('data', d => {
|
||||
chunks.push(d);
|
||||
})
|
||||
.on('error', err => {
|
||||
reject(err);
|
||||
return;
|
||||
})
|
||||
.on('end', () => {
|
||||
const buf = Buffer.concat(chunks);
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
let data = buf;
|
||||
if (buf) {
|
||||
if (opts.responseType === 'json') {
|
||||
try {
|
||||
data = JSON.parse(buf.toString('utf8'));
|
||||
}
|
||||
catch (_a) {
|
||||
data = buf.toString('utf8');
|
||||
}
|
||||
}
|
||||
else if (opts.responseType === 'text') {
|
||||
data = buf.toString('utf8');
|
||||
}
|
||||
else if (opts.responseType === 'arraybuffer') {
|
||||
data = buf.buffer;
|
||||
}
|
||||
res.data = data;
|
||||
}
|
||||
if (!opts.validateStatus(res.status)) {
|
||||
let message = `Request failed with status code ${res.status}. `;
|
||||
if (res.data && typeof res.data === 'object') {
|
||||
const body = util.inspect(res.data, { depth: 5 });
|
||||
message = `${message}\n'${body}`;
|
||||
}
|
||||
reject(new common_1.GaxiosError(message, opts, res));
|
||||
}
|
||||
resolve(res);
|
||||
return;
|
||||
});
|
||||
})
|
||||
.on('error', e => {
|
||||
reject(e);
|
||||
return;
|
||||
});
|
||||
}
|
||||
catch (e) {
|
||||
closeSession(url);
|
||||
reject(e);
|
||||
}
|
||||
res.request = req;
|
||||
// If data was provided, write it to the request in the form of
|
||||
// a stream, string data, or a basic object.
|
||||
if (config.data) {
|
||||
if (config.data instanceof stream_1.Stream) {
|
||||
config.data.pipe(req);
|
||||
}
|
||||
else if (typeof config.data === 'string') {
|
||||
const data = Buffer.from(config.data);
|
||||
req.end(data);
|
||||
}
|
||||
else if (typeof config.data === 'object') {
|
||||
const data = JSON.stringify(config.data);
|
||||
req.end(data);
|
||||
}
|
||||
}
|
||||
// Create a timeout so the Http2Session will be cleaned up after
|
||||
// a period of non-use. 500 milliseconds was chosen because it's
|
||||
// a nice round number, and I don't know what would be a better
|
||||
// choice. Keeping this channel open will hold a file descriptor
|
||||
// which will prevent the process from exiting.
|
||||
sessionData.timeoutHandle = setTimeout(() => {
|
||||
closeSession(url);
|
||||
}, 500);
|
||||
});
|
||||
}
|
||||
exports.request = request;
|
||||
/**
|
||||
* By default, throw for any non-2xx status code
|
||||
* @param status - status code from the HTTP response
|
||||
*/
|
||||
function validateStatus(status) {
|
||||
return status >= 200 && status < 300;
|
||||
}
|
||||
/**
|
||||
* Obtain an existing h2 session or go create a new one.
|
||||
* @param host - The hostname to which the session belongs.
|
||||
*/
|
||||
function _getClient(host) {
|
||||
if (!exports.sessions[host]) {
|
||||
if (DEBUG) {
|
||||
console.log(`Creating client for ${host}`);
|
||||
}
|
||||
const session = http2.connect(`https://${host}`);
|
||||
session
|
||||
.on('error', e => {
|
||||
console.error(`*ERROR*: ${e}`);
|
||||
delete exports.sessions[host];
|
||||
})
|
||||
.on('goaway', (errorCode, lastStreamId) => {
|
||||
console.error(`*GOAWAY*: ${errorCode} : ${lastStreamId}`);
|
||||
delete exports.sessions[host];
|
||||
});
|
||||
exports.sessions[host] = { session };
|
||||
}
|
||||
else {
|
||||
if (DEBUG) {
|
||||
console.log(`Used cached client for ${host}`);
|
||||
}
|
||||
}
|
||||
return exports.sessions[host];
|
||||
}
|
||||
async function closeSession(url) {
|
||||
const sessionData = exports.sessions[url.host];
|
||||
if (!sessionData) {
|
||||
return;
|
||||
}
|
||||
const { session } = sessionData;
|
||||
delete exports.sessions[url.host];
|
||||
if (DEBUG) {
|
||||
console.error(`Closing ${url.host}`);
|
||||
}
|
||||
session.close(() => {
|
||||
if (DEBUG) {
|
||||
console.error(`Closed ${url.host}`);
|
||||
}
|
||||
});
|
||||
setTimeout(() => {
|
||||
if (session && !session.destroyed) {
|
||||
if (DEBUG) {
|
||||
console.log(`Forcing close ${url.host}`);
|
||||
}
|
||||
if (session) {
|
||||
session.destroy();
|
||||
}
|
||||
}
|
||||
}, 1000);
|
||||
}
|
||||
exports.closeSession = closeSession;
|
||||
//# sourceMappingURL=http2.js.map
|
||||
9
node_modules/googleapis-common/build/src/index.d.ts
generated
vendored
Normal file
9
node_modules/googleapis-common/build/src/index.d.ts
generated
vendored
Normal file
@@ -0,0 +1,9 @@
|
||||
export { OAuth2Client, JWT, Compute, UserRefreshClient, DefaultTransporter, GoogleAuth, ExternalAccountClient, BaseExternalAccountClient, IdentityPoolClient, AwsClient, } from 'google-auth-library';
|
||||
export { GaxiosPromise, Gaxios, GaxiosError, GaxiosOptions, GaxiosResponse, Headers, RetryConfig, } from 'gaxios';
|
||||
export { APIEndpoint, APIRequestContext, APIRequestParams, BodyResponseCallback, GlobalOptions, GoogleConfigurable, MethodOptions, StreamMethodOptions, ServiceOptions, } from './api';
|
||||
export { getAPI } from './apiIndex';
|
||||
export { createAPIRequest } from './apirequest';
|
||||
export { AuthPlus } from './authplus';
|
||||
export { Discovery, DiscoveryOptions, EndpointCreator } from './discovery';
|
||||
export { Endpoint, Target } from './endpoint';
|
||||
export { FragmentResponse, HttpMethod, ParameterFormat, Schema, SchemaItem, SchemaItems, SchemaMethod, SchemaMethods, SchemaParameter, SchemaParameters, SchemaResource, SchemaResources, Schemas, SchemaType, } from './schema';
|
||||
40
node_modules/googleapis-common/build/src/index.js
generated
vendored
Normal file
40
node_modules/googleapis-common/build/src/index.js
generated
vendored
Normal file
@@ -0,0 +1,40 @@
|
||||
"use strict";
|
||||
// Copyright 2020 Google LLC
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.Endpoint = exports.Discovery = exports.AuthPlus = exports.createAPIRequest = exports.getAPI = exports.GaxiosError = exports.Gaxios = exports.AwsClient = exports.IdentityPoolClient = exports.BaseExternalAccountClient = exports.ExternalAccountClient = exports.GoogleAuth = exports.DefaultTransporter = exports.UserRefreshClient = exports.Compute = exports.JWT = exports.OAuth2Client = void 0;
|
||||
var google_auth_library_1 = require("google-auth-library");
|
||||
Object.defineProperty(exports, "OAuth2Client", { enumerable: true, get: function () { return google_auth_library_1.OAuth2Client; } });
|
||||
Object.defineProperty(exports, "JWT", { enumerable: true, get: function () { return google_auth_library_1.JWT; } });
|
||||
Object.defineProperty(exports, "Compute", { enumerable: true, get: function () { return google_auth_library_1.Compute; } });
|
||||
Object.defineProperty(exports, "UserRefreshClient", { enumerable: true, get: function () { return google_auth_library_1.UserRefreshClient; } });
|
||||
Object.defineProperty(exports, "DefaultTransporter", { enumerable: true, get: function () { return google_auth_library_1.DefaultTransporter; } });
|
||||
Object.defineProperty(exports, "GoogleAuth", { enumerable: true, get: function () { return google_auth_library_1.GoogleAuth; } });
|
||||
Object.defineProperty(exports, "ExternalAccountClient", { enumerable: true, get: function () { return google_auth_library_1.ExternalAccountClient; } });
|
||||
Object.defineProperty(exports, "BaseExternalAccountClient", { enumerable: true, get: function () { return google_auth_library_1.BaseExternalAccountClient; } });
|
||||
Object.defineProperty(exports, "IdentityPoolClient", { enumerable: true, get: function () { return google_auth_library_1.IdentityPoolClient; } });
|
||||
Object.defineProperty(exports, "AwsClient", { enumerable: true, get: function () { return google_auth_library_1.AwsClient; } });
|
||||
var gaxios_1 = require("gaxios");
|
||||
Object.defineProperty(exports, "Gaxios", { enumerable: true, get: function () { return gaxios_1.Gaxios; } });
|
||||
Object.defineProperty(exports, "GaxiosError", { enumerable: true, get: function () { return gaxios_1.GaxiosError; } });
|
||||
var apiIndex_1 = require("./apiIndex");
|
||||
Object.defineProperty(exports, "getAPI", { enumerable: true, get: function () { return apiIndex_1.getAPI; } });
|
||||
var apirequest_1 = require("./apirequest");
|
||||
Object.defineProperty(exports, "createAPIRequest", { enumerable: true, get: function () { return apirequest_1.createAPIRequest; } });
|
||||
var authplus_1 = require("./authplus");
|
||||
Object.defineProperty(exports, "AuthPlus", { enumerable: true, get: function () { return authplus_1.AuthPlus; } });
|
||||
var discovery_1 = require("./discovery");
|
||||
Object.defineProperty(exports, "Discovery", { enumerable: true, get: function () { return discovery_1.Discovery; } });
|
||||
var endpoint_1 = require("./endpoint");
|
||||
Object.defineProperty(exports, "Endpoint", { enumerable: true, get: function () { return endpoint_1.Endpoint; } });
|
||||
//# sourceMappingURL=index.js.map
|
||||
1
node_modules/googleapis-common/build/src/isbrowser.d.ts
generated
vendored
Normal file
1
node_modules/googleapis-common/build/src/isbrowser.d.ts
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
export declare function isBrowser(): boolean;
|
||||
20
node_modules/googleapis-common/build/src/isbrowser.js
generated
vendored
Normal file
20
node_modules/googleapis-common/build/src/isbrowser.js
generated
vendored
Normal file
@@ -0,0 +1,20 @@
|
||||
"use strict";
|
||||
// Copyright 2020 Google LLC
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.isBrowser = void 0;
|
||||
function isBrowser() {
|
||||
return typeof window !== 'undefined';
|
||||
}
|
||||
exports.isBrowser = isBrowser;
|
||||
//# sourceMappingURL=isbrowser.js.map
|
||||
127
node_modules/googleapis-common/build/src/schema.d.ts
generated
vendored
Normal file
127
node_modules/googleapis-common/build/src/schema.d.ts
generated
vendored
Normal file
@@ -0,0 +1,127 @@
|
||||
/**
|
||||
* These are a collection of interfaces that represent the GoogleApis
|
||||
* Discovery json formats.
|
||||
*/
|
||||
export interface Schemas {
|
||||
discoveryVersion: string;
|
||||
kind: string;
|
||||
items: Schema[];
|
||||
}
|
||||
export interface Schema {
|
||||
auth: {
|
||||
oauth2: {
|
||||
scopes: {
|
||||
[index: string]: {
|
||||
description: string;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
basePath: string;
|
||||
baseUrl: string;
|
||||
batchPath: string;
|
||||
description: string;
|
||||
discoveryVersion: string;
|
||||
discoveryRestUrl: string;
|
||||
documentationLink: string;
|
||||
etag: string;
|
||||
icons: {
|
||||
x16: string;
|
||||
x32: string;
|
||||
};
|
||||
id: string;
|
||||
kind: string;
|
||||
methods: SchemaMethods;
|
||||
name: string;
|
||||
ownerDomain: string;
|
||||
ownerName: string;
|
||||
parameters: SchemaParameters;
|
||||
protocol: string;
|
||||
resources: SchemaResources;
|
||||
revision: string;
|
||||
rootUrl: string;
|
||||
schemas: SchemaItems;
|
||||
servicePath: string;
|
||||
title: string;
|
||||
version: string;
|
||||
}
|
||||
export interface SchemaResources {
|
||||
[index: string]: SchemaResource;
|
||||
}
|
||||
export interface SchemaResource {
|
||||
methods?: SchemaMethods;
|
||||
resources?: SchemaResources;
|
||||
}
|
||||
export interface SchemaItems {
|
||||
[index: string]: SchemaItem;
|
||||
}
|
||||
export interface SchemaItem {
|
||||
description?: string;
|
||||
default?: string;
|
||||
id?: string;
|
||||
properties?: {
|
||||
[index: string]: SchemaItem;
|
||||
};
|
||||
additionalProperties?: {
|
||||
[index: string]: SchemaItem;
|
||||
};
|
||||
items?: {
|
||||
[index: string]: SchemaItem;
|
||||
};
|
||||
type?: SchemaType;
|
||||
format?: ParameterFormat;
|
||||
$ref?: string;
|
||||
}
|
||||
export interface SchemaParameters {
|
||||
[index: string]: SchemaParameter;
|
||||
}
|
||||
export interface SchemaParameter {
|
||||
default: string;
|
||||
description: string;
|
||||
location: string;
|
||||
enum: string[];
|
||||
enumDescription: string[];
|
||||
type: SchemaType;
|
||||
format: ParameterFormat;
|
||||
required: boolean;
|
||||
}
|
||||
export interface SchemaMethods {
|
||||
[index: string]: SchemaMethod;
|
||||
}
|
||||
export interface SchemaMethod {
|
||||
description: string;
|
||||
httpMethod: HttpMethod;
|
||||
id: string;
|
||||
parameterOrder?: string[];
|
||||
parameters?: {
|
||||
[index: string]: SchemaParameter;
|
||||
};
|
||||
path: string;
|
||||
request: {
|
||||
$ref: string;
|
||||
};
|
||||
response: {
|
||||
$ref: string;
|
||||
};
|
||||
sampleUrl: string;
|
||||
scopes: string[];
|
||||
fragment: string;
|
||||
mediaUpload: {
|
||||
protocols: {
|
||||
simple: {
|
||||
path: string;
|
||||
};
|
||||
};
|
||||
};
|
||||
supportsMediaDownload?: boolean;
|
||||
}
|
||||
export interface FragmentResponse {
|
||||
codeFragment: {
|
||||
[index: string]: {
|
||||
fragment: string;
|
||||
};
|
||||
};
|
||||
}
|
||||
export declare type ParameterFormat = 'int32';
|
||||
export declare type HttpMethod = 'GET' | 'PATCH' | 'PUT';
|
||||
export declare type SchemaType = 'object' | 'integer' | 'string' | 'array' | 'boolean';
|
||||
19
node_modules/googleapis-common/build/src/schema.js
generated
vendored
Normal file
19
node_modules/googleapis-common/build/src/schema.js
generated
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
"use strict";
|
||||
// Copyright 2020 Google LLC
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
/**
|
||||
* These are a collection of interfaces that represent the GoogleApis
|
||||
* Discovery json formats.
|
||||
*/
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
//# sourceMappingURL=schema.js.map
|
||||
90
node_modules/googleapis-common/package.json
generated
vendored
Normal file
90
node_modules/googleapis-common/package.json
generated
vendored
Normal file
@@ -0,0 +1,90 @@
|
||||
{
|
||||
"name": "googleapis-common",
|
||||
"version": "6.0.3",
|
||||
"description": "A common tooling library used by the googleapis npm module. You probably don't want to use this directly.",
|
||||
"repository": "googleapis/nodejs-googleapis-common",
|
||||
"main": "build/src/index.js",
|
||||
"types": "build/src/index.d.ts",
|
||||
"files": [
|
||||
"build/src",
|
||||
"!build/src/**/*.map"
|
||||
],
|
||||
"scripts": {
|
||||
"prebenchmark": "npm run compile",
|
||||
"benchmark": "node build/benchmark/bench.js",
|
||||
"compile": "tsc -p .",
|
||||
"test": "c8 mocha build/test",
|
||||
"system-test": "c8 mocha build/system-test --timeout 600000",
|
||||
"presystem-test": "npm run compile",
|
||||
"fix": "gts fix",
|
||||
"prepare": "npm run compile",
|
||||
"pretest": "npm run compile",
|
||||
"lint": "gts check",
|
||||
"samples-test": "mocha build/samples-test",
|
||||
"docs": "compodoc src/",
|
||||
"webpack": "webpack",
|
||||
"browser-test": "karma start",
|
||||
"docs-test": "linkinator docs",
|
||||
"predocs-test": "npm run docs",
|
||||
"prelint": "cd samples; npm link ../; npm install",
|
||||
"clean": "gts clean",
|
||||
"precompile": "gts clean"
|
||||
},
|
||||
"keywords": [],
|
||||
"author": "Google LLC",
|
||||
"license": "Apache-2.0",
|
||||
"dependencies": {
|
||||
"extend": "^3.0.2",
|
||||
"gaxios": "^5.0.1",
|
||||
"google-auth-library": "^8.0.2",
|
||||
"qs": "^6.7.0",
|
||||
"url-template": "^2.0.8",
|
||||
"uuid": "^9.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@compodoc/compodoc": "^1.1.9",
|
||||
"@types/execa": "^0.9.0",
|
||||
"@types/extend": "^3.0.1",
|
||||
"@types/mocha": "^9.0.0",
|
||||
"@types/mv": "^2.1.0",
|
||||
"@types/ncp": "^2.0.1",
|
||||
"@types/nock": "^10.0.3",
|
||||
"@types/proxyquire": "^1.3.28",
|
||||
"@types/qs": "^6.5.3",
|
||||
"@types/sinon": "^10.0.0",
|
||||
"@types/tmp": "0.2.3",
|
||||
"@types/url-template": "^2.0.28",
|
||||
"@types/uuid": "^8.0.0",
|
||||
"c8": "^7.0.0",
|
||||
"codecov": "^3.5.0",
|
||||
"execa": "^5.0.0",
|
||||
"gts": "^3.1.0",
|
||||
"http2spy": "^2.0.0",
|
||||
"is-docker": "^2.0.0",
|
||||
"karma": "^6.0.0",
|
||||
"karma-chrome-launcher": "^3.0.0",
|
||||
"karma-coverage": "^2.0.0",
|
||||
"karma-firefox-launcher": "^2.0.0",
|
||||
"karma-mocha": "^2.0.0",
|
||||
"karma-remap-coverage": "^0.1.5",
|
||||
"karma-sourcemap-loader": "^0.3.7",
|
||||
"karma-webpack": "^5.0.0",
|
||||
"linkinator": "^4.0.0",
|
||||
"mocha": "^9.2.2",
|
||||
"mv": "^2.1.1",
|
||||
"ncp": "^2.0.0",
|
||||
"nock": "^13.0.0",
|
||||
"null-loader": "^4.0.0",
|
||||
"proxyquire": "^2.1.3",
|
||||
"puppeteer": "^17.0.0",
|
||||
"sinon": "^14.0.0",
|
||||
"tmp": "^0.2.0",
|
||||
"ts-loader": "^8.0.0",
|
||||
"typescript": "^4.6.4",
|
||||
"webpack": "^5.30.0",
|
||||
"webpack-cli": "^4.0.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=12.0.0"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user