File size: 315 Bytes
1e92f2d |
1 2 3 4 5 6 7 8 9 10 11 12 13 |
export default async function getUser(token: string) {
const response = await fetch(
`https://${process.env.NEXT_PUBLIC_AUTH0_DOMAIN}/userinfo`,
{
headers: {
Authorization: `Bearer ${token}`,
"Content-Type": "application/json",
},
},
);
return await response.json();
}
|