Update service-token-router.ts

This commit is contained in:
Daniel Hougaard
2024-01-29 16:53:32 +04:00
parent 8ade2f3758
commit e78b14c6ec

View File

@@ -25,7 +25,12 @@ export const registerServiceTokenRouter = async (server: FastifyZodProvider) =>
200: ServiceTokensSchema.merge(
z.object({
workspace: z.string(),
user: sanitizedServiceTokenUserSchema,
user: sanitizedServiceTokenUserSchema.merge(
z.object({
_id: z.string(),
__v: z.number().default(0)
})
),
_id: z.string(),
__v: z.number().default(0)
})