@samva/webhooks 0.51.0 → 0.53.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -34,7 +34,7 @@ const validate426 = (value) => isObject(value) && isObject(value) && Object.hasO
34
34
  const validate427 = (value) => typeof value === "string" && value === "message.complained";
35
35
  const validate508 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate509(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate511(value["data"]));
36
36
  const validate509 = (value) => typeof value === "string" && value === "message.received";
37
- const validate511 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "channel") && Object.hasOwn(value, "disposition") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "organizationId") && (!Object.hasOwn(value, "mailboxId") || validate4(value["mailboxId"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "status") || validate8(value["status"])) && (!Object.hasOwn(value, "metadata") || validate11(value["metadata"])) && (!Object.hasOwn(value, "cost") || validate14(value["cost"])) && (!Object.hasOwn(value, "recipient") || validate8(value["recipient"])) && (!Object.hasOwn(value, "occurredAt") || validate8(value["occurredAt"])) && (!Object.hasOwn(value, "failureReason") || validate8(value["failureReason"])) && (!Object.hasOwn(value, "errorCode") || validate8(value["errorCode"])) && (!Object.hasOwn(value, "conversationId") || validate8(value["conversationId"])) && (!Object.hasOwn(value, "isBillable") || validate32(value["isBillable"])) && (!Object.hasOwn(value, "messageType") || validate8(value["messageType"])) && (!Object.hasOwn(value, "templateCategory") || validate38(value["templateCategory"])) && (!Object.hasOwn(value, "subject") || validate8(value["subject"])) && (!Object.hasOwn(value, "toEmails") || validate44(value["toEmails"])) && (!Object.hasOwn(value, "providerMessageId") || validate8(value["providerMessageId"])) && (!Object.hasOwn(value, "waId") || validate8(value["waId"])) && (!Object.hasOwn(value, "hasAttachments") || validate32(value["hasAttachments"])) && (!Object.hasOwn(value, "isAutoReply") || validate32(value["isAutoReply"])) && (!Object.hasOwn(value, "segments") || validate14(value["segments"])) && (!Object.hasOwn(value, "to") || validate8(value["to"])) && (!Object.hasOwn(value, "from") || validate8(value["from"])) && (!Object.hasOwn(value, "body") || validate8(value["body"])) && (!Object.hasOwn(value, "direction") || validate72(value["direction"])) && (!Object.hasOwn(value, "errorMessage") || validate8(value["errorMessage"])) && (!Object.hasOwn(value, "parts") || validate14(value["parts"])) && (!Object.hasOwn(value, "carrier") || validate8(value["carrier"])) && (!Object.hasOwn(value, "disposition") || validate592(value["disposition"])) && (!Object.hasOwn(value, "reason") || validate593(value["reason"])) && (!Object.hasOwn(value, "campaign") || validate596(value["campaign"])) && (!Object.hasOwn(value, "whatsapp") || validate601(value["whatsapp"])) && (!Object.hasOwn(value, "messageId") || validate2(value["messageId"])) && (!Object.hasOwn(value, "organizationId") || validate2(value["organizationId"]));
37
+ const validate511 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "channel") && Object.hasOwn(value, "disposition") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "organizationId") && (!Object.hasOwn(value, "mailboxId") || validate4(value["mailboxId"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "status") || validate8(value["status"])) && (!Object.hasOwn(value, "metadata") || validate11(value["metadata"])) && (!Object.hasOwn(value, "cost") || validate14(value["cost"])) && (!Object.hasOwn(value, "recipient") || validate8(value["recipient"])) && (!Object.hasOwn(value, "occurredAt") || validate8(value["occurredAt"])) && (!Object.hasOwn(value, "failureReason") || validate8(value["failureReason"])) && (!Object.hasOwn(value, "errorCode") || validate8(value["errorCode"])) && (!Object.hasOwn(value, "conversationId") || validate8(value["conversationId"])) && (!Object.hasOwn(value, "isBillable") || validate32(value["isBillable"])) && (!Object.hasOwn(value, "messageType") || validate8(value["messageType"])) && (!Object.hasOwn(value, "templateCategory") || validate38(value["templateCategory"])) && (!Object.hasOwn(value, "subject") || validate8(value["subject"])) && (!Object.hasOwn(value, "toEmails") || validate44(value["toEmails"])) && (!Object.hasOwn(value, "providerMessageId") || validate8(value["providerMessageId"])) && (!Object.hasOwn(value, "waId") || validate8(value["waId"])) && (!Object.hasOwn(value, "hasAttachments") || validate32(value["hasAttachments"])) && (!Object.hasOwn(value, "isAutoReply") || validate32(value["isAutoReply"])) && (!Object.hasOwn(value, "segments") || validate14(value["segments"])) && (!Object.hasOwn(value, "to") || validate8(value["to"])) && (!Object.hasOwn(value, "from") || validate8(value["from"])) && (!Object.hasOwn(value, "body") || validate8(value["body"])) && (!Object.hasOwn(value, "direction") || validate72(value["direction"])) && (!Object.hasOwn(value, "errorMessage") || validate8(value["errorMessage"])) && (!Object.hasOwn(value, "parts") || validate14(value["parts"])) && (!Object.hasOwn(value, "carrier") || validate8(value["carrier"])) && (!Object.hasOwn(value, "disposition") || validate592(value["disposition"])) && (!Object.hasOwn(value, "reason") || validate593(value["reason"])) && (!Object.hasOwn(value, "campaign") || validate596(value["campaign"])) && (!Object.hasOwn(value, "replyToMetadata") || validate12(value["replyToMetadata"])) && (!Object.hasOwn(value, "whatsapp") || validate602(value["whatsapp"])) && (!Object.hasOwn(value, "messageId") || validate2(value["messageId"])) && (!Object.hasOwn(value, "organizationId") || validate2(value["organizationId"]));
38
38
  const validate592 = (value) => typeof value === "string" && (value === "delivered" || value === "quarantined" || value === "isolated");
39
39
  const validate593 = (value) => validate594(value) || validate6(value);
40
40
  const validate594 = (value) => typeof value === "string" && (value === "spam" || value === "dmarc" || value === "virus" || value === "virus_unscanned" || value === "verdict_missing" || value === "phishing" || value === "fraud" || value === "prompt_injection");
@@ -42,320 +42,322 @@ const validate596 = (value) => validate597(value) || validate6(value);
42
42
  const validate597 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "campaignId") && Object.hasOwn(value, "runId") && (!Object.hasOwn(value, "campaignId") || validate598(value["campaignId"])) && (!Object.hasOwn(value, "runId") || validate599(value["runId"]));
43
43
  const validate598 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^camp_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
44
44
  const validate599 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^crun_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
45
- const validate601 = (value) => validate602(value) || validate6(value);
46
- const validate602 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "text") || validate8(value["text"])) && (!Object.hasOwn(value, "template") || validate606(value["template"])) && (!Object.hasOwn(value, "interactive") || validate658(value["interactive"])) && (!Object.hasOwn(value, "media") || validate758(value["media"])) && (!Object.hasOwn(value, "reaction") || validate781(value["reaction"])) && (!Object.hasOwn(value, "location") || validate789(value["location"])) && (!Object.hasOwn(value, "contacts") || validate795(value["contacts"])) && (!Object.hasOwn(value, "reply") || validate831(value["reply"])) && (!Object.hasOwn(value, "flowResponse") || validate836(value["flowResponse"])) && (!Object.hasOwn(value, "context") || validate842(value["context"]));
47
- const validate606 = (value) => validate607(value) || validate6(value);
48
- const validate607 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "name") && Object.hasOwn(value, "language") && Object.hasOwn(value, "components") && (!Object.hasOwn(value, "name") || validate2(value["name"])) && (!Object.hasOwn(value, "language") || validate2(value["language"])) && (!Object.hasOwn(value, "components") || validate610(value["components"]));
49
- const validate610 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate611);
50
- const validate611 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "parameters") && (!Object.hasOwn(value, "type") || validate612(value["type"])) && (!Object.hasOwn(value, "sub_type") || validate613(value["sub_type"])) && (!Object.hasOwn(value, "index") || validate8(value["index"])) && (!Object.hasOwn(value, "parameters") || validate619(value["parameters"]));
51
- const validate612 = (value) => typeof value === "string" && (value === "header" || value === "body" || value === "footer" || value === "button");
52
- const validate613 = (value) => validate614(value) || validate6(value);
53
- const validate614 = (value) => typeof value === "string" && (value === "url" || value === "quick_reply" || value === "copy_code" || value === "flow");
54
- const validate619 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate620);
55
- const validate620 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && (!Object.hasOwn(value, "type") || validate621(value["type"])) && (!Object.hasOwn(value, "text") || validate8(value["text"])) && (!Object.hasOwn(value, "currency") || validate625(value["currency"])) && (!Object.hasOwn(value, "date_time") || validate631(value["date_time"])) && (!Object.hasOwn(value, "image") || validate635(value["image"])) && (!Object.hasOwn(value, "document") || validate639(value["document"])) && (!Object.hasOwn(value, "video") || validate635(value["video"])) && (!Object.hasOwn(value, "coupon_code") || validate8(value["coupon_code"])) && (!Object.hasOwn(value, "action") || validate653(value["action"]));
56
- const validate621 = (value) => typeof value === "string" && (value === "text" || value === "currency" || value === "date_time" || value === "image" || value === "document" || value === "video" || value === "coupon_code" || value === "action");
57
- const validate625 = (value) => validate626(value) || validate6(value);
58
- const validate626 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "fallback_value") && Object.hasOwn(value, "code") && Object.hasOwn(value, "amount_1000") && (!Object.hasOwn(value, "fallback_value") || validate2(value["fallback_value"])) && (!Object.hasOwn(value, "code") || validate2(value["code"])) && (!Object.hasOwn(value, "amount_1000") || validate15(value["amount_1000"]));
59
- const validate631 = (value) => validate632(value) || validate6(value);
60
- const validate632 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "fallback_value") && (!Object.hasOwn(value, "fallback_value") || validate2(value["fallback_value"]));
61
- const validate635 = (value) => validate636(value) || validate6(value);
62
- const validate636 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "link") && (!Object.hasOwn(value, "link") || validate2(value["link"]));
63
- const validate639 = (value) => validate640(value) || validate6(value);
64
- const validate640 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "link") && (!Object.hasOwn(value, "link") || validate2(value["link"])) && (!Object.hasOwn(value, "filename") || validate8(value["filename"]));
65
- const validate653 = (value) => validate654(value) || validate6(value);
66
- const validate654 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "flow_token") && (!Object.hasOwn(value, "flow_token") || validate2(value["flow_token"]));
67
- const validate658 = (value) => validate659(value) || validate694(value) || validate710(value) || validate743(value);
68
- const validate659 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "body") && Object.hasOwn(value, "buttons") && (!Object.hasOwn(value, "type") || validate660(value["type"])) && (!Object.hasOwn(value, "header") || validate661(value["header"])) && (!Object.hasOwn(value, "body") || validate688(value["body"])) && (!Object.hasOwn(value, "footer") || validate664(value["footer"])) && (!Object.hasOwn(value, "buttons") || validate690(value["buttons"]));
69
- const validate660 = (value) => typeof value === "string" && value === "buttons";
70
- const validate661 = (value) => validate662(value) || validate665(value) || validate672(value) || validate679(value);
71
- const validate662 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "text") && (!Object.hasOwn(value, "type") || validate663(value["type"])) && (!Object.hasOwn(value, "text") || validate664(value["text"]));
72
- const validate663 = (value) => typeof value === "string" && value === "text";
73
- const validate664 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 60;
74
- const validate665 = (value) => validate666(value) || validate669(value);
75
- const validate666 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "url") && (!Object.hasOwn(value, "type") || validate667(value["type"])) && (!Object.hasOwn(value, "url") || validate2(value["url"]));
76
- const validate667 = (value) => typeof value === "string" && value === "image";
77
- const validate669 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "mediaId") && (!Object.hasOwn(value, "type") || validate667(value["type"])) && (!Object.hasOwn(value, "mediaId") || validate671(value["mediaId"]));
78
- const validate671 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^media_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
79
- const validate672 = (value) => validate673(value) || validate676(value);
80
- const validate673 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "url") && (!Object.hasOwn(value, "type") || validate674(value["type"])) && (!Object.hasOwn(value, "url") || validate2(value["url"]));
81
- const validate674 = (value) => typeof value === "string" && value === "video";
82
- const validate676 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "mediaId") && (!Object.hasOwn(value, "type") || validate674(value["type"])) && (!Object.hasOwn(value, "mediaId") || validate671(value["mediaId"]));
83
- const validate679 = (value) => validate680(value) || validate684(value);
84
- const validate680 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "url") && (!Object.hasOwn(value, "type") || validate681(value["type"])) && (!Object.hasOwn(value, "filename") || validate682(value["filename"])) && (!Object.hasOwn(value, "url") || validate2(value["url"]));
85
- const validate681 = (value) => typeof value === "string" && value === "document";
86
- const validate682 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 255;
87
- const validate684 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "mediaId") && (!Object.hasOwn(value, "type") || validate681(value["type"])) && (!Object.hasOwn(value, "filename") || validate682(value["filename"])) && (!Object.hasOwn(value, "mediaId") || validate671(value["mediaId"]));
88
- const validate688 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 1024;
89
- const validate690 = (value) => Array.isArray(value) && Array.isArray(value) && value.length >= 1 && Array.isArray(value) && value.length <= 3 && Array.isArray(value) && value.every(validate691);
90
- const validate691 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "title") && (!Object.hasOwn(value, "id") || validate692(value["id"])) && (!Object.hasOwn(value, "title") || validate693(value["title"]));
91
- const validate692 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 256;
92
- const validate693 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 20;
93
- const validate694 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "body") && Object.hasOwn(value, "button") && Object.hasOwn(value, "sections") && (!Object.hasOwn(value, "type") || validate695(value["type"])) && (!Object.hasOwn(value, "header") || validate662(value["header"])) && (!Object.hasOwn(value, "body") || validate699(value["body"])) && (!Object.hasOwn(value, "footer") || validate664(value["footer"])) && (!Object.hasOwn(value, "button") || validate693(value["button"])) && (!Object.hasOwn(value, "sections") || validate702(value["sections"]));
94
- const validate695 = (value) => typeof value === "string" && value === "list";
95
- const validate699 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 4096;
96
- const validate702 = (value) => Array.isArray(value) && Array.isArray(value) && value.length >= 1 && Array.isArray(value) && value.length <= 10 && Array.isArray(value) && value.every(validate703);
97
- const validate703 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "rows") && (!Object.hasOwn(value, "title") || validate704(value["title"])) && (!Object.hasOwn(value, "rows") || validate705(value["rows"]));
98
- const validate704 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 24;
99
- const validate705 = (value) => Array.isArray(value) && Array.isArray(value) && value.length >= 1 && Array.isArray(value) && value.every(validate706);
100
- const validate706 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "title") && (!Object.hasOwn(value, "id") || validate707(value["id"])) && (!Object.hasOwn(value, "title") || validate704(value["title"])) && (!Object.hasOwn(value, "description") || validate709(value["description"]));
101
- const validate707 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 200;
102
- const validate709 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 72;
103
- const validate710 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "body") && Object.hasOwn(value, "displayText") && Object.hasOwn(value, "url") && (!Object.hasOwn(value, "type") || validate711(value["type"])) && (!Object.hasOwn(value, "header") || validate661(value["header"])) && (!Object.hasOwn(value, "body") || validate688(value["body"])) && (!Object.hasOwn(value, "footer") || validate664(value["footer"])) && (!Object.hasOwn(value, "displayText") || validate693(value["displayText"])) && (!Object.hasOwn(value, "url") || validate2(value["url"]));
104
- const validate711 = (value) => typeof value === "string" && value === "cta_url";
105
- const validate743 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "body") && Object.hasOwn(value, "flowId") && Object.hasOwn(value, "cta") && Object.hasOwn(value, "flowVersionId") && Object.hasOwn(value, "providerFlowId") && (!Object.hasOwn(value, "type") || validate744(value["type"])) && (!Object.hasOwn(value, "header") || validate662(value["header"])) && (!Object.hasOwn(value, "body") || validate688(value["body"])) && (!Object.hasOwn(value, "footer") || validate664(value["footer"])) && (!Object.hasOwn(value, "flowId") || validate750(value["flowId"])) && (!Object.hasOwn(value, "cta") || validate751(value["cta"])) && (!Object.hasOwn(value, "token") || validate688(value["token"])) && (!Object.hasOwn(value, "action") || validate753(value["action"])) && (!Object.hasOwn(value, "screen") || validate754(value["screen"])) && (!Object.hasOwn(value, "data") || validate12(value["data"])) && (!Object.hasOwn(value, "flowVersionId") || validate756(value["flowVersionId"])) && (!Object.hasOwn(value, "providerFlowId") || validate2(value["providerFlowId"]));
106
- const validate744 = (value) => typeof value === "string" && value === "flow";
107
- const validate750 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^waflow_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
108
- const validate751 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 30;
109
- const validate753 = (value) => typeof value === "string" && (value === "navigate" || value === "data_exchange");
110
- const validate754 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^[A-Za-z_]{1,100}$", "u")).test(value);
111
- const validate756 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^wafver_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
112
- const validate758 = (value) => validate759(value) || validate6(value);
113
- const validate759 = (value) => validate760(value) || validate765(value) || validate770(value);
114
- const validate760 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "url") && (!Object.hasOwn(value, "type") || validate761(value["type"])) && (!Object.hasOwn(value, "url") || validate2(value["url"])) && (!Object.hasOwn(value, "caption") || validate2(value["caption"])) && (!Object.hasOwn(value, "filename") || validate2(value["filename"]));
115
- const validate761 = (value) => typeof value === "string" && (value === "image" || value === "video" || value === "audio" || value === "document" || value === "sticker");
116
- const validate765 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "mediaId") && (!Object.hasOwn(value, "type") || validate761(value["type"])) && (!Object.hasOwn(value, "mediaId") || validate671(value["mediaId"])) && (!Object.hasOwn(value, "caption") || validate2(value["caption"])) && (!Object.hasOwn(value, "filename") || validate2(value["filename"]));
117
- const validate770 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "providerMediaId") && (!Object.hasOwn(value, "type") || validate761(value["type"])) && (!Object.hasOwn(value, "providerMediaId") || validate2(value["providerMediaId"])) && (!Object.hasOwn(value, "mimeType") || validate8(value["mimeType"])) && (!Object.hasOwn(value, "caption") || validate8(value["caption"])) && (!Object.hasOwn(value, "filename") || validate2(value["filename"]));
118
- const validate781 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "providerMessageId") && Object.hasOwn(value, "emoji") && (!Object.hasOwn(value, "messageId") || validate782(value["messageId"])) && (!Object.hasOwn(value, "providerMessageId") || validate2(value["providerMessageId"])) && (!Object.hasOwn(value, "emoji") || validate8(value["emoji"]));
119
- const validate782 = (value) => validate783(value) || validate6(value);
120
- const validate783 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^msg_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
121
- const validate789 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "latitude") && Object.hasOwn(value, "longitude") && (!Object.hasOwn(value, "latitude") || validate15(value["latitude"])) && (!Object.hasOwn(value, "longitude") || validate15(value["longitude"])) && (!Object.hasOwn(value, "name") || validate2(value["name"])) && (!Object.hasOwn(value, "address") || validate2(value["address"])) && (!Object.hasOwn(value, "url") || validate2(value["url"]));
122
- const validate795 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate796);
123
- const validate796 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "name") || validate797(value["name"])) && (!Object.hasOwn(value, "phones") || validate804(value["phones"])) && (!Object.hasOwn(value, "emails") || validate809(value["emails"])) && (!Object.hasOwn(value, "urls") || validate813(value["urls"])) && (!Object.hasOwn(value, "org") || validate817(value["org"])) && (!Object.hasOwn(value, "addresses") || validate821(value["addresses"])) && (!Object.hasOwn(value, "birthday") || validate2(value["birthday"]));
124
- const validate797 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "formattedName") || validate2(value["formattedName"])) && (!Object.hasOwn(value, "firstName") || validate2(value["firstName"])) && (!Object.hasOwn(value, "lastName") || validate2(value["lastName"])) && (!Object.hasOwn(value, "middleName") || validate2(value["middleName"])) && (!Object.hasOwn(value, "prefix") || validate2(value["prefix"])) && (!Object.hasOwn(value, "suffix") || validate2(value["suffix"]));
125
- const validate804 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate805);
126
- const validate805 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "phone") || validate2(value["phone"])) && (!Object.hasOwn(value, "type") || validate2(value["type"])) && (!Object.hasOwn(value, "waId") || validate2(value["waId"]));
127
- const validate809 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate810);
128
- const validate810 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "email") || validate2(value["email"])) && (!Object.hasOwn(value, "type") || validate2(value["type"]));
129
- const validate813 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate814);
130
- const validate814 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "url") || validate2(value["url"])) && (!Object.hasOwn(value, "type") || validate2(value["type"]));
131
- const validate817 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "company") || validate2(value["company"])) && (!Object.hasOwn(value, "department") || validate2(value["department"])) && (!Object.hasOwn(value, "title") || validate2(value["title"]));
132
- const validate821 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate822);
133
- const validate822 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "street") || validate2(value["street"])) && (!Object.hasOwn(value, "city") || validate2(value["city"])) && (!Object.hasOwn(value, "state") || validate2(value["state"])) && (!Object.hasOwn(value, "zip") || validate2(value["zip"])) && (!Object.hasOwn(value, "country") || validate2(value["country"])) && (!Object.hasOwn(value, "countryCode") || validate2(value["countryCode"])) && (!Object.hasOwn(value, "type") || validate2(value["type"]));
134
- const validate831 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "id") && Object.hasOwn(value, "title") && (!Object.hasOwn(value, "type") || validate832(value["type"])) && (!Object.hasOwn(value, "id") || validate2(value["id"])) && (!Object.hasOwn(value, "title") || validate2(value["title"])) && (!Object.hasOwn(value, "description") || validate2(value["description"]));
135
- const validate832 = (value) => typeof value === "string" && (value === "button" || value === "list" || value === "template_button");
136
- const validate836 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "flowToken") && Object.hasOwn(value, "response") && (!Object.hasOwn(value, "flowToken") || validate8(value["flowToken"])) && (!Object.hasOwn(value, "response") || validate12(value["response"])) && (!Object.hasOwn(value, "body") || validate2(value["body"]));
137
- const validate842 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "providerMessageId") && (!Object.hasOwn(value, "messageId") || validate782(value["messageId"])) && (!Object.hasOwn(value, "providerMessageId") || validate2(value["providerMessageId"]));
138
- const validate850 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate851(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate853(value["data"]));
139
- const validate851 = (value) => typeof value === "string" && value === "message.opened";
140
- const validate853 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "deliveryId") && Object.hasOwn(value, "recipient") && Object.hasOwn(value, "occurredAt") && Object.hasOwn(value, "firstOpen") && Object.hasOwn(value, "machine") && Object.hasOwn(value, "machineReason") && (!Object.hasOwn(value, "messageId") || validate783(value["messageId"])) && (!Object.hasOwn(value, "organizationId") || validate855(value["organizationId"])) && (!Object.hasOwn(value, "channel") || validate856(value["channel"])) && (!Object.hasOwn(value, "deliveryId") || validate857(value["deliveryId"])) && (!Object.hasOwn(value, "recipient") || validate2(value["recipient"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"])) && (!Object.hasOwn(value, "userAgent") || validate8(value["userAgent"])) && (!Object.hasOwn(value, "ipAddress") || validate8(value["ipAddress"])) && (!Object.hasOwn(value, "firstOpen") || validate33(value["firstOpen"])) && (!Object.hasOwn(value, "machine") || validate33(value["machine"])) && (!Object.hasOwn(value, "machineReason") || validate868(value["machineReason"])) && (!Object.hasOwn(value, "country") || validate8(value["country"])) && (!Object.hasOwn(value, "city") || validate8(value["city"])) && (!Object.hasOwn(value, "asn") || validate14(value["asn"])) && (!Object.hasOwn(value, "code") || validate8(value["code"])) && (!Object.hasOwn(value, "linkIndex") || validate14(value["linkIndex"])) && (!Object.hasOwn(value, "destinationUrl") || validate8(value["destinationUrl"])) && (!Object.hasOwn(value, "metadata") || validate11(value["metadata"])) && (!Object.hasOwn(value, "campaignId") || validate892(value["campaignId"])) && (!Object.hasOwn(value, "campaignRunId") || validate895(value["campaignRunId"]));
141
- const validate855 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^org_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
142
- const validate856 = (value) => typeof value === "string" && value === "email";
143
- const validate857 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^mdel_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
144
- const validate868 = (value) => validate869(value) || validate6(value);
145
- const validate869 = (value) => typeof value === "string" && (value === "google-image-proxy" || value === "apple-mail-privacy" || value === "scanner-user-agent" || value === "scanner-asn" || value === "too-fast");
146
- const validate892 = (value) => validate598(value) || validate6(value);
147
- const validate895 = (value) => validate599(value) || validate6(value);
148
- const validate898 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate899(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate901(value["data"]));
149
- const validate899 = (value) => typeof value === "string" && value === "message.clicked";
150
- const validate901 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "deliveryId") && Object.hasOwn(value, "recipient") && Object.hasOwn(value, "occurredAt") && Object.hasOwn(value, "url") && Object.hasOwn(value, "linkTags") && Object.hasOwn(value, "firstClick") && Object.hasOwn(value, "machine") && Object.hasOwn(value, "machineReason") && (!Object.hasOwn(value, "messageId") || validate783(value["messageId"])) && (!Object.hasOwn(value, "organizationId") || validate855(value["organizationId"])) && (!Object.hasOwn(value, "channel") || validate856(value["channel"])) && (!Object.hasOwn(value, "deliveryId") || validate857(value["deliveryId"])) && (!Object.hasOwn(value, "recipient") || validate2(value["recipient"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"])) && (!Object.hasOwn(value, "userAgent") || validate8(value["userAgent"])) && (!Object.hasOwn(value, "ipAddress") || validate8(value["ipAddress"])) && (!Object.hasOwn(value, "url") || validate2(value["url"])) && (!Object.hasOwn(value, "linkTags") || validate915(value["linkTags"])) && (!Object.hasOwn(value, "firstClick") || validate33(value["firstClick"])) && (!Object.hasOwn(value, "machine") || validate33(value["machine"])) && (!Object.hasOwn(value, "machineReason") || validate868(value["machineReason"])) && (!Object.hasOwn(value, "country") || validate8(value["country"])) && (!Object.hasOwn(value, "city") || validate8(value["city"])) && (!Object.hasOwn(value, "asn") || validate14(value["asn"])) && (!Object.hasOwn(value, "code") || validate8(value["code"])) && (!Object.hasOwn(value, "linkIndex") || validate14(value["linkIndex"])) && (!Object.hasOwn(value, "destinationUrl") || validate8(value["destinationUrl"])) && (!Object.hasOwn(value, "metadata") || validate11(value["metadata"])) && (!Object.hasOwn(value, "campaignId") || validate892(value["campaignId"])) && (!Object.hasOwn(value, "campaignRunId") || validate895(value["campaignRunId"]));
151
- const validate915 = (value) => isObject(value) && isObject(value) && Object.entries(value).every(([key, item]) => validate45(item));
152
- const validate950 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate951(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate953(value["data"]));
153
- const validate951 = (value) => typeof value === "string" && value === "contact.created";
154
- const validate953 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "contactId") && Object.hasOwn(value, "status") && Object.hasOwn(value, "name") && Object.hasOwn(value, "identities") && Object.hasOwn(value, "tags") && Object.hasOwn(value, "createdAt") && Object.hasOwn(value, "updatedAt") && (!Object.hasOwn(value, "contactId") || validate954(value["contactId"])) && (!Object.hasOwn(value, "status") || validate955(value["status"])) && (!Object.hasOwn(value, "name") || validate2(value["name"])) && (!Object.hasOwn(value, "displayName") || validate957(value["displayName"])) && (!Object.hasOwn(value, "identities") || validate961(value["identities"])) && (!Object.hasOwn(value, "tags") || validate45(value["tags"])) && (!Object.hasOwn(value, "externalId") || validate957(value["externalId"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"]));
155
- const validate954 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^contact_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
156
- const validate955 = (value) => typeof value === "string" && (value === "active" || value === "paused" || value === "blocked" || value === "archived");
157
- const validate957 = (value) => validate2(value) || validate6(value) || validate6(value);
158
- const validate961 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate962);
159
- const validate962 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "identifier") && Object.hasOwn(value, "verified") && (!Object.hasOwn(value, "type") || validate963(value["type"])) && (!Object.hasOwn(value, "identifier") || validate2(value["identifier"])) && (!Object.hasOwn(value, "verified") || validate33(value["verified"]));
160
- const validate963 = (value) => typeof value === "string" && (value === "email" || value === "phone");
161
- const validate974 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate975(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate953(value["data"]));
162
- const validate975 = (value) => typeof value === "string" && value === "contact.updated";
163
- const validate998 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate999(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate953(value["data"]));
164
- const validate999 = (value) => typeof value === "string" && value === "contact.deleted";
165
- const validate1022 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1023(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1025(value["data"]));
166
- const validate1023 = (value) => typeof value === "string" && value === "contact.subscribed";
167
- const validate1025 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "contactId") && Object.hasOwn(value, "topicId") && Object.hasOwn(value, "topicName") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "source") && Object.hasOwn(value, "occurredAt") && (!Object.hasOwn(value, "organizationId") || validate855(value["organizationId"])) && (!Object.hasOwn(value, "contactId") || validate954(value["contactId"])) && (!Object.hasOwn(value, "email") || validate8(value["email"])) && (!Object.hasOwn(value, "topicId") || validate1031(value["topicId"])) && (!Object.hasOwn(value, "topicName") || validate2(value["topicName"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "consentIp") || validate8(value["consentIp"])) && (!Object.hasOwn(value, "consentSource") || validate8(value["consentSource"])) && (!Object.hasOwn(value, "source") || validate2(value["source"])) && (!Object.hasOwn(value, "formKey") || validate8(value["formKey"])) && (!Object.hasOwn(value, "page") || validate8(value["page"])) && (!Object.hasOwn(value, "referrer") || validate8(value["referrer"])) && (!Object.hasOwn(value, "messageId") || validate782(value["messageId"])) && (!Object.hasOwn(value, "campaignId") || validate892(value["campaignId"])) && (!Object.hasOwn(value, "campaignRunId") || validate895(value["campaignRunId"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"]));
168
- const validate1031 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^tpc_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
169
- const validate1060 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1061(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1025(value["data"]));
170
- const validate1061 = (value) => typeof value === "string" && value === "contact.unsubscribed";
171
- const validate1098 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1099(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1025(value["data"]));
172
- const validate1099 = (value) => typeof value === "string" && value === "contact.resubscribed";
173
- const validate1136 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1137(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1139(value["data"]));
174
- const validate1137 = (value) => typeof value === "string" && value === "contact.consent_changed";
175
- const validate1139 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "contactId") && Object.hasOwn(value, "identity") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "status") && Object.hasOwn(value, "previousStatus") && Object.hasOwn(value, "source") && Object.hasOwn(value, "capturedAt") && (!Object.hasOwn(value, "organizationId") || validate855(value["organizationId"])) && (!Object.hasOwn(value, "contactId") || validate954(value["contactId"])) && (!Object.hasOwn(value, "identity") || validate1142(value["identity"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "status") || validate1147(value["status"])) && (!Object.hasOwn(value, "previousStatus") || validate1148(value["previousStatus"])) && (!Object.hasOwn(value, "source") || validate2(value["source"])) && (!Object.hasOwn(value, "capturedAt") || validate2(value["capturedAt"]));
176
- const validate1142 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "type") && Object.hasOwn(value, "identifier") && (!Object.hasOwn(value, "id") || validate1143(value["id"])) && (!Object.hasOwn(value, "type") || validate963(value["type"])) && (!Object.hasOwn(value, "identifier") || validate2(value["identifier"]));
177
- const validate1143 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^cident_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
178
- const validate1147 = (value) => typeof value === "string" && (value === "opted_in" || value === "opted_out");
179
- const validate1148 = (value) => validate1147(value) || validate6(value);
180
- const validate1153 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1154(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1156(value["data"]));
181
- const validate1154 = (value) => typeof value === "string" && value === "conversation.created";
182
- const validate1156 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "conversationId") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "channels") && Object.hasOwn(value, "primaryChannel") && Object.hasOwn(value, "status") && Object.hasOwn(value, "createdAt") && Object.hasOwn(value, "updatedAt") && (!Object.hasOwn(value, "conversationId") || validate1157(value["conversationId"])) && (!Object.hasOwn(value, "organizationId") || validate855(value["organizationId"])) && (!Object.hasOwn(value, "title") || validate957(value["title"])) && (!Object.hasOwn(value, "channels") || validate1163(value["channels"])) && (!Object.hasOwn(value, "primaryChannel") || validate7(value["primaryChannel"])) && (!Object.hasOwn(value, "status") || validate1166(value["status"])) && (!Object.hasOwn(value, "primaryContactId") || validate1167(value["primaryContactId"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"]));
183
- const validate1157 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^conv_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
184
- const validate1163 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate7);
185
- const validate1166 = (value) => typeof value === "string" && (value === "active" || value === "waiting" || value === "resolved" || value === "escalated" || value === "archived");
186
- const validate1167 = (value) => validate954(value) || validate6(value) || validate6(value);
187
- const validate1173 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1174(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1156(value["data"]));
188
- const validate1174 = (value) => typeof value === "string" && value === "conversation.updated";
189
- const validate1193 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1194(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1156(value["data"]));
190
- const validate1194 = (value) => typeof value === "string" && value === "conversation.archived";
191
- const validate1213 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1214(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1216(value["data"]));
192
- const validate1214 = (value) => typeof value === "string" && value === "webhook.created";
193
- const validate1216 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "webhookId") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "name") && Object.hasOwn(value, "url") && Object.hasOwn(value, "eventTypes") && Object.hasOwn(value, "channels") && Object.hasOwn(value, "status") && Object.hasOwn(value, "createdAt") && Object.hasOwn(value, "updatedAt") && (!Object.hasOwn(value, "webhookId") || validate1217(value["webhookId"])) && (!Object.hasOwn(value, "organizationId") || validate855(value["organizationId"])) && (!Object.hasOwn(value, "name") || validate2(value["name"])) && (!Object.hasOwn(value, "url") || validate2(value["url"])) && (!Object.hasOwn(value, "eventTypes") || validate45(value["eventTypes"])) && (!Object.hasOwn(value, "channels") || validate44(value["channels"])) && (!Object.hasOwn(value, "status") || validate1227(value["status"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"]));
194
- const validate1217 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^wep_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
195
- const validate1227 = (value) => typeof value === "string" && (value === "active" || value === "disabled");
196
- const validate1230 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1231(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1216(value["data"]));
197
- const validate1231 = (value) => typeof value === "string" && value === "webhook.updated";
198
- const validate1247 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1248(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1216(value["data"]));
199
- const validate1248 = (value) => typeof value === "string" && value === "webhook.deleted";
200
- const validate1264 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1265(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate12(value["data"]));
201
- const validate1265 = (value) => typeof value === "string" && value === "webhook.test";
202
- const validate1268 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1269(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1271(value["data"]));
203
- const validate1269 = (value) => typeof value === "string" && value === "domain.updated";
204
- const validate1271 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "domainId") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "domain") && Object.hasOwn(value, "previousPhase") && Object.hasOwn(value, "phase") && Object.hasOwn(value, "dns") && Object.hasOwn(value, "provider") && Object.hasOwn(value, "operationId") && Object.hasOwn(value, "checkedAt") && Object.hasOwn(value, "nextCheckAt") && Object.hasOwn(value, "failure") && Object.hasOwn(value, "updatedAt") && (!Object.hasOwn(value, "domainId") || validate1272(value["domainId"])) && (!Object.hasOwn(value, "organizationId") || validate855(value["organizationId"])) && (!Object.hasOwn(value, "domain") || validate2(value["domain"])) && (!Object.hasOwn(value, "previousPhase") || validate1275(value["previousPhase"])) && (!Object.hasOwn(value, "phase") || validate1275(value["phase"])) && (!Object.hasOwn(value, "dns") || validate1277(value["dns"])) && (!Object.hasOwn(value, "provider") || validate1284(value["provider"])) && (!Object.hasOwn(value, "operationId") || validate1294(value["operationId"])) && (!Object.hasOwn(value, "checkedAt") || validate8(value["checkedAt"])) && (!Object.hasOwn(value, "nextCheckAt") || validate8(value["nextCheckAt"])) && (!Object.hasOwn(value, "failure") || validate1303(value["failure"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"]));
205
- const validate1272 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^dom_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
206
- const validate1275 = (value) => typeof value === "string" && (value === "dns-setup" || value === "provisioning" || value === "verifying" || value === "ready" || value === "degraded" || value === "failed");
207
- const validate1277 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "observed") && Object.hasOwn(value, "total") && Object.hasOwn(value, "satisfied") && Object.hasOwn(value, "missing") && Object.hasOwn(value, "mismatch") && Object.hasOwn(value, "unknown") && (!Object.hasOwn(value, "observed") || validate33(value["observed"])) && (!Object.hasOwn(value, "total") || validate1279(value["total"])) && (!Object.hasOwn(value, "satisfied") || validate1279(value["satisfied"])) && (!Object.hasOwn(value, "missing") || validate1279(value["missing"])) && (!Object.hasOwn(value, "mismatch") || validate1279(value["mismatch"])) && (!Object.hasOwn(value, "unknown") || validate1279(value["unknown"]));
208
- const validate1279 = (value) => typeof value === "number" && Number.isInteger(value) && typeof value === "number" && value >= -9007199254740991 && typeof value === "number" && value <= 9007199254740991;
209
- const validate1284 = (value) => validate1285(value) || validate6(value);
210
- const validate1285 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "identity") && (!Object.hasOwn(value, "identity") || validate1286(value["identity"])) && (!Object.hasOwn(value, "dkim") || validate1287(value["dkim"])) && (!Object.hasOwn(value, "mailFrom") || validate1287(value["mailFrom"]));
211
- const validate1286 = (value) => typeof value === "string" && (value === "pending" || value === "verified" || value === "failed" || value === "unknown");
212
- const validate1287 = (value) => validate1286(value) || validate6(value);
213
- const validate1294 = (value) => validate1295(value) || validate6(value);
214
- const validate1295 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^op_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
215
- const validate1303 = (value) => validate1304(value) || validate6(value);
216
- const validate1304 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "code") && Object.hasOwn(value, "message") && Object.hasOwn(value, "failedAt") && (!Object.hasOwn(value, "code") || validate2(value["code"])) && (!Object.hasOwn(value, "message") || validate2(value["message"])) && (!Object.hasOwn(value, "failedAt") || validate2(value["failedAt"]));
217
- const validate1310 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1311(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1313(value["data"]));
218
- const validate1311 = (value) => typeof value === "string" && value === "domain.warming.updated";
219
- const validate1313 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "domainId") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "domain") && Object.hasOwn(value, "planId") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "status") && Object.hasOwn(value, "holdReason") && Object.hasOwn(value, "batch") && Object.hasOwn(value, "updatedAt") && (!Object.hasOwn(value, "domainId") || validate2(value["domainId"])) && (!Object.hasOwn(value, "organizationId") || validate2(value["organizationId"])) && (!Object.hasOwn(value, "domain") || validate2(value["domain"])) && (!Object.hasOwn(value, "planId") || validate2(value["planId"])) && (!Object.hasOwn(value, "reason") || validate1318(value["reason"])) && (!Object.hasOwn(value, "status") || validate1319(value["status"])) && (!Object.hasOwn(value, "holdReason") || validate8(value["holdReason"])) && (!Object.hasOwn(value, "batch") || validate1323(value["batch"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"]));
220
- const validate1318 = (value) => typeof value === "string" && (value === "plan-created" || value === "policy-updated" || value === "window-opened" || value === "window-cancelled" || value === "paused" || value === "resumed" || value === "held" || value === "completed");
221
- const validate1319 = (value) => typeof value === "string" && (value === "active" || value === "paused" || value === "completed");
222
- const validate1323 = (value) => validate1324(value) || validate6(value);
223
- const validate1324 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "sequence") && Object.hasOwn(value, "startsAt") && Object.hasOwn(value, "endsAt") && Object.hasOwn(value, "allowanceRecipients") && Object.hasOwn(value, "dailyGrowthPercent") && Object.hasOwn(value, "targetDailyRecipients") && (!Object.hasOwn(value, "id") || validate2(value["id"])) && (!Object.hasOwn(value, "sequence") || validate15(value["sequence"])) && (!Object.hasOwn(value, "startsAt") || validate2(value["startsAt"])) && (!Object.hasOwn(value, "endsAt") || validate2(value["endsAt"])) && (!Object.hasOwn(value, "allowanceRecipients") || validate15(value["allowanceRecipients"])) && (!Object.hasOwn(value, "dailyGrowthPercent") || validate15(value["dailyGrowthPercent"])) && (!Object.hasOwn(value, "targetDailyRecipients") || validate15(value["targetDailyRecipients"]));
224
- const validate1334 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1335(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1337(value["data"]));
225
- const validate1335 = (value) => typeof value === "string" && value === "email.sending.paused";
226
- const validate1337 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "occurredAt") && (!Object.hasOwn(value, "organizationId") || validate855(value["organizationId"])) && (!Object.hasOwn(value, "namespaceId") || validate1339(value["namespaceId"])) && (!Object.hasOwn(value, "channel") || validate856(value["channel"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"]));
227
- const validate1339 = (value) => validate1340(value) || validate6(value);
228
- const validate1340 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^ns_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
229
- const validate1344 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1345(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1337(value["data"]));
230
- const validate1345 = (value) => typeof value === "string" && value === "email.sending.resumed";
231
- const validate1354 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1355(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1357(value["data"]));
232
- const validate1355 = (value) => typeof value === "string" && value === "template.registration.updated";
233
- const validate1357 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "templateId") && Object.hasOwn(value, "publicationId") && Object.hasOwn(value, "templateChannelVariantId") && Object.hasOwn(value, "target") && Object.hasOwn(value, "name") && Object.hasOwn(value, "language") && Object.hasOwn(value, "status") && Object.hasOwn(value, "pendingTemplateChannelVariantId") && Object.hasOwn(value, "category") && Object.hasOwn(value, "providerCategory") && Object.hasOwn(value, "providerTemplateId") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "submittedAt") && Object.hasOwn(value, "statusChangedAt") && Object.hasOwn(value, "createdAt") && Object.hasOwn(value, "updatedAt") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "previousStatus") && (!Object.hasOwn(value, "id") || validate1358(value["id"])) && (!Object.hasOwn(value, "templateId") || validate1359(value["templateId"])) && (!Object.hasOwn(value, "publicationId") || validate1360(value["publicationId"])) && (!Object.hasOwn(value, "templateChannelVariantId") || validate1361(value["templateChannelVariantId"])) && (!Object.hasOwn(value, "target") || validate1362(value["target"])) && (!Object.hasOwn(value, "name") || validate2(value["name"])) && (!Object.hasOwn(value, "language") || validate2(value["language"])) && (!Object.hasOwn(value, "status") || validate1372(value["status"])) && (!Object.hasOwn(value, "pendingTemplateChannelVariantId") || validate1373(value["pendingTemplateChannelVariantId"])) && (!Object.hasOwn(value, "category") || validate1376(value["category"])) && (!Object.hasOwn(value, "providerCategory") || validate1377(value["providerCategory"])) && (!Object.hasOwn(value, "providerTemplateId") || validate8(value["providerTemplateId"])) && (!Object.hasOwn(value, "reason") || validate8(value["reason"])) && (!Object.hasOwn(value, "submittedAt") || validate8(value["submittedAt"])) && (!Object.hasOwn(value, "statusChangedAt") || validate2(value["statusChangedAt"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"])) && (!Object.hasOwn(value, "organizationId") || validate855(value["organizationId"])) && (!Object.hasOwn(value, "previousStatus") || validate1372(value["previousStatus"]));
234
- const validate1358 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^treg_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
235
- const validate1359 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^tmpl_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
236
- const validate1360 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^tpub_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
237
- const validate1361 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^tvar_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
238
- const validate1362 = (value) => validate1363(value) || validate1366(value);
239
- const validate1363 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "provider") && Object.hasOwn(value, "wabaId") && (!Object.hasOwn(value, "provider") || validate1364(value["provider"])) && (!Object.hasOwn(value, "wabaId") || validate2(value["wabaId"]));
240
- const validate1364 = (value) => typeof value === "string" && value === "whatsapp";
241
- const validate1366 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "provider") && Object.hasOwn(value, "entityId") && Object.hasOwn(value, "headerId") && (!Object.hasOwn(value, "provider") || validate1367(value["provider"])) && (!Object.hasOwn(value, "entityId") || validate2(value["entityId"])) && (!Object.hasOwn(value, "headerId") || validate2(value["headerId"]));
242
- const validate1367 = (value) => typeof value === "string" && value === "dlt";
243
- const validate1372 = (value) => typeof value === "string" && (value === "draft" || value === "submitted" || value === "approved" || value === "rejected" || value === "paused" || value === "disabled");
244
- const validate1373 = (value) => validate1361(value) || validate6(value);
245
- const validate1376 = (value) => typeof value === "string" && (value === "marketing" || value === "utility" || value === "authentication" || value === "transactional" || value === "service_implicit" || value === "service_explicit" || value === "promotional");
246
- const validate1377 = (value) => validate1376(value) || validate6(value);
247
- const validate1394 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1395(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1397(value["data"]));
248
- const validate1395 = (value) => typeof value === "string" && value === "flow.registration.updated";
249
- const validate1397 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "flowId") && Object.hasOwn(value, "versionId") && Object.hasOwn(value, "versionNumber") && Object.hasOwn(value, "wabaId") && Object.hasOwn(value, "providerFlowId") && Object.hasOwn(value, "name") && Object.hasOwn(value, "status") && Object.hasOwn(value, "validationErrors") && Object.hasOwn(value, "endpointAlerts") && Object.hasOwn(value, "publishedAt") && Object.hasOwn(value, "statusChangedAt") && Object.hasOwn(value, "createdAt") && Object.hasOwn(value, "updatedAt") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "previousStatus") && (!Object.hasOwn(value, "id") || validate1398(value["id"])) && (!Object.hasOwn(value, "flowId") || validate750(value["flowId"])) && (!Object.hasOwn(value, "versionId") || validate756(value["versionId"])) && (!Object.hasOwn(value, "versionNumber") || validate1279(value["versionNumber"])) && (!Object.hasOwn(value, "wabaId") || validate2(value["wabaId"])) && (!Object.hasOwn(value, "providerFlowId") || validate8(value["providerFlowId"])) && (!Object.hasOwn(value, "name") || validate2(value["name"])) && (!Object.hasOwn(value, "status") || validate1407(value["status"])) && (!Object.hasOwn(value, "validationErrors") || validate1408(value["validationErrors"])) && (!Object.hasOwn(value, "endpointAlerts") || validate1415(value["endpointAlerts"])) && (!Object.hasOwn(value, "publishedAt") || validate8(value["publishedAt"])) && (!Object.hasOwn(value, "statusChangedAt") || validate2(value["statusChangedAt"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"])) && (!Object.hasOwn(value, "organizationId") || validate855(value["organizationId"])) && (!Object.hasOwn(value, "previousStatus") || validate1433(value["previousStatus"]));
250
- const validate1398 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^wafreg_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
251
- const validate1407 = (value) => typeof value === "string" && (value === "draft" || value === "published" || value === "throttled" || value === "blocked" || value === "deprecated");
252
- const validate1408 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate1409);
253
- const validate1409 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "error") && Object.hasOwn(value, "message") && (!Object.hasOwn(value, "error") || validate2(value["error"])) && (!Object.hasOwn(value, "message") || validate2(value["message"])) && (!Object.hasOwn(value, "path") || validate2(value["path"])) && (!Object.hasOwn(value, "line") || validate1279(value["line"])) && (!Object.hasOwn(value, "column") || validate1279(value["column"]));
254
- const validate1415 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate1416);
255
- const validate1416 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "kind") && Object.hasOwn(value, "message") && Object.hasOwn(value, "value") && Object.hasOwn(value, "threshold") && Object.hasOwn(value, "activatedAt") && (!Object.hasOwn(value, "kind") || validate2(value["kind"])) && (!Object.hasOwn(value, "message") || validate2(value["message"])) && (!Object.hasOwn(value, "value") || validate14(value["value"])) && (!Object.hasOwn(value, "threshold") || validate14(value["threshold"])) && (!Object.hasOwn(value, "activatedAt") || validate2(value["activatedAt"]));
256
- const validate1433 = (value) => validate1407(value) || validate6(value);
257
- const validate1436 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1437(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1439(value["data"]));
258
- const validate1437 = (value) => typeof value === "string" && value === "whatsapp.number.connected";
259
- const validate1439 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "businessAccountId") && Object.hasOwn(value, "phoneNumber") && Object.hasOwn(value, "phoneNumberId") && Object.hasOwn(value, "whatsappBusinessAccountId") && Object.hasOwn(value, "displayName") && Object.hasOwn(value, "verificationStatus") && Object.hasOwn(value, "reconnected") && Object.hasOwn(value, "setupLink") && (!Object.hasOwn(value, "organizationId") || validate855(value["organizationId"])) && (!Object.hasOwn(value, "namespaceId") || validate1339(value["namespaceId"])) && (!Object.hasOwn(value, "businessAccountId") || validate1444(value["businessAccountId"])) && (!Object.hasOwn(value, "phoneNumber") || validate2(value["phoneNumber"])) && (!Object.hasOwn(value, "phoneNumberId") || validate2(value["phoneNumberId"])) && (!Object.hasOwn(value, "whatsappBusinessAccountId") || validate2(value["whatsappBusinessAccountId"])) && (!Object.hasOwn(value, "displayName") || validate2(value["displayName"])) && (!Object.hasOwn(value, "verificationStatus") || validate1449(value["verificationStatus"])) && (!Object.hasOwn(value, "reconnected") || validate33(value["reconnected"])) && (!Object.hasOwn(value, "setupLink") || validate1451(value["setupLink"]));
260
- const validate1444 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^waba_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
261
- const validate1449 = (value) => typeof value === "string" && (value === "pending" || value === "verified" || value === "failed" || value === "suspended");
262
- const validate1451 = (value) => validate1452(value) || validate6(value);
263
- const validate1452 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "metadata") && (!Object.hasOwn(value, "id") || validate1453(value["id"])) && (!Object.hasOwn(value, "metadata") || validate1454(value["metadata"]));
264
- const validate1453 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^wasl_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
265
- const validate1454 = (value) => isObject(value) && isObject(value);
266
- const validate1456 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1457(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1459(value["data"]));
267
- const validate1457 = (value) => typeof value === "string" && value === "mailbox.message.received";
268
- const validate1459 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "message") && Object.hasOwn(value, "thread") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1339(value["namespaceId"])) && (!Object.hasOwn(value, "message") || validate1464(value["message"])) && (!Object.hasOwn(value, "thread") || validate1498(value["thread"]));
269
- const validate1464 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "from") && Object.hasOwn(value, "to") && Object.hasOwn(value, "cc") && Object.hasOwn(value, "subject") && Object.hasOwn(value, "text") && Object.hasOwn(value, "replyText") && Object.hasOwn(value, "attachments") && Object.hasOwn(value, "occurredAt") && (!Object.hasOwn(value, "id") || validate783(value["id"])) && (!Object.hasOwn(value, "campaign") || validate596(value["campaign"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "threadId") || validate1472(value["threadId"])) && (!Object.hasOwn(value, "from") || validate1473(value["from"])) && (!Object.hasOwn(value, "to") || validate45(value["to"])) && (!Object.hasOwn(value, "cc") || validate45(value["cc"])) && (!Object.hasOwn(value, "subject") || validate8(value["subject"])) && (!Object.hasOwn(value, "text") || validate8(value["text"])) && (!Object.hasOwn(value, "replyText") || validate8(value["replyText"])) && (!Object.hasOwn(value, "attachments") || validate1491(value["attachments"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"]));
270
- const validate1472 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^thread_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
271
- const validate1473 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "address") && (!Object.hasOwn(value, "address") || validate2(value["address"])) && (!Object.hasOwn(value, "name") || validate8(value["name"]));
272
- const validate1491 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate1492);
273
- const validate1492 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "filename") && Object.hasOwn(value, "contentType") && Object.hasOwn(value, "size") && (!Object.hasOwn(value, "id") || validate1493(value["id"])) && (!Object.hasOwn(value, "filename") || validate2(value["filename"])) && (!Object.hasOwn(value, "contentType") || validate2(value["contentType"])) && (!Object.hasOwn(value, "size") || validate15(value["size"]));
274
- const validate1493 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^att_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
275
- const validate1498 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "subject") && Object.hasOwn(value, "preview") && (!Object.hasOwn(value, "id") || validate1472(value["id"])) && (!Object.hasOwn(value, "endpointId") || validate1500(value["endpointId"])) && (!Object.hasOwn(value, "subject") || validate8(value["subject"])) && (!Object.hasOwn(value, "preview") || validate8(value["preview"]));
276
- const validate1500 = (value) => validate1501(value) || validate6(value);
277
- const validate1501 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^mbxep_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
278
- const validate1509 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1510(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1512(value["data"]));
279
- const validate1510 = (value) => typeof value === "string" && value === "mailbox.message.sent";
280
- const validate1512 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "actionId") && Object.hasOwn(value, "actor") && Object.hasOwn(value, "message") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1339(value["namespaceId"])) && (!Object.hasOwn(value, "actionId") || validate1517(value["actionId"])) && (!Object.hasOwn(value, "state") || validate1518(value["state"])) && (!Object.hasOwn(value, "acceptedAt") || validate2(value["acceptedAt"])) && (!Object.hasOwn(value, "actor") || validate1520(value["actor"])) && (!Object.hasOwn(value, "message") || validate1464(value["message"]));
281
- const validate1517 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^mbxact_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
282
- const validate1518 = (value) => typeof value === "string" && value === "completed";
283
- const validate1520 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "kind") && Object.hasOwn(value, "id") && Object.hasOwn(value, "source") && (!Object.hasOwn(value, "kind") || validate1521(value["kind"])) && (!Object.hasOwn(value, "id") || validate2(value["id"])) && (!Object.hasOwn(value, "displayName") || validate8(value["displayName"])) && (!Object.hasOwn(value, "source") || validate1526(value["source"]));
284
- const validate1521 = (value) => typeof value === "string" && (value === "user" || value === "apiKey" || value === "extension" || value === "externalAgent" || value === "samvaAgent" || value === "system");
285
- const validate1526 = (value) => typeof value === "string" && (value === "humanUi" || value === "externalApi" || value === "externalAgent" || value === "extension" || value === "samvaManagedAgent" || value === "system");
286
- const validate1561 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1562(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1564(value["data"]));
287
- const validate1562 = (value) => typeof value === "string" && value === "mailbox.action.pending_approval";
288
- const validate1564 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "action") && Object.hasOwn(value, "draft") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1339(value["namespaceId"])) && (!Object.hasOwn(value, "action") || validate1569(value["action"])) && (!Object.hasOwn(value, "draft") || validate1639(value["draft"])) && (!Object.hasOwn(value, "tool") || validate1649(value["tool"]));
289
- const validate1569 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "type") && Object.hasOwn(value, "reviewRound") && Object.hasOwn(value, "decision") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "proposedBy") && Object.hasOwn(value, "createdAt") && (!Object.hasOwn(value, "id") || validate1517(value["id"])) && (!Object.hasOwn(value, "type") || validate1571(value["type"])) && (!Object.hasOwn(value, "reviewRound") || validate1572(value["reviewRound"])) && (!Object.hasOwn(value, "state") || validate1573(value["state"])) && (!Object.hasOwn(value, "decision") || validate1574(value["decision"])) && (!Object.hasOwn(value, "threadId") || validate1625(value["threadId"])) && (!Object.hasOwn(value, "reason") || validate8(value["reason"])) && (!Object.hasOwn(value, "proposedBy") || validate1520(value["proposedBy"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"]));
290
- const validate1571 = (value) => typeof value === "string" && (value === "sendMessage" || value === "reply" || value === "updateDraft" || value === "createNote" || value === "assignThread" || value === "changeThreadState" || value === "call" || value === "extensionRequest" || value === "toolCall" || value === "handoff");
291
- const validate1572 = (value) => typeof value === "number" && Number.isInteger(value) && typeof value === "number" && value <= 9007199254740991 && typeof value === "number" && value > 0;
292
- const validate1573 = (value) => typeof value === "string" && value === "approvalRequired";
293
- const validate1574 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "reviewRound") && Object.hasOwn(value, "requirement") && Object.hasOwn(value, "decider") && Object.hasOwn(value, "outcome") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "scopes") && (!Object.hasOwn(value, "id") || validate1575(value["id"])) && (!Object.hasOwn(value, "reviewRound") || validate1572(value["reviewRound"])) && (!Object.hasOwn(value, "requirement") || validate1577(value["requirement"])) && (!Object.hasOwn(value, "decider") || validate1578(value["decider"])) && (!Object.hasOwn(value, "outcome") || validate1579(value["outcome"])) && (!Object.hasOwn(value, "reason") || validate1580(value["reason"])) && (!Object.hasOwn(value, "scopes") || validate1581(value["scopes"])) && (!Object.hasOwn(value, "rule") || validate1585(value["rule"])) && (!Object.hasOwn(value, "guard") || validate1592(value["guard"])) && (!Object.hasOwn(value, "guardReason") || validate1592(value["guardReason"])) && (!Object.hasOwn(value, "resolution") || validate1598(value["resolution"]));
294
- const validate1575 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^pdec_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
295
- const validate1577 = (value) => typeof value === "string" && (value === "run" || value === "model" || value === "person" || value === "never");
296
- const validate1578 = (value) => typeof value === "string" && (value === "rule" || value === "model" || value === "person" || value === "agent");
297
- const validate1579 = (value) => typeof value === "string" && (value === "allow" || value === "hold" || value === "refuse");
298
- const validate1580 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1;
299
- const validate1581 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate1582);
300
- const validate1582 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "kind") && Object.hasOwn(value, "id") && (!Object.hasOwn(value, "kind") || validate1583(value["kind"])) && (!Object.hasOwn(value, "id") || validate1580(value["id"]));
301
- const validate1583 = (value) => typeof value === "string" && (value === "organization" || value === "integration" || value === "mailbox" || value === "agent" || value === "apiKey");
302
- const validate1585 = (value) => validate1586(value) || validate6(value);
303
- const validate1586 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "scope") && Object.hasOwn(value, "index") && (!Object.hasOwn(value, "scope") || validate1582(value["scope"])) && (!Object.hasOwn(value, "index") || validate1590(value["index"]));
304
- const validate1590 = (value) => typeof value === "number" && Number.isInteger(value) && typeof value === "number" && value >= 0 && typeof value === "number" && value <= 9007199254740991;
305
- const validate1592 = (value) => validate1580(value) || validate6(value);
306
- const validate1598 = (value) => validate1599(value) || validate6(value);
307
- const validate1599 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "by") && Object.hasOwn(value, "at") && Object.hasOwn(value, "as") && (!Object.hasOwn(value, "by") || validate1600(value["by"])) && (!Object.hasOwn(value, "at") || validate2(value["at"])) && (!Object.hasOwn(value, "as") || validate1602(value["as"])) && (!Object.hasOwn(value, "diff") || validate1603(value["diff"]));
308
- const validate1600 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^user_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
309
- const validate1602 = (value) => typeof value === "string" && (value === "approved" || value === "edited" || value === "denied" || value === "alwaysAllowed");
310
- const validate1603 = (value) => validate1604(value) || validate6(value);
311
- const validate1604 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "text") || validate1605(value["text"])) && (!Object.hasOwn(value, "html") || validate1605(value["html"]));
312
- const validate1605 = (value) => validate1606(value) || validate6(value);
313
- const validate1606 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "before") && Object.hasOwn(value, "after") && (!Object.hasOwn(value, "before") || validate8(value["before"])) && (!Object.hasOwn(value, "after") || validate8(value["after"]));
314
- const validate1625 = (value) => validate1472(value) || validate6(value);
315
- const validate1639 = (value) => validate1640(value) || validate6(value);
316
- const validate1640 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "to") && Object.hasOwn(value, "cc") && Object.hasOwn(value, "subject") && (!Object.hasOwn(value, "to") || validate45(value["to"])) && (!Object.hasOwn(value, "cc") || validate45(value["cc"])) && (!Object.hasOwn(value, "subject") || validate8(value["subject"]));
317
- const validate1649 = (value) => validate1650(value) || validate6(value);
318
- const validate1650 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "name") && Object.hasOwn(value, "argumentsHash") && Object.hasOwn(value, "arguments") && (!Object.hasOwn(value, "name") || validate1651(value["name"])) && (!Object.hasOwn(value, "argumentsHash") || validate1652(value["argumentsHash"])) && (!Object.hasOwn(value, "arguments") || validate12(value["arguments"]));
319
- const validate1651 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 128;
320
- const validate1652 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^[0-9a-f]{64}$", "u")).test(value);
321
- const validate1655 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1656(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1658(value["data"]));
322
- const validate1656 = (value) => typeof value === "string" && value === "mailbox.action.resolved";
323
- const validate1658 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "action") && Object.hasOwn(value, "resolution") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1339(value["namespaceId"])) && (!Object.hasOwn(value, "action") || validate1663(value["action"])) && (!Object.hasOwn(value, "resolution") || validate1678(value["resolution"]));
324
- const validate1663 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "type") && Object.hasOwn(value, "reviewRound") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "proposedBy") && Object.hasOwn(value, "createdAt") && (!Object.hasOwn(value, "id") || validate1517(value["id"])) && (!Object.hasOwn(value, "type") || validate1571(value["type"])) && (!Object.hasOwn(value, "reviewRound") || validate1572(value["reviewRound"])) && (!Object.hasOwn(value, "threadId") || validate1625(value["threadId"])) && (!Object.hasOwn(value, "proposedBy") || validate1520(value["proposedBy"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"]));
325
- const validate1678 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "outcome") && Object.hasOwn(value, "actor") && Object.hasOwn(value, "resolvedAt") && Object.hasOwn(value, "reason") && (!Object.hasOwn(value, "outcome") || validate1679(value["outcome"])) && (!Object.hasOwn(value, "actor") || validate1520(value["actor"])) && (!Object.hasOwn(value, "resolvedAt") || validate2(value["resolvedAt"])) && (!Object.hasOwn(value, "reason") || validate8(value["reason"]));
326
- const validate1679 = (value) => typeof value === "string" && (value === "approved" || value === "denied" || value === "cancelled");
327
- const validate1691 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1692(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1694(value["data"]));
328
- const validate1692 = (value) => typeof value === "string" && value === "mailbox.message.spam";
329
- const validate1694 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "disposition") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "source") && Object.hasOwn(value, "message") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1339(value["namespaceId"])) && (!Object.hasOwn(value, "disposition") || validate1699(value["disposition"])) && (!Object.hasOwn(value, "threadId") || validate1625(value["threadId"])) && (!Object.hasOwn(value, "reason") || validate593(value["reason"])) && (!Object.hasOwn(value, "source") || validate1706(value["source"])) && (!Object.hasOwn(value, "message") || validate1707(value["message"]));
330
- const validate1699 = (value) => typeof value === "string" && (value === "spam" || value === "isolated");
331
- const validate1706 = (value) => typeof value === "string" && (value === "receipt" || value === "classifier" || value === "reader");
332
- const validate1707 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "from") && Object.hasOwn(value, "subject") && Object.hasOwn(value, "receivedAt") && (!Object.hasOwn(value, "id") || validate783(value["id"])) && (!Object.hasOwn(value, "from") || validate1473(value["from"])) && (!Object.hasOwn(value, "subject") || validate8(value["subject"])) && (!Object.hasOwn(value, "receivedAt") || validate2(value["receivedAt"]));
333
- const validate1718 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1719(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1721(value["data"]));
334
- const validate1719 = (value) => typeof value === "string" && value === "mailbox.message.discarded";
335
- const validate1721 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "discardedBy") && Object.hasOwn(value, "disposition") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "message") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1339(value["namespaceId"])) && (!Object.hasOwn(value, "discardedBy") || validate1520(value["discardedBy"])) && (!Object.hasOwn(value, "disposition") || validate1733(value["disposition"])) && (!Object.hasOwn(value, "reason") || validate594(value["reason"])) && (!Object.hasOwn(value, "message") || validate1707(value["message"]));
336
- const validate1733 = (value) => typeof value === "string" && (value === "quarantined" || value === "isolated");
337
- const validate1746 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1747(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1749(value["data"]));
338
- const validate1747 = (value) => typeof value === "string" && value === "mailbox.thread.deleted";
339
- const validate1749 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "threadId") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1339(value["namespaceId"])) && (!Object.hasOwn(value, "threadId") || validate1472(value["threadId"]));
340
- const validate1755 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1756(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1758(value["data"]));
341
- const validate1756 = (value) => typeof value === "string" && value === "mailbox.message.delivered";
342
- const validate1758 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "actionId") && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "recipient") && Object.hasOwn(value, "occurredAt") && Object.hasOwn(value, "status") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1339(value["namespaceId"])) && (!Object.hasOwn(value, "threadId") || validate1472(value["threadId"])) && (!Object.hasOwn(value, "actionId") || validate1517(value["actionId"])) && (!Object.hasOwn(value, "messageId") || validate783(value["messageId"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "recipient") || validate2(value["recipient"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"])) && (!Object.hasOwn(value, "status") || validate1769(value["status"]));
343
- const validate1769 = (value) => typeof value === "string" && value === "delivered";
344
- const validate1770 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1771(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1773(value["data"]));
345
- const validate1771 = (value) => typeof value === "string" && value === "mailbox.message.read";
346
- const validate1773 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "actionId") && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "recipient") && Object.hasOwn(value, "occurredAt") && Object.hasOwn(value, "status") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1339(value["namespaceId"])) && (!Object.hasOwn(value, "threadId") || validate1472(value["threadId"])) && (!Object.hasOwn(value, "actionId") || validate1517(value["actionId"])) && (!Object.hasOwn(value, "messageId") || validate783(value["messageId"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "recipient") || validate2(value["recipient"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"])) && (!Object.hasOwn(value, "status") || validate1784(value["status"]));
347
- const validate1784 = (value) => typeof value === "string" && value === "read";
348
- const validate1785 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1786(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1788(value["data"]));
349
- const validate1786 = (value) => typeof value === "string" && value === "mailbox.message.failed";
350
- const validate1788 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "actionId") && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "recipient") && Object.hasOwn(value, "occurredAt") && Object.hasOwn(value, "status") && Object.hasOwn(value, "error") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1339(value["namespaceId"])) && (!Object.hasOwn(value, "threadId") || validate1472(value["threadId"])) && (!Object.hasOwn(value, "actionId") || validate1517(value["actionId"])) && (!Object.hasOwn(value, "messageId") || validate783(value["messageId"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "recipient") || validate2(value["recipient"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"])) && (!Object.hasOwn(value, "status") || validate1799(value["status"])) && (!Object.hasOwn(value, "error") || validate1800(value["error"]));
351
- const validate1799 = (value) => typeof value === "string" && value === "failed";
352
- const validate1800 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "code") && Object.hasOwn(value, "message") && (!Object.hasOwn(value, "code") || validate8(value["code"])) && (!Object.hasOwn(value, "message") || validate8(value["message"]));
353
- const validate1807 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1808(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1810(value["data"]));
354
- const validate1808 = (value) => typeof value === "string" && value === "journey.webhook";
355
- const validate1810 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "journeyId") && Object.hasOwn(value, "journeyVersion") && Object.hasOwn(value, "runId") && Object.hasOwn(value, "nodeId") && Object.hasOwn(value, "contact") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "organizationId") || validate855(value["organizationId"])) && (!Object.hasOwn(value, "journeyId") || validate1812(value["journeyId"])) && (!Object.hasOwn(value, "journeyVersion") || validate1279(value["journeyVersion"])) && (!Object.hasOwn(value, "runId") || validate1814(value["runId"])) && (!Object.hasOwn(value, "nodeId") || validate2(value["nodeId"])) && (!Object.hasOwn(value, "contact") || validate1816(value["contact"])) && (!Object.hasOwn(value, "data") || validate12(value["data"]));
356
- const validate1812 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^jrny_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
357
- const validate1814 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^jrun_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
358
- const validate1816 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "externalId") && Object.hasOwn(value, "email") && (!Object.hasOwn(value, "id") || validate954(value["id"])) && (!Object.hasOwn(value, "externalId") || validate8(value["externalId"])) && (!Object.hasOwn(value, "email") || validate8(value["email"]));
45
+ const validate602 = (value) => validate603(value) || validate6(value);
46
+ const validate603 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "appHandlesFlowSubmission") || validate604(value["appHandlesFlowSubmission"])) && (!Object.hasOwn(value, "text") || validate8(value["text"])) && (!Object.hasOwn(value, "template") || validate608(value["template"])) && (!Object.hasOwn(value, "interactive") || validate661(value["interactive"])) && (!Object.hasOwn(value, "media") || validate761(value["media"])) && (!Object.hasOwn(value, "reaction") || validate784(value["reaction"])) && (!Object.hasOwn(value, "location") || validate792(value["location"])) && (!Object.hasOwn(value, "contacts") || validate798(value["contacts"])) && (!Object.hasOwn(value, "reply") || validate834(value["reply"])) && (!Object.hasOwn(value, "flowResponse") || validate839(value["flowResponse"])) && (!Object.hasOwn(value, "context") || validate846(value["context"]));
47
+ const validate604 = (value) => typeof value === "boolean" && value === true;
48
+ const validate608 = (value) => validate609(value) || validate6(value);
49
+ const validate609 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "name") && Object.hasOwn(value, "language") && Object.hasOwn(value, "components") && (!Object.hasOwn(value, "name") || validate2(value["name"])) && (!Object.hasOwn(value, "language") || validate2(value["language"])) && (!Object.hasOwn(value, "components") || validate612(value["components"]));
50
+ const validate612 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate613);
51
+ const validate613 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "parameters") && (!Object.hasOwn(value, "type") || validate614(value["type"])) && (!Object.hasOwn(value, "sub_type") || validate615(value["sub_type"])) && (!Object.hasOwn(value, "index") || validate8(value["index"])) && (!Object.hasOwn(value, "parameters") || validate621(value["parameters"]));
52
+ const validate614 = (value) => typeof value === "string" && (value === "header" || value === "body" || value === "footer" || value === "button");
53
+ const validate615 = (value) => validate616(value) || validate6(value);
54
+ const validate616 = (value) => typeof value === "string" && (value === "url" || value === "quick_reply" || value === "copy_code" || value === "flow");
55
+ const validate621 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate622);
56
+ const validate622 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && (!Object.hasOwn(value, "type") || validate623(value["type"])) && (!Object.hasOwn(value, "text") || validate8(value["text"])) && (!Object.hasOwn(value, "currency") || validate627(value["currency"])) && (!Object.hasOwn(value, "date_time") || validate633(value["date_time"])) && (!Object.hasOwn(value, "image") || validate637(value["image"])) && (!Object.hasOwn(value, "document") || validate641(value["document"])) && (!Object.hasOwn(value, "video") || validate637(value["video"])) && (!Object.hasOwn(value, "coupon_code") || validate8(value["coupon_code"])) && (!Object.hasOwn(value, "action") || validate655(value["action"]));
57
+ const validate623 = (value) => typeof value === "string" && (value === "text" || value === "currency" || value === "date_time" || value === "image" || value === "document" || value === "video" || value === "coupon_code" || value === "action");
58
+ const validate627 = (value) => validate628(value) || validate6(value);
59
+ const validate628 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "fallback_value") && Object.hasOwn(value, "code") && Object.hasOwn(value, "amount_1000") && (!Object.hasOwn(value, "fallback_value") || validate2(value["fallback_value"])) && (!Object.hasOwn(value, "code") || validate2(value["code"])) && (!Object.hasOwn(value, "amount_1000") || validate15(value["amount_1000"]));
60
+ const validate633 = (value) => validate634(value) || validate6(value);
61
+ const validate634 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "fallback_value") && (!Object.hasOwn(value, "fallback_value") || validate2(value["fallback_value"]));
62
+ const validate637 = (value) => validate638(value) || validate6(value);
63
+ const validate638 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "link") && (!Object.hasOwn(value, "link") || validate2(value["link"]));
64
+ const validate641 = (value) => validate642(value) || validate6(value);
65
+ const validate642 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "link") && (!Object.hasOwn(value, "link") || validate2(value["link"])) && (!Object.hasOwn(value, "filename") || validate8(value["filename"]));
66
+ const validate655 = (value) => validate656(value) || validate6(value);
67
+ const validate656 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "flow_token") && (!Object.hasOwn(value, "flow_token") || validate2(value["flow_token"])) && (!Object.hasOwn(value, "flow_action_data") || validate12(value["flow_action_data"]));
68
+ const validate661 = (value) => validate662(value) || validate697(value) || validate713(value) || validate746(value);
69
+ const validate662 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "body") && Object.hasOwn(value, "buttons") && (!Object.hasOwn(value, "type") || validate663(value["type"])) && (!Object.hasOwn(value, "header") || validate664(value["header"])) && (!Object.hasOwn(value, "body") || validate691(value["body"])) && (!Object.hasOwn(value, "footer") || validate667(value["footer"])) && (!Object.hasOwn(value, "buttons") || validate693(value["buttons"]));
70
+ const validate663 = (value) => typeof value === "string" && value === "buttons";
71
+ const validate664 = (value) => validate665(value) || validate668(value) || validate675(value) || validate682(value);
72
+ const validate665 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "text") && (!Object.hasOwn(value, "type") || validate666(value["type"])) && (!Object.hasOwn(value, "text") || validate667(value["text"]));
73
+ const validate666 = (value) => typeof value === "string" && value === "text";
74
+ const validate667 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 60;
75
+ const validate668 = (value) => validate669(value) || validate672(value);
76
+ const validate669 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "url") && (!Object.hasOwn(value, "type") || validate670(value["type"])) && (!Object.hasOwn(value, "url") || validate2(value["url"]));
77
+ const validate670 = (value) => typeof value === "string" && value === "image";
78
+ const validate672 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "mediaId") && (!Object.hasOwn(value, "type") || validate670(value["type"])) && (!Object.hasOwn(value, "mediaId") || validate674(value["mediaId"]));
79
+ const validate674 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^media_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
80
+ const validate675 = (value) => validate676(value) || validate679(value);
81
+ const validate676 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "url") && (!Object.hasOwn(value, "type") || validate677(value["type"])) && (!Object.hasOwn(value, "url") || validate2(value["url"]));
82
+ const validate677 = (value) => typeof value === "string" && value === "video";
83
+ const validate679 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "mediaId") && (!Object.hasOwn(value, "type") || validate677(value["type"])) && (!Object.hasOwn(value, "mediaId") || validate674(value["mediaId"]));
84
+ const validate682 = (value) => validate683(value) || validate687(value);
85
+ const validate683 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "url") && (!Object.hasOwn(value, "type") || validate684(value["type"])) && (!Object.hasOwn(value, "filename") || validate685(value["filename"])) && (!Object.hasOwn(value, "url") || validate2(value["url"]));
86
+ const validate684 = (value) => typeof value === "string" && value === "document";
87
+ const validate685 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 255;
88
+ const validate687 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "mediaId") && (!Object.hasOwn(value, "type") || validate684(value["type"])) && (!Object.hasOwn(value, "filename") || validate685(value["filename"])) && (!Object.hasOwn(value, "mediaId") || validate674(value["mediaId"]));
89
+ const validate691 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 1024;
90
+ const validate693 = (value) => Array.isArray(value) && Array.isArray(value) && value.length >= 1 && Array.isArray(value) && value.length <= 3 && Array.isArray(value) && value.every(validate694);
91
+ const validate694 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "title") && (!Object.hasOwn(value, "id") || validate695(value["id"])) && (!Object.hasOwn(value, "title") || validate696(value["title"]));
92
+ const validate695 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 256;
93
+ const validate696 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 20;
94
+ const validate697 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "body") && Object.hasOwn(value, "button") && Object.hasOwn(value, "sections") && (!Object.hasOwn(value, "type") || validate698(value["type"])) && (!Object.hasOwn(value, "header") || validate665(value["header"])) && (!Object.hasOwn(value, "body") || validate702(value["body"])) && (!Object.hasOwn(value, "footer") || validate667(value["footer"])) && (!Object.hasOwn(value, "button") || validate696(value["button"])) && (!Object.hasOwn(value, "sections") || validate705(value["sections"]));
95
+ const validate698 = (value) => typeof value === "string" && value === "list";
96
+ const validate702 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 4096;
97
+ const validate705 = (value) => Array.isArray(value) && Array.isArray(value) && value.length >= 1 && Array.isArray(value) && value.length <= 10 && Array.isArray(value) && value.every(validate706);
98
+ const validate706 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "rows") && (!Object.hasOwn(value, "title") || validate707(value["title"])) && (!Object.hasOwn(value, "rows") || validate708(value["rows"]));
99
+ const validate707 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 24;
100
+ const validate708 = (value) => Array.isArray(value) && Array.isArray(value) && value.length >= 1 && Array.isArray(value) && value.every(validate709);
101
+ const validate709 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "title") && (!Object.hasOwn(value, "id") || validate710(value["id"])) && (!Object.hasOwn(value, "title") || validate707(value["title"])) && (!Object.hasOwn(value, "description") || validate712(value["description"]));
102
+ const validate710 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 200;
103
+ const validate712 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 72;
104
+ const validate713 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "body") && Object.hasOwn(value, "displayText") && Object.hasOwn(value, "url") && (!Object.hasOwn(value, "type") || validate714(value["type"])) && (!Object.hasOwn(value, "header") || validate664(value["header"])) && (!Object.hasOwn(value, "body") || validate691(value["body"])) && (!Object.hasOwn(value, "footer") || validate667(value["footer"])) && (!Object.hasOwn(value, "displayText") || validate696(value["displayText"])) && (!Object.hasOwn(value, "url") || validate2(value["url"]));
105
+ const validate714 = (value) => typeof value === "string" && value === "cta_url";
106
+ const validate746 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "body") && Object.hasOwn(value, "flowId") && Object.hasOwn(value, "cta") && Object.hasOwn(value, "flowVersionId") && Object.hasOwn(value, "providerFlowId") && (!Object.hasOwn(value, "type") || validate747(value["type"])) && (!Object.hasOwn(value, "header") || validate665(value["header"])) && (!Object.hasOwn(value, "body") || validate691(value["body"])) && (!Object.hasOwn(value, "footer") || validate667(value["footer"])) && (!Object.hasOwn(value, "flowId") || validate753(value["flowId"])) && (!Object.hasOwn(value, "cta") || validate754(value["cta"])) && (!Object.hasOwn(value, "token") || validate691(value["token"])) && (!Object.hasOwn(value, "action") || validate756(value["action"])) && (!Object.hasOwn(value, "screen") || validate757(value["screen"])) && (!Object.hasOwn(value, "data") || validate12(value["data"])) && (!Object.hasOwn(value, "flowVersionId") || validate759(value["flowVersionId"])) && (!Object.hasOwn(value, "providerFlowId") || validate2(value["providerFlowId"]));
107
+ const validate747 = (value) => typeof value === "string" && value === "flow";
108
+ const validate753 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^waflow_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
109
+ const validate754 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 30;
110
+ const validate756 = (value) => typeof value === "string" && (value === "navigate" || value === "data_exchange");
111
+ const validate757 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^[A-Za-z_]{1,100}$", "u")).test(value);
112
+ const validate759 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^wafver_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
113
+ const validate761 = (value) => validate762(value) || validate6(value);
114
+ const validate762 = (value) => validate763(value) || validate768(value) || validate773(value);
115
+ const validate763 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "url") && (!Object.hasOwn(value, "type") || validate764(value["type"])) && (!Object.hasOwn(value, "url") || validate2(value["url"])) && (!Object.hasOwn(value, "caption") || validate2(value["caption"])) && (!Object.hasOwn(value, "filename") || validate2(value["filename"]));
116
+ const validate764 = (value) => typeof value === "string" && (value === "image" || value === "video" || value === "audio" || value === "document" || value === "sticker");
117
+ const validate768 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "mediaId") && (!Object.hasOwn(value, "type") || validate764(value["type"])) && (!Object.hasOwn(value, "mediaId") || validate674(value["mediaId"])) && (!Object.hasOwn(value, "caption") || validate2(value["caption"])) && (!Object.hasOwn(value, "filename") || validate2(value["filename"]));
118
+ const validate773 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "providerMediaId") && (!Object.hasOwn(value, "type") || validate764(value["type"])) && (!Object.hasOwn(value, "providerMediaId") || validate2(value["providerMediaId"])) && (!Object.hasOwn(value, "mimeType") || validate8(value["mimeType"])) && (!Object.hasOwn(value, "caption") || validate8(value["caption"])) && (!Object.hasOwn(value, "filename") || validate2(value["filename"]));
119
+ const validate784 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "providerMessageId") && Object.hasOwn(value, "emoji") && (!Object.hasOwn(value, "messageId") || validate785(value["messageId"])) && (!Object.hasOwn(value, "providerMessageId") || validate2(value["providerMessageId"])) && (!Object.hasOwn(value, "emoji") || validate8(value["emoji"]));
120
+ const validate785 = (value) => validate786(value) || validate6(value);
121
+ const validate786 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^msg_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
122
+ const validate792 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "latitude") && Object.hasOwn(value, "longitude") && (!Object.hasOwn(value, "latitude") || validate15(value["latitude"])) && (!Object.hasOwn(value, "longitude") || validate15(value["longitude"])) && (!Object.hasOwn(value, "name") || validate2(value["name"])) && (!Object.hasOwn(value, "address") || validate2(value["address"])) && (!Object.hasOwn(value, "url") || validate2(value["url"]));
123
+ const validate798 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate799);
124
+ const validate799 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "name") || validate800(value["name"])) && (!Object.hasOwn(value, "phones") || validate807(value["phones"])) && (!Object.hasOwn(value, "emails") || validate812(value["emails"])) && (!Object.hasOwn(value, "urls") || validate816(value["urls"])) && (!Object.hasOwn(value, "org") || validate820(value["org"])) && (!Object.hasOwn(value, "addresses") || validate824(value["addresses"])) && (!Object.hasOwn(value, "birthday") || validate2(value["birthday"]));
125
+ const validate800 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "formattedName") || validate2(value["formattedName"])) && (!Object.hasOwn(value, "firstName") || validate2(value["firstName"])) && (!Object.hasOwn(value, "lastName") || validate2(value["lastName"])) && (!Object.hasOwn(value, "middleName") || validate2(value["middleName"])) && (!Object.hasOwn(value, "prefix") || validate2(value["prefix"])) && (!Object.hasOwn(value, "suffix") || validate2(value["suffix"]));
126
+ const validate807 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate808);
127
+ const validate808 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "phone") || validate2(value["phone"])) && (!Object.hasOwn(value, "type") || validate2(value["type"])) && (!Object.hasOwn(value, "waId") || validate2(value["waId"]));
128
+ const validate812 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate813);
129
+ const validate813 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "email") || validate2(value["email"])) && (!Object.hasOwn(value, "type") || validate2(value["type"]));
130
+ const validate816 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate817);
131
+ const validate817 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "url") || validate2(value["url"])) && (!Object.hasOwn(value, "type") || validate2(value["type"]));
132
+ const validate820 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "company") || validate2(value["company"])) && (!Object.hasOwn(value, "department") || validate2(value["department"])) && (!Object.hasOwn(value, "title") || validate2(value["title"]));
133
+ const validate824 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate825);
134
+ const validate825 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "street") || validate2(value["street"])) && (!Object.hasOwn(value, "city") || validate2(value["city"])) && (!Object.hasOwn(value, "state") || validate2(value["state"])) && (!Object.hasOwn(value, "zip") || validate2(value["zip"])) && (!Object.hasOwn(value, "country") || validate2(value["country"])) && (!Object.hasOwn(value, "countryCode") || validate2(value["countryCode"])) && (!Object.hasOwn(value, "type") || validate2(value["type"]));
135
+ const validate834 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "id") && Object.hasOwn(value, "title") && (!Object.hasOwn(value, "type") || validate835(value["type"])) && (!Object.hasOwn(value, "id") || validate2(value["id"])) && (!Object.hasOwn(value, "title") || validate2(value["title"])) && (!Object.hasOwn(value, "description") || validate2(value["description"]));
136
+ const validate835 = (value) => typeof value === "string" && (value === "button" || value === "list" || value === "template_button");
137
+ const validate839 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "flowToken") && Object.hasOwn(value, "response") && (!Object.hasOwn(value, "flowToken") || validate8(value["flowToken"])) && (!Object.hasOwn(value, "submissionHandler") || validate843(value["submissionHandler"])) && (!Object.hasOwn(value, "response") || validate12(value["response"])) && (!Object.hasOwn(value, "body") || validate2(value["body"]));
138
+ const validate843 = (value) => typeof value === "string" && value === "app";
139
+ const validate846 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "providerMessageId") && (!Object.hasOwn(value, "messageId") || validate785(value["messageId"])) && (!Object.hasOwn(value, "providerMessageId") || validate2(value["providerMessageId"]));
140
+ const validate854 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate855(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate857(value["data"]));
141
+ const validate855 = (value) => typeof value === "string" && value === "message.opened";
142
+ const validate857 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "deliveryId") && Object.hasOwn(value, "recipient") && Object.hasOwn(value, "occurredAt") && Object.hasOwn(value, "firstOpen") && Object.hasOwn(value, "machine") && Object.hasOwn(value, "machineReason") && (!Object.hasOwn(value, "messageId") || validate786(value["messageId"])) && (!Object.hasOwn(value, "organizationId") || validate859(value["organizationId"])) && (!Object.hasOwn(value, "channel") || validate860(value["channel"])) && (!Object.hasOwn(value, "deliveryId") || validate861(value["deliveryId"])) && (!Object.hasOwn(value, "recipient") || validate2(value["recipient"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"])) && (!Object.hasOwn(value, "userAgent") || validate8(value["userAgent"])) && (!Object.hasOwn(value, "ipAddress") || validate8(value["ipAddress"])) && (!Object.hasOwn(value, "firstOpen") || validate33(value["firstOpen"])) && (!Object.hasOwn(value, "machine") || validate33(value["machine"])) && (!Object.hasOwn(value, "machineReason") || validate872(value["machineReason"])) && (!Object.hasOwn(value, "country") || validate8(value["country"])) && (!Object.hasOwn(value, "city") || validate8(value["city"])) && (!Object.hasOwn(value, "asn") || validate14(value["asn"])) && (!Object.hasOwn(value, "code") || validate8(value["code"])) && (!Object.hasOwn(value, "linkIndex") || validate14(value["linkIndex"])) && (!Object.hasOwn(value, "destinationUrl") || validate8(value["destinationUrl"])) && (!Object.hasOwn(value, "metadata") || validate11(value["metadata"])) && (!Object.hasOwn(value, "campaignId") || validate896(value["campaignId"])) && (!Object.hasOwn(value, "campaignRunId") || validate899(value["campaignRunId"]));
143
+ const validate859 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^org_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
144
+ const validate860 = (value) => typeof value === "string" && value === "email";
145
+ const validate861 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^mdel_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
146
+ const validate872 = (value) => validate873(value) || validate6(value);
147
+ const validate873 = (value) => typeof value === "string" && (value === "google-image-proxy" || value === "apple-mail-privacy" || value === "scanner-user-agent" || value === "scanner-asn" || value === "too-fast");
148
+ const validate896 = (value) => validate598(value) || validate6(value);
149
+ const validate899 = (value) => validate599(value) || validate6(value);
150
+ const validate902 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate903(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate905(value["data"]));
151
+ const validate903 = (value) => typeof value === "string" && value === "message.clicked";
152
+ const validate905 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "deliveryId") && Object.hasOwn(value, "recipient") && Object.hasOwn(value, "occurredAt") && Object.hasOwn(value, "url") && Object.hasOwn(value, "linkTags") && Object.hasOwn(value, "firstClick") && Object.hasOwn(value, "machine") && Object.hasOwn(value, "machineReason") && (!Object.hasOwn(value, "messageId") || validate786(value["messageId"])) && (!Object.hasOwn(value, "organizationId") || validate859(value["organizationId"])) && (!Object.hasOwn(value, "channel") || validate860(value["channel"])) && (!Object.hasOwn(value, "deliveryId") || validate861(value["deliveryId"])) && (!Object.hasOwn(value, "recipient") || validate2(value["recipient"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"])) && (!Object.hasOwn(value, "userAgent") || validate8(value["userAgent"])) && (!Object.hasOwn(value, "ipAddress") || validate8(value["ipAddress"])) && (!Object.hasOwn(value, "url") || validate2(value["url"])) && (!Object.hasOwn(value, "linkTags") || validate919(value["linkTags"])) && (!Object.hasOwn(value, "firstClick") || validate33(value["firstClick"])) && (!Object.hasOwn(value, "machine") || validate33(value["machine"])) && (!Object.hasOwn(value, "machineReason") || validate872(value["machineReason"])) && (!Object.hasOwn(value, "country") || validate8(value["country"])) && (!Object.hasOwn(value, "city") || validate8(value["city"])) && (!Object.hasOwn(value, "asn") || validate14(value["asn"])) && (!Object.hasOwn(value, "code") || validate8(value["code"])) && (!Object.hasOwn(value, "linkIndex") || validate14(value["linkIndex"])) && (!Object.hasOwn(value, "destinationUrl") || validate8(value["destinationUrl"])) && (!Object.hasOwn(value, "metadata") || validate11(value["metadata"])) && (!Object.hasOwn(value, "campaignId") || validate896(value["campaignId"])) && (!Object.hasOwn(value, "campaignRunId") || validate899(value["campaignRunId"]));
153
+ const validate919 = (value) => isObject(value) && isObject(value) && Object.entries(value).every(([key, item]) => validate45(item));
154
+ const validate954 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate955(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate957(value["data"]));
155
+ const validate955 = (value) => typeof value === "string" && value === "contact.created";
156
+ const validate957 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "contactId") && Object.hasOwn(value, "status") && Object.hasOwn(value, "name") && Object.hasOwn(value, "identities") && Object.hasOwn(value, "tags") && Object.hasOwn(value, "createdAt") && Object.hasOwn(value, "updatedAt") && (!Object.hasOwn(value, "contactId") || validate958(value["contactId"])) && (!Object.hasOwn(value, "status") || validate959(value["status"])) && (!Object.hasOwn(value, "name") || validate2(value["name"])) && (!Object.hasOwn(value, "displayName") || validate961(value["displayName"])) && (!Object.hasOwn(value, "identities") || validate965(value["identities"])) && (!Object.hasOwn(value, "tags") || validate45(value["tags"])) && (!Object.hasOwn(value, "externalId") || validate961(value["externalId"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"]));
157
+ const validate958 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^contact_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
158
+ const validate959 = (value) => typeof value === "string" && (value === "active" || value === "paused" || value === "blocked" || value === "archived");
159
+ const validate961 = (value) => validate2(value) || validate6(value) || validate6(value);
160
+ const validate965 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate966);
161
+ const validate966 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "identifier") && Object.hasOwn(value, "verified") && (!Object.hasOwn(value, "type") || validate967(value["type"])) && (!Object.hasOwn(value, "identifier") || validate2(value["identifier"])) && (!Object.hasOwn(value, "verified") || validate33(value["verified"]));
162
+ const validate967 = (value) => typeof value === "string" && (value === "email" || value === "phone");
163
+ const validate978 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate979(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate957(value["data"]));
164
+ const validate979 = (value) => typeof value === "string" && value === "contact.updated";
165
+ const validate1002 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1003(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate957(value["data"]));
166
+ const validate1003 = (value) => typeof value === "string" && value === "contact.deleted";
167
+ const validate1026 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1027(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1029(value["data"]));
168
+ const validate1027 = (value) => typeof value === "string" && value === "contact.subscribed";
169
+ const validate1029 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "contactId") && Object.hasOwn(value, "topicId") && Object.hasOwn(value, "topicName") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "source") && Object.hasOwn(value, "occurredAt") && (!Object.hasOwn(value, "organizationId") || validate859(value["organizationId"])) && (!Object.hasOwn(value, "contactId") || validate958(value["contactId"])) && (!Object.hasOwn(value, "email") || validate8(value["email"])) && (!Object.hasOwn(value, "topicId") || validate1035(value["topicId"])) && (!Object.hasOwn(value, "topicName") || validate2(value["topicName"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "consentIp") || validate8(value["consentIp"])) && (!Object.hasOwn(value, "consentSource") || validate8(value["consentSource"])) && (!Object.hasOwn(value, "source") || validate2(value["source"])) && (!Object.hasOwn(value, "formKey") || validate8(value["formKey"])) && (!Object.hasOwn(value, "page") || validate8(value["page"])) && (!Object.hasOwn(value, "referrer") || validate8(value["referrer"])) && (!Object.hasOwn(value, "messageId") || validate785(value["messageId"])) && (!Object.hasOwn(value, "campaignId") || validate896(value["campaignId"])) && (!Object.hasOwn(value, "campaignRunId") || validate899(value["campaignRunId"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"]));
170
+ const validate1035 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^tpc_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
171
+ const validate1064 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1065(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1029(value["data"]));
172
+ const validate1065 = (value) => typeof value === "string" && value === "contact.unsubscribed";
173
+ const validate1102 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1103(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1029(value["data"]));
174
+ const validate1103 = (value) => typeof value === "string" && value === "contact.resubscribed";
175
+ const validate1140 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1141(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1143(value["data"]));
176
+ const validate1141 = (value) => typeof value === "string" && value === "contact.consent_changed";
177
+ const validate1143 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "contactId") && Object.hasOwn(value, "identity") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "status") && Object.hasOwn(value, "previousStatus") && Object.hasOwn(value, "source") && Object.hasOwn(value, "capturedAt") && (!Object.hasOwn(value, "organizationId") || validate859(value["organizationId"])) && (!Object.hasOwn(value, "contactId") || validate958(value["contactId"])) && (!Object.hasOwn(value, "identity") || validate1146(value["identity"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "status") || validate1151(value["status"])) && (!Object.hasOwn(value, "previousStatus") || validate1152(value["previousStatus"])) && (!Object.hasOwn(value, "source") || validate2(value["source"])) && (!Object.hasOwn(value, "capturedAt") || validate2(value["capturedAt"]));
178
+ const validate1146 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "type") && Object.hasOwn(value, "identifier") && (!Object.hasOwn(value, "id") || validate1147(value["id"])) && (!Object.hasOwn(value, "type") || validate967(value["type"])) && (!Object.hasOwn(value, "identifier") || validate2(value["identifier"]));
179
+ const validate1147 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^cident_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
180
+ const validate1151 = (value) => typeof value === "string" && (value === "opted_in" || value === "opted_out");
181
+ const validate1152 = (value) => validate1151(value) || validate6(value);
182
+ const validate1157 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1158(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1160(value["data"]));
183
+ const validate1158 = (value) => typeof value === "string" && value === "conversation.created";
184
+ const validate1160 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "conversationId") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "channels") && Object.hasOwn(value, "primaryChannel") && Object.hasOwn(value, "status") && Object.hasOwn(value, "createdAt") && Object.hasOwn(value, "updatedAt") && (!Object.hasOwn(value, "conversationId") || validate1161(value["conversationId"])) && (!Object.hasOwn(value, "organizationId") || validate859(value["organizationId"])) && (!Object.hasOwn(value, "title") || validate961(value["title"])) && (!Object.hasOwn(value, "channels") || validate1167(value["channels"])) && (!Object.hasOwn(value, "primaryChannel") || validate7(value["primaryChannel"])) && (!Object.hasOwn(value, "status") || validate1170(value["status"])) && (!Object.hasOwn(value, "primaryContactId") || validate1171(value["primaryContactId"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"]));
185
+ const validate1161 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^conv_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
186
+ const validate1167 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate7);
187
+ const validate1170 = (value) => typeof value === "string" && (value === "active" || value === "waiting" || value === "resolved" || value === "escalated" || value === "archived");
188
+ const validate1171 = (value) => validate958(value) || validate6(value) || validate6(value);
189
+ const validate1177 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1178(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1160(value["data"]));
190
+ const validate1178 = (value) => typeof value === "string" && value === "conversation.updated";
191
+ const validate1197 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1198(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1160(value["data"]));
192
+ const validate1198 = (value) => typeof value === "string" && value === "conversation.archived";
193
+ const validate1217 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1218(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1220(value["data"]));
194
+ const validate1218 = (value) => typeof value === "string" && value === "webhook.created";
195
+ const validate1220 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "webhookId") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "name") && Object.hasOwn(value, "url") && Object.hasOwn(value, "eventTypes") && Object.hasOwn(value, "channels") && Object.hasOwn(value, "status") && Object.hasOwn(value, "createdAt") && Object.hasOwn(value, "updatedAt") && (!Object.hasOwn(value, "webhookId") || validate1221(value["webhookId"])) && (!Object.hasOwn(value, "organizationId") || validate859(value["organizationId"])) && (!Object.hasOwn(value, "name") || validate2(value["name"])) && (!Object.hasOwn(value, "url") || validate2(value["url"])) && (!Object.hasOwn(value, "eventTypes") || validate45(value["eventTypes"])) && (!Object.hasOwn(value, "channels") || validate44(value["channels"])) && (!Object.hasOwn(value, "status") || validate1231(value["status"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"]));
196
+ const validate1221 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^wep_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
197
+ const validate1231 = (value) => typeof value === "string" && (value === "active" || value === "disabled");
198
+ const validate1234 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1235(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1220(value["data"]));
199
+ const validate1235 = (value) => typeof value === "string" && value === "webhook.updated";
200
+ const validate1251 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1252(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1220(value["data"]));
201
+ const validate1252 = (value) => typeof value === "string" && value === "webhook.deleted";
202
+ const validate1268 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1269(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate12(value["data"]));
203
+ const validate1269 = (value) => typeof value === "string" && value === "webhook.test";
204
+ const validate1272 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1273(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1275(value["data"]));
205
+ const validate1273 = (value) => typeof value === "string" && value === "domain.updated";
206
+ const validate1275 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "domainId") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "domain") && Object.hasOwn(value, "previousPhase") && Object.hasOwn(value, "phase") && Object.hasOwn(value, "dns") && Object.hasOwn(value, "provider") && Object.hasOwn(value, "operationId") && Object.hasOwn(value, "checkedAt") && Object.hasOwn(value, "nextCheckAt") && Object.hasOwn(value, "failure") && Object.hasOwn(value, "updatedAt") && (!Object.hasOwn(value, "domainId") || validate1276(value["domainId"])) && (!Object.hasOwn(value, "organizationId") || validate859(value["organizationId"])) && (!Object.hasOwn(value, "domain") || validate2(value["domain"])) && (!Object.hasOwn(value, "previousPhase") || validate1279(value["previousPhase"])) && (!Object.hasOwn(value, "phase") || validate1279(value["phase"])) && (!Object.hasOwn(value, "dns") || validate1281(value["dns"])) && (!Object.hasOwn(value, "provider") || validate1288(value["provider"])) && (!Object.hasOwn(value, "operationId") || validate1298(value["operationId"])) && (!Object.hasOwn(value, "checkedAt") || validate8(value["checkedAt"])) && (!Object.hasOwn(value, "nextCheckAt") || validate8(value["nextCheckAt"])) && (!Object.hasOwn(value, "failure") || validate1307(value["failure"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"]));
207
+ const validate1276 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^dom_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
208
+ const validate1279 = (value) => typeof value === "string" && (value === "dns-setup" || value === "provisioning" || value === "verifying" || value === "ready" || value === "degraded" || value === "failed");
209
+ const validate1281 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "observed") && Object.hasOwn(value, "total") && Object.hasOwn(value, "satisfied") && Object.hasOwn(value, "missing") && Object.hasOwn(value, "mismatch") && Object.hasOwn(value, "unknown") && (!Object.hasOwn(value, "observed") || validate33(value["observed"])) && (!Object.hasOwn(value, "total") || validate1283(value["total"])) && (!Object.hasOwn(value, "satisfied") || validate1283(value["satisfied"])) && (!Object.hasOwn(value, "missing") || validate1283(value["missing"])) && (!Object.hasOwn(value, "mismatch") || validate1283(value["mismatch"])) && (!Object.hasOwn(value, "unknown") || validate1283(value["unknown"]));
210
+ const validate1283 = (value) => typeof value === "number" && Number.isInteger(value) && typeof value === "number" && value >= -9007199254740991 && typeof value === "number" && value <= 9007199254740991;
211
+ const validate1288 = (value) => validate1289(value) || validate6(value);
212
+ const validate1289 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "identity") && (!Object.hasOwn(value, "identity") || validate1290(value["identity"])) && (!Object.hasOwn(value, "dkim") || validate1291(value["dkim"])) && (!Object.hasOwn(value, "mailFrom") || validate1291(value["mailFrom"]));
213
+ const validate1290 = (value) => typeof value === "string" && (value === "pending" || value === "verified" || value === "failed" || value === "unknown");
214
+ const validate1291 = (value) => validate1290(value) || validate6(value);
215
+ const validate1298 = (value) => validate1299(value) || validate6(value);
216
+ const validate1299 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^op_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
217
+ const validate1307 = (value) => validate1308(value) || validate6(value);
218
+ const validate1308 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "code") && Object.hasOwn(value, "message") && Object.hasOwn(value, "failedAt") && (!Object.hasOwn(value, "code") || validate2(value["code"])) && (!Object.hasOwn(value, "message") || validate2(value["message"])) && (!Object.hasOwn(value, "failedAt") || validate2(value["failedAt"]));
219
+ const validate1314 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1315(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1317(value["data"]));
220
+ const validate1315 = (value) => typeof value === "string" && value === "domain.warming.updated";
221
+ const validate1317 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "domainId") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "domain") && Object.hasOwn(value, "planId") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "status") && Object.hasOwn(value, "holdReason") && Object.hasOwn(value, "batch") && Object.hasOwn(value, "updatedAt") && (!Object.hasOwn(value, "domainId") || validate2(value["domainId"])) && (!Object.hasOwn(value, "organizationId") || validate2(value["organizationId"])) && (!Object.hasOwn(value, "domain") || validate2(value["domain"])) && (!Object.hasOwn(value, "planId") || validate2(value["planId"])) && (!Object.hasOwn(value, "reason") || validate1322(value["reason"])) && (!Object.hasOwn(value, "status") || validate1323(value["status"])) && (!Object.hasOwn(value, "holdReason") || validate8(value["holdReason"])) && (!Object.hasOwn(value, "batch") || validate1327(value["batch"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"]));
222
+ const validate1322 = (value) => typeof value === "string" && (value === "plan-created" || value === "policy-updated" || value === "window-opened" || value === "window-cancelled" || value === "paused" || value === "resumed" || value === "held" || value === "completed");
223
+ const validate1323 = (value) => typeof value === "string" && (value === "active" || value === "paused" || value === "completed");
224
+ const validate1327 = (value) => validate1328(value) || validate6(value);
225
+ const validate1328 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "sequence") && Object.hasOwn(value, "startsAt") && Object.hasOwn(value, "endsAt") && Object.hasOwn(value, "allowanceRecipients") && Object.hasOwn(value, "dailyGrowthPercent") && Object.hasOwn(value, "targetDailyRecipients") && (!Object.hasOwn(value, "id") || validate2(value["id"])) && (!Object.hasOwn(value, "sequence") || validate15(value["sequence"])) && (!Object.hasOwn(value, "startsAt") || validate2(value["startsAt"])) && (!Object.hasOwn(value, "endsAt") || validate2(value["endsAt"])) && (!Object.hasOwn(value, "allowanceRecipients") || validate15(value["allowanceRecipients"])) && (!Object.hasOwn(value, "dailyGrowthPercent") || validate15(value["dailyGrowthPercent"])) && (!Object.hasOwn(value, "targetDailyRecipients") || validate15(value["targetDailyRecipients"]));
226
+ const validate1338 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1339(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1341(value["data"]));
227
+ const validate1339 = (value) => typeof value === "string" && value === "email.sending.paused";
228
+ const validate1341 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "occurredAt") && (!Object.hasOwn(value, "organizationId") || validate859(value["organizationId"])) && (!Object.hasOwn(value, "namespaceId") || validate1343(value["namespaceId"])) && (!Object.hasOwn(value, "channel") || validate860(value["channel"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"]));
229
+ const validate1343 = (value) => validate1344(value) || validate6(value);
230
+ const validate1344 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^ns_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
231
+ const validate1348 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1349(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1341(value["data"]));
232
+ const validate1349 = (value) => typeof value === "string" && value === "email.sending.resumed";
233
+ const validate1358 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1359(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1361(value["data"]));
234
+ const validate1359 = (value) => typeof value === "string" && value === "template.registration.updated";
235
+ const validate1361 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "templateId") && Object.hasOwn(value, "publicationId") && Object.hasOwn(value, "templateChannelVariantId") && Object.hasOwn(value, "target") && Object.hasOwn(value, "name") && Object.hasOwn(value, "language") && Object.hasOwn(value, "status") && Object.hasOwn(value, "pendingTemplateChannelVariantId") && Object.hasOwn(value, "category") && Object.hasOwn(value, "providerCategory") && Object.hasOwn(value, "providerTemplateId") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "submittedAt") && Object.hasOwn(value, "statusChangedAt") && Object.hasOwn(value, "createdAt") && Object.hasOwn(value, "updatedAt") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "previousStatus") && (!Object.hasOwn(value, "id") || validate1362(value["id"])) && (!Object.hasOwn(value, "templateId") || validate1363(value["templateId"])) && (!Object.hasOwn(value, "publicationId") || validate1364(value["publicationId"])) && (!Object.hasOwn(value, "templateChannelVariantId") || validate1365(value["templateChannelVariantId"])) && (!Object.hasOwn(value, "target") || validate1366(value["target"])) && (!Object.hasOwn(value, "name") || validate2(value["name"])) && (!Object.hasOwn(value, "language") || validate2(value["language"])) && (!Object.hasOwn(value, "status") || validate1376(value["status"])) && (!Object.hasOwn(value, "pendingTemplateChannelVariantId") || validate1377(value["pendingTemplateChannelVariantId"])) && (!Object.hasOwn(value, "category") || validate1380(value["category"])) && (!Object.hasOwn(value, "providerCategory") || validate1381(value["providerCategory"])) && (!Object.hasOwn(value, "providerTemplateId") || validate8(value["providerTemplateId"])) && (!Object.hasOwn(value, "reason") || validate8(value["reason"])) && (!Object.hasOwn(value, "submittedAt") || validate8(value["submittedAt"])) && (!Object.hasOwn(value, "statusChangedAt") || validate2(value["statusChangedAt"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"])) && (!Object.hasOwn(value, "organizationId") || validate859(value["organizationId"])) && (!Object.hasOwn(value, "previousStatus") || validate1376(value["previousStatus"]));
236
+ const validate1362 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^treg_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
237
+ const validate1363 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^tmpl_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
238
+ const validate1364 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^tpub_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
239
+ const validate1365 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^tvar_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
240
+ const validate1366 = (value) => validate1367(value) || validate1370(value);
241
+ const validate1367 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "provider") && Object.hasOwn(value, "wabaId") && (!Object.hasOwn(value, "provider") || validate1368(value["provider"])) && (!Object.hasOwn(value, "wabaId") || validate2(value["wabaId"]));
242
+ const validate1368 = (value) => typeof value === "string" && value === "whatsapp";
243
+ const validate1370 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "provider") && Object.hasOwn(value, "entityId") && Object.hasOwn(value, "headerId") && (!Object.hasOwn(value, "provider") || validate1371(value["provider"])) && (!Object.hasOwn(value, "entityId") || validate2(value["entityId"])) && (!Object.hasOwn(value, "headerId") || validate2(value["headerId"]));
244
+ const validate1371 = (value) => typeof value === "string" && value === "dlt";
245
+ const validate1376 = (value) => typeof value === "string" && (value === "draft" || value === "submitted" || value === "approved" || value === "rejected" || value === "paused" || value === "disabled");
246
+ const validate1377 = (value) => validate1365(value) || validate6(value);
247
+ const validate1380 = (value) => typeof value === "string" && (value === "marketing" || value === "utility" || value === "authentication" || value === "transactional" || value === "service_implicit" || value === "service_explicit" || value === "promotional");
248
+ const validate1381 = (value) => validate1380(value) || validate6(value);
249
+ const validate1398 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1399(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1401(value["data"]));
250
+ const validate1399 = (value) => typeof value === "string" && value === "flow.registration.updated";
251
+ const validate1401 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "flowId") && Object.hasOwn(value, "versionId") && Object.hasOwn(value, "versionNumber") && Object.hasOwn(value, "wabaId") && Object.hasOwn(value, "providerFlowId") && Object.hasOwn(value, "name") && Object.hasOwn(value, "status") && Object.hasOwn(value, "validationErrors") && Object.hasOwn(value, "endpointAlerts") && Object.hasOwn(value, "publishedAt") && Object.hasOwn(value, "statusChangedAt") && Object.hasOwn(value, "createdAt") && Object.hasOwn(value, "updatedAt") && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "previousStatus") && (!Object.hasOwn(value, "id") || validate1402(value["id"])) && (!Object.hasOwn(value, "flowId") || validate753(value["flowId"])) && (!Object.hasOwn(value, "versionId") || validate759(value["versionId"])) && (!Object.hasOwn(value, "versionNumber") || validate1283(value["versionNumber"])) && (!Object.hasOwn(value, "wabaId") || validate2(value["wabaId"])) && (!Object.hasOwn(value, "providerFlowId") || validate8(value["providerFlowId"])) && (!Object.hasOwn(value, "name") || validate2(value["name"])) && (!Object.hasOwn(value, "status") || validate1411(value["status"])) && (!Object.hasOwn(value, "validationErrors") || validate1412(value["validationErrors"])) && (!Object.hasOwn(value, "endpointAlerts") || validate1419(value["endpointAlerts"])) && (!Object.hasOwn(value, "publishedAt") || validate8(value["publishedAt"])) && (!Object.hasOwn(value, "statusChangedAt") || validate2(value["statusChangedAt"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"])) && (!Object.hasOwn(value, "updatedAt") || validate2(value["updatedAt"])) && (!Object.hasOwn(value, "organizationId") || validate859(value["organizationId"])) && (!Object.hasOwn(value, "previousStatus") || validate1437(value["previousStatus"]));
252
+ const validate1402 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^wafreg_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
253
+ const validate1411 = (value) => typeof value === "string" && (value === "draft" || value === "published" || value === "throttled" || value === "blocked" || value === "deprecated");
254
+ const validate1412 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate1413);
255
+ const validate1413 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "error") && Object.hasOwn(value, "message") && (!Object.hasOwn(value, "error") || validate2(value["error"])) && (!Object.hasOwn(value, "message") || validate2(value["message"])) && (!Object.hasOwn(value, "path") || validate2(value["path"])) && (!Object.hasOwn(value, "line") || validate1283(value["line"])) && (!Object.hasOwn(value, "column") || validate1283(value["column"]));
256
+ const validate1419 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate1420);
257
+ const validate1420 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "kind") && Object.hasOwn(value, "message") && Object.hasOwn(value, "value") && Object.hasOwn(value, "threshold") && Object.hasOwn(value, "activatedAt") && (!Object.hasOwn(value, "kind") || validate2(value["kind"])) && (!Object.hasOwn(value, "message") || validate2(value["message"])) && (!Object.hasOwn(value, "value") || validate14(value["value"])) && (!Object.hasOwn(value, "threshold") || validate14(value["threshold"])) && (!Object.hasOwn(value, "activatedAt") || validate2(value["activatedAt"]));
258
+ const validate1437 = (value) => validate1411(value) || validate6(value);
259
+ const validate1440 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1441(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1443(value["data"]));
260
+ const validate1441 = (value) => typeof value === "string" && value === "whatsapp.number.connected";
261
+ const validate1443 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "businessAccountId") && Object.hasOwn(value, "phoneNumber") && Object.hasOwn(value, "phoneNumberId") && Object.hasOwn(value, "whatsappBusinessAccountId") && Object.hasOwn(value, "displayName") && Object.hasOwn(value, "verificationStatus") && Object.hasOwn(value, "reconnected") && Object.hasOwn(value, "setupLink") && (!Object.hasOwn(value, "organizationId") || validate859(value["organizationId"])) && (!Object.hasOwn(value, "namespaceId") || validate1343(value["namespaceId"])) && (!Object.hasOwn(value, "businessAccountId") || validate1448(value["businessAccountId"])) && (!Object.hasOwn(value, "phoneNumber") || validate2(value["phoneNumber"])) && (!Object.hasOwn(value, "phoneNumberId") || validate2(value["phoneNumberId"])) && (!Object.hasOwn(value, "whatsappBusinessAccountId") || validate2(value["whatsappBusinessAccountId"])) && (!Object.hasOwn(value, "displayName") || validate2(value["displayName"])) && (!Object.hasOwn(value, "verificationStatus") || validate1453(value["verificationStatus"])) && (!Object.hasOwn(value, "reconnected") || validate33(value["reconnected"])) && (!Object.hasOwn(value, "setupLink") || validate1455(value["setupLink"]));
262
+ const validate1448 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^waba_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
263
+ const validate1453 = (value) => typeof value === "string" && (value === "pending" || value === "verified" || value === "failed" || value === "suspended");
264
+ const validate1455 = (value) => validate1456(value) || validate6(value);
265
+ const validate1456 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "metadata") && (!Object.hasOwn(value, "id") || validate1457(value["id"])) && (!Object.hasOwn(value, "metadata") || validate1458(value["metadata"]));
266
+ const validate1457 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^wasl_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
267
+ const validate1458 = (value) => isObject(value) && isObject(value);
268
+ const validate1460 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1461(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1463(value["data"]));
269
+ const validate1461 = (value) => typeof value === "string" && value === "mailbox.message.received";
270
+ const validate1463 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "message") && Object.hasOwn(value, "thread") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1343(value["namespaceId"])) && (!Object.hasOwn(value, "message") || validate1468(value["message"])) && (!Object.hasOwn(value, "thread") || validate1503(value["thread"]));
271
+ const validate1468 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "from") && Object.hasOwn(value, "to") && Object.hasOwn(value, "cc") && Object.hasOwn(value, "subject") && Object.hasOwn(value, "text") && Object.hasOwn(value, "replyText") && Object.hasOwn(value, "attachments") && Object.hasOwn(value, "occurredAt") && (!Object.hasOwn(value, "flowSubmissionHandledBy") || validate843(value["flowSubmissionHandledBy"])) && (!Object.hasOwn(value, "id") || validate786(value["id"])) && (!Object.hasOwn(value, "campaign") || validate596(value["campaign"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "threadId") || validate1477(value["threadId"])) && (!Object.hasOwn(value, "from") || validate1478(value["from"])) && (!Object.hasOwn(value, "to") || validate45(value["to"])) && (!Object.hasOwn(value, "cc") || validate45(value["cc"])) && (!Object.hasOwn(value, "subject") || validate8(value["subject"])) && (!Object.hasOwn(value, "text") || validate8(value["text"])) && (!Object.hasOwn(value, "replyText") || validate8(value["replyText"])) && (!Object.hasOwn(value, "attachments") || validate1496(value["attachments"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"]));
272
+ const validate1477 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^thread_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
273
+ const validate1478 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "address") && (!Object.hasOwn(value, "address") || validate2(value["address"])) && (!Object.hasOwn(value, "name") || validate8(value["name"]));
274
+ const validate1496 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate1497);
275
+ const validate1497 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "filename") && Object.hasOwn(value, "contentType") && Object.hasOwn(value, "size") && (!Object.hasOwn(value, "id") || validate1498(value["id"])) && (!Object.hasOwn(value, "filename") || validate2(value["filename"])) && (!Object.hasOwn(value, "contentType") || validate2(value["contentType"])) && (!Object.hasOwn(value, "size") || validate15(value["size"]));
276
+ const validate1498 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^att_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
277
+ const validate1503 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "subject") && Object.hasOwn(value, "preview") && (!Object.hasOwn(value, "id") || validate1477(value["id"])) && (!Object.hasOwn(value, "endpointId") || validate1505(value["endpointId"])) && (!Object.hasOwn(value, "subject") || validate8(value["subject"])) && (!Object.hasOwn(value, "preview") || validate8(value["preview"]));
278
+ const validate1505 = (value) => validate1506(value) || validate6(value);
279
+ const validate1506 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^mbxep_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
280
+ const validate1514 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1515(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1517(value["data"]));
281
+ const validate1515 = (value) => typeof value === "string" && value === "mailbox.message.sent";
282
+ const validate1517 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "actionId") && Object.hasOwn(value, "actor") && Object.hasOwn(value, "message") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1343(value["namespaceId"])) && (!Object.hasOwn(value, "actionId") || validate1522(value["actionId"])) && (!Object.hasOwn(value, "state") || validate1523(value["state"])) && (!Object.hasOwn(value, "acceptedAt") || validate2(value["acceptedAt"])) && (!Object.hasOwn(value, "actor") || validate1525(value["actor"])) && (!Object.hasOwn(value, "message") || validate1468(value["message"]));
283
+ const validate1522 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^mbxact_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
284
+ const validate1523 = (value) => typeof value === "string" && value === "completed";
285
+ const validate1525 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "kind") && Object.hasOwn(value, "id") && Object.hasOwn(value, "source") && (!Object.hasOwn(value, "kind") || validate1526(value["kind"])) && (!Object.hasOwn(value, "id") || validate2(value["id"])) && (!Object.hasOwn(value, "displayName") || validate8(value["displayName"])) && (!Object.hasOwn(value, "source") || validate1531(value["source"]));
286
+ const validate1526 = (value) => typeof value === "string" && (value === "user" || value === "apiKey" || value === "extension" || value === "externalAgent" || value === "samvaAgent" || value === "system");
287
+ const validate1531 = (value) => typeof value === "string" && (value === "humanUi" || value === "externalApi" || value === "externalAgent" || value === "extension" || value === "samvaManagedAgent" || value === "system");
288
+ const validate1567 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1568(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1570(value["data"]));
289
+ const validate1568 = (value) => typeof value === "string" && value === "mailbox.action.pending_approval";
290
+ const validate1570 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "action") && Object.hasOwn(value, "draft") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1343(value["namespaceId"])) && (!Object.hasOwn(value, "action") || validate1575(value["action"])) && (!Object.hasOwn(value, "draft") || validate1645(value["draft"])) && (!Object.hasOwn(value, "tool") || validate1655(value["tool"]));
291
+ const validate1575 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "type") && Object.hasOwn(value, "reviewRound") && Object.hasOwn(value, "decision") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "proposedBy") && Object.hasOwn(value, "createdAt") && (!Object.hasOwn(value, "id") || validate1522(value["id"])) && (!Object.hasOwn(value, "type") || validate1577(value["type"])) && (!Object.hasOwn(value, "reviewRound") || validate1578(value["reviewRound"])) && (!Object.hasOwn(value, "state") || validate1579(value["state"])) && (!Object.hasOwn(value, "decision") || validate1580(value["decision"])) && (!Object.hasOwn(value, "threadId") || validate1631(value["threadId"])) && (!Object.hasOwn(value, "reason") || validate8(value["reason"])) && (!Object.hasOwn(value, "proposedBy") || validate1525(value["proposedBy"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"]));
292
+ const validate1577 = (value) => typeof value === "string" && (value === "sendMessage" || value === "reply" || value === "updateDraft" || value === "createNote" || value === "assignThread" || value === "changeThreadState" || value === "call" || value === "extensionRequest" || value === "toolCall" || value === "handoff");
293
+ const validate1578 = (value) => typeof value === "number" && Number.isInteger(value) && typeof value === "number" && value <= 9007199254740991 && typeof value === "number" && value > 0;
294
+ const validate1579 = (value) => typeof value === "string" && value === "approvalRequired";
295
+ const validate1580 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "reviewRound") && Object.hasOwn(value, "requirement") && Object.hasOwn(value, "decider") && Object.hasOwn(value, "outcome") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "scopes") && (!Object.hasOwn(value, "id") || validate1581(value["id"])) && (!Object.hasOwn(value, "reviewRound") || validate1578(value["reviewRound"])) && (!Object.hasOwn(value, "requirement") || validate1583(value["requirement"])) && (!Object.hasOwn(value, "decider") || validate1584(value["decider"])) && (!Object.hasOwn(value, "outcome") || validate1585(value["outcome"])) && (!Object.hasOwn(value, "reason") || validate1586(value["reason"])) && (!Object.hasOwn(value, "scopes") || validate1587(value["scopes"])) && (!Object.hasOwn(value, "rule") || validate1591(value["rule"])) && (!Object.hasOwn(value, "guard") || validate1598(value["guard"])) && (!Object.hasOwn(value, "guardReason") || validate1598(value["guardReason"])) && (!Object.hasOwn(value, "resolution") || validate1604(value["resolution"]));
296
+ const validate1581 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^pdec_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
297
+ const validate1583 = (value) => typeof value === "string" && (value === "run" || value === "model" || value === "person" || value === "never");
298
+ const validate1584 = (value) => typeof value === "string" && (value === "rule" || value === "model" || value === "person" || value === "agent");
299
+ const validate1585 = (value) => typeof value === "string" && (value === "allow" || value === "hold" || value === "refuse");
300
+ const validate1586 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1;
301
+ const validate1587 = (value) => Array.isArray(value) && Array.isArray(value) && value.every(validate1588);
302
+ const validate1588 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "kind") && Object.hasOwn(value, "id") && (!Object.hasOwn(value, "kind") || validate1589(value["kind"])) && (!Object.hasOwn(value, "id") || validate1586(value["id"]));
303
+ const validate1589 = (value) => typeof value === "string" && (value === "organization" || value === "integration" || value === "mailbox" || value === "agent" || value === "apiKey");
304
+ const validate1591 = (value) => validate1592(value) || validate6(value);
305
+ const validate1592 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "scope") && Object.hasOwn(value, "index") && (!Object.hasOwn(value, "scope") || validate1588(value["scope"])) && (!Object.hasOwn(value, "index") || validate1596(value["index"]));
306
+ const validate1596 = (value) => typeof value === "number" && Number.isInteger(value) && typeof value === "number" && value >= 0 && typeof value === "number" && value <= 9007199254740991;
307
+ const validate1598 = (value) => validate1586(value) || validate6(value);
308
+ const validate1604 = (value) => validate1605(value) || validate6(value);
309
+ const validate1605 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "by") && Object.hasOwn(value, "at") && Object.hasOwn(value, "as") && (!Object.hasOwn(value, "by") || validate1606(value["by"])) && (!Object.hasOwn(value, "at") || validate2(value["at"])) && (!Object.hasOwn(value, "as") || validate1608(value["as"])) && (!Object.hasOwn(value, "diff") || validate1609(value["diff"]));
310
+ const validate1606 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^user_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
311
+ const validate1608 = (value) => typeof value === "string" && (value === "approved" || value === "edited" || value === "denied" || value === "alwaysAllowed");
312
+ const validate1609 = (value) => validate1610(value) || validate6(value);
313
+ const validate1610 = (value) => isObject(value) && isObject(value) && (!Object.hasOwn(value, "text") || validate1611(value["text"])) && (!Object.hasOwn(value, "html") || validate1611(value["html"]));
314
+ const validate1611 = (value) => validate1612(value) || validate6(value);
315
+ const validate1612 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "before") && Object.hasOwn(value, "after") && (!Object.hasOwn(value, "before") || validate8(value["before"])) && (!Object.hasOwn(value, "after") || validate8(value["after"]));
316
+ const validate1631 = (value) => validate1477(value) || validate6(value);
317
+ const validate1645 = (value) => validate1646(value) || validate6(value);
318
+ const validate1646 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "to") && Object.hasOwn(value, "cc") && Object.hasOwn(value, "subject") && (!Object.hasOwn(value, "to") || validate45(value["to"])) && (!Object.hasOwn(value, "cc") || validate45(value["cc"])) && (!Object.hasOwn(value, "subject") || validate8(value["subject"]));
319
+ const validate1655 = (value) => validate1656(value) || validate6(value);
320
+ const validate1656 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "name") && Object.hasOwn(value, "argumentsHash") && Object.hasOwn(value, "arguments") && (!Object.hasOwn(value, "name") || validate1657(value["name"])) && (!Object.hasOwn(value, "argumentsHash") || validate1658(value["argumentsHash"])) && (!Object.hasOwn(value, "arguments") || validate12(value["arguments"]));
321
+ const validate1657 = (value) => typeof value === "string" && typeof value === "string" && Array.from(value).length >= 1 && typeof value === "string" && Array.from(value).length <= 128;
322
+ const validate1658 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^[0-9a-f]{64}$", "u")).test(value);
323
+ const validate1661 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1662(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1664(value["data"]));
324
+ const validate1662 = (value) => typeof value === "string" && value === "mailbox.action.resolved";
325
+ const validate1664 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "action") && Object.hasOwn(value, "resolution") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1343(value["namespaceId"])) && (!Object.hasOwn(value, "action") || validate1669(value["action"])) && (!Object.hasOwn(value, "resolution") || validate1684(value["resolution"]));
326
+ const validate1669 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "type") && Object.hasOwn(value, "reviewRound") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "proposedBy") && Object.hasOwn(value, "createdAt") && (!Object.hasOwn(value, "id") || validate1522(value["id"])) && (!Object.hasOwn(value, "type") || validate1577(value["type"])) && (!Object.hasOwn(value, "reviewRound") || validate1578(value["reviewRound"])) && (!Object.hasOwn(value, "threadId") || validate1631(value["threadId"])) && (!Object.hasOwn(value, "proposedBy") || validate1525(value["proposedBy"])) && (!Object.hasOwn(value, "createdAt") || validate2(value["createdAt"]));
327
+ const validate1684 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "outcome") && Object.hasOwn(value, "actor") && Object.hasOwn(value, "resolvedAt") && Object.hasOwn(value, "reason") && (!Object.hasOwn(value, "outcome") || validate1685(value["outcome"])) && (!Object.hasOwn(value, "actor") || validate1525(value["actor"])) && (!Object.hasOwn(value, "resolvedAt") || validate2(value["resolvedAt"])) && (!Object.hasOwn(value, "reason") || validate8(value["reason"]));
328
+ const validate1685 = (value) => typeof value === "string" && (value === "approved" || value === "denied" || value === "cancelled");
329
+ const validate1697 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1698(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1700(value["data"]));
330
+ const validate1698 = (value) => typeof value === "string" && value === "mailbox.message.spam";
331
+ const validate1700 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "disposition") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "source") && Object.hasOwn(value, "message") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1343(value["namespaceId"])) && (!Object.hasOwn(value, "disposition") || validate1705(value["disposition"])) && (!Object.hasOwn(value, "threadId") || validate1631(value["threadId"])) && (!Object.hasOwn(value, "reason") || validate593(value["reason"])) && (!Object.hasOwn(value, "source") || validate1712(value["source"])) && (!Object.hasOwn(value, "message") || validate1713(value["message"]));
332
+ const validate1705 = (value) => typeof value === "string" && (value === "spam" || value === "isolated");
333
+ const validate1712 = (value) => typeof value === "string" && (value === "receipt" || value === "classifier" || value === "reader");
334
+ const validate1713 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "from") && Object.hasOwn(value, "subject") && Object.hasOwn(value, "receivedAt") && (!Object.hasOwn(value, "id") || validate786(value["id"])) && (!Object.hasOwn(value, "from") || validate1478(value["from"])) && (!Object.hasOwn(value, "subject") || validate8(value["subject"])) && (!Object.hasOwn(value, "receivedAt") || validate2(value["receivedAt"]));
335
+ const validate1724 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1725(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1727(value["data"]));
336
+ const validate1725 = (value) => typeof value === "string" && value === "mailbox.message.discarded";
337
+ const validate1727 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "discardedBy") && Object.hasOwn(value, "disposition") && Object.hasOwn(value, "reason") && Object.hasOwn(value, "message") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1343(value["namespaceId"])) && (!Object.hasOwn(value, "discardedBy") || validate1525(value["discardedBy"])) && (!Object.hasOwn(value, "disposition") || validate1739(value["disposition"])) && (!Object.hasOwn(value, "reason") || validate594(value["reason"])) && (!Object.hasOwn(value, "message") || validate1713(value["message"]));
338
+ const validate1739 = (value) => typeof value === "string" && (value === "quarantined" || value === "isolated");
339
+ const validate1752 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1753(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1755(value["data"]));
340
+ const validate1753 = (value) => typeof value === "string" && value === "mailbox.thread.deleted";
341
+ const validate1755 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "threadId") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1343(value["namespaceId"])) && (!Object.hasOwn(value, "threadId") || validate1477(value["threadId"]));
342
+ const validate1761 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1762(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1764(value["data"]));
343
+ const validate1762 = (value) => typeof value === "string" && value === "mailbox.message.delivered";
344
+ const validate1764 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "actionId") && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "recipient") && Object.hasOwn(value, "occurredAt") && Object.hasOwn(value, "status") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1343(value["namespaceId"])) && (!Object.hasOwn(value, "threadId") || validate1477(value["threadId"])) && (!Object.hasOwn(value, "actionId") || validate1522(value["actionId"])) && (!Object.hasOwn(value, "messageId") || validate786(value["messageId"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "recipient") || validate2(value["recipient"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"])) && (!Object.hasOwn(value, "status") || validate1775(value["status"]));
345
+ const validate1775 = (value) => typeof value === "string" && value === "delivered";
346
+ const validate1776 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1777(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1779(value["data"]));
347
+ const validate1777 = (value) => typeof value === "string" && value === "mailbox.message.read";
348
+ const validate1779 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "actionId") && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "recipient") && Object.hasOwn(value, "occurredAt") && Object.hasOwn(value, "status") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1343(value["namespaceId"])) && (!Object.hasOwn(value, "threadId") || validate1477(value["threadId"])) && (!Object.hasOwn(value, "actionId") || validate1522(value["actionId"])) && (!Object.hasOwn(value, "messageId") || validate786(value["messageId"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "recipient") || validate2(value["recipient"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"])) && (!Object.hasOwn(value, "status") || validate1790(value["status"]));
349
+ const validate1790 = (value) => typeof value === "string" && value === "read";
350
+ const validate1791 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1792(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1794(value["data"]));
351
+ const validate1792 = (value) => typeof value === "string" && value === "mailbox.message.failed";
352
+ const validate1794 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "mailboxId") && Object.hasOwn(value, "namespaceId") && Object.hasOwn(value, "threadId") && Object.hasOwn(value, "actionId") && Object.hasOwn(value, "messageId") && Object.hasOwn(value, "channel") && Object.hasOwn(value, "recipient") && Object.hasOwn(value, "occurredAt") && Object.hasOwn(value, "status") && Object.hasOwn(value, "error") && (!Object.hasOwn(value, "mailboxId") || validate5(value["mailboxId"])) && (!Object.hasOwn(value, "namespaceId") || validate1343(value["namespaceId"])) && (!Object.hasOwn(value, "threadId") || validate1477(value["threadId"])) && (!Object.hasOwn(value, "actionId") || validate1522(value["actionId"])) && (!Object.hasOwn(value, "messageId") || validate786(value["messageId"])) && (!Object.hasOwn(value, "channel") || validate7(value["channel"])) && (!Object.hasOwn(value, "recipient") || validate2(value["recipient"])) && (!Object.hasOwn(value, "occurredAt") || validate2(value["occurredAt"])) && (!Object.hasOwn(value, "status") || validate1805(value["status"])) && (!Object.hasOwn(value, "error") || validate1806(value["error"]));
353
+ const validate1805 = (value) => typeof value === "string" && value === "failed";
354
+ const validate1806 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "code") && Object.hasOwn(value, "message") && (!Object.hasOwn(value, "code") || validate8(value["code"])) && (!Object.hasOwn(value, "message") || validate8(value["message"]));
355
+ const validate1813 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "type") && Object.hasOwn(value, "timestamp") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "type") || validate1814(value["type"])) && (!Object.hasOwn(value, "timestamp") || validate2(value["timestamp"])) && (!Object.hasOwn(value, "data") || validate1816(value["data"]));
356
+ const validate1814 = (value) => typeof value === "string" && value === "journey.webhook";
357
+ const validate1816 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "organizationId") && Object.hasOwn(value, "journeyId") && Object.hasOwn(value, "journeyVersion") && Object.hasOwn(value, "runId") && Object.hasOwn(value, "nodeId") && Object.hasOwn(value, "contact") && Object.hasOwn(value, "data") && (!Object.hasOwn(value, "organizationId") || validate859(value["organizationId"])) && (!Object.hasOwn(value, "journeyId") || validate1818(value["journeyId"])) && (!Object.hasOwn(value, "journeyVersion") || validate1283(value["journeyVersion"])) && (!Object.hasOwn(value, "runId") || validate1820(value["runId"])) && (!Object.hasOwn(value, "nodeId") || validate2(value["nodeId"])) && (!Object.hasOwn(value, "contact") || validate1822(value["contact"])) && (!Object.hasOwn(value, "data") || validate12(value["data"]));
358
+ const validate1818 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^jrny_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
359
+ const validate1820 = (value) => typeof value === "string" && typeof value === "string" && (/* @__PURE__ */ new RegExp("^jrun_[0-9a-hjkmnp-tv-z]{16,24}$", "u")).test(value);
360
+ const validate1822 = (value) => isObject(value) && isObject(value) && Object.hasOwn(value, "id") && Object.hasOwn(value, "externalId") && Object.hasOwn(value, "email") && (!Object.hasOwn(value, "id") || validate958(value["id"])) && (!Object.hasOwn(value, "externalId") || validate8(value["externalId"])) && (!Object.hasOwn(value, "email") || validate8(value["email"]));
359
361
  /** Narrow an event to a structurally valid payload known to this package. */
360
362
  const isKnownEvent = (value) => {
361
363
  switch (value.type) {
@@ -366,40 +368,40 @@ const isKnownEvent = (value) => {
366
368
  case "message.bounced": return validate344(value);
367
369
  case "message.complained": return validate426(value);
368
370
  case "message.received": return validate508(value);
369
- case "message.opened": return validate850(value);
370
- case "message.clicked": return validate898(value);
371
- case "contact.created": return validate950(value);
372
- case "contact.updated": return validate974(value);
373
- case "contact.deleted": return validate998(value);
374
- case "contact.subscribed": return validate1022(value);
375
- case "contact.unsubscribed": return validate1060(value);
376
- case "contact.resubscribed": return validate1098(value);
377
- case "contact.consent_changed": return validate1136(value);
378
- case "conversation.created": return validate1153(value);
379
- case "conversation.updated": return validate1173(value);
380
- case "conversation.archived": return validate1193(value);
381
- case "webhook.created": return validate1213(value);
382
- case "webhook.updated": return validate1230(value);
383
- case "webhook.deleted": return validate1247(value);
384
- case "webhook.test": return validate1264(value);
385
- case "domain.updated": return validate1268(value);
386
- case "domain.warming.updated": return validate1310(value);
387
- case "email.sending.paused": return validate1334(value);
388
- case "email.sending.resumed": return validate1344(value);
389
- case "template.registration.updated": return validate1354(value);
390
- case "flow.registration.updated": return validate1394(value);
391
- case "whatsapp.number.connected": return validate1436(value);
392
- case "mailbox.message.received": return validate1456(value);
393
- case "mailbox.message.sent": return validate1509(value);
394
- case "mailbox.action.pending_approval": return validate1561(value);
395
- case "mailbox.action.resolved": return validate1655(value);
396
- case "mailbox.message.spam": return validate1691(value);
397
- case "mailbox.message.discarded": return validate1718(value);
398
- case "mailbox.thread.deleted": return validate1746(value);
399
- case "mailbox.message.delivered": return validate1755(value);
400
- case "mailbox.message.read": return validate1770(value);
401
- case "mailbox.message.failed": return validate1785(value);
402
- case "journey.webhook": return validate1807(value);
371
+ case "message.opened": return validate854(value);
372
+ case "message.clicked": return validate902(value);
373
+ case "contact.created": return validate954(value);
374
+ case "contact.updated": return validate978(value);
375
+ case "contact.deleted": return validate1002(value);
376
+ case "contact.subscribed": return validate1026(value);
377
+ case "contact.unsubscribed": return validate1064(value);
378
+ case "contact.resubscribed": return validate1102(value);
379
+ case "contact.consent_changed": return validate1140(value);
380
+ case "conversation.created": return validate1157(value);
381
+ case "conversation.updated": return validate1177(value);
382
+ case "conversation.archived": return validate1197(value);
383
+ case "webhook.created": return validate1217(value);
384
+ case "webhook.updated": return validate1234(value);
385
+ case "webhook.deleted": return validate1251(value);
386
+ case "webhook.test": return validate1268(value);
387
+ case "domain.updated": return validate1272(value);
388
+ case "domain.warming.updated": return validate1314(value);
389
+ case "email.sending.paused": return validate1338(value);
390
+ case "email.sending.resumed": return validate1348(value);
391
+ case "template.registration.updated": return validate1358(value);
392
+ case "flow.registration.updated": return validate1398(value);
393
+ case "whatsapp.number.connected": return validate1440(value);
394
+ case "mailbox.message.received": return validate1460(value);
395
+ case "mailbox.message.sent": return validate1514(value);
396
+ case "mailbox.action.pending_approval": return validate1567(value);
397
+ case "mailbox.action.resolved": return validate1661(value);
398
+ case "mailbox.message.spam": return validate1697(value);
399
+ case "mailbox.message.discarded": return validate1724(value);
400
+ case "mailbox.thread.deleted": return validate1752(value);
401
+ case "mailbox.message.delivered": return validate1761(value);
402
+ case "mailbox.message.read": return validate1776(value);
403
+ case "mailbox.message.failed": return validate1791(value);
404
+ case "journey.webhook": return validate1813(value);
403
405
  default: return false;
404
406
  }
405
407
  };
@@ -413,40 +415,40 @@ const validateEvent = (value) => {
413
415
  case "message.bounced": return validate344(value);
414
416
  case "message.complained": return validate426(value);
415
417
  case "message.received": return validate508(value);
416
- case "message.opened": return validate850(value);
417
- case "message.clicked": return validate898(value);
418
- case "contact.created": return validate950(value);
419
- case "contact.updated": return validate974(value);
420
- case "contact.deleted": return validate998(value);
421
- case "contact.subscribed": return validate1022(value);
422
- case "contact.unsubscribed": return validate1060(value);
423
- case "contact.resubscribed": return validate1098(value);
424
- case "contact.consent_changed": return validate1136(value);
425
- case "conversation.created": return validate1153(value);
426
- case "conversation.updated": return validate1173(value);
427
- case "conversation.archived": return validate1193(value);
428
- case "webhook.created": return validate1213(value);
429
- case "webhook.updated": return validate1230(value);
430
- case "webhook.deleted": return validate1247(value);
431
- case "webhook.test": return validate1264(value);
432
- case "domain.updated": return validate1268(value);
433
- case "domain.warming.updated": return validate1310(value);
434
- case "email.sending.paused": return validate1334(value);
435
- case "email.sending.resumed": return validate1344(value);
436
- case "template.registration.updated": return validate1354(value);
437
- case "flow.registration.updated": return validate1394(value);
438
- case "whatsapp.number.connected": return validate1436(value);
439
- case "mailbox.message.received": return validate1456(value);
440
- case "mailbox.message.sent": return validate1509(value);
441
- case "mailbox.action.pending_approval": return validate1561(value);
442
- case "mailbox.action.resolved": return validate1655(value);
443
- case "mailbox.message.spam": return validate1691(value);
444
- case "mailbox.message.discarded": return validate1718(value);
445
- case "mailbox.thread.deleted": return validate1746(value);
446
- case "mailbox.message.delivered": return validate1755(value);
447
- case "mailbox.message.read": return validate1770(value);
448
- case "mailbox.message.failed": return validate1785(value);
449
- case "journey.webhook": return validate1807(value);
418
+ case "message.opened": return validate854(value);
419
+ case "message.clicked": return validate902(value);
420
+ case "contact.created": return validate954(value);
421
+ case "contact.updated": return validate978(value);
422
+ case "contact.deleted": return validate1002(value);
423
+ case "contact.subscribed": return validate1026(value);
424
+ case "contact.unsubscribed": return validate1064(value);
425
+ case "contact.resubscribed": return validate1102(value);
426
+ case "contact.consent_changed": return validate1140(value);
427
+ case "conversation.created": return validate1157(value);
428
+ case "conversation.updated": return validate1177(value);
429
+ case "conversation.archived": return validate1197(value);
430
+ case "webhook.created": return validate1217(value);
431
+ case "webhook.updated": return validate1234(value);
432
+ case "webhook.deleted": return validate1251(value);
433
+ case "webhook.test": return validate1268(value);
434
+ case "domain.updated": return validate1272(value);
435
+ case "domain.warming.updated": return validate1314(value);
436
+ case "email.sending.paused": return validate1338(value);
437
+ case "email.sending.resumed": return validate1348(value);
438
+ case "template.registration.updated": return validate1358(value);
439
+ case "flow.registration.updated": return validate1398(value);
440
+ case "whatsapp.number.connected": return validate1440(value);
441
+ case "mailbox.message.received": return validate1460(value);
442
+ case "mailbox.message.sent": return validate1514(value);
443
+ case "mailbox.action.pending_approval": return validate1567(value);
444
+ case "mailbox.action.resolved": return validate1661(value);
445
+ case "mailbox.message.spam": return validate1697(value);
446
+ case "mailbox.message.discarded": return validate1724(value);
447
+ case "mailbox.thread.deleted": return validate1752(value);
448
+ case "mailbox.message.delivered": return validate1761(value);
449
+ case "mailbox.message.read": return validate1776(value);
450
+ case "mailbox.message.failed": return validate1791(value);
451
+ case "journey.webhook": return validate1813(value);
450
452
  default: return true;
451
453
  }
452
454
  };
@@ -725,4 +727,4 @@ const readWebhookHeaders = (headers) => requireHeaders({
725
727
  });
726
728
  export { generateWebhookSecret as a, verifyWebhookAt as c, MalformedWebhookPayloadError as d, WebhookCryptoError as f, isKnownEvent as g, WebhookVerificationError as h, WEBHOOK_TIMESTAMP_HEADER as i, InvalidWebhookHeadersError as l, WebhookTimestampError as m, WEBHOOK_ID_HEADER as n, readWebhookHeaders as o, WebhookSignatureError as p, WEBHOOK_SIGNATURE_HEADER as r, signWebhook as s, DEFAULT_TOLERANCE_SECONDS as t, InvalidWebhookSecretError as u };
727
729
 
728
- //# sourceMappingURL=protocol-COaro8fP.js.map
730
+ //# sourceMappingURL=protocol-Q3-Vd3-K.js.map