@getlatedev/node 0.2.1102 → 0.2.1104
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/README.md +16 -4
- package/dist/index.d.mts +978 -266
- package/dist/index.d.ts +978 -266
- package/dist/index.js +85 -1
- package/dist/index.mjs +85 -1
- package/package.json +1 -1
- package/src/client.ts +24 -0
- package/src/generated/sdk.gen.ts +224 -16
- package/src/generated/types.gen.ts +1028 -265
|
@@ -3104,6 +3104,23 @@ export type CampaignBidding = {
|
|
|
3104
3104
|
*/
|
|
3105
3105
|
export type channel2 = 'SEARCH' | 'DISPLAY';
|
|
3106
3106
|
|
|
3107
|
+
/**
|
|
3108
|
+
* Actions taken on the matched comment itself (comment trigger only; ignored on the
|
|
3109
|
+
* story-reply and DM doors). They never block or fail the DM: when one cannot run,
|
|
3110
|
+
* the log row says why (`likeSkipped`, `hideSkipped`).
|
|
3111
|
+
*
|
|
3112
|
+
*/
|
|
3113
|
+
export type CommentAutomationActions = {
|
|
3114
|
+
/**
|
|
3115
|
+
* Like the comment as the account. Facebook always; Instagram only for accounts connected through Facebook Login and allowlisted for likes while Meta reviews the permission. Otherwise the like is skipped and logged.
|
|
3116
|
+
*/
|
|
3117
|
+
likeComment?: boolean;
|
|
3118
|
+
/**
|
|
3119
|
+
* Hide the comment once the first DM has been attempted, so the private reply is never sent to an already hidden comment.
|
|
3120
|
+
*/
|
|
3121
|
+
hideComment?: boolean;
|
|
3122
|
+
};
|
|
3123
|
+
|
|
3107
3124
|
/**
|
|
3108
3125
|
* Who a comment automation answers. Instagram only - Meta exposes the follow
|
|
3109
3126
|
* relationship on no other platform, and only for people who have MESSAGED the
|
|
@@ -3150,6 +3167,23 @@ export type followerStatus = 'any' | 'follower' | 'non_follower';
|
|
|
3150
3167
|
*/
|
|
3151
3168
|
export type whenUnknown = 'send' | 'skip' | 'verify';
|
|
3152
3169
|
|
|
3170
|
+
/**
|
|
3171
|
+
* An image, video, audio clip or file sent right after the DM text as a second message
|
|
3172
|
+
* (a Meta message carries one body, so text and attachment are two sends). On the comment
|
|
3173
|
+
* trigger Meta may refuse the second message until the commenter replies; the DM then
|
|
3174
|
+
* still counts as sent and the log row carries `mediaError`.
|
|
3175
|
+
*
|
|
3176
|
+
*/
|
|
3177
|
+
export type CommentAutomationDmMedia = {
|
|
3178
|
+
type: 'image' | 'video' | 'audio' | 'file';
|
|
3179
|
+
/**
|
|
3180
|
+
* Publicly reachable http(s) URL Meta downloads the media from.
|
|
3181
|
+
*/
|
|
3182
|
+
url: string;
|
|
3183
|
+
};
|
|
3184
|
+
|
|
3185
|
+
export type type3 = 'image' | 'video' | 'audio' | 'file';
|
|
3186
|
+
|
|
3153
3187
|
/**
|
|
3154
3188
|
* Copy for the follow gate. Sensible defaults are used for any field left empty.
|
|
3155
3189
|
*/
|
|
@@ -3168,13 +3202,191 @@ export type CommentAutomationFollowGate = {
|
|
|
3168
3202
|
notFollowingMessage?: string;
|
|
3169
3203
|
};
|
|
3170
3204
|
|
|
3205
|
+
export type CommentAutomationLog = {
|
|
3206
|
+
id?: string;
|
|
3207
|
+
commentId?: string;
|
|
3208
|
+
commenterId?: string;
|
|
3209
|
+
commenterName?: (string) | null;
|
|
3210
|
+
commenterUsername?: (string) | null;
|
|
3211
|
+
commentText?: (string) | null;
|
|
3212
|
+
/**
|
|
3213
|
+
* Which door triggered this send. Null on rows written before this field existed (all of those are comment-triggered).
|
|
3214
|
+
*/
|
|
3215
|
+
source?: ('comment' | 'live_comment' | 'story_reply' | 'story_mention' | 'dm') | null;
|
|
3216
|
+
/**
|
|
3217
|
+
* DM outcome. 'pending' = the automation has a dmDelaySeconds and the response is queued but not sent yet. 'gated' = the follow-gate confirmation DM went out and we are waiting for the tap; it flips to 'sent' or 'skipped' when they tap. 'skipped' also covers repeatPolicy, cooldown and dedupeSameTextHours suppressions, with the reason in error.
|
|
3218
|
+
*/
|
|
3219
|
+
status?: 'pending' | 'sent' | 'failed' | 'skipped' | 'gated';
|
|
3220
|
+
/**
|
|
3221
|
+
* How the audience rule resolved. Null on automations without one.
|
|
3222
|
+
*/
|
|
3223
|
+
audienceOutcome?: ('passed' | 'blocked' | 'gate_sent' | 'gate_passed' | 'gate_failed') | null;
|
|
3224
|
+
/**
|
|
3225
|
+
* Whether the follow-gate button reached the commenter: 'rejected' = Meta refused the gate DM, 'omitted' = the prompt went out as plain text because it was over 640 characters. Null when no gate DM was sent.
|
|
3226
|
+
*/
|
|
3227
|
+
gateButtonStatus?: ('delivered' | 'rejected' | 'omitted') | null;
|
|
3228
|
+
/**
|
|
3229
|
+
* Follow relationship at decision time. Null when Instagram would not tell us (the commenter never messaged the account).
|
|
3230
|
+
*/
|
|
3231
|
+
commenterIsFollower?: (boolean) | null;
|
|
3232
|
+
commenterFollowerCount?: (number) | null;
|
|
3233
|
+
/**
|
|
3234
|
+
* When the follow-gate tap was claimed.
|
|
3235
|
+
*/
|
|
3236
|
+
gateResolvedAt?: (string) | null;
|
|
3237
|
+
/**
|
|
3238
|
+
* DM error message when status is failed, or the reason when it is skipped.
|
|
3239
|
+
*/
|
|
3240
|
+
error?: (string) | null;
|
|
3241
|
+
/**
|
|
3242
|
+
* Platform error codes of the failed DM (Meta `code` and `error_subcode`), when the platform sent them. Null on successful rows and on rows written before this field existed.
|
|
3243
|
+
*/
|
|
3244
|
+
platformError?: {
|
|
3245
|
+
code?: number;
|
|
3246
|
+
subcode?: number;
|
|
3247
|
+
} | null;
|
|
3248
|
+
/**
|
|
3249
|
+
* True when the failed send spent the comment's single private reply (Instagram subcode 1545133 or 2534023, or Meta code 10900 on Instagram and Facebook), the same rule as `details.privateReplyConsumed` on the private-reply endpoint. Null on direct DMs and on rows written before this field existed.
|
|
3250
|
+
*/
|
|
3251
|
+
privateReplyConsumed?: (boolean) | null;
|
|
3252
|
+
/**
|
|
3253
|
+
* Outcome of the optional public reply on the triggering comment. With publicReplyPolicy after_dm, 'skipped' if no commentReply was configured or if the DM failed (the public reply is not attempted in that case).
|
|
3254
|
+
*/
|
|
3255
|
+
commentReplyStatus?: ('pending' | 'sent' | 'failed' | 'skipped') | null;
|
|
3256
|
+
/**
|
|
3257
|
+
* Public-reply error message if commentReplyStatus is failed
|
|
3258
|
+
*/
|
|
3259
|
+
commentReplyError?: (string) | null;
|
|
3260
|
+
/**
|
|
3261
|
+
* When the public reply was posted. Null when it was not.
|
|
3262
|
+
*/
|
|
3263
|
+
publicReplyPostedAt?: (string) | null;
|
|
3264
|
+
/**
|
|
3265
|
+
* Why actions.likeComment did not like the comment. Null when it did or was not configured.
|
|
3266
|
+
*/
|
|
3267
|
+
likeSkipped?: (string) | null;
|
|
3268
|
+
/**
|
|
3269
|
+
* Why actions.hideComment did not hide the comment. Null when it did or was not configured.
|
|
3270
|
+
*/
|
|
3271
|
+
hideSkipped?: (string) | null;
|
|
3272
|
+
/**
|
|
3273
|
+
* Why the dmMedia follow-up was not delivered. The DM itself still counts as sent.
|
|
3274
|
+
*/
|
|
3275
|
+
mediaError?: (string) | null;
|
|
3276
|
+
/**
|
|
3277
|
+
* When the next queued send fires. Present only while something is still pending.
|
|
3278
|
+
*/
|
|
3279
|
+
nextDueAt?: (string) | null;
|
|
3280
|
+
/**
|
|
3281
|
+
* This recipient's first click on a tracked link (what uniqueClicks counts).
|
|
3282
|
+
*/
|
|
3283
|
+
clickedAt?: (string) | null;
|
|
3284
|
+
/**
|
|
3285
|
+
* This recipient's total clicks on tracked links.
|
|
3286
|
+
*/
|
|
3287
|
+
clickCount?: number;
|
|
3288
|
+
createdAt?: string;
|
|
3289
|
+
};
|
|
3290
|
+
|
|
3291
|
+
/**
|
|
3292
|
+
* Which door triggered this send. Null on rows written before this field existed (all of those are comment-triggered).
|
|
3293
|
+
*/
|
|
3294
|
+
export type source = 'comment' | 'live_comment' | 'story_reply' | 'story_mention' | 'dm';
|
|
3295
|
+
|
|
3296
|
+
/**
|
|
3297
|
+
* DM outcome. 'pending' = the automation has a dmDelaySeconds and the response is queued but not sent yet. 'gated' = the follow-gate confirmation DM went out and we are waiting for the tap; it flips to 'sent' or 'skipped' when they tap. 'skipped' also covers repeatPolicy, cooldown and dedupeSameTextHours suppressions, with the reason in error.
|
|
3298
|
+
*/
|
|
3299
|
+
export type status10 = 'pending' | 'sent' | 'failed' | 'skipped' | 'gated';
|
|
3300
|
+
|
|
3301
|
+
/**
|
|
3302
|
+
* How the audience rule resolved. Null on automations without one.
|
|
3303
|
+
*/
|
|
3304
|
+
export type audienceOutcome = 'passed' | 'blocked' | 'gate_sent' | 'gate_passed' | 'gate_failed';
|
|
3305
|
+
|
|
3306
|
+
/**
|
|
3307
|
+
* Whether the follow-gate button reached the commenter: 'rejected' = Meta refused the gate DM, 'omitted' = the prompt went out as plain text because it was over 640 characters. Null when no gate DM was sent.
|
|
3308
|
+
*/
|
|
3309
|
+
export type gateButtonStatus = 'delivered' | 'rejected' | 'omitted';
|
|
3310
|
+
|
|
3311
|
+
/**
|
|
3312
|
+
* Outcome of the optional public reply on the triggering comment. With publicReplyPolicy after_dm, 'skipped' if no commentReply was configured or if the DM failed (the public reply is not attempted in that case).
|
|
3313
|
+
*/
|
|
3314
|
+
export type commentReplyStatus = 'pending' | 'sent' | 'failed' | 'skipped';
|
|
3315
|
+
|
|
3316
|
+
export type CommentAutomationQuickReply = {
|
|
3317
|
+
title: string;
|
|
3318
|
+
/**
|
|
3319
|
+
* Delivered back via the messaging webhook when tapped.
|
|
3320
|
+
*/
|
|
3321
|
+
payload: string;
|
|
3322
|
+
imageUrl?: string;
|
|
3323
|
+
};
|
|
3324
|
+
|
|
3325
|
+
/**
|
|
3326
|
+
* Whether a commenter can receive this automation's DM more than once.
|
|
3327
|
+
* * `once` (default) - one DM per person per door, ever.
|
|
3328
|
+
* * `every_comment` - every new matching comment is eligible again. One comment
|
|
3329
|
+
* is still answered at most once. `cooldownHours` suppresses a repeat sent to the
|
|
3330
|
+
* same person within that many hours.
|
|
3331
|
+
*
|
|
3332
|
+
*/
|
|
3333
|
+
export type CommentAutomationRepeatPolicy = {
|
|
3334
|
+
mode: 'once' | 'every_comment';
|
|
3335
|
+
/**
|
|
3336
|
+
* every_comment only (400 with once). Hours after a DM during which the same person is not DMed again.
|
|
3337
|
+
*/
|
|
3338
|
+
cooldownHours?: number;
|
|
3339
|
+
};
|
|
3340
|
+
|
|
3341
|
+
export type mode = 'once' | 'every_comment';
|
|
3342
|
+
|
|
3343
|
+
/**
|
|
3344
|
+
* Running counters for the automation.
|
|
3345
|
+
*/
|
|
3346
|
+
export type CommentAutomationStats = {
|
|
3347
|
+
/**
|
|
3348
|
+
* Matched triggers that reached the audience or send stage.
|
|
3349
|
+
*/
|
|
3350
|
+
triggered?: number;
|
|
3351
|
+
dmsSent?: number;
|
|
3352
|
+
dmsFailed?: number;
|
|
3353
|
+
uniqueContacts?: number;
|
|
3354
|
+
/**
|
|
3355
|
+
* DMs sent with a trackable (wrapped) link. CTR denominator: divide clicks by this, not dmsSent. Lags dmsSent for campaigns that predate click tracking.
|
|
3356
|
+
*/
|
|
3357
|
+
trackedSends?: number;
|
|
3358
|
+
/**
|
|
3359
|
+
* Total clicks on tracked links (bots/prefetch excluded).
|
|
3360
|
+
*/
|
|
3361
|
+
linkClicks?: number;
|
|
3362
|
+
/**
|
|
3363
|
+
* Distinct people who clicked a tracked link.
|
|
3364
|
+
*/
|
|
3365
|
+
uniqueClicks?: number;
|
|
3366
|
+
/**
|
|
3367
|
+
* DMs confirmed delivered (Messenger; IG emits no delivery receipt).
|
|
3368
|
+
*/
|
|
3369
|
+
delivered?: number;
|
|
3370
|
+
/**
|
|
3371
|
+
* DMs confirmed read (IG messaging_seen / Messenger message_reads).
|
|
3372
|
+
*/
|
|
3373
|
+
read?: number;
|
|
3374
|
+
/**
|
|
3375
|
+
* Triggers the audience rule did not answer with the DM.
|
|
3376
|
+
*/
|
|
3377
|
+
audienceSkipped?: number;
|
|
3378
|
+
followGateSent?: number;
|
|
3379
|
+
followGatePassed?: number;
|
|
3380
|
+
followGateFailed?: number;
|
|
3381
|
+
};
|
|
3382
|
+
|
|
3171
3383
|
/**
|
|
3172
3384
|
* A Meta generic template (product card) sent as the automation's first DM.
|
|
3173
3385
|
* It REPLACES the plain `dmMessage` bubble: a Meta message carries one body
|
|
3174
3386
|
* shape, and a comment gets exactly one private reply, so the card and the
|
|
3175
3387
|
* text cannot both be delivered. Put your selling copy in `subtitle`.
|
|
3176
|
-
* Mutually exclusive with `buttons` (sending both is a 400). Works on
|
|
3177
|
-
*
|
|
3388
|
+
* Mutually exclusive with `buttons` (sending both is a 400). Works on every
|
|
3389
|
+
* Instagram and Facebook trigger.
|
|
3178
3390
|
* Up to 10 elements, rendered as a horizontally swipeable carousel.
|
|
3179
3391
|
* Rendering confirmed on the Instagram and Messenger mobile apps.
|
|
3180
3392
|
*
|
|
@@ -3188,7 +3400,7 @@ export type CommentAutomationTemplate = {
|
|
|
3188
3400
|
elements: Array<CommentAutomationTemplateElement>;
|
|
3189
3401
|
};
|
|
3190
3402
|
|
|
3191
|
-
export type
|
|
3403
|
+
export type type4 = 'generic';
|
|
3192
3404
|
|
|
3193
3405
|
/**
|
|
3194
3406
|
* Facebook only. How Messenger renders each element imageUrl: horizontal (1.91:1, the default) or square (1:1). Instagram has no such setting, so an Instagram automation carrying it is a 400.
|
|
@@ -3360,9 +3572,9 @@ export type platform5 = 'shopify';
|
|
|
3360
3572
|
|
|
3361
3573
|
export type method = 'code' | 'automatic';
|
|
3362
3574
|
|
|
3363
|
-
export type
|
|
3575
|
+
export type type5 = 'percentage' | 'fixed_amount' | 'free_shipping' | 'buy_x_get_y' | 'app';
|
|
3364
3576
|
|
|
3365
|
-
export type
|
|
3577
|
+
export type status11 = 'active' | 'scheduled' | 'expired';
|
|
3366
3578
|
|
|
3367
3579
|
export type CommerceImage = {
|
|
3368
3580
|
/**
|
|
@@ -3417,7 +3629,7 @@ export type CommerceMarket = {
|
|
|
3417
3629
|
type?: string;
|
|
3418
3630
|
};
|
|
3419
3631
|
|
|
3420
|
-
export type
|
|
3632
|
+
export type status12 = 'active' | 'draft';
|
|
3421
3633
|
|
|
3422
3634
|
export type CommerceMenu = {
|
|
3423
3635
|
id?: string;
|
|
@@ -3438,7 +3650,7 @@ export type CommerceMenuItem = {
|
|
|
3438
3650
|
items?: Array<CommerceMenuItem>;
|
|
3439
3651
|
};
|
|
3440
3652
|
|
|
3441
|
-
export type
|
|
3653
|
+
export type type6 = 'frontpage' | 'collection' | 'collections' | 'product' | 'catalog' | 'page' | 'blog' | 'article' | 'search' | 'shop_policy' | 'http' | 'metaobject' | 'customer_account_page';
|
|
3442
3654
|
|
|
3443
3655
|
export type CommerceMenuItemInput = {
|
|
3444
3656
|
title: string;
|
|
@@ -3807,7 +4019,7 @@ export type ConversionDestination = {
|
|
|
3807
4019
|
* For LinkedIn, `inactive` means the rule is soft-deleted (`enabled: false`).
|
|
3808
4020
|
*
|
|
3809
4021
|
*/
|
|
3810
|
-
export type
|
|
4022
|
+
export type status13 = 'active' | 'inactive';
|
|
3811
4023
|
|
|
3812
4024
|
/**
|
|
3813
4025
|
* A single conversion event to relay to the ad platform. All PII fields
|
|
@@ -4693,7 +4905,7 @@ export type objective = 'OUTCOME_ENGAGEMENT' | 'OUTCOME_SALES' | 'OUTCOME_LEADS'
|
|
|
4693
4905
|
* `adSetId`, the new ads themselves.
|
|
4694
4906
|
*
|
|
4695
4907
|
*/
|
|
4696
|
-
export type
|
|
4908
|
+
export type status14 = 'ACTIVE' | 'PAUSED';
|
|
4697
4909
|
|
|
4698
4910
|
/**
|
|
4699
4911
|
* Campaign-level status, same semantics as `POST /v1/ads/create`. Defaults
|
|
@@ -5077,7 +5289,7 @@ export type privacy_level = 2;
|
|
|
5077
5289
|
/**
|
|
5078
5290
|
* 1=SCHEDULED, 2=ACTIVE, 3=COMPLETED, 4=CANCELED
|
|
5079
5291
|
*/
|
|
5080
|
-
export type
|
|
5292
|
+
export type status15 = 1 | 2 | 3 | 4;
|
|
5081
5293
|
|
|
5082
5294
|
/**
|
|
5083
5295
|
* 1=STAGE_INSTANCE, 2=VOICE, 3=EXTERNAL
|
|
@@ -5111,7 +5323,7 @@ export type DmButton = {
|
|
|
5111
5323
|
phone?: string;
|
|
5112
5324
|
};
|
|
5113
5325
|
|
|
5114
|
-
export type
|
|
5326
|
+
export type type7 = 'url' | 'postback' | 'phone';
|
|
5115
5327
|
|
|
5116
5328
|
/**
|
|
5117
5329
|
* Canonical error envelope. `error` is the human-readable message; `type`,
|
|
@@ -5246,7 +5458,7 @@ export type ErrorResponse = {
|
|
|
5246
5458
|
/**
|
|
5247
5459
|
* Error class for programmatic handling.
|
|
5248
5460
|
*/
|
|
5249
|
-
export type
|
|
5461
|
+
export type type8 = 'invalid_request_error' | 'authentication_error' | 'permission_error' | 'not_found' | 'rate_limit_error' | 'platform_error' | 'api_error';
|
|
5250
5462
|
|
|
5251
5463
|
/**
|
|
5252
5464
|
* Meta ad create failures only. The step that failed: `media` (image/video download or upload), `campaign`, `adset`, `creative`, `ad` (the ad POST itself, where Meta's code 31 / 3858385 hold and 100 / 1359188 payment rejections land), `activation` (switching the created objects on), or `other` (a read or check before any write).
|
|
@@ -5287,7 +5499,7 @@ export type ExternalPostMediaItem = {
|
|
|
5287
5499
|
unavailableReason?: 'platform_withheld';
|
|
5288
5500
|
};
|
|
5289
5501
|
|
|
5290
|
-
export type
|
|
5502
|
+
export type type9 = 'image' | 'video';
|
|
5291
5503
|
|
|
5292
5504
|
/**
|
|
5293
5505
|
* unavailable means the media file could not be retrieved (url is null or, for LinkedIn videos, a cover image standing in for the file). available or absent means the file is available at url (older synced items omit the field).
|
|
@@ -5446,7 +5658,7 @@ export type ExternalPostWebhookPost = {
|
|
|
5446
5658
|
/**
|
|
5447
5659
|
* Always "external". Distinguishes these from Zernio-originated post.* events.
|
|
5448
5660
|
*/
|
|
5449
|
-
export type
|
|
5661
|
+
export type source2 = 'external';
|
|
5450
5662
|
|
|
5451
5663
|
/**
|
|
5452
5664
|
* Feed posts support up to 10 images (no mixed video+image). Stories require single media (24h, no captions). Reels require a single vertical video (9:16). The Zernio API does not preflight Reel duration. Meta's Reels publishing guide documents 3-90 seconds. Geo-restriction is a hard visibility restriction: users outside the specified countries cannot see the post. Not supported for stories. Draft, carousel, and colored-background text options live under facebookSettings, see FacebookSettings.
|
|
@@ -5619,7 +5831,7 @@ export type FeedbackReceipt = {
|
|
|
5619
5831
|
duplicate?: boolean;
|
|
5620
5832
|
};
|
|
5621
5833
|
|
|
5622
|
-
export type
|
|
5834
|
+
export type status16 = 'received';
|
|
5623
5835
|
|
|
5624
5836
|
export type FollowerStatsResponse = {
|
|
5625
5837
|
accounts?: Array<AccountWithFollowerStats>;
|
|
@@ -5744,7 +5956,7 @@ export type GoogleAdLabel = {
|
|
|
5744
5956
|
description?: (string) | null;
|
|
5745
5957
|
};
|
|
5746
5958
|
|
|
5747
|
-
export type
|
|
5959
|
+
export type status17 = 'ENABLED' | 'REMOVED' | 'UNKNOWN';
|
|
5748
5960
|
|
|
5749
5961
|
/**
|
|
5750
5962
|
* At least one id across the four target lists. Up to 1000 ids per list.
|
|
@@ -5842,7 +6054,7 @@ export type GoogleAdsManagerLink = {
|
|
|
5842
6054
|
/**
|
|
5843
6055
|
* Status the link has after this call.
|
|
5844
6056
|
*/
|
|
5845
|
-
export type
|
|
6057
|
+
export type status18 = 'PENDING' | 'ACTIVE' | 'REFUSED' | 'CANCELED' | 'INACTIVE';
|
|
5846
6058
|
|
|
5847
6059
|
/**
|
|
5848
6060
|
* Link one asset to the asset group. Send exactly one of asset (an existing asset), text, imageUrl or youtubeVideoId (new content, created in the same request).
|
|
@@ -6014,7 +6226,7 @@ export type topicType = 'STANDARD' | 'EVENT' | 'OFFER';
|
|
|
6014
6226
|
/**
|
|
6015
6227
|
* Button action type: LEARN_MORE, BOOK, ORDER, SHOP, SIGN_UP, CALL
|
|
6016
6228
|
*/
|
|
6017
|
-
export type
|
|
6229
|
+
export type type10 = 'LEARN_MORE' | 'BOOK' | 'ORDER' | 'SHOP' | 'SIGN_UP' | 'CALL';
|
|
6018
6230
|
|
|
6019
6231
|
/**
|
|
6020
6232
|
* A Google Business Profile review, as returned by every gmb-reviews read endpoint.
|
|
@@ -6332,7 +6544,7 @@ export type GoogleListingGroupFilterNode = {
|
|
|
6332
6544
|
} | null;
|
|
6333
6545
|
};
|
|
6334
6546
|
|
|
6335
|
-
export type
|
|
6547
|
+
export type type11 = 'SUBDIVISION' | 'UNIT_INCLUDED' | 'UNIT_EXCLUDED';
|
|
6336
6548
|
|
|
6337
6549
|
export type GoogleListingGroupNode = {
|
|
6338
6550
|
dimension: GoogleListingGroupDimension;
|
|
@@ -6563,7 +6775,7 @@ export type GoogleRecommendationResult = {
|
|
|
6563
6775
|
error?: string;
|
|
6564
6776
|
};
|
|
6565
6777
|
|
|
6566
|
-
export type
|
|
6778
|
+
export type status19 = 'applied' | 'dismissed' | 'failed';
|
|
6567
6779
|
|
|
6568
6780
|
export type GoogleRsaDescription = {
|
|
6569
6781
|
text: string;
|
|
@@ -6651,7 +6863,7 @@ export type ImessageSandboxContact = {
|
|
|
6651
6863
|
createdAt?: string;
|
|
6652
6864
|
};
|
|
6653
6865
|
|
|
6654
|
-
export type
|
|
6866
|
+
export type status20 = 'pending' | 'active';
|
|
6655
6867
|
|
|
6656
6868
|
/**
|
|
6657
6869
|
* An iMessage sender registered as an account on a profile.
|
|
@@ -6720,7 +6932,7 @@ export type kind = 'phone' | 'email';
|
|
|
6720
6932
|
|
|
6721
6933
|
export type region = 'US' | 'GB';
|
|
6722
6934
|
|
|
6723
|
-
export type
|
|
6935
|
+
export type status21 = 'ordering' | 'activating' | 'active' | 'suspended' | 'canceled' | 'failed';
|
|
6724
6936
|
|
|
6725
6937
|
/**
|
|
6726
6938
|
* Attachment snapshot inside an edit-history entry.
|
|
@@ -6792,7 +7004,7 @@ export type InboxWebhookConversation = {
|
|
|
6792
7004
|
contactId?: string;
|
|
6793
7005
|
};
|
|
6794
7006
|
|
|
6795
|
-
export type
|
|
7007
|
+
export type status22 = 'active' | 'archived';
|
|
6796
7008
|
|
|
6797
7009
|
/**
|
|
6798
7010
|
* The conversation object included in conversation lifecycle webhook payloads (conversation.started, conversation.control_changed).
|
|
@@ -7907,7 +8119,7 @@ export type MediaItem = {
|
|
|
7907
8119
|
tiktokProcessed?: boolean;
|
|
7908
8120
|
};
|
|
7909
8121
|
|
|
7910
|
-
export type
|
|
8122
|
+
export type type12 = 'image' | 'video' | 'gif' | 'document';
|
|
7911
8123
|
|
|
7912
8124
|
export type MediaSubtitle = {
|
|
7913
8125
|
/**
|
|
@@ -7950,6 +8162,28 @@ export type MessagingCarouselCard = {
|
|
|
7950
8162
|
linkUrl?: string;
|
|
7951
8163
|
};
|
|
7952
8164
|
|
|
8165
|
+
export type MessengerGreeting = {
|
|
8166
|
+
/**
|
|
8167
|
+
* Meta locale, e.g. `default`, `en_US`, `es_ES`.
|
|
8168
|
+
*/
|
|
8169
|
+
locale: string;
|
|
8170
|
+
text: string;
|
|
8171
|
+
};
|
|
8172
|
+
|
|
8173
|
+
export type MessengerIceBreakerLocale = {
|
|
8174
|
+
/**
|
|
8175
|
+
* Meta locale, e.g. `default`, `en_US`.
|
|
8176
|
+
*/
|
|
8177
|
+
locale: string;
|
|
8178
|
+
call_to_actions: Array<{
|
|
8179
|
+
question: string;
|
|
8180
|
+
/**
|
|
8181
|
+
* Postback payload sent on tap. `zernio:workflow:<workflowId>` starts that workflow.
|
|
8182
|
+
*/
|
|
8183
|
+
payload: string;
|
|
8184
|
+
}>;
|
|
8185
|
+
};
|
|
8186
|
+
|
|
7953
8187
|
/**
|
|
7954
8188
|
* Meta (facebook/instagram) options for platformSpecificData on POST /v1/ads/boost and /v1/ads/create. Unknown keys are rejected, not dropped.
|
|
7955
8189
|
*/
|
|
@@ -8633,7 +8867,7 @@ export type OwnedPhoneNumber = {
|
|
|
8633
8867
|
}>;
|
|
8634
8868
|
};
|
|
8635
8869
|
|
|
8636
|
-
export type
|
|
8870
|
+
export type status23 = 'pending_payment' | 'pending_regulatory' | 'regulatory_declined' | 'provisioning' | 'verifying' | 'active' | 'suspended' | 'releasing' | 'released';
|
|
8637
8871
|
|
|
8638
8872
|
export type metaVerificationStatus = 'pending' | 'code_requested' | 'verified' | 'expired';
|
|
8639
8873
|
|
|
@@ -8763,7 +8997,7 @@ export type PlatformAnalytics = {
|
|
|
8763
8997
|
errorMessage?: (string) | null;
|
|
8764
8998
|
};
|
|
8765
8999
|
|
|
8766
|
-
export type
|
|
9000
|
+
export type status24 = 'published' | 'failed';
|
|
8767
9001
|
|
|
8768
9002
|
/**
|
|
8769
9003
|
* Sync state of analytics for this platform
|
|
@@ -8892,7 +9126,7 @@ export type PortfolioBidStrategy = {
|
|
|
8892
9126
|
targetRoas?: (number) | null;
|
|
8893
9127
|
};
|
|
8894
9128
|
|
|
8895
|
-
export type
|
|
9129
|
+
export type type13 = 'TARGET_CPA' | 'TARGET_ROAS' | 'MAXIMIZE_CONVERSIONS' | 'MAXIMIZE_CONVERSION_VALUE';
|
|
8896
9130
|
|
|
8897
9131
|
export type Post = {
|
|
8898
9132
|
_id?: string;
|
|
@@ -9173,7 +9407,7 @@ export type Product = {
|
|
|
9173
9407
|
publishedAt?: (string) | null;
|
|
9174
9408
|
};
|
|
9175
9409
|
|
|
9176
|
-
export type
|
|
9410
|
+
export type status25 = 'active' | 'draft' | 'archived';
|
|
9177
9411
|
|
|
9178
9412
|
export type ProductImage = {
|
|
9179
9413
|
url?: string;
|
|
@@ -9388,7 +9622,7 @@ export type RcsAgent = {
|
|
|
9388
9622
|
createdAt?: string;
|
|
9389
9623
|
};
|
|
9390
9624
|
|
|
9391
|
-
export type
|
|
9625
|
+
export type status26 = 'requested' | 'changes_requested' | 'brand_vetting' | 'agent_review' | 'testing' | 'launch_review' | 'launching' | 'live' | 'rejected' | 'deactivated';
|
|
9392
9626
|
|
|
9393
9627
|
export type useCase = 'MULTI_USE' | 'PROMOTIONAL' | 'TRANSACTIONAL' | 'OTP';
|
|
9394
9628
|
|
|
@@ -9440,7 +9674,7 @@ export type RcsBrand = RcsBrandInput & {
|
|
|
9440
9674
|
/**
|
|
9441
9675
|
* draft = not filed yet (still editable).
|
|
9442
9676
|
*/
|
|
9443
|
-
export type
|
|
9677
|
+
export type status27 = 'draft' | 'vetting' | 'verified' | 'rejected';
|
|
9444
9678
|
|
|
9445
9679
|
export type RcsBrandInput = {
|
|
9446
9680
|
displayName: string;
|
|
@@ -9527,7 +9761,7 @@ export type RcsCarrierApproval = {
|
|
|
9527
9761
|
|
|
9528
9762
|
export type scope2 = 'carrier' | 'hub' | 'bot';
|
|
9529
9763
|
|
|
9530
|
-
export type
|
|
9764
|
+
export type status28 = 'PENDING' | 'SUBMITTED' | 'APPROVED' | 'REJECTED';
|
|
9531
9765
|
|
|
9532
9766
|
/**
|
|
9533
9767
|
* Message content. `suggestions` (max 11) render as chips under the message.
|
|
@@ -9553,7 +9787,7 @@ export type RcsContent = {
|
|
|
9553
9787
|
suggestions?: Array<RcsSuggestion>;
|
|
9554
9788
|
};
|
|
9555
9789
|
|
|
9556
|
-
export type
|
|
9790
|
+
export type type14 = 'text';
|
|
9557
9791
|
|
|
9558
9792
|
export type orientation = 'VERTICAL' | 'HORIZONTAL';
|
|
9559
9793
|
|
|
@@ -9666,7 +9900,7 @@ export type RcsSuggestion = {
|
|
|
9666
9900
|
postbackData?: string;
|
|
9667
9901
|
};
|
|
9668
9902
|
|
|
9669
|
-
export type
|
|
9903
|
+
export type type15 = 'reply';
|
|
9670
9904
|
|
|
9671
9905
|
export type application = 'BROWSER' | 'WEBVIEW';
|
|
9672
9906
|
|
|
@@ -10054,7 +10288,7 @@ export type contentType3 = 'story' | 'saved_story' | 'spotlight';
|
|
|
10054
10288
|
|
|
10055
10289
|
export type SocialAccount = {
|
|
10056
10290
|
_id: string;
|
|
10057
|
-
platform: 'tiktok' | 'instagram' | 'facebook' | 'youtube' | 'linkedin' | 'twitter' | 'threads' | 'pinterest' | 'reddit' | 'bluesky' | 'googlebusiness' | 'telegram' | 'snapchat' | 'discord' | 'slack' | 'whatsapp' | 'shopify' | 'wordpress' | 'linkedinads' | 'metaads' | 'pinterestads' | 'tiktokads' | 'xads' | 'googleads' | 'openaiads' | 'sms' | 'phone' | 'rcs';
|
|
10291
|
+
platform: 'tiktok' | 'instagram' | 'facebook' | 'youtube' | 'linkedin' | 'twitter' | 'threads' | 'pinterest' | 'reddit' | 'bluesky' | 'googlebusiness' | 'telegram' | 'snapchat' | 'discord' | 'slack' | 'whatsapp' | 'shopify' | 'wordpress' | 'linkedinads' | 'metaads' | 'pinterestads' | 'tiktokads' | 'xads' | 'googleads' | 'openaiads' | 'sms' | 'phone' | 'rcs' | 'whopads';
|
|
10058
10292
|
profileId: (string | Profile);
|
|
10059
10293
|
username?: string;
|
|
10060
10294
|
displayName?: string;
|
|
@@ -10136,7 +10370,7 @@ export type SocialAccount = {
|
|
|
10136
10370
|
};
|
|
10137
10371
|
};
|
|
10138
10372
|
|
|
10139
|
-
export type platform11 = 'tiktok' | 'instagram' | 'facebook' | 'youtube' | 'linkedin' | 'twitter' | 'threads' | 'pinterest' | 'reddit' | 'bluesky' | 'googlebusiness' | 'telegram' | 'snapchat' | 'discord' | 'slack' | 'whatsapp' | 'shopify' | 'wordpress' | 'linkedinads' | 'metaads' | 'pinterestads' | 'tiktokads' | 'xads' | 'googleads' | 'openaiads' | 'sms' | 'phone' | 'rcs';
|
|
10373
|
+
export type platform11 = 'tiktok' | 'instagram' | 'facebook' | 'youtube' | 'linkedin' | 'twitter' | 'threads' | 'pinterest' | 'reddit' | 'bluesky' | 'googlebusiness' | 'telegram' | 'snapchat' | 'discord' | 'slack' | 'whatsapp' | 'shopify' | 'wordpress' | 'linkedinads' | 'metaads' | 'pinterestads' | 'tiktokads' | 'xads' | 'googleads' | 'openaiads' | 'sms' | 'phone' | 'rcs' | 'whopads';
|
|
10140
10374
|
|
|
10141
10375
|
/**
|
|
10142
10376
|
* A tracking tag's install on a connected store: a Shopify web pixel, or a Custom HTML widget on a WordPress site. Fields marked Shopify or WordPress are present only for that platform.
|
|
@@ -10709,7 +10943,7 @@ export type TrackingTag = {
|
|
|
10709
10943
|
*/
|
|
10710
10944
|
events?: Array<TrackingTagEvent>;
|
|
10711
10945
|
name: string;
|
|
10712
|
-
platform: 'metaads' | 'openaiads' | 'tiktokads' | 'googleads' | 'xads' | 'linkedinads' | 'pinterestads';
|
|
10946
|
+
platform: 'metaads' | 'openaiads' | 'tiktokads' | 'googleads' | 'xads' | 'linkedinads' | 'pinterestads' | 'whopads';
|
|
10713
10947
|
/**
|
|
10714
10948
|
* Platform-native flavor of the tag (Meta: `pixel`).
|
|
10715
10949
|
*/
|
|
@@ -10764,7 +10998,7 @@ export type TrackingTag = {
|
|
|
10764
10998
|
autoTagging?: boolean;
|
|
10765
10999
|
};
|
|
10766
11000
|
|
|
10767
|
-
export type platform12 = 'metaads' | 'openaiads' | 'tiktokads' | 'googleads' | 'xads' | 'linkedinads' | 'pinterestads';
|
|
11001
|
+
export type platform12 = 'metaads' | 'openaiads' | 'tiktokads' | 'googleads' | 'xads' | 'linkedinads' | 'pinterestads' | 'whopads';
|
|
10768
11002
|
|
|
10769
11003
|
/**
|
|
10770
11004
|
* Platform-native flavor of the tag (Meta: `pixel`).
|
|
@@ -11003,7 +11237,7 @@ export type UploadedFile = {
|
|
|
11003
11237
|
mimeType?: string;
|
|
11004
11238
|
};
|
|
11005
11239
|
|
|
11006
|
-
export type
|
|
11240
|
+
export type type16 = 'image' | 'video' | 'document';
|
|
11007
11241
|
|
|
11008
11242
|
export type UploadTokenResponse = {
|
|
11009
11243
|
token?: string;
|
|
@@ -11012,7 +11246,7 @@ export type UploadTokenResponse = {
|
|
|
11012
11246
|
status?: 'pending' | 'completed' | 'expired';
|
|
11013
11247
|
};
|
|
11014
11248
|
|
|
11015
|
-
export type
|
|
11249
|
+
export type status29 = 'pending' | 'completed' | 'expired';
|
|
11016
11250
|
|
|
11017
11251
|
export type UploadTokenStatusResponse = {
|
|
11018
11252
|
token?: string;
|
|
@@ -11213,7 +11447,7 @@ export type granularity = 'day' | 'month' | 'total';
|
|
|
11213
11447
|
/**
|
|
11214
11448
|
* `cycle` = a real billing period resolved; `window` = trailing/custom window (or cycle fallback).
|
|
11215
11449
|
*/
|
|
11216
|
-
export type
|
|
11450
|
+
export type source3 = 'cycle' | 'window';
|
|
11217
11451
|
|
|
11218
11452
|
export type groupBy = 'profile' | 'account';
|
|
11219
11453
|
|
|
@@ -11519,7 +11753,7 @@ export type Verification = {
|
|
|
11519
11753
|
resend?: boolean;
|
|
11520
11754
|
};
|
|
11521
11755
|
|
|
11522
|
-
export type
|
|
11756
|
+
export type status30 = 'pending' | 'approved' | 'expired' | 'max_attempts_reached' | 'canceled' | 'delivery_failed';
|
|
11523
11757
|
|
|
11524
11758
|
export type channel4 = 'sms' | 'whatsapp';
|
|
11525
11759
|
|
|
@@ -11551,7 +11785,7 @@ export type Webhook = {
|
|
|
11551
11785
|
/**
|
|
11552
11786
|
* Events subscribed to
|
|
11553
11787
|
*/
|
|
11554
|
-
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.platform.deleted' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'account.ads.sync_failed' | 'account.ads.sync_recovered' | 'analytics.synced' | 'message.received' | 'conversation.started' | 'conversation.control_changed' | 'call.received' | 'call.ended' | 'call.failed' | 'call.permission_request' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.played' | 'message.failed' | 'reaction.received' | 'referral.received' | 'comment.received' | 'review.new' | 'review.updated' | 'lead.received' | 'ad.status_changed' | 'ad.video.processed' | 'whatsapp.template.status_updated' | 'whatsapp.template.category_updated' | 'whatsapp.account.name_status_updated' | 'whatsapp.account.quality_updated' | 'whatsapp.account.status_updated' | 'whatsapp.account.alert_received' | 'whatsapp.contact.identity_changed' | 'whatsapp.automatic_event' | 'whatsapp.number.activated' | 'whatsapp.number.declined' | 'whatsapp.number.action_required' | 'whatsapp.number.verification_required' | 'whatsapp.number.suspended' | 'whatsapp.number.reactivated' | 'whatsapp.number.released' | 'whatsapp.number.kyc_submitted' | 'phone_number.stock_available' | 'verification.approved' | 'verification.failed' | 'api.changelog.published' | 'sms.registration.action_required' | 'sms.registration.status_updated' | 'branded_calling.identity.status_updated' | 'branded_calling.identity.action_required' | 'branded_calling.number.status_updated' | 'rcs.agent.status_updated' | 'commerce.product.created' | 'commerce.product.updated' | 'commerce.product.deleted')>;
|
|
11788
|
+
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.platform.deleted' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'account.ads.sync_failed' | 'account.ads.sync_recovered' | 'analytics.synced' | 'message.received' | 'conversation.started' | 'conversation.control_changed' | 'call.received' | 'call.ended' | 'call.failed' | 'call.permission_request' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.played' | 'message.failed' | 'reaction.received' | 'referral.received' | 'comment.received' | 'review.new' | 'review.updated' | 'lead.received' | 'ad.status_changed' | 'ad.video.processed' | 'whatsapp.template.status_updated' | 'whatsapp.template.category_updated' | 'whatsapp.account.name_status_updated' | 'whatsapp.account.quality_updated' | 'whatsapp.account.status_updated' | 'whatsapp.account.alert_received' | 'whatsapp.contact.identity_changed' | 'whatsapp.automatic_event' | 'whatsapp.number.activated' | 'whatsapp.number.declined' | 'whatsapp.number.action_required' | 'whatsapp.number.verification_required' | 'whatsapp.number.suspended' | 'whatsapp.number.reactivated' | 'whatsapp.number.released' | 'whatsapp.number.kyc_submitted' | 'phone_number.stock_available' | 'verification.approved' | 'verification.failed' | 'api.changelog.published' | 'sms.registration.action_required' | 'sms.registration.status_updated' | 'branded_calling.identity.status_updated' | 'branded_calling.identity.action_required' | 'branded_calling.number.status_updated' | 'rcs.agent.status_updated' | 'commerce.product.created' | 'commerce.product.updated' | 'commerce.product.deleted' | 'contact.tag_added' | 'contact.tag_removed' | 'contact.field_changed' | 'sequence.enrolled' | 'sequence.exited' | 'workflow.run.started' | 'workflow.run.completed' | 'workflow.run.failed')>;
|
|
11555
11789
|
/**
|
|
11556
11790
|
* Whether webhook delivery is enabled
|
|
11557
11791
|
*/
|
|
@@ -11673,7 +11907,7 @@ export type WebhookLog = {
|
|
|
11673
11907
|
/**
|
|
11674
11908
|
* Delivery outcome
|
|
11675
11909
|
*/
|
|
11676
|
-
export type
|
|
11910
|
+
export type status31 = 'success' | 'failed';
|
|
11677
11911
|
|
|
11678
11912
|
/**
|
|
11679
11913
|
* Webhook payload for `account.ads.initial_sync_completed` events.
|
|
@@ -11785,7 +12019,7 @@ export type event = 'account.ads.initial_sync_completed';
|
|
|
11785
12019
|
/**
|
|
11786
12020
|
* Overall outcome of the initial sync.
|
|
11787
12021
|
*/
|
|
11788
|
-
export type
|
|
12022
|
+
export type status32 = 'success' | 'failure';
|
|
11789
12023
|
|
|
11790
12024
|
/**
|
|
11791
12025
|
* Stable category for UX branching. New values may be added; existing ones are
|
|
@@ -12146,7 +12380,7 @@ export type event7 = 'ad.video.processed';
|
|
|
12146
12380
|
/**
|
|
12147
12381
|
* `ready`: usable as `video.id` on the create endpoints. `error`: Meta could not process it; upload again.
|
|
12148
12382
|
*/
|
|
12149
|
-
export type
|
|
12383
|
+
export type status33 = 'ready' | 'error';
|
|
12150
12384
|
|
|
12151
12385
|
/**
|
|
12152
12386
|
* Webhook payload for `analytics.synced`. Fired once per connected account each
|
|
@@ -12500,6 +12734,10 @@ export type WebhookPayloadComment = {
|
|
|
12500
12734
|
* Parent comment ID if this is a reply
|
|
12501
12735
|
*/
|
|
12502
12736
|
parentCommentId: (string) | null;
|
|
12737
|
+
/**
|
|
12738
|
+
* Instagram only: true when the comment was made on a live broadcast (the live_comments webhook field). Absent on every other comment.
|
|
12739
|
+
*/
|
|
12740
|
+
isLive?: boolean;
|
|
12503
12741
|
/**
|
|
12504
12742
|
* Ad context. Present only when the comment was made on paid content.
|
|
12505
12743
|
* Instagram: populated from the webhook payload's value.media.ad_id, value.media.ad_title and value.media.original_media_id, each only when Meta includes it.
|
|
@@ -12630,11 +12868,72 @@ export type WebhookPayloadCommerceProduct = {
|
|
|
12630
12868
|
|
|
12631
12869
|
export type event15 = 'commerce.product.created' | 'commerce.product.updated' | 'commerce.product.deleted';
|
|
12632
12870
|
|
|
12633
|
-
export type
|
|
12871
|
+
export type type17 = 'product';
|
|
12872
|
+
|
|
12873
|
+
export type WebhookPayloadContactFieldChanged = {
|
|
12874
|
+
/**
|
|
12875
|
+
* Event id, the dedupe key.
|
|
12876
|
+
*/
|
|
12877
|
+
id: string;
|
|
12878
|
+
event: 'contact.field_changed';
|
|
12879
|
+
timestamp: string;
|
|
12880
|
+
contact: {
|
|
12881
|
+
/**
|
|
12882
|
+
* Zernio contact id.
|
|
12883
|
+
*/
|
|
12884
|
+
id?: string;
|
|
12885
|
+
};
|
|
12886
|
+
/**
|
|
12887
|
+
* Custom field slug.
|
|
12888
|
+
*/
|
|
12889
|
+
field: string;
|
|
12890
|
+
/**
|
|
12891
|
+
* Value before the write; null when the field was not set.
|
|
12892
|
+
*/
|
|
12893
|
+
previousValue: unknown;
|
|
12894
|
+
/**
|
|
12895
|
+
* Value after the write; null when the field was removed.
|
|
12896
|
+
*/
|
|
12897
|
+
value: unknown;
|
|
12898
|
+
/**
|
|
12899
|
+
* Who wrote the field: the API or dashboard, a workflow set_field node, or an automation.
|
|
12900
|
+
*/
|
|
12901
|
+
source: 'api' | 'workflow' | 'automation';
|
|
12902
|
+
};
|
|
12903
|
+
|
|
12904
|
+
export type event16 = 'contact.field_changed';
|
|
12634
12905
|
|
|
12635
12906
|
/**
|
|
12636
|
-
*
|
|
12637
|
-
|
|
12907
|
+
* Who wrote the field: the API or dashboard, a workflow set_field node, or an automation.
|
|
12908
|
+
*/
|
|
12909
|
+
export type source4 = 'api' | 'workflow' | 'automation';
|
|
12910
|
+
|
|
12911
|
+
export type WebhookPayloadContactTag = {
|
|
12912
|
+
/**
|
|
12913
|
+
* Event id, the dedupe key.
|
|
12914
|
+
*/
|
|
12915
|
+
id: string;
|
|
12916
|
+
event: 'contact.tag_added' | 'contact.tag_removed';
|
|
12917
|
+
timestamp: string;
|
|
12918
|
+
contact: {
|
|
12919
|
+
/**
|
|
12920
|
+
* Zernio contact id.
|
|
12921
|
+
*/
|
|
12922
|
+
id?: string;
|
|
12923
|
+
};
|
|
12924
|
+
tag: string;
|
|
12925
|
+
/**
|
|
12926
|
+
* Who wrote the tag: the API or dashboard, a workflow add_tag / remove_tag node, or a comment-automation link click.
|
|
12927
|
+
*/
|
|
12928
|
+
source: 'api' | 'workflow' | 'automation';
|
|
12929
|
+
};
|
|
12930
|
+
|
|
12931
|
+
export type event17 = 'contact.tag_added' | 'contact.tag_removed';
|
|
12932
|
+
|
|
12933
|
+
/**
|
|
12934
|
+
* Who answers a conversation changed under Meta's handover protocol. WhatsApp: Meta
|
|
12935
|
+
* Business Agent took it over, handed it to you, or another partner app took it.
|
|
12936
|
+
* Facebook and Instagram: another app passed the thread to you, or took or received it.
|
|
12638
12937
|
*
|
|
12639
12938
|
*/
|
|
12640
12939
|
export type WebhookPayloadConversationControlChanged = {
|
|
@@ -12647,13 +12946,17 @@ export type WebhookPayloadConversationControlChanged = {
|
|
|
12647
12946
|
account: InboxWebhookAccount;
|
|
12648
12947
|
control: {
|
|
12649
12948
|
/**
|
|
12650
|
-
* Who answers now. ai_agent: Meta Business Agent; app: you; other: another partner
|
|
12949
|
+
* Who answers now. ai_agent: Meta Business Agent (WhatsApp); app: you; other: another app (a WhatsApp partner, or a Messenger / Instagram receiver such as Page Inbox).
|
|
12651
12950
|
*/
|
|
12652
12951
|
owner: 'app' | 'ai_agent' | 'other';
|
|
12653
12952
|
/**
|
|
12654
|
-
* Owner before this change, null when
|
|
12953
|
+
* Owner before this change, null when no handover had touched the thread.
|
|
12655
12954
|
*/
|
|
12656
12955
|
previousOwner: ('app' | 'ai_agent' | 'other') | null;
|
|
12956
|
+
/**
|
|
12957
|
+
* Meta app id of the new owner, when Meta names it (Facebook and Instagram handovers, WhatsApp partner apps). Page Inbox is 263902037430900.
|
|
12958
|
+
*/
|
|
12959
|
+
ownerAppId?: string;
|
|
12657
12960
|
/**
|
|
12658
12961
|
* Free-form string the transferring app attached to the handover, forwarded verbatim.
|
|
12659
12962
|
*/
|
|
@@ -12666,15 +12969,15 @@ export type WebhookPayloadConversationControlChanged = {
|
|
|
12666
12969
|
timestamp: string;
|
|
12667
12970
|
};
|
|
12668
12971
|
|
|
12669
|
-
export type
|
|
12972
|
+
export type event18 = 'conversation.control_changed';
|
|
12670
12973
|
|
|
12671
12974
|
/**
|
|
12672
|
-
* Who answers now. ai_agent: Meta Business Agent; app: you; other: another partner
|
|
12975
|
+
* Who answers now. ai_agent: Meta Business Agent (WhatsApp); app: you; other: another app (a WhatsApp partner, or a Messenger / Instagram receiver such as Page Inbox).
|
|
12673
12976
|
*/
|
|
12674
12977
|
export type owner = 'app' | 'ai_agent' | 'other';
|
|
12675
12978
|
|
|
12676
12979
|
/**
|
|
12677
|
-
* Owner before this change, null when
|
|
12980
|
+
* Owner before this change, null when no handover had touched the thread.
|
|
12678
12981
|
*/
|
|
12679
12982
|
export type previousOwner = 'app' | 'ai_agent' | 'other';
|
|
12680
12983
|
|
|
@@ -12703,7 +13006,7 @@ export type WebhookPayloadConversationStarted = {
|
|
|
12703
13006
|
timestamp: string;
|
|
12704
13007
|
};
|
|
12705
13008
|
|
|
12706
|
-
export type
|
|
13009
|
+
export type event19 = 'conversation.started';
|
|
12707
13010
|
|
|
12708
13011
|
/**
|
|
12709
13012
|
* Webhook payload for post.external.created / post.external.updated /
|
|
@@ -12735,7 +13038,7 @@ export type WebhookPayloadExternalPost = {
|
|
|
12735
13038
|
timestamp: string;
|
|
12736
13039
|
};
|
|
12737
13040
|
|
|
12738
|
-
export type
|
|
13041
|
+
export type event20 = 'post.external.created' | 'post.external.updated' | 'post.external.deleted';
|
|
12739
13042
|
|
|
12740
13043
|
/**
|
|
12741
13044
|
* Webhook payload for lead.received events (Meta Lead Gen / Instant Forms).
|
|
@@ -12806,7 +13109,7 @@ export type WebhookPayloadLead = {
|
|
|
12806
13109
|
timestamp: string;
|
|
12807
13110
|
};
|
|
12808
13111
|
|
|
12809
|
-
export type
|
|
13112
|
+
export type event21 = 'lead.received';
|
|
12810
13113
|
|
|
12811
13114
|
export type platform14 = 'facebook';
|
|
12812
13115
|
|
|
@@ -13000,15 +13303,35 @@ export type WebhookPayloadMessage = {
|
|
|
13000
13303
|
*
|
|
13001
13304
|
*/
|
|
13002
13305
|
sentVia?: ('human' | 'api' | 'broadcast' | 'sequence' | 'workflow' | 'comment_automation' | 'bulk-api') | null;
|
|
13306
|
+
/**
|
|
13307
|
+
* Always null on this event; see message.sent.
|
|
13308
|
+
*/
|
|
13309
|
+
automationId?: (string) | null;
|
|
13310
|
+
/**
|
|
13311
|
+
* Always null on this event; see message.sent.
|
|
13312
|
+
*/
|
|
13313
|
+
workflowId?: (string) | null;
|
|
13314
|
+
/**
|
|
13315
|
+
* Always null on this event; see message.sent.
|
|
13316
|
+
*/
|
|
13317
|
+
executionId?: (string) | null;
|
|
13318
|
+
/**
|
|
13319
|
+
* Always null on this event; see message.sent.
|
|
13320
|
+
*/
|
|
13321
|
+
broadcastId?: (string) | null;
|
|
13322
|
+
/**
|
|
13323
|
+
* Always null on this event; see message.sent.
|
|
13324
|
+
*/
|
|
13325
|
+
sequenceId?: (string) | null;
|
|
13003
13326
|
};
|
|
13004
13327
|
conversation: InboxWebhookConversation;
|
|
13005
13328
|
account: InboxWebhookAccount;
|
|
13006
13329
|
/**
|
|
13007
|
-
* Platform-specific message context (present when the message is a quick reply tap, postback button tap, inline keyboard callback, a quote-reply to an earlier message,
|
|
13330
|
+
* Platform-specific message context (present when the message is a quick reply tap, postback button tap, inline keyboard callback, a quote-reply to an earlier message, an inbound another app is answering under Meta's handover protocol, or a TikTok DM that is not plain text)
|
|
13008
13331
|
*/
|
|
13009
13332
|
metadata?: {
|
|
13010
13333
|
/**
|
|
13011
|
-
*
|
|
13334
|
+
* true when this inbound arrived on Meta's standby path because another app owned the conversation: Meta Business Agent on WhatsApp, another handover receiver (such as Page Inbox) on Facebook and Instagram. That app answers it, Zernio only observes, and no automation runs. On WhatsApp sending a reply takes control back; on Facebook and Instagram take control first with POST /v1/inbox/conversations/{conversationId}/thread-control. See conversation.control_changed.
|
|
13012
13335
|
*/
|
|
13013
13336
|
standby?: boolean;
|
|
13014
13337
|
/**
|
|
@@ -13365,7 +13688,7 @@ export type WebhookPayloadMessage = {
|
|
|
13365
13688
|
timestamp: string;
|
|
13366
13689
|
};
|
|
13367
13690
|
|
|
13368
|
-
export type
|
|
13691
|
+
export type event22 = 'message.received';
|
|
13369
13692
|
|
|
13370
13693
|
/**
|
|
13371
13694
|
* Which Zernio surface produced the message. Always present and
|
|
@@ -13426,7 +13749,7 @@ export type WebhookPayloadMessageDeleted = {
|
|
|
13426
13749
|
timestamp: string;
|
|
13427
13750
|
};
|
|
13428
13751
|
|
|
13429
|
-
export type
|
|
13752
|
+
export type event23 = 'message.deleted';
|
|
13430
13753
|
|
|
13431
13754
|
/**
|
|
13432
13755
|
* Shared payload for message.delivered, message.read, message.played and
|
|
@@ -13489,7 +13812,7 @@ export type WebhookPayloadMessageDeliveryStatus = {
|
|
|
13489
13812
|
timestamp: string;
|
|
13490
13813
|
};
|
|
13491
13814
|
|
|
13492
|
-
export type
|
|
13815
|
+
export type event24 = 'message.delivered' | 'message.read' | 'message.played' | 'message.failed';
|
|
13493
13816
|
|
|
13494
13817
|
/**
|
|
13495
13818
|
* Webhook payload for message.edited events. Fires when the sender
|
|
@@ -13527,7 +13850,7 @@ export type WebhookPayloadMessageEdited = {
|
|
|
13527
13850
|
timestamp: string;
|
|
13528
13851
|
};
|
|
13529
13852
|
|
|
13530
|
-
export type
|
|
13853
|
+
export type event25 = 'message.edited';
|
|
13531
13854
|
|
|
13532
13855
|
/**
|
|
13533
13856
|
* Webhook payload for message sent events (fired when a message is sent via the API, or from the WhatsApp Business app on Coexistence numbers)
|
|
@@ -13649,6 +13972,26 @@ export type WebhookPayloadMessageSent = {
|
|
|
13649
13972
|
*
|
|
13650
13973
|
*/
|
|
13651
13974
|
sentVia?: ('human' | 'api' | 'broadcast' | 'sequence' | 'workflow' | 'comment_automation' | 'bulk-api') | null;
|
|
13975
|
+
/**
|
|
13976
|
+
* The comment automation that sent this DM (sentVia comment_automation). Null otherwise.
|
|
13977
|
+
*/
|
|
13978
|
+
automationId?: (string) | null;
|
|
13979
|
+
/**
|
|
13980
|
+
* The workflow whose run sent this message (sentVia workflow). Null otherwise.
|
|
13981
|
+
*/
|
|
13982
|
+
workflowId?: (string) | null;
|
|
13983
|
+
/**
|
|
13984
|
+
* The workflow run (execution) that sent this message, as returned by the workflow executions endpoints. Null when workflowId is null.
|
|
13985
|
+
*/
|
|
13986
|
+
executionId?: (string) | null;
|
|
13987
|
+
/**
|
|
13988
|
+
* The broadcast that sent this message (sentVia broadcast). Null otherwise.
|
|
13989
|
+
*/
|
|
13990
|
+
broadcastId?: (string) | null;
|
|
13991
|
+
/**
|
|
13992
|
+
* The sequence whose step sent this message (sentVia sequence). Null otherwise.
|
|
13993
|
+
*/
|
|
13994
|
+
sequenceId?: (string) | null;
|
|
13652
13995
|
};
|
|
13653
13996
|
pricing?: WhatsAppMessagePricing;
|
|
13654
13997
|
billingConversation?: WhatsAppBillingConversation;
|
|
@@ -13745,7 +14088,7 @@ export type WebhookPayloadMessageSent = {
|
|
|
13745
14088
|
timestamp: string;
|
|
13746
14089
|
};
|
|
13747
14090
|
|
|
13748
|
-
export type
|
|
14091
|
+
export type event26 = 'message.sent';
|
|
13749
14092
|
|
|
13750
14093
|
/**
|
|
13751
14094
|
* Every platform whose outgoing messages Zernio observes. sms is absent on purpose: its carrier receipts update delivery status and never raise message.sent.
|
|
@@ -13755,7 +14098,7 @@ export type platform15 = 'instagram' | 'facebook' | 'telegram' | 'whatsapp' | 't
|
|
|
13755
14098
|
/**
|
|
13756
14099
|
* WhatsApp send origin. whatsapp_business_app when sent from the WhatsApp Business phone app on a Coexistence number; cloud_api when sent through Zernio (dashboard, API, or broadcasts); meta_business_agent when Meta Business Agent answered on the number. Absent on non-WhatsApp platforms. Says where WhatsApp saw the send come from, not which Zernio surface produced it: read sentVia for that.
|
|
13757
14100
|
*/
|
|
13758
|
-
export type
|
|
14101
|
+
export type source5 = 'whatsapp_business_app' | 'cloud_api' | 'meta_business_agent';
|
|
13759
14102
|
|
|
13760
14103
|
/**
|
|
13761
14104
|
* Webhook payload for phone_number.stock_available events
|
|
@@ -13799,7 +14142,7 @@ export type WebhookPayloadPhoneNumberStockAvailable = {
|
|
|
13799
14142
|
timestamp: string;
|
|
13800
14143
|
};
|
|
13801
14144
|
|
|
13802
|
-
export type
|
|
14145
|
+
export type event27 = 'phone_number.stock_available';
|
|
13803
14146
|
|
|
13804
14147
|
/**
|
|
13805
14148
|
* Webhook payload for post events
|
|
@@ -13849,7 +14192,7 @@ export type WebhookPayloadPost = {
|
|
|
13849
14192
|
timestamp: string;
|
|
13850
14193
|
};
|
|
13851
14194
|
|
|
13852
|
-
export type
|
|
14195
|
+
export type event28 = 'post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled';
|
|
13853
14196
|
|
|
13854
14197
|
/**
|
|
13855
14198
|
* Webhook payload for the per-platform terminal events
|
|
@@ -13968,12 +14311,12 @@ export type WebhookPayloadPostPlatform = {
|
|
|
13968
14311
|
timestamp: string;
|
|
13969
14312
|
};
|
|
13970
14313
|
|
|
13971
|
-
export type
|
|
14314
|
+
export type event29 = 'post.platform.published' | 'post.platform.failed' | 'post.platform.deleted' | 'post.tiktok.url_resolved';
|
|
13972
14315
|
|
|
13973
14316
|
/**
|
|
13974
14317
|
* Terminal status this event fires on. Matches the event suffix.
|
|
13975
14318
|
*/
|
|
13976
|
-
export type
|
|
14319
|
+
export type status34 = 'published' | 'failed' | 'deleted';
|
|
13977
14320
|
|
|
13978
14321
|
/**
|
|
13979
14322
|
* Webhook payload for reaction received events (WhatsApp, Telegram, Slack, Instagram, Facebook Messenger, TikTok)
|
|
@@ -14028,7 +14371,7 @@ export type WebhookPayloadReaction = {
|
|
|
14028
14371
|
timestamp: string;
|
|
14029
14372
|
};
|
|
14030
14373
|
|
|
14031
|
-
export type
|
|
14374
|
+
export type event30 = 'reaction.received';
|
|
14032
14375
|
|
|
14033
14376
|
export type action = 'added' | 'removed';
|
|
14034
14377
|
|
|
@@ -14102,7 +14445,7 @@ export type WebhookPayloadReferral = {
|
|
|
14102
14445
|
timestamp: string;
|
|
14103
14446
|
};
|
|
14104
14447
|
|
|
14105
|
-
export type
|
|
14448
|
+
export type event31 = 'referral.received';
|
|
14106
14449
|
|
|
14107
14450
|
/**
|
|
14108
14451
|
* Webhook payload for the review.new event (new review posted on a connected account).
|
|
@@ -14129,7 +14472,7 @@ export type WebhookPayloadReviewNew = {
|
|
|
14129
14472
|
timestamp: string;
|
|
14130
14473
|
};
|
|
14131
14474
|
|
|
14132
|
-
export type
|
|
14475
|
+
export type event32 = 'review.new';
|
|
14133
14476
|
|
|
14134
14477
|
/**
|
|
14135
14478
|
* Webhook payload for the review.updated event. Fired when the reviewer edits their
|
|
@@ -14162,7 +14505,40 @@ export type WebhookPayloadReviewUpdated = {
|
|
|
14162
14505
|
timestamp: string;
|
|
14163
14506
|
};
|
|
14164
14507
|
|
|
14165
|
-
export type
|
|
14508
|
+
export type event33 = 'review.updated';
|
|
14509
|
+
|
|
14510
|
+
export type WebhookPayloadSequenceEnrollment = {
|
|
14511
|
+
/**
|
|
14512
|
+
* Event id, the dedupe key.
|
|
14513
|
+
*/
|
|
14514
|
+
id: string;
|
|
14515
|
+
event: 'sequence.enrolled' | 'sequence.exited';
|
|
14516
|
+
timestamp: string;
|
|
14517
|
+
sequence: {
|
|
14518
|
+
id?: string;
|
|
14519
|
+
name?: string;
|
|
14520
|
+
};
|
|
14521
|
+
contact: {
|
|
14522
|
+
/**
|
|
14523
|
+
* Zernio contact id.
|
|
14524
|
+
*/
|
|
14525
|
+
id?: string;
|
|
14526
|
+
};
|
|
14527
|
+
enrollment: {
|
|
14528
|
+
id?: string;
|
|
14529
|
+
};
|
|
14530
|
+
/**
|
|
14531
|
+
* sequence.exited only. completed: the last step was sent; replied: the contact replied and the sequence exits on reply; manual: unenrolled through the API; failed: the step kept failing to send; unsubscribed: the contact opted out.
|
|
14532
|
+
*/
|
|
14533
|
+
exitReason?: 'completed' | 'replied' | 'manual' | 'failed' | 'unsubscribed';
|
|
14534
|
+
};
|
|
14535
|
+
|
|
14536
|
+
export type event34 = 'sequence.enrolled' | 'sequence.exited';
|
|
14537
|
+
|
|
14538
|
+
/**
|
|
14539
|
+
* sequence.exited only. completed: the last step was sent; replied: the contact replied and the sequence exits on reply; manual: unenrolled through the API; failed: the step kept failing to send; unsubscribed: the contact opted out.
|
|
14540
|
+
*/
|
|
14541
|
+
export type exitReason = 'completed' | 'replied' | 'manual' | 'failed' | 'unsubscribed';
|
|
14166
14542
|
|
|
14167
14543
|
/**
|
|
14168
14544
|
* Webhook payload for test deliveries
|
|
@@ -14183,7 +14559,7 @@ export type WebhookPayloadTest = {
|
|
|
14183
14559
|
timestamp: string;
|
|
14184
14560
|
};
|
|
14185
14561
|
|
|
14186
|
-
export type
|
|
14562
|
+
export type event35 = 'webhook.test';
|
|
14187
14563
|
|
|
14188
14564
|
/**
|
|
14189
14565
|
* Webhook payload for `whatsapp.account.alert_received`, forwarded from Meta's
|
|
@@ -14230,7 +14606,7 @@ export type WebhookPayloadWhatsAppAccountAlertReceived = {
|
|
|
14230
14606
|
timestamp: string;
|
|
14231
14607
|
};
|
|
14232
14608
|
|
|
14233
|
-
export type
|
|
14609
|
+
export type event36 = 'whatsapp.account.alert_received';
|
|
14234
14610
|
|
|
14235
14611
|
export type platform16 = 'whatsapp';
|
|
14236
14612
|
|
|
@@ -14281,12 +14657,12 @@ export type WebhookPayloadWhatsAppAccountNameStatusUpdated = {
|
|
|
14281
14657
|
timestamp: string;
|
|
14282
14658
|
};
|
|
14283
14659
|
|
|
14284
|
-
export type
|
|
14660
|
+
export type event37 = 'whatsapp.account.name_status_updated';
|
|
14285
14661
|
|
|
14286
14662
|
/**
|
|
14287
14663
|
* Normalized from Meta's `decision` (REJECTED -> DECLINED, DEFERRED -> PENDING_REVIEW; the review is still open on DEFERRED, not a rejection).
|
|
14288
14664
|
*/
|
|
14289
|
-
export type
|
|
14665
|
+
export type status35 = 'APPROVED' | 'DECLINED' | 'PENDING_REVIEW';
|
|
14290
14666
|
|
|
14291
14667
|
/**
|
|
14292
14668
|
* Webhook payload for `whatsapp.account.quality_updated`. Fired when a connected
|
|
@@ -14334,12 +14710,12 @@ export type WebhookPayloadWhatsAppAccountQualityUpdated = {
|
|
|
14334
14710
|
timestamp: string;
|
|
14335
14711
|
};
|
|
14336
14712
|
|
|
14337
|
-
export type
|
|
14713
|
+
export type event38 = 'whatsapp.account.quality_updated';
|
|
14338
14714
|
|
|
14339
14715
|
/**
|
|
14340
14716
|
* The Meta webhook field that reported the change.
|
|
14341
14717
|
*/
|
|
14342
|
-
export type
|
|
14718
|
+
export type source6 = 'phone_number_quality_update' | 'business_capability_update';
|
|
14343
14719
|
|
|
14344
14720
|
/**
|
|
14345
14721
|
* Webhook payload for `whatsapp.account.status_updated`. Fired when Meta restricts,
|
|
@@ -14405,12 +14781,12 @@ export type WebhookPayloadWhatsAppAccountStatusUpdated = {
|
|
|
14405
14781
|
timestamp: string;
|
|
14406
14782
|
};
|
|
14407
14783
|
|
|
14408
|
-
export type
|
|
14784
|
+
export type event39 = 'whatsapp.account.status_updated';
|
|
14409
14785
|
|
|
14410
14786
|
/**
|
|
14411
14787
|
* `active` only on a reinstatement (DISABLED_UPDATE with ban state REINSTATE).
|
|
14412
14788
|
*/
|
|
14413
|
-
export type
|
|
14789
|
+
export type status36 = 'restricted' | 'active';
|
|
14414
14790
|
|
|
14415
14791
|
/**
|
|
14416
14792
|
* Webhook payload for the `whatsapp.contact.identity_changed` event. Fired when
|
|
@@ -14457,7 +14833,7 @@ export type WebhookPayloadWhatsAppContactIdentityChanged = {
|
|
|
14457
14833
|
timestamp: string;
|
|
14458
14834
|
};
|
|
14459
14835
|
|
|
14460
|
-
export type
|
|
14836
|
+
export type event40 = 'whatsapp.contact.identity_changed';
|
|
14461
14837
|
|
|
14462
14838
|
/**
|
|
14463
14839
|
* Which Meta signal reported the change. `user_changed_number`: new phone number. `user_changed_user_id` and `user_id_update`: new BSUID.
|
|
@@ -14526,7 +14902,7 @@ export type WebhookPayloadWhatsAppTemplateCategoryUpdated = {
|
|
|
14526
14902
|
timestamp: string;
|
|
14527
14903
|
};
|
|
14528
14904
|
|
|
14529
|
-
export type
|
|
14905
|
+
export type event41 = 'whatsapp.template.category_updated';
|
|
14530
14906
|
|
|
14531
14907
|
/**
|
|
14532
14908
|
* `scheduled` is Meta's 24h advance notice of an upcoming
|
|
@@ -14603,7 +14979,7 @@ export type WebhookPayloadWhatsAppTemplateStatusUpdated = {
|
|
|
14603
14979
|
timestamp: string;
|
|
14604
14980
|
};
|
|
14605
14981
|
|
|
14606
|
-
export type
|
|
14982
|
+
export type event42 = 'whatsapp.template.status_updated';
|
|
14607
14983
|
|
|
14608
14984
|
/**
|
|
14609
14985
|
* New status. Forwarded verbatim from Meta's `event` field.
|
|
@@ -14611,7 +14987,66 @@ export type event39 = 'whatsapp.template.status_updated';
|
|
|
14611
14987
|
* request before the template is actually removed.
|
|
14612
14988
|
*
|
|
14613
14989
|
*/
|
|
14614
|
-
export type
|
|
14990
|
+
export type status37 = 'APPROVED' | 'REJECTED' | 'PENDING' | 'PAUSED' | 'DISABLED' | 'IN_APPEAL' | 'PENDING_DELETION';
|
|
14991
|
+
|
|
14992
|
+
export type WebhookPayloadWorkflowRun = {
|
|
14993
|
+
/**
|
|
14994
|
+
* Event id, the dedupe key.
|
|
14995
|
+
*/
|
|
14996
|
+
id: string;
|
|
14997
|
+
event: 'workflow.run.started' | 'workflow.run.completed' | 'workflow.run.failed';
|
|
14998
|
+
timestamp: string;
|
|
14999
|
+
workflow: {
|
|
15000
|
+
id?: string;
|
|
15001
|
+
/**
|
|
15002
|
+
* Null when the workflow was deleted while the run was live.
|
|
15003
|
+
*/
|
|
15004
|
+
name?: (string) | null;
|
|
15005
|
+
};
|
|
15006
|
+
execution: {
|
|
15007
|
+
/**
|
|
15008
|
+
* Workflow run (execution) id.
|
|
15009
|
+
*/
|
|
15010
|
+
id?: string;
|
|
15011
|
+
/**
|
|
15012
|
+
* running on workflow.run.started; completed or exited (ended on purpose before the last node, e.g. a handoff) on workflow.run.completed; failed on workflow.run.failed.
|
|
15013
|
+
*/
|
|
15014
|
+
status?: 'running' | 'waiting' | 'completed' | 'exited' | 'failed';
|
|
15015
|
+
};
|
|
15016
|
+
/**
|
|
15017
|
+
* Null while a comment-triggered run has not sent the private reply that opens its conversation.
|
|
15018
|
+
*/
|
|
15019
|
+
conversation: {
|
|
15020
|
+
id?: string;
|
|
15021
|
+
} | null;
|
|
15022
|
+
contact: {
|
|
15023
|
+
/**
|
|
15024
|
+
* Zernio contact id.
|
|
15025
|
+
*/
|
|
15026
|
+
id?: string;
|
|
15027
|
+
} | null;
|
|
15028
|
+
trigger: {
|
|
15029
|
+
/**
|
|
15030
|
+
* The trigger node type, e.g. inbound_message (the default when the node sets none). Null when the workflow was deleted while the run was live.
|
|
15031
|
+
*/
|
|
15032
|
+
type?: (string) | null;
|
|
15033
|
+
/**
|
|
15034
|
+
* The inbound message that started the run, when there was one.
|
|
15035
|
+
*/
|
|
15036
|
+
text?: string;
|
|
15037
|
+
};
|
|
15038
|
+
/**
|
|
15039
|
+
* workflow.run.failed only: which node failed and why.
|
|
15040
|
+
*/
|
|
15041
|
+
error?: string;
|
|
15042
|
+
};
|
|
15043
|
+
|
|
15044
|
+
export type event43 = 'workflow.run.started' | 'workflow.run.completed' | 'workflow.run.failed';
|
|
15045
|
+
|
|
15046
|
+
/**
|
|
15047
|
+
* running on workflow.run.started; completed or exited (ended on purpose before the last node, e.g. a handoff) on workflow.run.completed; failed on workflow.run.failed.
|
|
15048
|
+
*/
|
|
15049
|
+
export type status38 = 'running' | 'waiting' | 'completed' | 'exited' | 'failed';
|
|
14615
15050
|
|
|
14616
15051
|
/**
|
|
14617
15052
|
* WhatsApp only. Meta's `conversation` object from the status webhook (the billing
|
|
@@ -14700,6 +15135,24 @@ export type WhatsAppContactIdentity = {
|
|
|
14700
15135
|
whatsappUsername: (string) | null;
|
|
14701
15136
|
};
|
|
14702
15137
|
|
|
15138
|
+
export type WhatsAppConversationalAutomation = {
|
|
15139
|
+
/**
|
|
15140
|
+
* When true, Meta sends a `request_welcome` event the first time a person opens a chat with the number.
|
|
15141
|
+
*/
|
|
15142
|
+
enable_welcome_message?: boolean;
|
|
15143
|
+
/**
|
|
15144
|
+
* Ice breakers shown to a person opening a chat. Tapping one sends its text as a normal message.
|
|
15145
|
+
*/
|
|
15146
|
+
prompts?: Array<(string)>;
|
|
15147
|
+
/**
|
|
15148
|
+
* Slash commands shown when a person types `/`. Names are unique, letters, digits and underscores, without the slash.
|
|
15149
|
+
*/
|
|
15150
|
+
commands?: Array<{
|
|
15151
|
+
command_name: string;
|
|
15152
|
+
command_description: string;
|
|
15153
|
+
}>;
|
|
15154
|
+
};
|
|
15155
|
+
|
|
14703
15156
|
export type WhatsAppFooterComponent = {
|
|
14704
15157
|
type: 'footer';
|
|
14705
15158
|
/**
|
|
@@ -14858,7 +15311,7 @@ export type WhatsAppTemplateButton = {
|
|
|
14858
15311
|
navigate_screen?: string;
|
|
14859
15312
|
};
|
|
14860
15313
|
|
|
14861
|
-
export type
|
|
15314
|
+
export type type18 = 'quick_reply' | 'url' | 'phone_number' | 'otp' | 'copy_code' | 'flow' | 'mpm' | 'catalog';
|
|
14862
15315
|
|
|
14863
15316
|
/**
|
|
14864
15317
|
* Required when type is otp
|
|
@@ -14900,7 +15353,7 @@ export type WhatsAppTemplateLookupError = {
|
|
|
14900
15353
|
};
|
|
14901
15354
|
};
|
|
14902
15355
|
|
|
14903
|
-
export type
|
|
15356
|
+
export type type19 = 'platform_error';
|
|
14904
15357
|
|
|
14905
15358
|
export type code = 'platform_api_error';
|
|
14906
15359
|
|
|
@@ -14982,7 +15435,7 @@ export type WorkflowExecutionEvent = {
|
|
|
14982
15435
|
|
|
14983
15436
|
export type action2 = 'execution_started' | 'execution_completed' | 'execution_exited' | 'execution_paused' | 'execution_resumed' | 'node_started' | 'node_completed' | 'node_failed' | 'node_skipped';
|
|
14984
15437
|
|
|
14985
|
-
export type
|
|
15438
|
+
export type status39 = 'success' | 'failed' | 'pending';
|
|
14986
15439
|
|
|
14987
15440
|
/**
|
|
14988
15441
|
* A node in a workflow graph. `config` shape depends on `type`.
|
|
@@ -15004,13 +15457,16 @@ export type WorkflowNode = {
|
|
|
15004
15457
|
/**
|
|
15005
15458
|
* Type-specific settings. All string fields support `{{variable}}` interpolation against the run's variable bag (resolved at execution time).
|
|
15006
15459
|
*
|
|
15007
|
-
* **trigger**: `{ triggerType: inbound_message|api_call|whatsapp_event, keywords:[string], matchType: any|contains|exact|regex, onlyFirstMessage:boolean, eventType: message_sent|message_delivered|message_read|message_failed|reaction }`. Default `triggerType` is `inbound_message` for legacy nodes. `
|
|
15460
|
+
* **trigger**: `{ triggerType: inbound_message|api_call|whatsapp_event|referral|story_mention|comment|reaction, keywords:[string], matchType: any|contains|exact|regex, onlyFirstMessage:boolean, eventType: message_sent|message_delivered|message_read|message_failed|reaction, referral:{ ref, matchType: exact|prefix|any }, reaction:{ emojis:[string] }, comment:{ keywords:[string], matchType: any|contains|exact|regex, platformPostId }, cooldownHours:int (1-720) }`. Default `triggerType` is `inbound_message` for legacy nodes. A workflow starts only on events of its own trigger type: `inbound_message` on a message, `referral` on an ig.me / m.me / click-to-message ad referral (standalone, or the first message carrying one; the two are deduplicated per conversation within 60 seconds), `story_mention` on an Instagram story mention, `reaction` on a reaction (Instagram, Facebook, WhatsApp, Telegram groups), `comment` on an Instagram or Facebook comment (the run starts with no conversation and its first `send_message`, which must be text (with optional buttons or quick replies) or cards and must follow the trigger directly (checked on save; Instagram delivers only plain text to commenters who do not follow the account), is sent as a private reply to the comment; the run then continues in the conversation that reply opens; when an active comment automation's keywords match the comment, the automation answers and the workflow does not start), `whatsapp_event` on a WhatsApp status of a message we sent (filtered by `eventType`), `api_call` only via `POST /v1/workflows/{workflowId}/trigger`. `referral.matchType` defaults to `any`. `cooldownHours` (inbound_message, referral, story_mention, reaction and whatsapp_event) stops the same contact from starting the workflow again inside the window. A `whatsapp_event` workflow never starts on the status of a message a workflow, sequence or comment automation sent. A redelivered platform event never starts the same workflow twice.
|
|
15008
15461
|
*
|
|
15009
|
-
* **
|
|
15462
|
+
* **Variables** available from the start of every run (absent values are `''`): `lastMessage`, `inboundText`, `triggerText`, `conversationId`, `contact.name`, `contact.phone`, `contact.handle`, `contact.tags` (array), `contact.fields` (the contact's custom fields object), `contact.lastInteractionAt` (ISO date), `contact.lastInteractionHoursAgo` (number), `contact.isFollower` (Instagram, from the stored profile: true, false or `''` when unknown), `referral.ref`, `referral.source`, `referral.type`, `referral.adId`, `postback.payload`, `postback.title`, `quickReply.payload`, `quickReply.title`, `story.id`, `story.url`, `comment.id`, `comment.text`, `comment.platformPostId`, `reaction.emoji`, `reaction.action` (added|removed). `api_call` runs also get the request's `variables`, merged over these. An array or object interpolated into text renders as JSON.
|
|
15010
15463
|
*
|
|
15011
|
-
* **
|
|
15464
|
+
* **send_message**: `{ messageType: text|template|media|interactive|cards, text, template, media:{mediaType:image|video|audio|document, url,caption}, interactive, buttons, quickReplies, messageTag }`. `template` is `{name,language,variableMapping}` for `messageType: template` and `{ type: generic, elements:[{ title, subtitle, imageUrl, buttons }] }` (1 to 10 cards) for `messageType: cards`. `template` and `interactive` are WhatsApp-only. `interactive.type` is inferred from the payload shape when omitted; payloads with neither `type` nor an inferable shape are rejected.
|
|
15465
|
+
* Facebook and Instagram only (rejected with a 400 on other platforms; WhatsApp keeps `interactive`): `cards`, plus `buttons` on `text` (cards carry their own buttons) and `quickReplies` / `messageTag` on `text`, `media` and `cards`. `media` takes no `buttons` (a 400 at save). `buttons:[{ type: url|postback|phone, title, url, payload, phone, workflowId }]` (1 to 3, text only and the text then 640 characters at most, sent as Meta's button_template, `phone` Facebook-only, not inside cards), `quickReplies:[{ title, payload, imageUrl, workflowId }]` (1 to 13, not combined with `buttons`) and `messageTag: HUMAN_AGENT|CONFIRMED_EVENT_UPDATE|POST_PURCHASE_UPDATE|ACCOUNT_UPDATE` (Instagram accepts only `HUMAN_AGENT`). Titles are capped at 20 characters (80 for card titles and subtitles). A postback button or quick reply with no `payload` gets `zernio:workflow:<this workflow id>`, so a tap answers this workflow's pending `wait_for_reply` or restarts it; with `workflowId` (a 24-hex workflow id, not combined with `payload`) the tap starts that workflow instead.
|
|
15012
15466
|
*
|
|
15013
|
-
* **
|
|
15467
|
+
* **wait_for_reply**: `{ timeoutMinutes:int (max 43200), saveAs:string }`. Resume via the `'reply'` edge on inbound, or `'timeout'` edge after `timeoutMinutes` of silence. On Facebook and Instagram a button tap sets `{{postback.payload}}` / `{{postback.title}}` and a quick reply tap sets `{{quickReply.payload}}` / `{{quickReply.title}}`; each reply clears the previous tap.
|
|
15468
|
+
*
|
|
15469
|
+
* **condition**: `{ rules:[{ id, variable, operator: equals|not_equals|contains|not_contains|starts_with|ends_with|exists|not_exists|matches|greater_than|less_than|greater_or_equal|less_or_equal|before|after|has_tag|not_has_tag|is_true|is_false, value }] }`. First matching rule takes its `id` as the sourceHandle; otherwise `'default'`. Text operators compare case-insensitively. `greater_than`, `less_than`, `greater_or_equal` and `less_or_equal` compare numbers (a non-numeric side is false); `before` and `after` compare ISO dates; `has_tag` and `not_has_tag` test whether an array variable (such as `contact.tags`) contains `value`; `is_true` and `is_false` take no value.
|
|
15014
15470
|
*
|
|
15015
15471
|
* **set_variable**: `{ assignments:[{ name, value }] }`. Run-scoped (lives only for this execution; use `set_field` for persistent values).
|
|
15016
15472
|
*
|
|
@@ -15059,7 +15515,7 @@ export type WorkflowNode = {
|
|
|
15059
15515
|
* integrations (webhook, ai, handoff, start_call).
|
|
15060
15516
|
*
|
|
15061
15517
|
*/
|
|
15062
|
-
export type
|
|
15518
|
+
export type type20 = 'trigger' | 'send_message' | 'wait_for_reply' | 'condition' | 'set_variable' | 'delay' | 'webhook' | 'ai' | 'handoff' | 'start_call' | 'a_b_split' | 'set_field' | 'enroll_sequence' | 'add_tag' | 'remove_tag' | 'end';
|
|
15063
15519
|
|
|
15064
15520
|
/**
|
|
15065
15521
|
* A single X API operation with its per-call price and the Zernio platform methods that trigger it.
|
|
@@ -15179,7 +15635,7 @@ export type XArticle = {
|
|
|
15179
15635
|
/**
|
|
15180
15636
|
* Publish creates an X Article draft and then publishes it. Draft stops after draft creation and returns the X draft ID without a public URL.
|
|
15181
15637
|
*/
|
|
15182
|
-
export type
|
|
15638
|
+
export type mode2 = 'publish' | 'draft';
|
|
15183
15639
|
|
|
15184
15640
|
export type XArticleBlock = {
|
|
15185
15641
|
type: 'unstyled' | 'header-one' | 'header-two' | 'header-three' | 'unordered-list-item' | 'ordered-list-item' | 'blockquote' | 'atomic';
|
|
@@ -15195,7 +15651,7 @@ export type XArticleBlock = {
|
|
|
15195
15651
|
entity_ranges?: Array<XArticleEntityRange>;
|
|
15196
15652
|
};
|
|
15197
15653
|
|
|
15198
|
-
export type
|
|
15654
|
+
export type type21 = 'unstyled' | 'header-one' | 'header-two' | 'header-three' | 'unordered-list-item' | 'ordered-list-item' | 'blockquote' | 'atomic';
|
|
15199
15655
|
|
|
15200
15656
|
/**
|
|
15201
15657
|
* X's snake_case content-state shape. Standard DraftJS camelCase fields such as entityMap, inlineStyleRanges, and entityRanges are rejected.
|
|
@@ -15274,7 +15730,7 @@ export type XArticleEntity = {
|
|
|
15274
15730
|
|
|
15275
15731
|
export type mutability = 'immutable' | 'mutable' | 'segmented';
|
|
15276
15732
|
|
|
15277
|
-
export type
|
|
15733
|
+
export type type22 = 'divider' | 'latex';
|
|
15278
15734
|
|
|
15279
15735
|
/**
|
|
15280
15736
|
* The referenced entity must exist, and offset plus length must not exceed the containing block's text length.
|
|
@@ -18557,7 +19013,7 @@ export type GetAllAccountsHealthData = {
|
|
|
18557
19013
|
/**
|
|
18558
19014
|
* Filter by platform
|
|
18559
19015
|
*/
|
|
18560
|
-
platform?: 'facebook' | 'instagram' | 'linkedin' | 'twitter' | 'tiktok' | 'youtube' | 'threads' | 'pinterest' | 'reddit' | 'bluesky' | 'googlebusiness' | 'telegram' | 'snapchat' | 'discord' | 'slack' | 'whatsapp' | 'shopify' | 'wordpress' | 'linkedinads' | 'metaads' | 'pinterestads' | 'tiktokads' | 'xads' | 'googleads' | 'openaiads';
|
|
19016
|
+
platform?: 'facebook' | 'instagram' | 'linkedin' | 'twitter' | 'tiktok' | 'youtube' | 'threads' | 'pinterest' | 'reddit' | 'bluesky' | 'googlebusiness' | 'telegram' | 'snapchat' | 'discord' | 'slack' | 'whatsapp' | 'shopify' | 'wordpress' | 'linkedinads' | 'metaads' | 'pinterestads' | 'tiktokads' | 'xads' | 'googleads' | 'openaiads' | 'whopads';
|
|
18561
19017
|
/**
|
|
18562
19018
|
* Filter by profile ID
|
|
18563
19019
|
*/
|
|
@@ -22560,6 +23016,97 @@ export type ConnectOpenAiAdsCredentialsError = (ErrorResponse | unknown | {
|
|
|
22560
23016
|
};
|
|
22561
23017
|
});
|
|
22562
23018
|
|
|
23019
|
+
export type ConnectWhopAdsCredentialsData = {
|
|
23020
|
+
body: {
|
|
23021
|
+
/**
|
|
23022
|
+
* Account API key from the Whop dashboard.
|
|
23023
|
+
*/
|
|
23024
|
+
apiKey: string;
|
|
23025
|
+
/**
|
|
23026
|
+
* Your Zernio profile ID
|
|
23027
|
+
*/
|
|
23028
|
+
profileId: string;
|
|
23029
|
+
/**
|
|
23030
|
+
* Optional state passthrough for the connect flow.
|
|
23031
|
+
*/
|
|
23032
|
+
state?: string;
|
|
23033
|
+
/**
|
|
23034
|
+
* Optional URL to redirect to after successful connection, echoed back as redirectUrl.
|
|
23035
|
+
*/
|
|
23036
|
+
redirect_url?: string;
|
|
23037
|
+
};
|
|
23038
|
+
};
|
|
23039
|
+
|
|
23040
|
+
export type ConnectWhopAdsCredentialsResponse = ({
|
|
23041
|
+
/**
|
|
23042
|
+
* The Zernio account id (platform `whopads`) to use as `{accountId}` on the tracking-tags routes.
|
|
23043
|
+
*/
|
|
23044
|
+
accountId?: string;
|
|
23045
|
+
/**
|
|
23046
|
+
* The Whop account id (`biz_...`), which is also the tracking tag id.
|
|
23047
|
+
*/
|
|
23048
|
+
whopAccountId?: string;
|
|
23049
|
+
accountName?: string;
|
|
23050
|
+
redirectUrl?: string;
|
|
23051
|
+
});
|
|
23052
|
+
|
|
23053
|
+
export type ConnectWhopAdsCredentialsError = (ErrorResponse | unknown | {
|
|
23054
|
+
/**
|
|
23055
|
+
* Human-readable error message suitable for end-user display.
|
|
23056
|
+
*/
|
|
23057
|
+
error: string;
|
|
23058
|
+
/**
|
|
23059
|
+
* Machine-readable error code. Stable across versions.
|
|
23060
|
+
*/
|
|
23061
|
+
code: 'PAYMENT_REQUIRED';
|
|
23062
|
+
/**
|
|
23063
|
+
* Discriminator for which gate fired.
|
|
23064
|
+
*/
|
|
23065
|
+
reason: 'free_tier_exceeded' | 'twitter_passthrough' | 'enterprise_required' | 'card_verification_required';
|
|
23066
|
+
/**
|
|
23067
|
+
* Link to the relevant documentation page.
|
|
23068
|
+
*/
|
|
23069
|
+
documentation_url?: string;
|
|
23070
|
+
/**
|
|
23071
|
+
* Deep-link to send the end-user to. For
|
|
23072
|
+
* `free_tier_exceeded` and `twitter_passthrough` this opens
|
|
23073
|
+
* the add-payment-method drawer on the Zernio billing page.
|
|
23074
|
+
* For `enterprise_required` this is the Zernio enterprise
|
|
23075
|
+
* contact page.
|
|
23076
|
+
*
|
|
23077
|
+
*/
|
|
23078
|
+
dashboard_url?: string;
|
|
23079
|
+
/**
|
|
23080
|
+
* Structured context for SDK clients that want to render their own UX. Keys vary by `reason`.
|
|
23081
|
+
*/
|
|
23082
|
+
details?: {
|
|
23083
|
+
/**
|
|
23084
|
+
* How many accounts the free tier allows. Only set when reason=free_tier_exceeded.
|
|
23085
|
+
*/
|
|
23086
|
+
free_tier_account_limit?: number;
|
|
23087
|
+
/**
|
|
23088
|
+
* How many accounts the team currently has connected. Set when reason=free_tier_exceeded or reason=enterprise_required.
|
|
23089
|
+
*/
|
|
23090
|
+
current_account_count?: number;
|
|
23091
|
+
/**
|
|
23092
|
+
* Whether the team currently has a card on file in Stripe. Set when reason=free_tier_exceeded or reason=twitter_passthrough.
|
|
23093
|
+
*/
|
|
23094
|
+
has_payment_method?: boolean;
|
|
23095
|
+
/**
|
|
23096
|
+
* One-time card verification charge in USD cents, credited to usage. Only set when reason=card_verification_required.
|
|
23097
|
+
*/
|
|
23098
|
+
verification_amount_cents?: number;
|
|
23099
|
+
/**
|
|
23100
|
+
* The negotiated connected-account cap from the
|
|
23101
|
+
* team's enterprise contract. Self-service teams
|
|
23102
|
+
* have no cap and never receive this reason. Only
|
|
23103
|
+
* set when reason=enterprise_required.
|
|
23104
|
+
*
|
|
23105
|
+
*/
|
|
23106
|
+
effective_account_limit?: number;
|
|
23107
|
+
};
|
|
23108
|
+
});
|
|
23109
|
+
|
|
22563
23110
|
export type ConnectWhatsAppCredentialsData = {
|
|
22564
23111
|
body: {
|
|
22565
23112
|
/**
|
|
@@ -25457,7 +26004,7 @@ export type CreateWebhookSettingsData = {
|
|
|
25457
26004
|
/**
|
|
25458
26005
|
* Events to subscribe to (at least one required)
|
|
25459
26006
|
*/
|
|
25460
|
-
events: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.platform.deleted' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'account.ads.sync_failed' | 'account.ads.sync_recovered' | 'analytics.synced' | 'message.received' | 'conversation.started' | 'conversation.control_changed' | 'call.received' | 'call.ended' | 'call.failed' | 'call.permission_request' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.played' | 'message.failed' | 'reaction.received' | 'referral.received' | 'comment.received' | 'review.new' | 'review.updated' | 'lead.received' | 'ad.status_changed' | 'ad.video.processed' | 'whatsapp.template.status_updated' | 'whatsapp.template.category_updated' | 'whatsapp.account.name_status_updated' | 'whatsapp.account.quality_updated' | 'whatsapp.account.status_updated' | 'whatsapp.account.alert_received' | 'whatsapp.contact.identity_changed' | 'whatsapp.automatic_event' | 'whatsapp.number.activated' | 'whatsapp.number.declined' | 'whatsapp.number.action_required' | 'whatsapp.number.verification_required' | 'whatsapp.number.suspended' | 'whatsapp.number.reactivated' | 'whatsapp.number.released' | 'whatsapp.number.kyc_submitted' | 'phone_number.stock_available' | 'verification.approved' | 'verification.failed' | 'api.changelog.published' | 'sms.registration.action_required' | 'sms.registration.status_updated' | 'branded_calling.identity.status_updated' | 'branded_calling.identity.action_required' | 'branded_calling.number.status_updated' | 'rcs.agent.status_updated' | 'commerce.product.created' | 'commerce.product.updated' | 'commerce.product.deleted')>;
|
|
26007
|
+
events: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.platform.deleted' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'account.ads.sync_failed' | 'account.ads.sync_recovered' | 'analytics.synced' | 'message.received' | 'conversation.started' | 'conversation.control_changed' | 'call.received' | 'call.ended' | 'call.failed' | 'call.permission_request' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.played' | 'message.failed' | 'reaction.received' | 'referral.received' | 'comment.received' | 'review.new' | 'review.updated' | 'lead.received' | 'ad.status_changed' | 'ad.video.processed' | 'whatsapp.template.status_updated' | 'whatsapp.template.category_updated' | 'whatsapp.account.name_status_updated' | 'whatsapp.account.quality_updated' | 'whatsapp.account.status_updated' | 'whatsapp.account.alert_received' | 'whatsapp.contact.identity_changed' | 'whatsapp.automatic_event' | 'whatsapp.number.activated' | 'whatsapp.number.declined' | 'whatsapp.number.action_required' | 'whatsapp.number.verification_required' | 'whatsapp.number.suspended' | 'whatsapp.number.reactivated' | 'whatsapp.number.released' | 'whatsapp.number.kyc_submitted' | 'phone_number.stock_available' | 'verification.approved' | 'verification.failed' | 'api.changelog.published' | 'sms.registration.action_required' | 'sms.registration.status_updated' | 'branded_calling.identity.status_updated' | 'branded_calling.identity.action_required' | 'branded_calling.number.status_updated' | 'rcs.agent.status_updated' | 'commerce.product.created' | 'commerce.product.updated' | 'commerce.product.deleted' | 'contact.tag_added' | 'contact.tag_removed' | 'contact.field_changed' | 'sequence.enrolled' | 'sequence.exited' | 'workflow.run.started' | 'workflow.run.completed' | 'workflow.run.failed')>;
|
|
25461
26008
|
/**
|
|
25462
26009
|
* Enable or disable webhook delivery. Defaults to `true` when omitted.
|
|
25463
26010
|
*/
|
|
@@ -25523,7 +26070,7 @@ export type UpdateWebhookSettingsData = {
|
|
|
25523
26070
|
/**
|
|
25524
26071
|
* Events to subscribe to. Must contain at least one event if provided.
|
|
25525
26072
|
*/
|
|
25526
|
-
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.platform.deleted' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'account.ads.sync_failed' | 'account.ads.sync_recovered' | 'analytics.synced' | 'message.received' | 'conversation.started' | 'conversation.control_changed' | 'call.received' | 'call.ended' | 'call.failed' | 'call.permission_request' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.played' | 'message.failed' | 'reaction.received' | 'referral.received' | 'comment.received' | 'review.new' | 'review.updated' | 'lead.received' | 'ad.status_changed' | 'ad.video.processed' | 'whatsapp.template.status_updated' | 'whatsapp.template.category_updated' | 'whatsapp.account.name_status_updated' | 'whatsapp.account.quality_updated' | 'whatsapp.account.status_updated' | 'whatsapp.account.alert_received' | 'whatsapp.contact.identity_changed' | 'whatsapp.automatic_event' | 'whatsapp.number.activated' | 'whatsapp.number.declined' | 'whatsapp.number.action_required' | 'whatsapp.number.verification_required' | 'whatsapp.number.suspended' | 'whatsapp.number.reactivated' | 'whatsapp.number.released' | 'whatsapp.number.kyc_submitted' | 'phone_number.stock_available' | 'verification.approved' | 'verification.failed' | 'api.changelog.published' | 'sms.registration.action_required' | 'sms.registration.status_updated' | 'branded_calling.identity.status_updated' | 'branded_calling.identity.action_required' | 'branded_calling.number.status_updated' | 'rcs.agent.status_updated' | 'commerce.product.created' | 'commerce.product.updated' | 'commerce.product.deleted')>;
|
|
26073
|
+
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.platform.deleted' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'account.ads.sync_failed' | 'account.ads.sync_recovered' | 'analytics.synced' | 'message.received' | 'conversation.started' | 'conversation.control_changed' | 'call.received' | 'call.ended' | 'call.failed' | 'call.permission_request' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.played' | 'message.failed' | 'reaction.received' | 'referral.received' | 'comment.received' | 'review.new' | 'review.updated' | 'lead.received' | 'ad.status_changed' | 'ad.video.processed' | 'whatsapp.template.status_updated' | 'whatsapp.template.category_updated' | 'whatsapp.account.name_status_updated' | 'whatsapp.account.quality_updated' | 'whatsapp.account.status_updated' | 'whatsapp.account.alert_received' | 'whatsapp.contact.identity_changed' | 'whatsapp.automatic_event' | 'whatsapp.number.activated' | 'whatsapp.number.declined' | 'whatsapp.number.action_required' | 'whatsapp.number.verification_required' | 'whatsapp.number.suspended' | 'whatsapp.number.reactivated' | 'whatsapp.number.released' | 'whatsapp.number.kyc_submitted' | 'phone_number.stock_available' | 'verification.approved' | 'verification.failed' | 'api.changelog.published' | 'sms.registration.action_required' | 'sms.registration.status_updated' | 'branded_calling.identity.status_updated' | 'branded_calling.identity.action_required' | 'branded_calling.number.status_updated' | 'rcs.agent.status_updated' | 'commerce.product.created' | 'commerce.product.updated' | 'commerce.product.deleted' | 'contact.tag_added' | 'contact.tag_removed' | 'contact.field_changed' | 'sequence.enrolled' | 'sequence.exited' | 'workflow.run.started' | 'workflow.run.completed' | 'workflow.run.failed')>;
|
|
25527
26074
|
/**
|
|
25528
26075
|
* Enable or disable webhook delivery
|
|
25529
26076
|
*/
|
|
@@ -25862,6 +26409,10 @@ export type ListInboxConversationsData = {
|
|
|
25862
26409
|
* Pagination cursor for next page
|
|
25863
26410
|
*/
|
|
25864
26411
|
cursor?: string;
|
|
26412
|
+
/**
|
|
26413
|
+
* requests lists Facebook and Instagram Message Requests (threads from people the account has not accepted) live from Meta, first page only, each item with `folder: requests`. Meta has no accept call: replying moves a thread to the inbox, which is what POST /v1/inbox/conversations/{conversationId}/accept does. When Meta will not list the folder for the one account asked (`accountId`), the call answers 400 PLATFORM_LIMITATION; across several accounts the refusal is reported per account in meta.failedAccounts.
|
|
26414
|
+
*/
|
|
26415
|
+
folder?: 'inbox' | 'requests';
|
|
25865
26416
|
/**
|
|
25866
26417
|
* Maximum number of conversations to return
|
|
25867
26418
|
*/
|
|
@@ -25917,9 +26468,13 @@ export type ListInboxConversationsResponse = ({
|
|
|
25917
26468
|
*/
|
|
25918
26469
|
unreadCount?: (number) | null;
|
|
25919
26470
|
/**
|
|
25920
|
-
*
|
|
26471
|
+
* Present once a handover has touched the thread (WhatsApp, Facebook, Instagram). ai_agent: Meta Business Agent answers (WhatsApp) and new inbound arrive flagged metadata.standby; app: you hold control; other: another app does (a WhatsApp partner, or a Messenger / Instagram receiver such as Page Inbox). Change it with POST /v1/inbox/conversations/{conversationId}/thread-control.
|
|
25921
26472
|
*/
|
|
25922
26473
|
threadControl?: 'app' | 'ai_agent' | 'other';
|
|
26474
|
+
/**
|
|
26475
|
+
* Present only on items listed with folder=requests: a Message Request the account has not accepted yet.
|
|
26476
|
+
*/
|
|
26477
|
+
folder?: 'requests';
|
|
25923
26478
|
/**
|
|
25924
26479
|
* iMessage only, true for a group thread. Manage it through the /v1/imessage/groups/{conversationId} endpoints.
|
|
25925
26480
|
*/
|
|
@@ -26869,6 +27424,9 @@ export type SendInboxMessageData = {
|
|
|
26869
27424
|
* Instagram / Facebook: also mutually exclusive with `template`.
|
|
26870
27425
|
* A Meta message carries one body shape, so sending both is a 400
|
|
26871
27426
|
* rather than a silent drop of the buttons.
|
|
27427
|
+
* The buttons and `message` render as Meta's button_template (one
|
|
27428
|
+
* bubble with the text and the buttons below it), so `message` must
|
|
27429
|
+
* be 640 characters or less when buttons are attached (400 otherwise).
|
|
26872
27430
|
*
|
|
26873
27431
|
* WhatsApp: buttons always render as interactive reply buttons.
|
|
26874
27432
|
* Only `title` and `payload` are used; `type`, `url`, and `phone`
|
|
@@ -27612,11 +28170,18 @@ export type SetConversationThreadControlData = {
|
|
|
27612
28170
|
* Social account ID
|
|
27613
28171
|
*/
|
|
27614
28172
|
accountId: string;
|
|
27615
|
-
action: 'release' | 'take' | 'pass';
|
|
27616
28173
|
/**
|
|
27617
|
-
*
|
|
28174
|
+
* `request` is Facebook and Instagram only.
|
|
28175
|
+
*/
|
|
28176
|
+
action: 'release' | 'take' | 'pass' | 'request';
|
|
28177
|
+
/**
|
|
28178
|
+
* WhatsApp only. With action pass: send control to Meta Business Agent instead of the escalation partner.
|
|
27618
28179
|
*/
|
|
27619
28180
|
target?: 'ai_agent';
|
|
28181
|
+
/**
|
|
28182
|
+
* Facebook and Instagram only, required with action pass: the Meta app id receiving the thread.
|
|
28183
|
+
*/
|
|
28184
|
+
targetAppId?: string;
|
|
27620
28185
|
/**
|
|
27621
28186
|
* Free-form note forwarded verbatim to the app receiving control (its messaging_handovers webhook).
|
|
27622
28187
|
*/
|
|
@@ -27634,11 +28199,43 @@ export type SetConversationThreadControlResponse = ({
|
|
|
27634
28199
|
success?: boolean;
|
|
27635
28200
|
control?: {
|
|
27636
28201
|
owner?: 'app' | 'ai_agent' | 'other';
|
|
28202
|
+
/**
|
|
28203
|
+
* The app that received the thread, on a Facebook or Instagram pass.
|
|
28204
|
+
*/
|
|
28205
|
+
ownerAppId?: string;
|
|
27637
28206
|
};
|
|
27638
28207
|
});
|
|
27639
28208
|
|
|
27640
28209
|
export type SetConversationThreadControlError = (ErrorResponse | unknown);
|
|
27641
28210
|
|
|
28211
|
+
export type AcceptConversationRequestData = {
|
|
28212
|
+
body: {
|
|
28213
|
+
/**
|
|
28214
|
+
* Facebook or Instagram social account ID
|
|
28215
|
+
*/
|
|
28216
|
+
accountId: string;
|
|
28217
|
+
/**
|
|
28218
|
+
* The reply that accepts the request
|
|
28219
|
+
*/
|
|
28220
|
+
message: string;
|
|
28221
|
+
};
|
|
28222
|
+
path: {
|
|
28223
|
+
/**
|
|
28224
|
+
* The `id` of the request item from the requests folder.
|
|
28225
|
+
*/
|
|
28226
|
+
conversationId: string;
|
|
28227
|
+
};
|
|
28228
|
+
};
|
|
28229
|
+
|
|
28230
|
+
export type AcceptConversationRequestResponse = ({
|
|
28231
|
+
success?: boolean;
|
|
28232
|
+
data?: {
|
|
28233
|
+
messageId?: string;
|
|
28234
|
+
};
|
|
28235
|
+
});
|
|
28236
|
+
|
|
28237
|
+
export type AcceptConversationRequestError = (ErrorResponse | unknown);
|
|
28238
|
+
|
|
27642
28239
|
export type MarkConversationReadData = {
|
|
27643
28240
|
body: {
|
|
27644
28241
|
/**
|
|
@@ -27863,6 +28460,102 @@ export type DeleteMessengerGetStartedError = (ErrorResponse | {
|
|
|
27863
28460
|
error?: string;
|
|
27864
28461
|
} | unknown);
|
|
27865
28462
|
|
|
28463
|
+
export type GetMessengerGreetingData = {
|
|
28464
|
+
path: {
|
|
28465
|
+
accountId: string;
|
|
28466
|
+
};
|
|
28467
|
+
};
|
|
28468
|
+
|
|
28469
|
+
export type GetMessengerGreetingResponse = ({
|
|
28470
|
+
data?: Array<MessengerGreeting>;
|
|
28471
|
+
});
|
|
28472
|
+
|
|
28473
|
+
export type GetMessengerGreetingError = (ErrorResponse | {
|
|
28474
|
+
error?: string;
|
|
28475
|
+
});
|
|
28476
|
+
|
|
28477
|
+
export type SetMessengerGreetingData = {
|
|
28478
|
+
body: {
|
|
28479
|
+
/**
|
|
28480
|
+
* One entry per locale; one must use locale `default`.
|
|
28481
|
+
*/
|
|
28482
|
+
greeting: Array<MessengerGreeting>;
|
|
28483
|
+
};
|
|
28484
|
+
path: {
|
|
28485
|
+
accountId: string;
|
|
28486
|
+
};
|
|
28487
|
+
};
|
|
28488
|
+
|
|
28489
|
+
export type SetMessengerGreetingResponse = ({
|
|
28490
|
+
success?: boolean;
|
|
28491
|
+
});
|
|
28492
|
+
|
|
28493
|
+
export type SetMessengerGreetingError = (ErrorResponse | {
|
|
28494
|
+
error?: string;
|
|
28495
|
+
});
|
|
28496
|
+
|
|
28497
|
+
export type DeleteMessengerGreetingData = {
|
|
28498
|
+
path: {
|
|
28499
|
+
accountId: string;
|
|
28500
|
+
};
|
|
28501
|
+
};
|
|
28502
|
+
|
|
28503
|
+
export type DeleteMessengerGreetingResponse = ({
|
|
28504
|
+
success?: boolean;
|
|
28505
|
+
});
|
|
28506
|
+
|
|
28507
|
+
export type DeleteMessengerGreetingError = (ErrorResponse | {
|
|
28508
|
+
error?: string;
|
|
28509
|
+
});
|
|
28510
|
+
|
|
28511
|
+
export type GetMessengerIceBreakersData = {
|
|
28512
|
+
path: {
|
|
28513
|
+
accountId: string;
|
|
28514
|
+
};
|
|
28515
|
+
};
|
|
28516
|
+
|
|
28517
|
+
export type GetMessengerIceBreakersResponse = ({
|
|
28518
|
+
data?: Array<MessengerIceBreakerLocale>;
|
|
28519
|
+
});
|
|
28520
|
+
|
|
28521
|
+
export type GetMessengerIceBreakersError = (ErrorResponse | {
|
|
28522
|
+
error?: string;
|
|
28523
|
+
});
|
|
28524
|
+
|
|
28525
|
+
export type SetMessengerIceBreakersData = {
|
|
28526
|
+
body: {
|
|
28527
|
+
/**
|
|
28528
|
+
* One entry per locale; one must use locale `default`.
|
|
28529
|
+
*/
|
|
28530
|
+
ice_breakers: Array<MessengerIceBreakerLocale>;
|
|
28531
|
+
};
|
|
28532
|
+
path: {
|
|
28533
|
+
accountId: string;
|
|
28534
|
+
};
|
|
28535
|
+
};
|
|
28536
|
+
|
|
28537
|
+
export type SetMessengerIceBreakersResponse = ({
|
|
28538
|
+
success?: boolean;
|
|
28539
|
+
});
|
|
28540
|
+
|
|
28541
|
+
export type SetMessengerIceBreakersError = (ErrorResponse | {
|
|
28542
|
+
error?: string;
|
|
28543
|
+
});
|
|
28544
|
+
|
|
28545
|
+
export type DeleteMessengerIceBreakersData = {
|
|
28546
|
+
path: {
|
|
28547
|
+
accountId: string;
|
|
28548
|
+
};
|
|
28549
|
+
};
|
|
28550
|
+
|
|
28551
|
+
export type DeleteMessengerIceBreakersResponse = ({
|
|
28552
|
+
success?: boolean;
|
|
28553
|
+
});
|
|
28554
|
+
|
|
28555
|
+
export type DeleteMessengerIceBreakersError = (ErrorResponse | {
|
|
28556
|
+
error?: string;
|
|
28557
|
+
});
|
|
28558
|
+
|
|
27866
28559
|
export type GetInstagramIceBreakersData = {
|
|
27867
28560
|
path: {
|
|
27868
28561
|
accountId: string;
|
|
@@ -32174,6 +32867,57 @@ export type UpdateWhatsAppCommerceSettingsResponse = ({
|
|
|
32174
32867
|
|
|
32175
32868
|
export type UpdateWhatsAppCommerceSettingsError = (ErrorResponse);
|
|
32176
32869
|
|
|
32870
|
+
export type GetWhatsAppConversationalAutomationData = {
|
|
32871
|
+
query: {
|
|
32872
|
+
/**
|
|
32873
|
+
* WhatsApp account ID
|
|
32874
|
+
*/
|
|
32875
|
+
accountId: string;
|
|
32876
|
+
};
|
|
32877
|
+
};
|
|
32878
|
+
|
|
32879
|
+
export type GetWhatsAppConversationalAutomationResponse = ({
|
|
32880
|
+
data?: WhatsAppConversationalAutomation;
|
|
32881
|
+
});
|
|
32882
|
+
|
|
32883
|
+
export type GetWhatsAppConversationalAutomationError = (ErrorResponse | {
|
|
32884
|
+
error?: string;
|
|
32885
|
+
});
|
|
32886
|
+
|
|
32887
|
+
export type SetWhatsAppConversationalAutomationData = {
|
|
32888
|
+
body: ({
|
|
32889
|
+
/**
|
|
32890
|
+
* WhatsApp account ID
|
|
32891
|
+
*/
|
|
32892
|
+
accountId: string;
|
|
32893
|
+
} & WhatsAppConversationalAutomation);
|
|
32894
|
+
};
|
|
32895
|
+
|
|
32896
|
+
export type SetWhatsAppConversationalAutomationResponse = ({
|
|
32897
|
+
success?: boolean;
|
|
32898
|
+
});
|
|
32899
|
+
|
|
32900
|
+
export type SetWhatsAppConversationalAutomationError = (ErrorResponse | {
|
|
32901
|
+
error?: string;
|
|
32902
|
+
});
|
|
32903
|
+
|
|
32904
|
+
export type DeleteWhatsAppConversationalAutomationData = {
|
|
32905
|
+
query: {
|
|
32906
|
+
/**
|
|
32907
|
+
* WhatsApp account ID
|
|
32908
|
+
*/
|
|
32909
|
+
accountId: string;
|
|
32910
|
+
};
|
|
32911
|
+
};
|
|
32912
|
+
|
|
32913
|
+
export type DeleteWhatsAppConversationalAutomationResponse = ({
|
|
32914
|
+
success?: boolean;
|
|
32915
|
+
});
|
|
32916
|
+
|
|
32917
|
+
export type DeleteWhatsAppConversationalAutomationError = (ErrorResponse | {
|
|
32918
|
+
error?: string;
|
|
32919
|
+
});
|
|
32920
|
+
|
|
32177
32921
|
export type GetWhatsAppBusinessProfileData = {
|
|
32178
32922
|
query: {
|
|
32179
32923
|
/**
|
|
@@ -36955,12 +37699,22 @@ export type CreateBroadcastData = {
|
|
|
36955
37699
|
name: string;
|
|
36956
37700
|
description?: string;
|
|
36957
37701
|
message?: {
|
|
37702
|
+
/**
|
|
37703
|
+
* Required on every platform except WhatsApp (which sends `template`) and an SMS broadcast that carries attachments.
|
|
37704
|
+
*/
|
|
36958
37705
|
text?: string;
|
|
37706
|
+
/**
|
|
37707
|
+
* SMS only: sent as MMS media, one media_url per attachment. Each url must be public http(s); JPEG, PNG, GIF, WEBP, MP4 or 3GPP under 1 MB (checked at create when the host answers a HEAD request; Telnyx enforces the 1 MB total per message at send).
|
|
37708
|
+
*/
|
|
36959
37709
|
attachments?: Array<{
|
|
36960
37710
|
type?: string;
|
|
36961
37711
|
url?: string;
|
|
36962
37712
|
filename?: string;
|
|
36963
37713
|
}>;
|
|
37714
|
+
/**
|
|
37715
|
+
* Instagram and Facebook only. Meta message tag sent with every recipient message (messaging_type MESSAGE_TAG) so the broadcast can reach people outside the 24h window. Instagram accepts HUMAN_AGENT only. Rejected with a 400 on any other platform.
|
|
37716
|
+
*/
|
|
37717
|
+
messageTag?: 'CONFIRMED_EVENT_UPDATE' | 'POST_PURCHASE_UPDATE' | 'ACCOUNT_UPDATE' | 'HUMAN_AGENT';
|
|
36964
37718
|
};
|
|
36965
37719
|
/**
|
|
36966
37720
|
* WhatsApp template (required when platform is whatsapp)
|
|
@@ -36987,6 +37741,12 @@ export type CreateBroadcastData = {
|
|
|
36987
37741
|
segmentFilters?: {
|
|
36988
37742
|
tags?: Array<(string)>;
|
|
36989
37743
|
isSubscribed?: boolean;
|
|
37744
|
+
/**
|
|
37745
|
+
* Custom field values a contact must hold, keyed by field slug. Exact match per key (type included: 5 does not match "5"); every key must match.
|
|
37746
|
+
*/
|
|
37747
|
+
customFields?: {
|
|
37748
|
+
[key: string]: unknown;
|
|
37749
|
+
};
|
|
36990
37750
|
};
|
|
36991
37751
|
};
|
|
36992
37752
|
};
|
|
@@ -37029,6 +37789,10 @@ export type GetBroadcastResponse = ({
|
|
|
37029
37789
|
};
|
|
37030
37790
|
segmentFilters?: {
|
|
37031
37791
|
tags?: Array<(string)>;
|
|
37792
|
+
isSubscribed?: boolean;
|
|
37793
|
+
customFields?: {
|
|
37794
|
+
[key: string]: unknown;
|
|
37795
|
+
};
|
|
37032
37796
|
};
|
|
37033
37797
|
status?: 'draft' | 'scheduled' | 'sending' | 'completed' | 'failed' | 'cancelled';
|
|
37034
37798
|
scheduledAt?: string;
|
|
@@ -37057,6 +37821,18 @@ export type UpdateBroadcastData = {
|
|
|
37057
37821
|
*/
|
|
37058
37822
|
message?: {
|
|
37059
37823
|
text?: string;
|
|
37824
|
+
/**
|
|
37825
|
+
* SMS only: sent as MMS media.
|
|
37826
|
+
*/
|
|
37827
|
+
attachments?: Array<{
|
|
37828
|
+
type?: string;
|
|
37829
|
+
url?: string;
|
|
37830
|
+
filename?: string;
|
|
37831
|
+
}>;
|
|
37832
|
+
/**
|
|
37833
|
+
* Instagram and Facebook only. See createBroadcast.
|
|
37834
|
+
*/
|
|
37835
|
+
messageTag?: 'CONFIRMED_EVENT_UPDATE' | 'POST_PURCHASE_UPDATE' | 'ACCOUNT_UPDATE' | 'HUMAN_AGENT';
|
|
37060
37836
|
};
|
|
37061
37837
|
/**
|
|
37062
37838
|
* WhatsApp template payload (used when platform is `whatsapp`).
|
|
@@ -37490,7 +38266,10 @@ export type ListWorkflowExecutionsResponse = ({
|
|
|
37490
38266
|
[key: string]: unknown;
|
|
37491
38267
|
};
|
|
37492
38268
|
platformIdentifier?: string;
|
|
37493
|
-
|
|
38269
|
+
/**
|
|
38270
|
+
* Null only while a comment-triggered run has not sent its private reply yet.
|
|
38271
|
+
*/
|
|
38272
|
+
conversationId?: (string) | null;
|
|
37494
38273
|
stepCount?: number;
|
|
37495
38274
|
lastError?: (string) | null;
|
|
37496
38275
|
resumeAt?: (string) | null;
|
|
@@ -37550,6 +38329,40 @@ export type TriggerWorkflowError = (unknown | ErrorResponse | {
|
|
|
37550
38329
|
error?: string;
|
|
37551
38330
|
});
|
|
37552
38331
|
|
|
38332
|
+
export type TriggerApiCallWorkflowData = {
|
|
38333
|
+
body: {
|
|
38334
|
+
/**
|
|
38335
|
+
* A conversation on the workflow's account
|
|
38336
|
+
*/
|
|
38337
|
+
conversationId?: string;
|
|
38338
|
+
/**
|
|
38339
|
+
* A contact with a conversation on the workflow's account
|
|
38340
|
+
*/
|
|
38341
|
+
contactId?: string;
|
|
38342
|
+
/**
|
|
38343
|
+
* Recipient phone in E.164 (WhatsApp workflows only)
|
|
38344
|
+
*/
|
|
38345
|
+
to?: string;
|
|
38346
|
+
/**
|
|
38347
|
+
* Seed variables, merged over the standard run variables
|
|
38348
|
+
*/
|
|
38349
|
+
variables?: {
|
|
38350
|
+
[key: string]: unknown;
|
|
38351
|
+
};
|
|
38352
|
+
};
|
|
38353
|
+
path: {
|
|
38354
|
+
workflowId: string;
|
|
38355
|
+
};
|
|
38356
|
+
};
|
|
38357
|
+
|
|
38358
|
+
export type TriggerApiCallWorkflowResponse = ({
|
|
38359
|
+
executionId: string;
|
|
38360
|
+
});
|
|
38361
|
+
|
|
38362
|
+
export type TriggerApiCallWorkflowError = (ErrorResponse | {
|
|
38363
|
+
error?: string;
|
|
38364
|
+
});
|
|
38365
|
+
|
|
37553
38366
|
export type ListWorkflowExecutionEventsData = {
|
|
37554
38367
|
path: {
|
|
37555
38368
|
executionId: string;
|
|
@@ -38040,11 +38853,12 @@ export type ListCommentAutomationsResponse = ({
|
|
|
38040
38853
|
automations?: Array<{
|
|
38041
38854
|
id?: string;
|
|
38042
38855
|
name?: string;
|
|
38043
|
-
platform?: 'instagram' | 'facebook';
|
|
38044
|
-
trigger?: 'comment' | 'story_reply';
|
|
38856
|
+
platform?: 'instagram' | 'facebook' | 'tiktok' | 'threads' | 'linkedin' | 'youtube';
|
|
38857
|
+
trigger?: 'comment' | 'live_comment' | 'story_reply' | 'story_mention';
|
|
38045
38858
|
accountId?: string;
|
|
38046
38859
|
platformPostId?: string;
|
|
38047
38860
|
postTitle?: string;
|
|
38861
|
+
postId?: string;
|
|
38048
38862
|
keywords?: Array<(string)>;
|
|
38049
38863
|
/**
|
|
38050
38864
|
* How a keyword is compared with the comment. 'contains' (default) matches anywhere, even inside another word (keyword 'app' fires on 'happy'). 'word' matches the keyword only as a standalone word. 'exact' requires the whole comment to be exactly the keyword.
|
|
@@ -38093,33 +38907,19 @@ export type ListCommentAutomationsResponse = ({
|
|
|
38093
38907
|
* Whether these keywords also fire on a plain inbound DM.
|
|
38094
38908
|
*/
|
|
38095
38909
|
alsoMatchInDms?: boolean;
|
|
38910
|
+
repeatPolicy?: CommentAutomationRepeatPolicy;
|
|
38911
|
+
/**
|
|
38912
|
+
* Same-text dedupe window in hours. Omitted when off.
|
|
38913
|
+
*/
|
|
38914
|
+
dedupeSameTextHours?: number;
|
|
38915
|
+
publicReplyPolicy?: 'after_dm' | 'always';
|
|
38916
|
+
actions?: CommentAutomationActions;
|
|
38917
|
+
quickReplies?: Array<CommentAutomationQuickReply>;
|
|
38918
|
+
dmMedia?: CommentAutomationDmMedia;
|
|
38919
|
+
audience?: CommentAutomationAudience;
|
|
38920
|
+
followGate?: CommentAutomationFollowGate;
|
|
38096
38921
|
isActive?: boolean;
|
|
38097
|
-
stats?:
|
|
38098
|
-
triggered?: number;
|
|
38099
|
-
dmsSent?: number;
|
|
38100
|
-
dmsFailed?: number;
|
|
38101
|
-
uniqueContacts?: number;
|
|
38102
|
-
/**
|
|
38103
|
-
* DMs sent with a trackable (wrapped) link. CTR denominator: divide clicks by this, not dmsSent. Lags dmsSent for campaigns that predate click tracking.
|
|
38104
|
-
*/
|
|
38105
|
-
trackedSends?: number;
|
|
38106
|
-
/**
|
|
38107
|
-
* Total clicks on tracked links (bots/prefetch excluded).
|
|
38108
|
-
*/
|
|
38109
|
-
linkClicks?: number;
|
|
38110
|
-
/**
|
|
38111
|
-
* Distinct people who clicked a tracked link.
|
|
38112
|
-
*/
|
|
38113
|
-
uniqueClicks?: number;
|
|
38114
|
-
/**
|
|
38115
|
-
* DMs confirmed delivered (Messenger; IG emits no delivery receipt).
|
|
38116
|
-
*/
|
|
38117
|
-
delivered?: number;
|
|
38118
|
-
/**
|
|
38119
|
-
* DMs confirmed read (IG messaging_seen / Messenger message_reads).
|
|
38120
|
-
*/
|
|
38121
|
-
read?: number;
|
|
38122
|
-
};
|
|
38922
|
+
stats?: CommentAutomationStats;
|
|
38123
38923
|
createdAt?: string;
|
|
38124
38924
|
}>;
|
|
38125
38925
|
});
|
|
@@ -38130,13 +38930,13 @@ export type CreateCommentAutomationData = {
|
|
|
38130
38930
|
body: {
|
|
38131
38931
|
profileId: string;
|
|
38132
38932
|
/**
|
|
38133
|
-
* Instagram or
|
|
38933
|
+
* Instagram, Facebook, TikTok, Threads, LinkedIn or YouTube account ID. On the last four the automation only posts the public reply. X accounts are refused (400, code platform_not_supported) while X comment polling is off.
|
|
38134
38934
|
*/
|
|
38135
38935
|
accountId: string;
|
|
38136
38936
|
/**
|
|
38137
|
-
* What fires the automation. 'comment' (keyword comment on a post)
|
|
38937
|
+
* What fires the automation. 'comment' (keyword comment on a post), 'live_comment' (keyword comment on an Instagram live broadcast), 'story_reply' (keyword reply to an Instagram story) or 'story_mention' (a story mentioning the Instagram account). For 'story_reply', platformPostId is the story media id (omit for any story). Every trigger but 'comment' is Instagram only; reply-only platforms accept 'comment' only.
|
|
38138
38938
|
*/
|
|
38139
|
-
trigger?: 'comment' | 'story_reply';
|
|
38939
|
+
trigger?: 'comment' | 'live_comment' | 'story_reply' | 'story_mention';
|
|
38140
38940
|
/**
|
|
38141
38941
|
* Platform media/post ID (or story media id when trigger=story_reply). Omit for an account-wide (any-post / any-story) automation.
|
|
38142
38942
|
*/
|
|
@@ -38170,9 +38970,9 @@ export type CreateCommentAutomationData = {
|
|
|
38170
38970
|
*/
|
|
38171
38971
|
typoTolerance?: boolean;
|
|
38172
38972
|
/**
|
|
38173
|
-
* DM text to
|
|
38973
|
+
* DM text sent to the commenter. Required on Instagram and Facebook (400 missing_required_field when absent). Rejected on TikTok, Threads, LinkedIn and YouTube, which have no private reply (400 invalid_field_value). Max 640 chars when buttons are set, otherwise ~1000.
|
|
38174
38974
|
*/
|
|
38175
|
-
dmMessage
|
|
38975
|
+
dmMessage?: string;
|
|
38176
38976
|
/**
|
|
38177
38977
|
* Optional inline DM buttons (1-3). Phone buttons are Facebook-only. Omit or pass [] for a plain-text DM.
|
|
38178
38978
|
*/
|
|
@@ -38182,7 +38982,7 @@ export type CreateCommentAutomationData = {
|
|
|
38182
38982
|
*/
|
|
38183
38983
|
template?: (CommentAutomationTemplate);
|
|
38184
38984
|
/**
|
|
38185
|
-
*
|
|
38985
|
+
* Public reply to the comment. Optional on Instagram and Facebook; required on TikTok, Threads, LinkedIn and YouTube, where it is the automation's only action.
|
|
38186
38986
|
*/
|
|
38187
38987
|
commentReply?: string;
|
|
38188
38988
|
/**
|
|
@@ -38215,6 +39015,25 @@ export type CreateCommentAutomationData = {
|
|
|
38215
39015
|
alsoMatchInDms?: boolean;
|
|
38216
39016
|
audience?: CommentAutomationAudience;
|
|
38217
39017
|
followGate?: CommentAutomationFollowGate;
|
|
39018
|
+
repeatPolicy?: CommentAutomationRepeatPolicy;
|
|
39019
|
+
/**
|
|
39020
|
+
* Skip the DM when this recipient already received identical DM text (after personalisation) from this account, from any automation, within this many hours. The skip is logged with status skipped.
|
|
39021
|
+
*/
|
|
39022
|
+
dedupeSameTextHours?: (number) | null;
|
|
39023
|
+
/**
|
|
39024
|
+
* 'after_dm' posts commentReply only after a successful DM. 'always' posts it whatever the audience rule, dedupe or DM outcome: the moment a comment matches, or after commentReplyDelaySeconds when set (raised to dmDelaySeconds, so it never precedes the DM attempt).
|
|
39025
|
+
*/
|
|
39026
|
+
publicReplyPolicy?: 'after_dm' | 'always';
|
|
39027
|
+
actions?: CommentAutomationActions;
|
|
39028
|
+
/**
|
|
39029
|
+
* Opt-in quick-reply chips on the DM (up to 13). Chips do not render in Message Requests, where a first DM to a cold commenter lands, so prefer buttons for first contact. Mutually exclusive with buttons and template (400).
|
|
39030
|
+
*/
|
|
39031
|
+
quickReplies?: Array<CommentAutomationQuickReply>;
|
|
39032
|
+
dmMedia?: (CommentAutomationDmMedia | null);
|
|
39033
|
+
/**
|
|
39034
|
+
* Create the automation paused with false.
|
|
39035
|
+
*/
|
|
39036
|
+
isActive?: boolean;
|
|
38218
39037
|
};
|
|
38219
39038
|
};
|
|
38220
39039
|
|
|
@@ -38223,8 +39042,8 @@ export type CreateCommentAutomationResponse = ({
|
|
|
38223
39042
|
automation?: {
|
|
38224
39043
|
id?: string;
|
|
38225
39044
|
name?: string;
|
|
38226
|
-
platform?:
|
|
38227
|
-
trigger?: 'comment' | 'story_reply';
|
|
39045
|
+
platform?: 'instagram' | 'facebook' | 'tiktok' | 'threads' | 'linkedin' | 'youtube';
|
|
39046
|
+
trigger?: 'comment' | 'live_comment' | 'story_reply' | 'story_mention';
|
|
38228
39047
|
platformPostId?: string;
|
|
38229
39048
|
keywords?: Array<(string)>;
|
|
38230
39049
|
/**
|
|
@@ -38270,17 +39089,22 @@ export type CreateCommentAutomationResponse = ({
|
|
|
38270
39089
|
* Whether these keywords also fire on a plain inbound DM.
|
|
38271
39090
|
*/
|
|
38272
39091
|
alsoMatchInDms?: boolean;
|
|
39092
|
+
repeatPolicy?: CommentAutomationRepeatPolicy;
|
|
39093
|
+
/**
|
|
39094
|
+
* Same-text dedupe window in hours. Omitted when off.
|
|
39095
|
+
*/
|
|
39096
|
+
dedupeSameTextHours?: number;
|
|
39097
|
+
publicReplyPolicy?: 'after_dm' | 'always';
|
|
39098
|
+
actions?: CommentAutomationActions;
|
|
39099
|
+
quickReplies?: Array<CommentAutomationQuickReply>;
|
|
39100
|
+
dmMedia?: CommentAutomationDmMedia;
|
|
38273
39101
|
isActive?: boolean;
|
|
38274
|
-
stats?:
|
|
38275
|
-
totalTriggered?: number;
|
|
38276
|
-
totalSent?: number;
|
|
38277
|
-
totalFailed?: number;
|
|
38278
|
-
};
|
|
39102
|
+
stats?: CommentAutomationStats;
|
|
38279
39103
|
createdAt?: string;
|
|
38280
39104
|
};
|
|
38281
39105
|
});
|
|
38282
39106
|
|
|
38283
|
-
export type CreateCommentAutomationError = (
|
|
39107
|
+
export type CreateCommentAutomationError = (ErrorResponse | unknown);
|
|
38284
39108
|
|
|
38285
39109
|
export type GetCommentAutomationData = {
|
|
38286
39110
|
path: {
|
|
@@ -38293,8 +39117,8 @@ export type GetCommentAutomationResponse = ({
|
|
|
38293
39117
|
automation?: {
|
|
38294
39118
|
id?: string;
|
|
38295
39119
|
name?: string;
|
|
38296
|
-
platform?:
|
|
38297
|
-
trigger?: 'comment' | 'story_reply';
|
|
39120
|
+
platform?: 'instagram' | 'facebook' | 'tiktok' | 'threads' | 'linkedin' | 'youtube';
|
|
39121
|
+
trigger?: 'comment' | 'live_comment' | 'story_reply' | 'story_mention';
|
|
38298
39122
|
accountId?: string;
|
|
38299
39123
|
platformPostId?: string;
|
|
38300
39124
|
postId?: string;
|
|
@@ -38343,67 +39167,24 @@ export type GetCommentAutomationResponse = ({
|
|
|
38343
39167
|
* Whether these keywords also fire on a plain inbound DM.
|
|
38344
39168
|
*/
|
|
38345
39169
|
alsoMatchInDms?: boolean;
|
|
39170
|
+
repeatPolicy?: CommentAutomationRepeatPolicy;
|
|
39171
|
+
/**
|
|
39172
|
+
* Same-text dedupe window in hours. Omitted when off.
|
|
39173
|
+
*/
|
|
39174
|
+
dedupeSameTextHours?: number;
|
|
39175
|
+
publicReplyPolicy?: 'after_dm' | 'always';
|
|
39176
|
+
actions?: CommentAutomationActions;
|
|
39177
|
+
quickReplies?: Array<CommentAutomationQuickReply>;
|
|
39178
|
+
dmMedia?: CommentAutomationDmMedia;
|
|
38346
39179
|
isActive?: boolean;
|
|
38347
|
-
stats?:
|
|
38348
|
-
totalTriggered?: number;
|
|
38349
|
-
totalSent?: number;
|
|
38350
|
-
totalFailed?: number;
|
|
38351
|
-
};
|
|
39180
|
+
stats?: CommentAutomationStats;
|
|
38352
39181
|
createdAt?: string;
|
|
38353
39182
|
updatedAt?: string;
|
|
38354
39183
|
};
|
|
38355
|
-
|
|
38356
|
-
|
|
38357
|
-
|
|
38358
|
-
|
|
38359
|
-
commenterName?: string;
|
|
38360
|
-
commentText?: string;
|
|
38361
|
-
/**
|
|
38362
|
-
* Which door triggered this send. Absent on rows written before this field existed (all of those are comment-triggered).
|
|
38363
|
-
*/
|
|
38364
|
-
source?: 'comment' | 'story_reply' | 'dm';
|
|
38365
|
-
/**
|
|
38366
|
-
* DM outcome. 'pending' = the automation has a dmDelaySeconds and the response is queued but not sent yet. 'gated' = the follow-gate confirmation DM went out and we are waiting for the tap; it flips to 'sent' or 'skipped' when they tap.
|
|
38367
|
-
*/
|
|
38368
|
-
status?: 'pending' | 'sent' | 'failed' | 'skipped' | 'gated';
|
|
38369
|
-
/**
|
|
38370
|
-
* How the audience rule resolved. Absent on automations without one.
|
|
38371
|
-
*/
|
|
38372
|
-
audienceOutcome?: 'passed' | 'blocked' | 'gate_sent' | 'gate_passed' | 'gate_failed';
|
|
38373
|
-
/**
|
|
38374
|
-
* Follow relationship at decision time. Absent when Instagram would not tell us (the commenter never messaged the account).
|
|
38375
|
-
*/
|
|
38376
|
-
commenterIsFollower?: boolean;
|
|
38377
|
-
commenterFollowerCount?: number;
|
|
38378
|
-
/**
|
|
38379
|
-
* DM error message if status is failed
|
|
38380
|
-
*/
|
|
38381
|
-
error?: string;
|
|
38382
|
-
/**
|
|
38383
|
-
* Platform error codes of the failed DM (Meta `code` and `error_subcode`), when the platform sent them. Absent on successful rows and on rows written before this field existed.
|
|
38384
|
-
*/
|
|
38385
|
-
platformError?: {
|
|
38386
|
-
code?: number;
|
|
38387
|
-
subcode?: number;
|
|
38388
|
-
};
|
|
38389
|
-
/**
|
|
38390
|
-
* True when the failed send spent the comment's single private reply (Instagram subcode 1545133 or 2534023, or Meta code 10900 on Instagram and Facebook), the same rule as `details.privateReplyConsumed` on the private-reply endpoint. Absent on direct DMs and on rows written before this field existed.
|
|
38391
|
-
*/
|
|
38392
|
-
privateReplyConsumed?: boolean;
|
|
38393
|
-
/**
|
|
38394
|
-
* Outcome of the optional public reply on the triggering comment. 'skipped' if no commentReply was configured or if the DM failed (the public reply is not attempted in that case).
|
|
38395
|
-
*/
|
|
38396
|
-
commentReplyStatus?: 'sent' | 'failed' | 'skipped';
|
|
38397
|
-
/**
|
|
38398
|
-
* Public-reply error message if commentReplyStatus is failed
|
|
38399
|
-
*/
|
|
38400
|
-
commentReplyError?: string;
|
|
38401
|
-
/**
|
|
38402
|
-
* When the next queued send fires. Present only while something is still pending.
|
|
38403
|
-
*/
|
|
38404
|
-
nextDueAt?: string;
|
|
38405
|
-
createdAt?: string;
|
|
38406
|
-
}>;
|
|
39184
|
+
/**
|
|
39185
|
+
* The 20 most recent trigger logs.
|
|
39186
|
+
*/
|
|
39187
|
+
logs?: Array<CommentAutomationLog>;
|
|
38407
39188
|
});
|
|
38408
39189
|
|
|
38409
39190
|
export type GetCommentAutomationError = (ErrorResponse | {
|
|
@@ -38414,9 +39195,9 @@ export type UpdateCommentAutomationData = {
|
|
|
38414
39195
|
body?: {
|
|
38415
39196
|
name?: string;
|
|
38416
39197
|
/**
|
|
38417
|
-
* What fires the automation. Changing it detaches the automation from its bound post or story (a post id and a story id are different objects), unless this same request sets a new binding. '
|
|
39198
|
+
* What fires the automation. Changing it detaches the automation from its bound post or story (a post id and a story id are different objects), unless this same request sets a new binding. Every trigger but 'comment' is Instagram only; 'story_mention' also requires no keywords and no binding.
|
|
38418
39199
|
*/
|
|
38419
|
-
trigger?: 'comment' | 'story_reply';
|
|
39200
|
+
trigger?: 'comment' | 'live_comment' | 'story_reply' | 'story_mention';
|
|
38420
39201
|
keywords?: Array<(string)>;
|
|
38421
39202
|
/**
|
|
38422
39203
|
* How a keyword is compared with the comment. 'contains' (default) matches anywhere, even inside another word (keyword 'app' fires on 'happy'). 'word' matches the keyword only as a standalone word. 'exact' requires the whole comment to be exactly the keyword.
|
|
@@ -38471,6 +39252,21 @@ export type UpdateCommentAutomationData = {
|
|
|
38471
39252
|
audience?: CommentAutomationAudience;
|
|
38472
39253
|
followGate?: CommentAutomationFollowGate;
|
|
38473
39254
|
isActive?: boolean;
|
|
39255
|
+
repeatPolicy?: CommentAutomationRepeatPolicy;
|
|
39256
|
+
/**
|
|
39257
|
+
* Skip the DM when this recipient already received identical DM text (after personalisation) from this account, from any automation, within this many hours. The skip is logged with status skipped. Send null to clear.
|
|
39258
|
+
*/
|
|
39259
|
+
dedupeSameTextHours?: (number) | null;
|
|
39260
|
+
/**
|
|
39261
|
+
* 'after_dm' posts commentReply only after a successful DM. 'always' posts it whatever the audience rule, dedupe or DM outcome: the moment a comment matches, or after commentReplyDelaySeconds when set (raised to dmDelaySeconds, so it never precedes the DM attempt).
|
|
39262
|
+
*/
|
|
39263
|
+
publicReplyPolicy?: 'after_dm' | 'always';
|
|
39264
|
+
actions?: CommentAutomationActions;
|
|
39265
|
+
/**
|
|
39266
|
+
* Opt-in quick-reply chips on the DM (up to 13). Chips do not render in Message Requests, where a first DM to a cold commenter lands, so prefer buttons for first contact. Mutually exclusive with buttons and template (400). Send null to clear.
|
|
39267
|
+
*/
|
|
39268
|
+
quickReplies?: Array<CommentAutomationQuickReply> | null;
|
|
39269
|
+
dmMedia?: (CommentAutomationDmMedia | null);
|
|
38474
39270
|
};
|
|
38475
39271
|
path: {
|
|
38476
39272
|
automationId: string;
|
|
@@ -38516,7 +39312,17 @@ export type UpdateCommentAutomationResponse = ({
|
|
|
38516
39312
|
* Whether these keywords also fire on a plain inbound DM.
|
|
38517
39313
|
*/
|
|
38518
39314
|
alsoMatchInDms?: boolean;
|
|
39315
|
+
repeatPolicy?: CommentAutomationRepeatPolicy;
|
|
39316
|
+
/**
|
|
39317
|
+
* Same-text dedupe window in hours. Omitted when off.
|
|
39318
|
+
*/
|
|
39319
|
+
dedupeSameTextHours?: number;
|
|
39320
|
+
publicReplyPolicy?: 'after_dm' | 'always';
|
|
39321
|
+
actions?: CommentAutomationActions;
|
|
39322
|
+
quickReplies?: Array<CommentAutomationQuickReply>;
|
|
39323
|
+
dmMedia?: CommentAutomationDmMedia;
|
|
38519
39324
|
isActive?: boolean;
|
|
39325
|
+
stats?: CommentAutomationStats;
|
|
38520
39326
|
updatedAt?: string;
|
|
38521
39327
|
};
|
|
38522
39328
|
});
|
|
@@ -38553,58 +39359,7 @@ export type ListCommentAutomationLogsData = {
|
|
|
38553
39359
|
|
|
38554
39360
|
export type ListCommentAutomationLogsResponse = ({
|
|
38555
39361
|
success?: boolean;
|
|
38556
|
-
logs?: Array<
|
|
38557
|
-
id?: string;
|
|
38558
|
-
commentId?: string;
|
|
38559
|
-
commenterId?: string;
|
|
38560
|
-
commenterName?: string;
|
|
38561
|
-
commentText?: string;
|
|
38562
|
-
/**
|
|
38563
|
-
* Which door triggered this send. Absent on rows written before this field existed (all of those are comment-triggered).
|
|
38564
|
-
*/
|
|
38565
|
-
source?: 'comment' | 'story_reply' | 'dm';
|
|
38566
|
-
/**
|
|
38567
|
-
* DM outcome. 'pending' = the automation has a dmDelaySeconds and the response is queued but not sent yet. 'gated' = the follow-gate confirmation DM went out and we are waiting for the tap; it flips to 'sent' or 'skipped' when they tap.
|
|
38568
|
-
*/
|
|
38569
|
-
status?: 'pending' | 'sent' | 'failed' | 'skipped' | 'gated';
|
|
38570
|
-
/**
|
|
38571
|
-
* How the audience rule resolved. Absent on automations without one.
|
|
38572
|
-
*/
|
|
38573
|
-
audienceOutcome?: 'passed' | 'blocked' | 'gate_sent' | 'gate_passed' | 'gate_failed';
|
|
38574
|
-
/**
|
|
38575
|
-
* Follow relationship at decision time. Absent when Instagram would not tell us (the commenter never messaged the account).
|
|
38576
|
-
*/
|
|
38577
|
-
commenterIsFollower?: boolean;
|
|
38578
|
-
commenterFollowerCount?: number;
|
|
38579
|
-
/**
|
|
38580
|
-
* DM error message if status is failed
|
|
38581
|
-
*/
|
|
38582
|
-
error?: string;
|
|
38583
|
-
/**
|
|
38584
|
-
* Platform error codes of the failed DM (Meta `code` and `error_subcode`), when the platform sent them. Absent on successful rows and on rows written before this field existed.
|
|
38585
|
-
*/
|
|
38586
|
-
platformError?: {
|
|
38587
|
-
code?: number;
|
|
38588
|
-
subcode?: number;
|
|
38589
|
-
};
|
|
38590
|
-
/**
|
|
38591
|
-
* True when the failed send spent the comment's single private reply (Instagram subcode 1545133 or 2534023, or Meta code 10900 on Instagram and Facebook), the same rule as `details.privateReplyConsumed` on the private-reply endpoint. Absent on direct DMs and on rows written before this field existed.
|
|
38592
|
-
*/
|
|
38593
|
-
privateReplyConsumed?: boolean;
|
|
38594
|
-
/**
|
|
38595
|
-
* Outcome of the optional public reply on the triggering comment. 'skipped' if no commentReply was configured or if the DM failed (the public reply is not attempted in that case).
|
|
38596
|
-
*/
|
|
38597
|
-
commentReplyStatus?: 'sent' | 'failed' | 'skipped';
|
|
38598
|
-
/**
|
|
38599
|
-
* Public-reply error message if commentReplyStatus is failed
|
|
38600
|
-
*/
|
|
38601
|
-
commentReplyError?: string;
|
|
38602
|
-
/**
|
|
38603
|
-
* When the next queued send fires. Present only while something is still pending.
|
|
38604
|
-
*/
|
|
38605
|
-
nextDueAt?: string;
|
|
38606
|
-
createdAt?: string;
|
|
38607
|
-
}>;
|
|
39362
|
+
logs?: Array<CommentAutomationLog>;
|
|
38608
39363
|
pagination?: {
|
|
38609
39364
|
total?: number;
|
|
38610
39365
|
limit?: number;
|
|
@@ -45215,6 +45970,10 @@ export type BoostPostData = {
|
|
|
45215
45970
|
* Meta WhatsApp only. E.164 number already paired with the Page. Omit to use the default pairing. Requires WHATSAPP_MESSAGE callToAction. Stored as creative.whatsappPhoneNumber on the ad.
|
|
45216
45971
|
*/
|
|
45217
45972
|
whatsappPhoneNumber?: string;
|
|
45973
|
+
/**
|
|
45974
|
+
* Meta messaging boosts only (callToAction MESSAGE_PAGE, WHATSAPP_MESSAGE or INSTAGRAM_MESSAGE). A workflow in the account's profile, started in the conversation a click on the ad opens. Stored on the ad. 400 without a messaging callToAction or on another platform, 404 when no such workflow exists in the profile.
|
|
45975
|
+
*/
|
|
45976
|
+
workflowId?: string;
|
|
45218
45977
|
/**
|
|
45219
45978
|
* ISO 4217 currency code matching the ad account's currency. Meta only. Optional: Zernio resolves it from the ad account when omitted. The value selects the minor-unit exponent Zernio converts budget/bid amounts by before calling Meta (most currencies are cents; zero-decimal currencies like JPY/KRW are sent as-is).
|
|
45220
45979
|
*/
|
|
@@ -50100,6 +50859,10 @@ export type CreateMessagingAdData = {
|
|
|
50100
50859
|
*
|
|
50101
50860
|
*/
|
|
50102
50861
|
placementAssets?: (MetaPlacementAssets);
|
|
50862
|
+
/**
|
|
50863
|
+
* A workflow in the ad account's profile. When someone clicks the ad, that workflow starts in the conversation the click opens (on the first message, a postback or a standalone referral carrying the ad id), ahead of keyword-matched workflows, if it is active on the receiving account. Stored on the ad. 404 when no such workflow exists in the profile.
|
|
50864
|
+
*/
|
|
50865
|
+
workflowId?: string;
|
|
50103
50866
|
/**
|
|
50104
50867
|
* Dry-runs the ad on Meta with execution_options validate_only as ONE inline campaign + ad set + creative + ad (or creative + ad on the existing ad set with `adSetId`). Nothing is uploaded or created and nothing is stored; media is checked by URL. Supports one creative with `imageUrl`, image `placementAssets`, `carouselCards`, an existing `video.id`, or an existing post. Several creatives, a new `video.url` and video `placementAssets` need uploads first and return 400. Success returns 200 with per-node results; a Meta rejection returns the Meta error.
|
|
50105
50868
|
*/
|
|
@@ -51188,7 +51951,7 @@ export type ListTrackingTagsData = {
|
|
|
51188
51951
|
};
|
|
51189
51952
|
|
|
51190
51953
|
export type ListTrackingTagsResponse = ({
|
|
51191
|
-
platform?: 'metaads' | 'openaiads' | 'tiktokads' | 'googleads' | 'xads' | 'linkedinads' | 'pinterestads';
|
|
51954
|
+
platform?: 'metaads' | 'openaiads' | 'tiktokads' | 'googleads' | 'xads' | 'linkedinads' | 'pinterestads' | 'whopads';
|
|
51192
51955
|
tags?: Array<TrackingTag>;
|
|
51193
51956
|
});
|
|
51194
51957
|
|
|
@@ -51219,7 +51982,7 @@ export type CreateTrackingTagData = {
|
|
|
51219
51982
|
};
|
|
51220
51983
|
|
|
51221
51984
|
export type CreateTrackingTagResponse = ({
|
|
51222
|
-
platform?: 'metaads' | 'openaiads' | 'tiktokads' | 'googleads' | 'xads' | 'linkedinads' | 'pinterestads';
|
|
51985
|
+
platform?: 'metaads' | 'openaiads' | 'tiktokads' | 'googleads' | 'xads' | 'linkedinads' | 'pinterestads' | 'whopads';
|
|
51223
51986
|
tag?: TrackingTag;
|
|
51224
51987
|
});
|
|
51225
51988
|
|
|
@@ -51242,7 +52005,7 @@ export type GetTrackingTagData = {
|
|
|
51242
52005
|
};
|
|
51243
52006
|
|
|
51244
52007
|
export type GetTrackingTagResponse = ({
|
|
51245
|
-
platform?: 'metaads' | 'tiktokads' | 'googleads' | 'xads' | 'openaiads' | 'linkedinads' | 'pinterestads';
|
|
52008
|
+
platform?: 'metaads' | 'tiktokads' | 'googleads' | 'xads' | 'openaiads' | 'linkedinads' | 'pinterestads' | 'whopads';
|
|
51246
52009
|
tag?: TrackingTag;
|
|
51247
52010
|
});
|
|
51248
52011
|
|
|
@@ -51288,7 +52051,7 @@ export type UpdateTrackingTagData = {
|
|
|
51288
52051
|
};
|
|
51289
52052
|
|
|
51290
52053
|
export type UpdateTrackingTagResponse = ({
|
|
51291
|
-
platform?: 'metaads' | 'tiktokads' | 'googleads' | 'xads' | 'openaiads' | 'linkedinads' | 'pinterestads';
|
|
52054
|
+
platform?: 'metaads' | 'tiktokads' | 'googleads' | 'xads' | 'openaiads' | 'linkedinads' | 'pinterestads' | 'whopads';
|
|
51292
52055
|
tag?: TrackingTag;
|
|
51293
52056
|
});
|
|
51294
52057
|
|
|
@@ -51383,7 +52146,7 @@ export type InstallTrackingTagOnStoreData = {
|
|
|
51383
52146
|
};
|
|
51384
52147
|
|
|
51385
52148
|
export type InstallTrackingTagOnStoreResponse = ({
|
|
51386
|
-
platform?: 'metaads' | 'tiktokads' | 'googleads' | 'xads' | 'openaiads' | 'linkedinads' | 'pinterestads';
|
|
52149
|
+
platform?: 'metaads' | 'tiktokads' | 'googleads' | 'xads' | 'openaiads' | 'linkedinads' | 'pinterestads' | 'whopads';
|
|
51387
52150
|
install?: (StorePixelInstall & {
|
|
51388
52151
|
/**
|
|
51389
52152
|
* Shopify only: the pixel this install replaced on the store, if any.
|
|
@@ -51436,7 +52199,7 @@ export type GetTrackingTagStoreInstallData = {
|
|
|
51436
52199
|
};
|
|
51437
52200
|
|
|
51438
52201
|
export type GetTrackingTagStoreInstallResponse = ({
|
|
51439
|
-
platform?: 'metaads' | 'tiktokads' | 'googleads' | 'xads' | 'openaiads' | 'linkedinads' | 'pinterestads';
|
|
52202
|
+
platform?: 'metaads' | 'tiktokads' | 'googleads' | 'xads' | 'openaiads' | 'linkedinads' | 'pinterestads' | 'whopads';
|
|
51440
52203
|
install?: (StorePixelInstall & {
|
|
51441
52204
|
/**
|
|
51442
52205
|
* WordPress only.
|
|
@@ -51484,7 +52247,7 @@ export type RemoveTrackingTagFromStoreData = {
|
|
|
51484
52247
|
};
|
|
51485
52248
|
|
|
51486
52249
|
export type RemoveTrackingTagFromStoreResponse = ({
|
|
51487
|
-
platform?: 'metaads' | 'tiktokads' | 'googleads' | 'xads' | 'openaiads' | 'linkedinads' | 'pinterestads';
|
|
52250
|
+
platform?: 'metaads' | 'tiktokads' | 'googleads' | 'xads' | 'openaiads' | 'linkedinads' | 'pinterestads' | 'whopads';
|
|
51488
52251
|
install?: (StorePixelInstall & {
|
|
51489
52252
|
/**
|
|
51490
52253
|
* WordPress only: number of Zernio widgets deleted.
|
|
@@ -51703,7 +52466,7 @@ export type GetTrackingTagStatsData = {
|
|
|
51703
52466
|
};
|
|
51704
52467
|
|
|
51705
52468
|
export type GetTrackingTagStatsResponse = ({
|
|
51706
|
-
platform?: 'metaads' | 'tiktokads' | 'googleads' | 'xads' | 'openaiads' | 'linkedinads' | 'pinterestads';
|
|
52469
|
+
platform?: 'metaads' | 'tiktokads' | 'googleads' | 'xads' | 'openaiads' | 'linkedinads' | 'pinterestads' | 'whopads';
|
|
51707
52470
|
stats?: {
|
|
51708
52471
|
aggregation?: string;
|
|
51709
52472
|
startTime?: number;
|