import { z } from "zod";

export const snsEnvelopeSchema = z.object({
  Type: z.enum(["SubscriptionConfirmation", "Notification", "UnsubscribeConfirmation"]),
  MessageId: z.string(),
  TopicArn: z.string(),
  Message: z.string(),
  SubscribeURL: z.string().url().optional(),
  Signature: z.string(),
  SigningCertURL: z.string().url(),
  Timestamp: z.string(),
});

export type SnsEnvelope = z.infer<typeof snsEnvelopeSchema>;
