@botozap/sdk 0.8.0 → 0.9.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.
package/dist/index.d.cts CHANGED
@@ -14,6 +14,19 @@ interface SendResult {
14
14
  status: MessageStatus;
15
15
  /** Presente apenas quando a chave é do ambiente sandbox. */
16
16
  sandbox?: boolean;
17
+ /** Só em `type: "reaction"`: alvo e ação (`react`/`unreact`). */
18
+ type?: "reaction";
19
+ reaction?: SendReactionResult;
20
+ }
21
+ /** Eco de `POST /v1/messages` com `type: "reaction"`. */
22
+ interface SendReactionResult {
23
+ /** UUID interno da mensagem alvo. */
24
+ message_id: string;
25
+ /** wamid da mensagem alvo. */
26
+ wamid: string;
27
+ /** `""` quando a reação foi retirada. */
28
+ emoji: string;
29
+ action: "react" | "unreact";
17
30
  }
18
31
  /** Componente de template do WhatsApp (header, body, button…). */
19
32
  interface TemplatePayload {
@@ -72,8 +85,20 @@ interface Customer {
72
85
  name?: string;
73
86
  [key: string]: unknown;
74
87
  }
88
+ /**
89
+ * Origem da mensagem: `api` (esta API), `app` (Painel ou app WhatsApp Business
90
+ * em coexistência), `history` (histórico importado), `broadcast` (Transmissão).
91
+ * Valores novos podem surgir.
92
+ */
93
+ type MessageSource = "api" | "app" | "history" | "broadcast" | (string & {});
75
94
  interface Message {
76
95
  id: string;
96
+ /** Origem da mensagem (ver `MessageSource`). */
97
+ source?: MessageSource;
98
+ /** Chegada à BotoZap (ISO 8601); chave de `sort=created_at`. */
99
+ created_at?: string;
100
+ /** Data real da mensagem no canal; `null` quando desconhecida. Chave de `sort=event_at`. */
101
+ event_at?: string | null;
77
102
  [key: string]: unknown;
78
103
  }
79
104
  interface Broadcast {
@@ -138,6 +163,10 @@ interface Conversation {
138
163
  * + 24h); `null` sem clique recente. Não altera a regra da janela de 24h.
139
164
  */
140
165
  fep_reply_by?: string | null;
166
+ /** Última mensagem da Conversa (inclui `source`); `null` sem mensagens. */
167
+ last_message?: (Partial<Message> & {
168
+ source?: MessageSource;
169
+ }) | null;
141
170
  [key: string]: unknown;
142
171
  }
143
172
  interface Assignment {
@@ -149,7 +178,7 @@ interface Webhook {
149
178
  /** Cliente cujas entregas o endpoint recebe; `null` = todos os da Conta. */
150
179
  customer_id?: string | null;
151
180
  url: string;
152
- events?: string[];
181
+ events?: (WebhookCategory | (string & {}))[];
153
182
  active?: boolean;
154
183
  /** True quando o endpoint tem Authorization no Vault. O valor nunca é devolvido. */
155
184
  has_authorization?: boolean;
@@ -171,10 +200,24 @@ interface ApiLog {
171
200
  id: string;
172
201
  [key: string]: unknown;
173
202
  }
203
+ /**
204
+ * Status de uma entrega de webhook. `limited`: recebida cortada pelo limite de
205
+ * repasse do plano Free; não será tentada.
206
+ */
207
+ type WebhookDeliveryStatus = "pending" | "success" | "failed" | "exhausted" | "limited";
174
208
  interface WebhookDelivery {
175
209
  id: string;
210
+ status?: WebhookDeliveryStatus;
176
211
  [key: string]: unknown;
177
212
  }
213
+ /**
214
+ * Categorias aceitas em `webhooks.create({ events })`. `app_messages` é opt-in
215
+ * (coexistência: `whatsapp.message.echo`, `.edited`, `.revoked`) e só chega a
216
+ * Endpoints que a assinaram explicitamente; `events` vazio não a recebe.
217
+ * `account` inclui `whatsapp.phone_number.connected`.
218
+ */
219
+ declare const WEBHOOK_CATEGORIES: readonly ["messages", "statuses", "crm", "account", "app_messages"];
220
+ type WebhookCategory = (typeof WEBHOOK_CATEGORIES)[number];
178
221
  /** Evento autoritativo do stream durável da Conta e ambiente autenticados. */
179
222
  interface BotoZapEvent {
180
223
  id: string;
@@ -288,6 +331,18 @@ interface SetupLink {
288
331
 
289
332
  /** Public /api/v1/ai contracts. Revisions are opaque strings unless the endpoint explicitly uses a number. */
290
333
  type AiProvider = "anthropic" | "openai" | "google" | "openrouter" | "deepseek" | "xai";
334
+ /** Provedores que aceitam credencial NOVA hoje; os demais respondem 422 `provider_not_enabled`. */
335
+ declare const AI_CREDENTIAL_PROVIDERS: readonly ["openai", "anthropic"];
336
+ /** Item de `ai.providers.get().providers`. */
337
+ type AiProviderInfo = {
338
+ id: AiProvider;
339
+ label: string;
340
+ key_url: string | null;
341
+ description: string | null;
342
+ /** false: criar credencial desse provedor responde 422 `provider_not_enabled`. */
343
+ accepts_new_credentials: boolean;
344
+ [key: string]: unknown;
345
+ };
291
346
  /** Every BYOK purpose. #498 added granular purposes; without their own binding they inherit the Customer default. */
292
347
  declare const AI_PURPOSES: readonly ["default", "agent_turn", "agent_operator", "router", "followup", "proposal", "transcription", "embedding", "guard", "evaluator", "classification", "compaction", "case_chat", "learning_judge", "learning_distiller", "vision", "commercial_proposal"];
293
348
  type AiPurpose = (typeof AI_PURPOSES)[number];
@@ -1881,7 +1936,7 @@ declare class AiCredentialsResource {
1881
1936
  get(input: AiScope & {
1882
1937
  id: string;
1883
1938
  }): Promise<AiCredential>;
1884
- /** Cria credencial própria no Vault; a resposta nunca contém a chave. */
1939
+ /** Cria credencial própria no Vault; a resposta nunca contém a chave. Só `AI_CREDENTIAL_PROVIDERS` (openai/anthropic); os demais: 422 `provider_not_enabled`. */
1885
1940
  create(input: AiScope & {
1886
1941
  provider: AiProvider;
1887
1942
  label: string;
@@ -1913,7 +1968,7 @@ declare class AiProvidersResource {
1913
1968
  constructor(client: BotoZap);
1914
1969
  /** GET /ai/providers */
1915
1970
  get(input: AiScope): Promise<{
1916
- providers: AiRecord[];
1971
+ providers: AiProviderInfo[];
1917
1972
  purposes: Record<string, string>;
1918
1973
  credentials: AiCredential[];
1919
1974
  bindings: AiBinding[];
@@ -3341,8 +3396,15 @@ declare class Radar {
3341
3396
  configureStageRule(stageId: string, input: StageRuleInput): Promise<StageRule>;
3342
3397
  }
3343
3398
 
3399
+ /**
3400
+ * Ordem de `messages.list`: `created_at` (padrão, chegada à BotoZap) ou
3401
+ * `event_at` (data real da mensagem; útil com histórico importado). O cursor é
3402
+ * da ordem que o gerou: reuse-o com o mesmo `sort`.
3403
+ */
3404
+ type MessageSort = "created_at" | "event_at";
3344
3405
  /** Filtros de `messages.list` (paginação por cursor). Ver GET /v1/messages. */
3345
3406
  interface ListMessagesParams extends CursorParams {
3407
+ sort?: MessageSort;
3346
3408
  /** id da Meta OU uuid interno do número. */
3347
3409
  phone_number_id?: string;
3348
3410
  /** uuid interno da conversa (o `id` de /v1/conversations). */
@@ -3398,16 +3460,128 @@ interface SendDocumentParams {
3398
3460
  from?: string;
3399
3461
  }
3400
3462
  type SendMediaParams = SendImageParams | SendVideoParams | SendAudioParams | SendDocumentParams;
3463
+ /** Header de `interactive` (texto; mídia só em button e cta_url). */
3464
+ type InteractiveHeader = {
3465
+ type: "text";
3466
+ text: string;
3467
+ } | {
3468
+ type: "image";
3469
+ image: {
3470
+ link: string;
3471
+ };
3472
+ } | {
3473
+ type: "video";
3474
+ video: {
3475
+ link: string;
3476
+ };
3477
+ } | {
3478
+ type: "document";
3479
+ document: {
3480
+ link: string;
3481
+ filename?: string;
3482
+ };
3483
+ };
3484
+ interface InteractiveBase {
3485
+ header?: InteractiveHeader;
3486
+ body: {
3487
+ text: string;
3488
+ };
3489
+ footer?: {
3490
+ text: string;
3491
+ };
3492
+ }
3493
+ /** Até 3 botões de resposta (título até 20 caracteres, ids únicos). */
3494
+ interface InteractiveButtonPayload extends InteractiveBase {
3495
+ type: "button";
3496
+ action: {
3497
+ buttons: {
3498
+ type?: "reply";
3499
+ reply: {
3500
+ id: string;
3501
+ title: string;
3502
+ };
3503
+ }[];
3504
+ };
3505
+ }
3506
+ /** Lista: até 10 seções e 10 opções no total; `title` da seção obrigatório com mais de uma. */
3507
+ interface InteractiveListPayload extends InteractiveBase {
3508
+ type: "list";
3509
+ header?: {
3510
+ type: "text";
3511
+ text: string;
3512
+ };
3513
+ action: {
3514
+ button: string;
3515
+ sections: {
3516
+ title?: string;
3517
+ rows: {
3518
+ id: string;
3519
+ title: string;
3520
+ description?: string;
3521
+ }[];
3522
+ }[];
3523
+ };
3524
+ }
3525
+ /** Botão de link (URL https pública). */
3526
+ interface InteractiveCtaUrlPayload extends InteractiveBase {
3527
+ type: "cta_url";
3528
+ action: {
3529
+ name: "cta_url";
3530
+ parameters: {
3531
+ display_text: string;
3532
+ url: string;
3533
+ };
3534
+ };
3535
+ }
3536
+ /** Objeto `interactive` no formato da Cloud API (validado pela API). */
3537
+ type InteractivePayload = InteractiveButtonPayload | InteractiveListPayload | InteractiveCtaUrlPayload;
3538
+ interface SendInteractiveParams {
3539
+ to: string;
3540
+ interactive: InteractivePayload;
3541
+ from?: string;
3542
+ }
3543
+ interface SendLocationParams {
3544
+ to: string;
3545
+ latitude: number;
3546
+ longitude: number;
3547
+ name?: string;
3548
+ address?: string;
3549
+ from?: string;
3550
+ }
3551
+ interface SendReactionParams {
3552
+ to: string;
3553
+ /** UUID interno ou wamid da mensagem RECEBIDA do contato (até 30 dias). */
3554
+ message_id: string;
3555
+ /** Emoji da reação; `""` retira a reação. */
3556
+ emoji: string;
3557
+ from?: string;
3558
+ }
3559
+ interface SendOptions {
3560
+ /** Reuse for retries of the same send; a different payload conflicts. */
3561
+ idempotencyKey?: string;
3562
+ }
3401
3563
  /** Endpoints de mensagem (POST /v1/messages, GET /v1/messages/:id). */
3402
3564
  declare class Messages {
3403
3565
  private readonly client;
3404
3566
  constructor(client: BotoZap);
3405
3567
  /** Envia uma mensagem de texto. */
3406
- send(params: SendTextParams): Promise<SendResult>;
3568
+ send(params: SendTextParams, options?: SendOptions): Promise<SendResult>;
3407
3569
  /** Envia uma mensagem usando um template aprovado. */
3408
- sendTemplate(params: SendTemplateParams): Promise<SendResult>;
3570
+ sendTemplate(params: SendTemplateParams, options?: SendOptions): Promise<SendResult>;
3409
3571
  /** Envia mídia por URL pública. */
3410
- sendMedia(params: SendMediaParams): Promise<SendResult>;
3572
+ sendMedia(params: SendMediaParams, options?: SendOptions): Promise<SendResult>;
3573
+ /**
3574
+ * Envia botões de resposta, lista ou botão de link (WhatsApp; mensagem livre,
3575
+ * exige janela de 24h aberta).
3576
+ */
3577
+ sendInteractive(params: SendInteractiveParams, options?: SendOptions): Promise<SendResult>;
3578
+ /** Envia uma localização (WhatsApp; mensagem livre). */
3579
+ sendLocation(params: SendLocationParams, options?: SendOptions): Promise<SendResult>;
3580
+ /**
3581
+ * Reage a uma mensagem recebida (WhatsApp). `emoji: ""` retira a reação.
3582
+ * O retorno traz `reaction` com o alvo e a ação.
3583
+ */
3584
+ sendReaction(params: SendReactionParams, options?: SendOptions): Promise<SendResult>;
3411
3585
  /** Lista as mensagens da conta (paginação por cursor). */
3412
3586
  list(params?: ListMessagesParams): Promise<CursorList<Message>>;
3413
3587
  /** Busca uma mensagem pelo id interno. */
@@ -3734,7 +3908,7 @@ declare class Conversations {
3734
3908
  * A leitura e o envio usam a mesma chave; o POST /messages revalida Conta,
3735
3909
  * ambiente, identidade, janela, quota e billing antes de chamar a Meta.
3736
3910
  */
3737
- reply(id: string, params: ReplyConversationParams): Promise<SendResult>;
3911
+ reply(id: string, params: ReplyConversationParams, options?: SendOptions): Promise<SendResult>;
3738
3912
  update(id: string, params: Record<string, unknown>): Promise<Conversation>;
3739
3913
  /** Lista as atribuições da conversa (paginação por offset/página). */
3740
3914
  listAssignments(id: string, params?: OffsetParams): Promise<OffsetList<Assignment>>;
@@ -4036,8 +4210,8 @@ declare class ApiLogs {
4036
4210
  interface ListWebhookDeliveriesParams extends CursorParams {
4037
4211
  /** Alias de `endpoint_id` na rota — entregas de um endpoint específico. */
4038
4212
  webhook_id?: string;
4039
- /** delivery_status (pending|success|failed|exhausted). */
4040
- status?: string;
4213
+ /** delivery_status (pending|success|failed|exhausted|limited). */
4214
+ status?: WebhookDeliveryStatus | (string & {});
4041
4215
  /** Tipo do evento (ex.: "webhook.test", "messages"). */
4042
4216
  event_type?: string;
4043
4217
  }
@@ -4048,9 +4222,35 @@ declare class WebhookDeliveries {
4048
4222
  list(params?: ListWebhookDeliveriesParams): Promise<CursorList<WebhookDelivery>>;
4049
4223
  }
4050
4224
 
4225
+ /** Identidade e permissões efetivas da credencial autenticada. */
4226
+ interface Me {
4227
+ /** UUID da Conta derivado pela API a partir da chave autenticada. */
4228
+ account_id: string;
4229
+ /** Ambiente ao qual a chave pertence. */
4230
+ environment: "live" | "sandbox";
4231
+ /** Scopes efetivos concedidos à chave. */
4232
+ scopes: string[];
4233
+ /** Ausente em versões anteriores da API; OAuth exige todos os campos abaixo. */
4234
+ auth_type?: "api_key" | "oauth";
4235
+ user_id?: string;
4236
+ client_id?: string;
4237
+ grant_id?: string;
4238
+ /** Contratos de rota permitidos, por exemplo GET /v1/contacts/:id. */
4239
+ allowed_routes?: string[];
4240
+ }
4241
+ /** Introspecção da identidade da chave autenticada. */
4242
+ declare class MeResource {
4243
+ private readonly client;
4244
+ constructor(client: BotoZap);
4245
+ /** Retorna a Conta, o ambiente e os scopes efetivos da chave. */
4246
+ get(): Promise<Me>;
4247
+ }
4248
+
4051
4249
  interface BotoZapOptions {
4052
- /** Chave de API da conta (cabeçalho Authorization: Bearer). */
4053
- apiKey: string;
4250
+ /** Chave de API da conta. Use apenas uma credencial: apiKey ou accessToken. */
4251
+ apiKey?: string;
4252
+ /** Token OAuth, ou provider chamado em cada requisição para usar o token atualizado. */
4253
+ accessToken?: string | (() => string | Promise<string>);
4054
4254
  /** Sobrescreve a URL base. Padrão: https://botozap.com.br/api/v1 */
4055
4255
  baseUrl?: string;
4056
4256
  /** Injeta um fetch (testes, runtimes sem fetch global). */
@@ -4098,7 +4298,8 @@ declare class BotoZap {
4098
4298
  readonly users: Users;
4099
4299
  readonly apiLogs: ApiLogs;
4100
4300
  readonly webhookDeliveries: WebhookDeliveries;
4101
- private readonly apiKey;
4301
+ readonly me: MeResource;
4302
+ private readonly credential;
4102
4303
  private readonly baseUrl;
4103
4304
  private readonly fetchImpl;
4104
4305
  constructor(options: BotoZapOptions);
@@ -4130,12 +4331,33 @@ declare class BotoZap {
4130
4331
  * `Retry-After` / `X-RateLimit-*`. Os headers são só os da RESPOSTA; nenhum
4131
4332
  * header de request (que carrega a apiKey) entra aqui.
4132
4333
  */
4334
+ type SendFailureDetails = {
4335
+ outcome?: "rejected" | "accepted" | "unknown";
4336
+ retry?: "backoff" | "after_correction" | "reconcile_first" | "unknown";
4337
+ };
4133
4338
  declare class BotoZapError extends Error {
4134
4339
  readonly code: string;
4135
4340
  readonly status: number;
4341
+ readonly outcome?: SendFailureDetails["outcome"];
4342
+ readonly retry?: SendFailureDetails["retry"];
4136
4343
  /** Headers da resposta HTTP. Ausente em erros sem resposta (status 0). */
4137
4344
  readonly headers?: Record<string, string>;
4138
- constructor(code: string, message: string, status: number, headers?: Record<string, string>);
4345
+ constructor(code: string, message: string, status: number, headers?: Record<string, string>, details?: SendFailureDetails);
4139
4346
  }
4347
+ /**
4348
+ * Códigos de erro conhecidos da API (não exaustivo; valores novos podem surgir).
4349
+ * Envio (POST /v1/messages): `invalid_reaction`, `missing_reaction_target`,
4350
+ * `reaction_target_not_found`, `reaction_target_invalid`,
4351
+ * `reaction_target_expired`, `unsupported_type`, `free_form_limit_reached`
4352
+ * (429, limite 1:1 do Free). Plano: `plan_restricted` (403, escritas de IA,
4353
+ * Agenda, Calendário e Jornadas fora do plano), `free_number_cap` (402, setup
4354
+ * além do teto de Números do Free). IA: `provider_not_enabled` (422, credencial
4355
+ * nova de provedor com `accepts_new_credentials: false`).
4356
+ */
4357
+ type BotoZapErrorCode = "invalid_request" | "unsupported_type" | "invalid_reaction" | "missing_reaction_target" | "reaction_target_not_found" | "reaction_target_invalid" | "reaction_target_expired" | "free_form_limit_reached" | "quota_exceeded" | "plan_restricted" | "free_number_cap" | "provider_not_enabled" | (string & {});
4358
+ /** Códigos que indicam limite ou restrição do plano contratado. */
4359
+ declare const PLAN_ERROR_CODES: readonly ["plan_restricted", "free_form_limit_reached", "free_number_cap"];
4360
+ /** True quando o erro é recusa por plano (upgrade resolve; retry não). */
4361
+ declare function isPlanError(error: unknown): error is BotoZapError;
4140
4362
 
4141
- export { AI_CONFIGURABLE_PURPOSES, AI_OPERATIONS, AI_PURPOSES, type AddRecipientsError, type AddRecipientsResult, AgendaConfiguration, AgendaExceptions, type AgendaRecord, Ai, type AiAgent, type AiAgentConfig, type AiAgentCoverage, type AiAgentInput, type AiAgentVersion, AiAgentsResource, type AiAlert, type AiAlertBulkFilters, type AiAlertListItem, AiAlertsResource, type AiArtifactUploadInput, type AiAudioPricing, type AiBinding, type AiBindingTarget, type AiBudget, type AiBudgetInput, type AiCapabilitySignal, type AiCapabilityUsage, type AiCapabilityUsageList, type AiCase, type AiCaseChat, type AiCaseEvent, type AiCaseKind, type AiCaseReply, type AiCaseReplyInput, type AiCaseSource, AiCasesResource, type AiCatalogItems, type AiCatalogModel, type AiCatalogProduct, type AiCatalogSyncInput, type AiCatalogSyncResult, type AiChannelGate, type AiCommercialDecision, type AiCommercialEffect, type AiCommercialJob, type AiCommercialProposal, AiCommercialProposalsResource, type AiCommercialRequest, type AiCommercialSettings, type AiConfigurablePurpose, type AiContactAuthorization, type AiConversationCheckpoint, type AiCredential, AiCredentialsResource, type AiDraftResult, type AiEligibilityOverview, AiEligibilityResource, type AiEligibilitySettings, type AiEnrollment, type AiEvolution, AiEvolutionResource, type AiEvolutionSource, type AiExecution, type AiExecutionCitations, type AiExecutionSecurity, AiExecutionsResource, type AiField, type AiFlow, type AiFlowGraph, type AiFlowInput, type AiFlowSettings, type AiFlowVersion, type AiFollowupEffect, type AiFollowupEvent, AiFollowupFlowsResource, type AiFollowupPromise, type AiFollowupPromiseDetail, type AiFollowupPromiseStatus, type AiFollowupQueueFilters, type AiFollowupQueuePage, type AiFollowupQueueRow, AiFollowupsResource, type AiGateMode, type AiInference, type AiInferenceOrigin, type AiInferenceOutcome, type AiInferenceSummary, AiInferencesResource, type AiKnowledgeChunk, type AiKnowledgeCitation, type AiKnowledgeConversation, type AiKnowledgeHit, type AiKnowledgeImport, type AiKnowledgePreview, AiKnowledgeResource, type AiKnowledgeSearchDiagnostics, type AiKnowledgeSource, type AiMemory, type AiMemoryEntry, type AiMemoryEntryEvent, AiMemoryResource, type AiModelCatalogSnapshot, type AiModelCatalogSync, type AiNoticeCheck, type AiNoticeEffect, type AiNoticeField, type AiNoticeJob, type AiNoticeSettings, AiNoticesResource, type AiOperation, type AiOperatorMetrics, AiOperatorResource, type AiPage, type AiPlatformSkill, type AiPlatformSkillComposition, type AiPreparedUpload, type AiProposal, AiProposalsResource, type AiProvider, type AiProviderModel, AiProvidersResource, type AiPurpose, type AiRate, type AiRateInput, type AiRecord, type AiRevision, type AiRouter, type AiRouterConfig, type AiRouterTest, AiRoutersResource, type AiScope, type AiSkill, type AiSkillInput, type AiSkillNearMiss, type AiSkillVersion, AiSkillsResource, type AiSourceKind, type AiStyleAdjustment, type AiStyleAdjustmentId, AiStyleAdjustmentsResource, type AiToolId, type AiTurnPromise, type AiUploadReceiptCallback, AiUploadsResource, AiUsageResource, type AiUsageSummary, type AiUsageTokens, type AiWindow, type ApiLog, type Appointment, type AppointmentAvailability, type AppointmentExceptionInput, type AppointmentFields, type AppointmentHistory, type AppointmentQuery, type AppointmentScheduleInput, type AppointmentServiceInput, type AppointmentStatus, Appointments, type Assignment, type AvailabilityQuery, BotoZap, BotoZapError, type BotoZapEvent, type BotoZapOptions, type Broadcast, type BroadcastRecipient, type BroadcastRecipientInput, Calendar, type CalendarConnection, type CalendarJob, type CalendarSelection, type Contact, type ContactField, ContactFields, type ContactStage, ContactStages, type Conversation, type ConversationEntryPoint, type ConversationNote, type ConversationReferral, type ConversationReminder, type CreateAppointment, type CreateAssignmentParams, type CreateBroadcastParams, type CreateContactParams, type CreateCustomerParams, type CreateDemand, type CreateOpportunity, type CreateSetupLinkParams, type CreateTemplateParams, type CreateWebhookParams, type CrmActivity, type CrmConversation, type CrmFields, type CrmMetadata, type CrmQuery, type CrmRecord, CrmResource, type CursorList, type CursorPaging, type CursorParams, type Customer, type Demand, type DemandFields, type EventList, type EventPaging, Inbox, type InboxMutation, type InboxMutationResult, type InboxState, type InboxTools, type Journey, type JourneyConfig, type JourneyEnrollment, type JourneyQuery, type JourneyRun, type JourneyStep, Journeys, type ListApiLogsParams, type ListBroadcastsParams, type ListContactsParams, type ListConversationsParams, type ListEventsParams, type ListMessagesParams, type ListPhoneNumbersParams, type ListRecipientsParams, type ListTemplatesParams, type ListWebhookDeliveriesParams, type MediaAsset, type MediaUploadResult, type Message, type MessageStatus, type MetaCostCategory, type MetaCostDay, type MetaCostEstimate, type MetaCostGroup, type MetaCostReport, type MetaCostSource, type MetaCostSync, type MetaCostUnavailableReason, type MetaCostsParams, type OffsetList, type OffsetMeta, type OffsetParams, type Opportunity, type OpportunityFields, type PhoneNumber, Radar, type RadarEntry, type RadarPage, type RadarQuery, type ReplyConversationParams, type RequestOptions, SavedReplies, type SavedReply, type SavedReplyInput, type SavedReplyQuery, type ScheduleBroadcastParams, type SendAudioParams, type SendDocumentParams, type SendImageParams, type SendMediaParams, type SendResult, type SendTemplateParams, type SendTextParams, type SendVideoParams, type SetupLink, type StageColor, type StageRule, type StageRuleInput, type Template, type TemplatePayload, type UpdateAppointment, type UpdateBroadcastParams, type UpdateContactParams, type UpdateCustomerParams, type UpdatePhoneNumberParams, type UpdateSetupLinkParams, type UpdateWebhookParams, type UploadMediaParams, type User, type Webhook, type WebhookAuthorizationHeaders, type WebhookDelivery };
4363
+ export { AI_CONFIGURABLE_PURPOSES, AI_CREDENTIAL_PROVIDERS, AI_OPERATIONS, AI_PURPOSES, type AddRecipientsError, type AddRecipientsResult, AgendaConfiguration, AgendaExceptions, type AgendaRecord, Ai, type AiAgent, type AiAgentConfig, type AiAgentCoverage, type AiAgentInput, type AiAgentVersion, AiAgentsResource, type AiAlert, type AiAlertBulkFilters, type AiAlertListItem, AiAlertsResource, type AiArtifactUploadInput, type AiAudioPricing, type AiBinding, type AiBindingTarget, type AiBudget, type AiBudgetInput, type AiCapabilitySignal, type AiCapabilityUsage, type AiCapabilityUsageList, type AiCase, type AiCaseChat, type AiCaseEvent, type AiCaseKind, type AiCaseReply, type AiCaseReplyInput, type AiCaseSource, AiCasesResource, type AiCatalogItems, type AiCatalogModel, type AiCatalogProduct, type AiCatalogSyncInput, type AiCatalogSyncResult, type AiChannelGate, type AiCommercialDecision, type AiCommercialEffect, type AiCommercialJob, type AiCommercialProposal, AiCommercialProposalsResource, type AiCommercialRequest, type AiCommercialSettings, type AiConfigurablePurpose, type AiContactAuthorization, type AiConversationCheckpoint, type AiCredential, AiCredentialsResource, type AiDraftResult, type AiEligibilityOverview, AiEligibilityResource, type AiEligibilitySettings, type AiEnrollment, type AiEvolution, AiEvolutionResource, type AiEvolutionSource, type AiExecution, type AiExecutionCitations, type AiExecutionSecurity, AiExecutionsResource, type AiField, type AiFlow, type AiFlowGraph, type AiFlowInput, type AiFlowSettings, type AiFlowVersion, type AiFollowupEffect, type AiFollowupEvent, AiFollowupFlowsResource, type AiFollowupPromise, type AiFollowupPromiseDetail, type AiFollowupPromiseStatus, type AiFollowupQueueFilters, type AiFollowupQueuePage, type AiFollowupQueueRow, AiFollowupsResource, type AiGateMode, type AiInference, type AiInferenceOrigin, type AiInferenceOutcome, type AiInferenceSummary, AiInferencesResource, type AiKnowledgeChunk, type AiKnowledgeCitation, type AiKnowledgeConversation, type AiKnowledgeHit, type AiKnowledgeImport, type AiKnowledgePreview, AiKnowledgeResource, type AiKnowledgeSearchDiagnostics, type AiKnowledgeSource, type AiMemory, type AiMemoryEntry, type AiMemoryEntryEvent, AiMemoryResource, type AiModelCatalogSnapshot, type AiModelCatalogSync, type AiNoticeCheck, type AiNoticeEffect, type AiNoticeField, type AiNoticeJob, type AiNoticeSettings, AiNoticesResource, type AiOperation, type AiOperatorMetrics, AiOperatorResource, type AiPage, type AiPlatformSkill, type AiPlatformSkillComposition, type AiPreparedUpload, type AiProposal, AiProposalsResource, type AiProvider, type AiProviderInfo, type AiProviderModel, AiProvidersResource, type AiPurpose, type AiRate, type AiRateInput, type AiRecord, type AiRevision, type AiRouter, type AiRouterConfig, type AiRouterTest, AiRoutersResource, type AiScope, type AiSkill, type AiSkillInput, type AiSkillNearMiss, type AiSkillVersion, AiSkillsResource, type AiSourceKind, type AiStyleAdjustment, type AiStyleAdjustmentId, AiStyleAdjustmentsResource, type AiToolId, type AiTurnPromise, type AiUploadReceiptCallback, AiUploadsResource, AiUsageResource, type AiUsageSummary, type AiUsageTokens, type AiWindow, type ApiLog, type Appointment, type AppointmentAvailability, type AppointmentExceptionInput, type AppointmentFields, type AppointmentHistory, type AppointmentQuery, type AppointmentScheduleInput, type AppointmentServiceInput, type AppointmentStatus, Appointments, type Assignment, type AvailabilityQuery, BotoZap, BotoZapError, type BotoZapErrorCode, type BotoZapEvent, type BotoZapOptions, type Broadcast, type BroadcastRecipient, type BroadcastRecipientInput, Calendar, type CalendarConnection, type CalendarJob, type CalendarSelection, type Contact, type ContactField, ContactFields, type ContactStage, ContactStages, type Conversation, type ConversationEntryPoint, type ConversationNote, type ConversationReferral, type ConversationReminder, type CreateAppointment, type CreateAssignmentParams, type CreateBroadcastParams, type CreateContactParams, type CreateCustomerParams, type CreateDemand, type CreateOpportunity, type CreateSetupLinkParams, type CreateTemplateParams, type CreateWebhookParams, type CrmActivity, type CrmConversation, type CrmFields, type CrmMetadata, type CrmQuery, type CrmRecord, CrmResource, type CursorList, type CursorPaging, type CursorParams, type Customer, type Demand, type DemandFields, type EventList, type EventPaging, Inbox, type InboxMutation, type InboxMutationResult, type InboxState, type InboxTools, type InteractiveButtonPayload, type InteractiveCtaUrlPayload, type InteractiveHeader, type InteractiveListPayload, type InteractivePayload, type Journey, type JourneyConfig, type JourneyEnrollment, type JourneyQuery, type JourneyRun, type JourneyStep, Journeys, type ListApiLogsParams, type ListBroadcastsParams, type ListContactsParams, type ListConversationsParams, type ListEventsParams, type ListMessagesParams, type ListPhoneNumbersParams, type ListRecipientsParams, type ListTemplatesParams, type ListWebhookDeliveriesParams, type Me, type MediaAsset, type MediaUploadResult, type Message, type MessageSort, type MessageSource, type MessageStatus, type MetaCostCategory, type MetaCostDay, type MetaCostEstimate, type MetaCostGroup, type MetaCostReport, type MetaCostSource, type MetaCostSync, type MetaCostUnavailableReason, type MetaCostsParams, type OffsetList, type OffsetMeta, type OffsetParams, type Opportunity, type OpportunityFields, PLAN_ERROR_CODES, type PhoneNumber, Radar, type RadarEntry, type RadarPage, type RadarQuery, type ReplyConversationParams, type RequestOptions, SavedReplies, type SavedReply, type SavedReplyInput, type SavedReplyQuery, type ScheduleBroadcastParams, type SendAudioParams, type SendDocumentParams, type SendFailureDetails, type SendImageParams, type SendInteractiveParams, type SendLocationParams, type SendMediaParams, type SendOptions, type SendReactionParams, type SendReactionResult, type SendResult, type SendTemplateParams, type SendTextParams, type SendVideoParams, type SetupLink, type StageColor, type StageRule, type StageRuleInput, type Template, type TemplatePayload, type UpdateAppointment, type UpdateBroadcastParams, type UpdateContactParams, type UpdateCustomerParams, type UpdatePhoneNumberParams, type UpdateSetupLinkParams, type UpdateWebhookParams, type UploadMediaParams, type User, WEBHOOK_CATEGORIES, type Webhook, type WebhookAuthorizationHeaders, type WebhookCategory, type WebhookDelivery, type WebhookDeliveryStatus, isPlanError };