UNPKG

@microfox/whatsapp-business

Version:

WhatsApp Business API SDK: A lightweight, type-safe SDK for interacting with the WhatsApp Business API

1,536 lines (1,534 loc) 172 kB
import { z } from 'zod'; declare const WhatsAppSDKConfigSchema: z.ZodObject<{ phoneNumberId: z.ZodString; businessAccountId: z.ZodString; version: z.ZodDefault<z.ZodOptional<z.ZodString>>; baseUrl: z.ZodOptional<z.ZodString>; accessToken: z.ZodString; }, "strip", z.ZodTypeAny, { phoneNumberId: string; businessAccountId: string; version: string; accessToken: string; baseUrl?: string | undefined; }, { phoneNumberId: string; businessAccountId: string; accessToken: string; version?: string | undefined; baseUrl?: string | undefined; }>; declare const ReceipientTypeSchema: z.ZodEnum<["individual", "group"]>; declare const MessageOptionsSchema: z.ZodObject<{ recipientType: z.ZodEnum<["individual", "group"]>; }, "strip", z.ZodTypeAny, { recipientType: "individual" | "group"; }, { recipientType: "individual" | "group"; }>; declare const TextMessageOptionsSchema: z.ZodObject<{ recipientType: z.ZodEnum<["individual", "group"]>; } & { previewUrl: z.ZodOptional<z.ZodBoolean>; }, "strip", z.ZodTypeAny, { recipientType: "individual" | "group"; previewUrl?: boolean | undefined; }, { recipientType: "individual" | "group"; previewUrl?: boolean | undefined; }>; declare const TypingIndicatorOptionsSchema: z.ZodObject<{ messageId: z.ZodString; type: z.ZodOptional<z.ZodEnum<["text"]>>; }, "strip", z.ZodTypeAny, { messageId: string; type?: "text" | undefined; }, { messageId: string; type?: "text" | undefined; }>; declare const ContextSchema: z.ZodObject<{ message_id: z.ZodString; }, "strip", z.ZodTypeAny, { message_id: string; }, { message_id: string; }>; declare const MediaObjectSchema: z.ZodObject<{ id: z.ZodOptional<z.ZodString>; link: z.ZodOptional<z.ZodString>; caption: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }>; declare const LocationObjectSchema: z.ZodObject<{ longitude: z.ZodNumber; latitude: z.ZodNumber; name: z.ZodOptional<z.ZodString>; address: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { longitude: number; latitude: number; name?: string | undefined; address?: string | undefined; }, { longitude: number; latitude: number; name?: string | undefined; address?: string | undefined; }>; declare const ContactObjectSchema: z.ZodObject<{ name: z.ZodObject<{ formatted_name: z.ZodString; first_name: z.ZodOptional<z.ZodString>; last_name: z.ZodOptional<z.ZodString>; middle_name: z.ZodOptional<z.ZodString>; suffix: z.ZodOptional<z.ZodString>; prefix: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { formatted_name: string; first_name?: string | undefined; last_name?: string | undefined; middle_name?: string | undefined; suffix?: string | undefined; prefix?: string | undefined; }, { formatted_name: string; first_name?: string | undefined; last_name?: string | undefined; middle_name?: string | undefined; suffix?: string | undefined; prefix?: string | undefined; }>; phones: z.ZodArray<z.ZodObject<{ phone: z.ZodString; type: z.ZodOptional<z.ZodEnum<["CELL", "MAIN", "IPHONE", "HOME", "WORK"]>>; wa_id: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { phone: string; type?: "CELL" | "MAIN" | "IPHONE" | "HOME" | "WORK" | undefined; wa_id?: string | undefined; }, { phone: string; type?: "CELL" | "MAIN" | "IPHONE" | "HOME" | "WORK" | undefined; wa_id?: string | undefined; }>, "many">; emails: z.ZodOptional<z.ZodArray<z.ZodObject<{ email: z.ZodString; type: z.ZodOptional<z.ZodEnum<["HOME", "WORK"]>>; }, "strip", z.ZodTypeAny, { email: string; type?: "HOME" | "WORK" | undefined; }, { email: string; type?: "HOME" | "WORK" | undefined; }>, "many">>; urls: z.ZodOptional<z.ZodArray<z.ZodObject<{ url: z.ZodString; type: z.ZodOptional<z.ZodEnum<["HOME", "WORK"]>>; }, "strip", z.ZodTypeAny, { url: string; type?: "HOME" | "WORK" | undefined; }, { url: string; type?: "HOME" | "WORK" | undefined; }>, "many">>; addresses: z.ZodOptional<z.ZodArray<z.ZodObject<{ street: z.ZodOptional<z.ZodString>; city: z.ZodOptional<z.ZodString>; state: z.ZodOptional<z.ZodString>; zip: z.ZodOptional<z.ZodString>; country: z.ZodOptional<z.ZodString>; country_code: z.ZodOptional<z.ZodString>; type: z.ZodOptional<z.ZodEnum<["HOME", "WORK"]>>; }, "strip", z.ZodTypeAny, { type?: "HOME" | "WORK" | undefined; street?: string | undefined; city?: string | undefined; state?: string | undefined; zip?: string | undefined; country?: string | undefined; country_code?: string | undefined; }, { type?: "HOME" | "WORK" | undefined; street?: string | undefined; city?: string | undefined; state?: string | undefined; zip?: string | undefined; country?: string | undefined; country_code?: string | undefined; }>, "many">>; org: z.ZodOptional<z.ZodObject<{ company: z.ZodOptional<z.ZodString>; department: z.ZodOptional<z.ZodString>; title: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { company?: string | undefined; department?: string | undefined; title?: string | undefined; }, { company?: string | undefined; department?: string | undefined; title?: string | undefined; }>>; birthday: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { name: { formatted_name: string; first_name?: string | undefined; last_name?: string | undefined; middle_name?: string | undefined; suffix?: string | undefined; prefix?: string | undefined; }; phones: { phone: string; type?: "CELL" | "MAIN" | "IPHONE" | "HOME" | "WORK" | undefined; wa_id?: string | undefined; }[]; emails?: { email: string; type?: "HOME" | "WORK" | undefined; }[] | undefined; urls?: { url: string; type?: "HOME" | "WORK" | undefined; }[] | undefined; addresses?: { type?: "HOME" | "WORK" | undefined; street?: string | undefined; city?: string | undefined; state?: string | undefined; zip?: string | undefined; country?: string | undefined; country_code?: string | undefined; }[] | undefined; org?: { company?: string | undefined; department?: string | undefined; title?: string | undefined; } | undefined; birthday?: string | undefined; }, { name: { formatted_name: string; first_name?: string | undefined; last_name?: string | undefined; middle_name?: string | undefined; suffix?: string | undefined; prefix?: string | undefined; }; phones: { phone: string; type?: "CELL" | "MAIN" | "IPHONE" | "HOME" | "WORK" | undefined; wa_id?: string | undefined; }[]; emails?: { email: string; type?: "HOME" | "WORK" | undefined; }[] | undefined; urls?: { url: string; type?: "HOME" | "WORK" | undefined; }[] | undefined; addresses?: { type?: "HOME" | "WORK" | undefined; street?: string | undefined; city?: string | undefined; state?: string | undefined; zip?: string | undefined; country?: string | undefined; country_code?: string | undefined; }[] | undefined; org?: { company?: string | undefined; department?: string | undefined; title?: string | undefined; } | undefined; birthday?: string | undefined; }>; declare const ButtonSchema: z.ZodObject<{ type: z.ZodEnum<["reply", "url", "phone_number", "flow"]>; reply: z.ZodOptional<z.ZodObject<{ id: z.ZodString; title: z.ZodString; }, "strip", z.ZodTypeAny, { id: string; title: string; }, { id: string; title: string; }>>; url: z.ZodOptional<z.ZodObject<{ target: z.ZodString; display_text: z.ZodString; }, "strip", z.ZodTypeAny, { target: string; display_text: string; }, { target: string; display_text: string; }>>; phone_number: z.ZodOptional<z.ZodObject<{ number: z.ZodString; display_text: z.ZodString; }, "strip", z.ZodTypeAny, { number: string; display_text: string; }, { number: string; display_text: string; }>>; flow: z.ZodOptional<z.ZodObject<{ id: z.ZodString; tracking_data: z.ZodOptional<z.ZodString>; params: z.ZodOptional<z.ZodArray<z.ZodString, "many">>; }, "strip", z.ZodTypeAny, { id: string; params?: string[] | undefined; tracking_data?: string | undefined; }, { id: string; params?: string[] | undefined; tracking_data?: string | undefined; }>>; }, "strip", z.ZodTypeAny, { type: "url" | "reply" | "phone_number" | "flow"; url?: { target: string; display_text: string; } | undefined; reply?: { id: string; title: string; } | undefined; phone_number?: { number: string; display_text: string; } | undefined; flow?: { id: string; params?: string[] | undefined; tracking_data?: string | undefined; } | undefined; }, { type: "url" | "reply" | "phone_number" | "flow"; url?: { target: string; display_text: string; } | undefined; reply?: { id: string; title: string; } | undefined; phone_number?: { number: string; display_text: string; } | undefined; flow?: { id: string; params?: string[] | undefined; tracking_data?: string | undefined; } | undefined; }>; declare const ListSectionSchema: z.ZodObject<{ title: z.ZodString; rows: z.ZodArray<z.ZodObject<{ id: z.ZodString; title: z.ZodString; description: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id: string; title: string; description?: string | undefined; }, { id: string; title: string; description?: string | undefined; }>, "many">; }, "strip", z.ZodTypeAny, { title: string; rows: { id: string; title: string; description?: string | undefined; }[]; }, { title: string; rows: { id: string; title: string; description?: string | undefined; }[]; }>; declare const FlowActionPayloadSchema: z.ZodObject<{ screen: z.ZodOptional<z.ZodString>; data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>; }, "strip", z.ZodTypeAny, { screen?: string | undefined; data?: Record<string, any> | undefined; }, { screen?: string | undefined; data?: Record<string, any> | undefined; }>; declare const FlowParametersSchema: z.ZodObject<{ flow_message_version: z.ZodLiteral<"3">; flow_id: z.ZodOptional<z.ZodString>; flow_name: z.ZodOptional<z.ZodString>; flow_cta: z.ZodString; mode: z.ZodDefault<z.ZodOptional<z.ZodEnum<["draft", "published"]>>>; flow_token: z.ZodOptional<z.ZodString>; flow_action: z.ZodDefault<z.ZodOptional<z.ZodEnum<["navigate", "data_exchange"]>>>; flow_action_payload: z.ZodOptional<z.ZodObject<{ screen: z.ZodOptional<z.ZodString>; data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>; }, "strip", z.ZodTypeAny, { screen?: string | undefined; data?: Record<string, any> | undefined; }, { screen?: string | undefined; data?: Record<string, any> | undefined; }>>; }, "strip", z.ZodTypeAny, { flow_message_version: "3"; flow_cta: string; mode: "draft" | "published"; flow_action: "navigate" | "data_exchange"; flow_id?: string | undefined; flow_name?: string | undefined; flow_token?: string | undefined; flow_action_payload?: { screen?: string | undefined; data?: Record<string, any> | undefined; } | undefined; }, { flow_message_version: "3"; flow_cta: string; flow_id?: string | undefined; flow_name?: string | undefined; mode?: "draft" | "published" | undefined; flow_token?: string | undefined; flow_action?: "navigate" | "data_exchange" | undefined; flow_action_payload?: { screen?: string | undefined; data?: Record<string, any> | undefined; } | undefined; }>; declare const CtaUrlParametersSchema: z.ZodObject<{ display_text: z.ZodString; url: z.ZodString; }, "strip", z.ZodTypeAny, { url: string; display_text: string; }, { url: string; display_text: string; }>; declare const InteractiveMessageSchema$1: z.ZodObject<{ type: z.ZodEnum<["button", "list", "cta_url", "location_request"]>; header: z.ZodOptional<z.ZodObject<{ type: z.ZodEnum<["text", "image", "video", "document"]>; text: z.ZodOptional<z.ZodString>; image: z.ZodOptional<z.ZodObject<{ id: z.ZodOptional<z.ZodString>; link: z.ZodOptional<z.ZodString>; caption: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }>>; video: z.ZodOptional<z.ZodObject<{ id: z.ZodOptional<z.ZodString>; link: z.ZodOptional<z.ZodString>; caption: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }>>; document: z.ZodOptional<z.ZodObject<{ id: z.ZodOptional<z.ZodString>; link: z.ZodOptional<z.ZodString>; caption: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }>>; }, "strip", z.ZodTypeAny, { type: "text" | "image" | "video" | "document"; text?: string | undefined; image?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; video?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; document?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; }, { type: "text" | "image" | "video" | "document"; text?: string | undefined; image?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; video?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; document?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; }>>; body: z.ZodObject<{ text: z.ZodString; }, "strip", z.ZodTypeAny, { text: string; }, { text: string; }>; footer: z.ZodOptional<z.ZodObject<{ text: z.ZodString; }, "strip", z.ZodTypeAny, { text: string; }, { text: string; }>>; action: z.ZodObject<{ name: z.ZodOptional<z.ZodEnum<["cta_url"]>>; parameters: z.ZodOptional<z.ZodObject<{ display_text: z.ZodString; url: z.ZodString; }, "strip", z.ZodTypeAny, { url: string; display_text: string; }, { url: string; display_text: string; }>>; buttons: z.ZodOptional<z.ZodArray<z.ZodObject<{ type: z.ZodEnum<["reply", "url", "phone_number", "flow"]>; reply: z.ZodOptional<z.ZodObject<{ id: z.ZodString; title: z.ZodString; }, "strip", z.ZodTypeAny, { id: string; title: string; }, { id: string; title: string; }>>; url: z.ZodOptional<z.ZodObject<{ target: z.ZodString; display_text: z.ZodString; }, "strip", z.ZodTypeAny, { target: string; display_text: string; }, { target: string; display_text: string; }>>; phone_number: z.ZodOptional<z.ZodObject<{ number: z.ZodString; display_text: z.ZodString; }, "strip", z.ZodTypeAny, { number: string; display_text: string; }, { number: string; display_text: string; }>>; flow: z.ZodOptional<z.ZodObject<{ id: z.ZodString; tracking_data: z.ZodOptional<z.ZodString>; params: z.ZodOptional<z.ZodArray<z.ZodString, "many">>; }, "strip", z.ZodTypeAny, { id: string; params?: string[] | undefined; tracking_data?: string | undefined; }, { id: string; params?: string[] | undefined; tracking_data?: string | undefined; }>>; }, "strip", z.ZodTypeAny, { type: "url" | "reply" | "phone_number" | "flow"; url?: { target: string; display_text: string; } | undefined; reply?: { id: string; title: string; } | undefined; phone_number?: { number: string; display_text: string; } | undefined; flow?: { id: string; params?: string[] | undefined; tracking_data?: string | undefined; } | undefined; }, { type: "url" | "reply" | "phone_number" | "flow"; url?: { target: string; display_text: string; } | undefined; reply?: { id: string; title: string; } | undefined; phone_number?: { number: string; display_text: string; } | undefined; flow?: { id: string; params?: string[] | undefined; tracking_data?: string | undefined; } | undefined; }>, "many">>; button: z.ZodOptional<z.ZodString>; sections: z.ZodOptional<z.ZodArray<z.ZodObject<{ title: z.ZodString; rows: z.ZodArray<z.ZodObject<{ id: z.ZodString; title: z.ZodString; description: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id: string; title: string; description?: string | undefined; }, { id: string; title: string; description?: string | undefined; }>, "many">; }, "strip", z.ZodTypeAny, { title: string; rows: { id: string; title: string; description?: string | undefined; }[]; }, { title: string; rows: { id: string; title: string; description?: string | undefined; }[]; }>, "many">>; url: z.ZodOptional<z.ZodString>; location_request: z.ZodOptional<z.ZodObject<{ current_location: z.ZodOptional<z.ZodBoolean>; location_types: z.ZodOptional<z.ZodArray<z.ZodString, "many">>; }, "strip", z.ZodTypeAny, { current_location?: boolean | undefined; location_types?: string[] | undefined; }, { current_location?: boolean | undefined; location_types?: string[] | undefined; }>>; }, "strip", z.ZodTypeAny, { name?: "cta_url" | undefined; url?: string | undefined; button?: string | undefined; location_request?: { current_location?: boolean | undefined; location_types?: string[] | undefined; } | undefined; parameters?: { url: string; display_text: string; } | undefined; buttons?: { type: "url" | "reply" | "phone_number" | "flow"; url?: { target: string; display_text: string; } | undefined; reply?: { id: string; title: string; } | undefined; phone_number?: { number: string; display_text: string; } | undefined; flow?: { id: string; params?: string[] | undefined; tracking_data?: string | undefined; } | undefined; }[] | undefined; sections?: { title: string; rows: { id: string; title: string; description?: string | undefined; }[]; }[] | undefined; }, { name?: "cta_url" | undefined; url?: string | undefined; button?: string | undefined; location_request?: { current_location?: boolean | undefined; location_types?: string[] | undefined; } | undefined; parameters?: { url: string; display_text: string; } | undefined; buttons?: { type: "url" | "reply" | "phone_number" | "flow"; url?: { target: string; display_text: string; } | undefined; reply?: { id: string; title: string; } | undefined; phone_number?: { number: string; display_text: string; } | undefined; flow?: { id: string; params?: string[] | undefined; tracking_data?: string | undefined; } | undefined; }[] | undefined; sections?: { title: string; rows: { id: string; title: string; description?: string | undefined; }[]; }[] | undefined; }>; }, "strip", z.ZodTypeAny, { type: "button" | "list" | "cta_url" | "location_request"; body: { text: string; }; action: { name?: "cta_url" | undefined; url?: string | undefined; button?: string | undefined; location_request?: { current_location?: boolean | undefined; location_types?: string[] | undefined; } | undefined; parameters?: { url: string; display_text: string; } | undefined; buttons?: { type: "url" | "reply" | "phone_number" | "flow"; url?: { target: string; display_text: string; } | undefined; reply?: { id: string; title: string; } | undefined; phone_number?: { number: string; display_text: string; } | undefined; flow?: { id: string; params?: string[] | undefined; tracking_data?: string | undefined; } | undefined; }[] | undefined; sections?: { title: string; rows: { id: string; title: string; description?: string | undefined; }[]; }[] | undefined; }; header?: { type: "text" | "image" | "video" | "document"; text?: string | undefined; image?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; video?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; document?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; } | undefined; footer?: { text: string; } | undefined; }, { type: "button" | "list" | "cta_url" | "location_request"; body: { text: string; }; action: { name?: "cta_url" | undefined; url?: string | undefined; button?: string | undefined; location_request?: { current_location?: boolean | undefined; location_types?: string[] | undefined; } | undefined; parameters?: { url: string; display_text: string; } | undefined; buttons?: { type: "url" | "reply" | "phone_number" | "flow"; url?: { target: string; display_text: string; } | undefined; reply?: { id: string; title: string; } | undefined; phone_number?: { number: string; display_text: string; } | undefined; flow?: { id: string; params?: string[] | undefined; tracking_data?: string | undefined; } | undefined; }[] | undefined; sections?: { title: string; rows: { id: string; title: string; description?: string | undefined; }[]; }[] | undefined; }; header?: { type: "text" | "image" | "video" | "document"; text?: string | undefined; image?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; video?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; document?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; } | undefined; footer?: { text: string; } | undefined; }>; declare const ReactionSchema: z.ZodObject<{ message_id: z.ZodString; emoji: z.ZodString; }, "strip", z.ZodTypeAny, { message_id: string; emoji: string; }, { message_id: string; emoji: string; }>; declare const ReplyContextSchema: z.ZodObject<{ message_id: z.ZodString; forwarded: z.ZodOptional<z.ZodBoolean>; quoted: z.ZodOptional<z.ZodBoolean>; }, "strip", z.ZodTypeAny, { message_id: string; forwarded?: boolean | undefined; quoted?: boolean | undefined; }, { message_id: string; forwarded?: boolean | undefined; quoted?: boolean | undefined; }>; declare const FlowSchema: z.ZodObject<{ id: z.ZodString; token: z.ZodString; header: z.ZodObject<{ type: z.ZodLiteral<"text">; text: z.ZodString; }, "strip", z.ZodTypeAny, { type: "text"; text: string; }, { type: "text"; text: string; }>; body: z.ZodObject<{ text: z.ZodString; }, "strip", z.ZodTypeAny, { text: string; }, { text: string; }>; footer: z.ZodObject<{ text: z.ZodString; }, "strip", z.ZodTypeAny, { text: string; }, { text: string; }>; parameters: z.ZodObject<{ mode: z.ZodDefault<z.ZodLiteral<"draft">>; flow_message_version: z.ZodDefault<z.ZodLiteral<"3">>; flow_id: z.ZodString; flow_cta: z.ZodString; flow_action: z.ZodDefault<z.ZodEnum<["navigate", "data_exchange"]>>; flow_action_payload: z.ZodOptional<z.ZodObject<{ screen: z.ZodDefault<z.ZodString>; data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>; }, "strip", z.ZodTypeAny, { screen: string; data?: Record<string, any> | undefined; }, { screen?: string | undefined; data?: Record<string, any> | undefined; }>>; }, "strip", z.ZodTypeAny, { flow_message_version: "3"; flow_id: string; flow_cta: string; mode: "draft"; flow_action: "navigate" | "data_exchange"; flow_action_payload?: { screen: string; data?: Record<string, any> | undefined; } | undefined; }, { flow_id: string; flow_cta: string; flow_message_version?: "3" | undefined; mode?: "draft" | undefined; flow_action?: "navigate" | "data_exchange" | undefined; flow_action_payload?: { screen?: string | undefined; data?: Record<string, any> | undefined; } | undefined; }>; }, "strip", z.ZodTypeAny, { id: string; header: { type: "text"; text: string; }; body: { text: string; }; footer: { text: string; }; parameters: { flow_message_version: "3"; flow_id: string; flow_cta: string; mode: "draft"; flow_action: "navigate" | "data_exchange"; flow_action_payload?: { screen: string; data?: Record<string, any> | undefined; } | undefined; }; token: string; }, { id: string; header: { type: "text"; text: string; }; body: { text: string; }; footer: { text: string; }; parameters: { flow_id: string; flow_cta: string; flow_message_version?: "3" | undefined; mode?: "draft" | undefined; flow_action?: "navigate" | "data_exchange" | undefined; flow_action_payload?: { screen?: string | undefined; data?: Record<string, any> | undefined; } | undefined; }; token: string; }>; declare const TemplateComponentSchema: z.ZodObject<{ type: z.ZodEnum<["header", "body", "footer", "buttons"]>; parameters: z.ZodArray<z.ZodObject<{ type: z.ZodEnum<["text", "currency", "date_time", "image", "document", "video"]>; text: z.ZodOptional<z.ZodString>; currency: z.ZodOptional<z.ZodObject<{ fallback_value: z.ZodString; code: z.ZodString; amount_1000: z.ZodNumber; }, "strip", z.ZodTypeAny, { code: string; fallback_value: string; amount_1000: number; }, { code: string; fallback_value: string; amount_1000: number; }>>; date_time: z.ZodOptional<z.ZodObject<{ fallback_value: z.ZodString; }, "strip", z.ZodTypeAny, { fallback_value: string; }, { fallback_value: string; }>>; image: z.ZodOptional<z.ZodObject<{ id: z.ZodOptional<z.ZodString>; link: z.ZodOptional<z.ZodString>; caption: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }>>; document: z.ZodOptional<z.ZodObject<{ id: z.ZodOptional<z.ZodString>; link: z.ZodOptional<z.ZodString>; caption: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }>>; video: z.ZodOptional<z.ZodObject<{ id: z.ZodOptional<z.ZodString>; link: z.ZodOptional<z.ZodString>; caption: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }>>; }, "strip", z.ZodTypeAny, { type: "text" | "image" | "video" | "document" | "currency" | "date_time"; text?: string | undefined; image?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; video?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; document?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; currency?: { code: string; fallback_value: string; amount_1000: number; } | undefined; date_time?: { fallback_value: string; } | undefined; }, { type: "text" | "image" | "video" | "document" | "currency" | "date_time"; text?: string | undefined; image?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; video?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; document?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; currency?: { code: string; fallback_value: string; amount_1000: number; } | undefined; date_time?: { fallback_value: string; } | undefined; }>, "many">; }, "strip", z.ZodTypeAny, { type: "header" | "body" | "footer" | "buttons"; parameters: { type: "text" | "image" | "video" | "document" | "currency" | "date_time"; text?: string | undefined; image?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; video?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; document?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; currency?: { code: string; fallback_value: string; amount_1000: number; } | undefined; date_time?: { fallback_value: string; } | undefined; }[]; }, { type: "header" | "body" | "footer" | "buttons"; parameters: { type: "text" | "image" | "video" | "document" | "currency" | "date_time"; text?: string | undefined; image?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; video?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; document?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; currency?: { code: string; fallback_value: string; amount_1000: number; } | undefined; date_time?: { fallback_value: string; } | undefined; }[]; }>; declare const AnalyticsOptionsSchema: z.ZodObject<{ start: z.ZodOptional<z.ZodString>; end: z.ZodOptional<z.ZodString>; granularity: z.ZodDefault<z.ZodOptional<z.ZodEnum<["HOUR", "DAY", "MONTH"]>>>; }, "strip", z.ZodTypeAny, { granularity: "HOUR" | "DAY" | "MONTH"; start?: string | undefined; end?: string | undefined; }, { start?: string | undefined; end?: string | undefined; granularity?: "HOUR" | "DAY" | "MONTH" | undefined; }>; declare const TemplateOptionsSchema: z.ZodObject<{ limit: z.ZodDefault<z.ZodOptional<z.ZodNumber>>; offset: z.ZodDefault<z.ZodOptional<z.ZodNumber>>; }, "strip", z.ZodTypeAny, { limit: number; offset: number; }, { limit?: number | undefined; offset?: number | undefined; }>; declare const CommandSchema: z.ZodObject<{ command_name: z.ZodString; command_description: z.ZodString; }, "strip", z.ZodTypeAny, { command_name: string; command_description: string; }, { command_name: string; command_description: string; }>; declare const ConversationalAutomationSchema: z.ZodObject<{ enable_welcome_message: z.ZodOptional<z.ZodBoolean>; commands: z.ZodOptional<z.ZodArray<z.ZodObject<{ command_name: z.ZodString; command_description: z.ZodString; }, "strip", z.ZodTypeAny, { command_name: string; command_description: string; }, { command_name: string; command_description: string; }>, "many">>; prompts: z.ZodOptional<z.ZodArray<z.ZodString, "many">>; }, "strip", z.ZodTypeAny, { enable_welcome_message?: boolean | undefined; commands?: { command_name: string; command_description: string; }[] | undefined; prompts?: string[] | undefined; }, { enable_welcome_message?: boolean | undefined; commands?: { command_name: string; command_description: string; }[] | undefined; prompts?: string[] | undefined; }>; declare const ConversationalComponentsResponseSchema: z.ZodObject<{ conversational_automation: z.ZodObject<{ enable_welcome_message: z.ZodBoolean; prompts: z.ZodArray<z.ZodString, "many">; commands: z.ZodArray<z.ZodObject<{ command_name: z.ZodString; command_description: z.ZodString; }, "strip", z.ZodTypeAny, { command_name: string; command_description: string; }, { command_name: string; command_description: string; }>, "many">; }, "strip", z.ZodTypeAny, { enable_welcome_message: boolean; commands: { command_name: string; command_description: string; }[]; prompts: string[]; }, { enable_welcome_message: boolean; commands: { command_name: string; command_description: string; }[]; prompts: string[]; }>; id: z.ZodString; }, "strip", z.ZodTypeAny, { id: string; conversational_automation: { enable_welcome_message: boolean; commands: { command_name: string; command_description: string; }[]; prompts: string[]; }; }, { id: string; conversational_automation: { enable_welcome_message: boolean; commands: { command_name: string; command_description: string; }[]; prompts: string[]; }; }>; declare const RequestOptionsSchema: z.ZodObject<{ isFormData: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>; }, "strip", z.ZodTypeAny, { isFormData: boolean; }, { isFormData?: boolean | undefined; }>; declare const BusinessProfileSchema: z.ZodObject<{ messaging_product: z.ZodLiteral<"whatsapp">; address: z.ZodOptional<z.ZodString>; description: z.ZodOptional<z.ZodString>; vertical: z.ZodOptional<z.ZodString>; email: z.ZodOptional<z.ZodString>; websites: z.ZodOptional<z.ZodArray<z.ZodString, "many">>; profile_picture_url: z.ZodOptional<z.ZodString>; about: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { messaging_product: "whatsapp"; address?: string | undefined; email?: string | undefined; description?: string | undefined; vertical?: string | undefined; websites?: string[] | undefined; profile_picture_url?: string | undefined; about?: string | undefined; }, { messaging_product: "whatsapp"; address?: string | undefined; email?: string | undefined; description?: string | undefined; vertical?: string | undefined; websites?: string[] | undefined; profile_picture_url?: string | undefined; about?: string | undefined; }>; declare const BusinessProfileUpdateSchema: z.ZodObject<Omit<{ messaging_product: z.ZodLiteral<"whatsapp">; address: z.ZodOptional<z.ZodString>; description: z.ZodOptional<z.ZodString>; vertical: z.ZodOptional<z.ZodString>; email: z.ZodOptional<z.ZodString>; websites: z.ZodOptional<z.ZodArray<z.ZodString, "many">>; profile_picture_url: z.ZodOptional<z.ZodString>; about: z.ZodOptional<z.ZodString>; }, "messaging_product">, "strip", z.ZodTypeAny, { address?: string | undefined; email?: string | undefined; description?: string | undefined; vertical?: string | undefined; websites?: string[] | undefined; profile_picture_url?: string | undefined; about?: string | undefined; }, { address?: string | undefined; email?: string | undefined; description?: string | undefined; vertical?: string | undefined; websites?: string[] | undefined; profile_picture_url?: string | undefined; about?: string | undefined; }>; declare const TemplateDataSchema: z.ZodObject<{ name: z.ZodString; category: z.ZodEnum<["AUTHENTICATION", "MARKETING", "UTILITY"]>; components: z.ZodArray<z.ZodObject<{ type: z.ZodEnum<["header", "body", "footer", "buttons"]>; parameters: z.ZodArray<z.ZodObject<{ type: z.ZodEnum<["text", "currency", "date_time", "image", "document", "video"]>; text: z.ZodOptional<z.ZodString>; currency: z.ZodOptional<z.ZodObject<{ fallback_value: z.ZodString; code: z.ZodString; amount_1000: z.ZodNumber; }, "strip", z.ZodTypeAny, { code: string; fallback_value: string; amount_1000: number; }, { code: string; fallback_value: string; amount_1000: number; }>>; date_time: z.ZodOptional<z.ZodObject<{ fallback_value: z.ZodString; }, "strip", z.ZodTypeAny, { fallback_value: string; }, { fallback_value: string; }>>; image: z.ZodOptional<z.ZodObject<{ id: z.ZodOptional<z.ZodString>; link: z.ZodOptional<z.ZodString>; caption: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }>>; document: z.ZodOptional<z.ZodObject<{ id: z.ZodOptional<z.ZodString>; link: z.ZodOptional<z.ZodString>; caption: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }>>; video: z.ZodOptional<z.ZodObject<{ id: z.ZodOptional<z.ZodString>; link: z.ZodOptional<z.ZodString>; caption: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }, { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; }>>; }, "strip", z.ZodTypeAny, { type: "text" | "image" | "video" | "document" | "currency" | "date_time"; text?: string | undefined; image?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; video?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; document?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; currency?: { code: string; fallback_value: string; amount_1000: number; } | undefined; date_time?: { fallback_value: string; } | undefined; }, { type: "text" | "image" | "video" | "document" | "currency" | "date_time"; text?: string | undefined; image?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; video?: { id?: string | undefined; link?: string | undefined; caption?: string | undefined; filename?: string | undefined; } | undefined; document?: {