We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 56be052 commit 23dded7Copy full SHA for 23dded7
lib/utils/token/getClaim.ts
@@ -5,9 +5,9 @@ import { getClaims } from "./getClaims";
5
*
6
* @param keyName key to get from the token
7
* @param {("accessToken"|"idToken")} [tokenType="accessToken"] - Type of token to get claims from
8
- * @returns { Promise<string | number | string[] | null> }
+ * @returns { Promise<string | number | string[] | { id: string; name: string }[] | null> }
9
*/
10
-export const getClaim = async <T = JWTDecoded, V = string | number | string[]>(
+export const getClaim = async <T = JWTDecoded, V = string | number | string[] | { id: string; name: string }[]>(
11
keyName: keyof T,
12
tokenType: "accessToken" | "idToken" = "accessToken",
13
): Promise<{
0 commit comments