Skip to content

Commit

Permalink
feat(clerk-sdk-node): Enable CLERK_JWT_KEY usage from clerk-sdk-node
Browse files Browse the repository at this point in the history
  • Loading branch information
igneel64 committed Mar 21, 2022
1 parent ef04974 commit 6151101
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/sdk-node/src/Clerk.ts
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ export default class Clerk extends ClerkBackendAPI {
this._jwksClient = jwks({
jwksUri: `${serverApiUrl}/${apiVersion}/jwks`,
requestHeaders: {
Authorization: `Bearer ${defaultApiKey}`,
Authorization: `Bearer ${apiKey}`,
},
timeout: 5000,
cache: true,
Expand Down Expand Up @@ -158,11 +158,12 @@ export default class Clerk extends ClerkBackendAPI {

/** Base initialization */

// TODO: More comprehensive base initialization
this.base = new Base(
importKey,
verifySignature,
decodeBase64,
loadCryptoKey
process.env.CLERK_JWT_KEY ? undefined : loadCryptoKey
);
}

Expand Down

0 comments on commit 6151101

Please sign in to comment.