MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / jwtPart

Function jwtPart

packages/core/sdk/src/oauth-helpers.test.ts:91–92  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

89const validRefreshBody = { access_token: "tok2", token_type: "Bearer", expires_in: 3600 };
90
91const jwtPart = (value: unknown): string =>
92 Buffer.from(JSON.stringify(value)).toString("base64url");
93
94const unsignedJwt = (claims: Record<string, unknown>, alg = "RS256"): string =>
95 `${jwtPart({ alg, typ: "JWT" })}.${jwtPart(claims)}.sig`;

Callers 1

unsignedJwtFunction · 0.70

Calls 1

toStringMethod · 0.80

Tested by

no test coverage detected