From 4d4ff5f2ac28726e5751318643582efdc43cb17c Mon Sep 17 00:00:00 2001 From: averikitsch Date: Fri, 16 Oct 2020 10:03:17 -0700 Subject: [PATCH] feat(userAgent): allow for optional user agent to be provided --- src/storage.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/storage.ts b/src/storage.ts index 50bdd5586..aafd9ff1a 100644 --- a/src/storage.ts +++ b/src/storage.ts @@ -49,6 +49,7 @@ export interface StorageOptions extends GoogleAuthOptions { autoRetry?: boolean; maxRetries?: number; promise?: typeof Promise; + userAgent?: string; /** * The API endpoint of the service used to make requests. * Defaults to `storage.googleapis.com`. @@ -370,6 +371,8 @@ export class Storage extends Service { * attempted before returning the error. * @property {Constructor} [promise] Custom promise module to use instead of * native Promises. + * @property {string} [userAgent] The value to be prepended to the User-Agent + * header in API requests. */ /** * Constructs the Storage client.