mirror of
https://github.com/fosrl/pangolin.git
synced 2026-03-06 10:46:38 +00:00
basic invite user functional
This commit is contained in:
@@ -24,6 +24,8 @@ const inviteUserBodySchema = z.object({
|
||||
validHours: z.number().gt(0).lte(168),
|
||||
});
|
||||
|
||||
export type InviteUserBody = z.infer<typeof inviteUserBodySchema>;
|
||||
|
||||
export type InviteUserResponse = {
|
||||
inviteLink: string;
|
||||
expiresAt: number;
|
||||
@@ -112,7 +114,7 @@ export async function inviteUser(
|
||||
roleId,
|
||||
});
|
||||
|
||||
const inviteLink = `${config.app.base_url}/invite/${inviteId}-${token}`;
|
||||
const inviteLink = `${config.app.base_url}/invite?token=${inviteId}-${token}`;
|
||||
|
||||
return response<InviteUserResponse>(res, {
|
||||
data: {
|
||||
|
||||
Reference in New Issue
Block a user