This commit is contained in:
AdisakKanthawilang 2024-08-09 14:17:24 +07:00
parent 8e82201fbd
commit 1736f5043e
7 changed files with 147 additions and 30 deletions

13
src/middlewares/user.ts Normal file
View file

@ -0,0 +1,13 @@
import type { Request } from "express";
export type RequestWithUser = Request & {
user: {
sub: string;
name: string;
given_name: string;
familiy_name: string;
preferred_username: string;
email: string;
role: string[];
};
};