You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"The MUX_TOKEN_ID environment variable is missing or empty; either provide it, or instantiate the Mux client with an tokenId option, like new Mux({ tokenId: 'my token id' }).",
146
-
);
147
-
}
148
-
if(tokenSecret===undefined){
149
-
thrownewErrors.MuxError(
150
-
"The MUX_TOKEN_SECRET environment variable is missing or empty; either provide it, or instantiate the Mux client with an tokenSecret option, like new Mux({ tokenSecret: 'my secret' }).",
151
-
);
152
-
}
153
-
154
151
constoptions: ClientOptions={
155
152
tokenId,
156
153
tokenSecret,
157
154
webhookSecret,
158
155
jwtSigningKey,
159
156
jwtPrivateKey,
157
+
authorizationToken,
160
158
...opts,
161
159
baseURL: baseURL||`https://api.mux.com`,
162
160
};
@@ -177,6 +175,7 @@ export class Mux extends Core.APIClient {
177
175
this.webhookSecret=webhookSecret;
178
176
this.jwtSigningKey=jwtSigningKey;
179
177
this.jwtPrivateKey=jwtPrivateKey;
178
+
this.authorizationToken=authorizationToken;
180
179
}
181
180
182
181
video: API.Video=newAPI.Video(this);
@@ -203,7 +202,34 @@ export class Mux extends Core.APIClient {
'Could not resolve authentication method. Expected either tokenId, tokenSecret or authorizationToken to be set. Or for one of the "Authorization" or "Authorization" headers to be explicitly omitted',
0 commit comments