* revert: "fix: Request permissions to allow events to be created on shared Office365/Outlook calendars (#17760)" This reverts commit1680cba5a5. * plain.com card * detiled error handling for get customer * working email and id * hmac * Revert "fix: correct line-breaks in calendar event description (#18077)" This reverts commit06494a6999. * pr changes requet * remove pan for now * add-new-implementation-for-early-review * Pushing fix for createHmac stringify * added validation and user repository for email check * add apiRouteMiddleware which handles the error handling * HMAC_SECRET_KEY -> PLAIN_HMAC_SECRET_KEY * Use the right error * Convey right error to consumer * Fixup apiRouteMiddleware to handle handler * Don't export handler, only export POST * changed to app directory * working unkown user card --------- Co-authored-by: Keith Williams <keithwillcode@gmail.com> Co-authored-by: Omar López <zomars@me.com> Co-authored-by: Alex van Andel <me@alexvanandel.com>
16 lines
404 B
TypeScript
16 lines
404 B
TypeScript
import { z } from "zod";
|
|
|
|
import { Component } from "./components";
|
|
|
|
export const Card = z.object({
|
|
key: z.string(),
|
|
timeToLiveSeconds: z.number().int().min(0).nullish().default(null),
|
|
components: z.array(Component).nullable(),
|
|
});
|
|
export type Card = z.infer<typeof Card>;
|
|
|
|
export const ResponseBody = z.object({
|
|
cards: z.array(Card),
|
|
});
|
|
export type ResponseBody = z.infer<typeof ResponseBody>;
|