@getlatedev/node 0.2.1266 → 0.2.1268

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.
@@ -2188,7 +2188,15 @@ export type ApiChangelogEntry = {
2188
2188
  */
2189
2189
  platforms: Array<(string)>;
2190
2190
  /**
2191
- * The announcement, in Markdown.
2191
+ * The change in a few words, for example `Delete inbox conversations`. Null on older entries.
2192
+ */
2193
+ title: (string) | null;
2194
+ /**
2195
+ * One or two plain sentences on what changed and why it matters. Null when `title` is.
2196
+ */
2197
+ summary: (string) | null;
2198
+ /**
2199
+ * The details in Markdown: endpoints, fields and how to use them.
2192
2200
  */
2193
2201
  message: string;
2194
2202
  publishedAt: string;
@@ -10180,9 +10188,9 @@ export type Post = {
10180
10188
  scheduledFor?: string;
10181
10189
  timezone?: string;
10182
10190
  /**
10183
- * `cancelled` is set by POST /v1/posts/{postId}/unpublish once every platform entry has been removed from its platform (a post with published entries left becomes `partial`); cancelled posts can be edited and rescheduled like drafts.
10191
+ * `cancelled` is set by POST /v1/posts/{postId}/unpublish once every platform entry has been removed from its platform (a post with published entries left becomes `partial`); cancelled posts can be edited and rescheduled like drafts. `pending_approval` (set by `requiresApproval: true`) never publishes until POST /v1/posts/{postId}/review approves it.
10184
10192
  */
10185
- status?: 'draft' | 'scheduled' | 'publishing' | 'published' | 'partial' | 'failed' | 'cancelled';
10193
+ status?: 'draft' | 'pending_approval' | 'scheduled' | 'publishing' | 'published' | 'partial' | 'failed' | 'cancelled';
10186
10194
  /**
10187
10195
  * YouTube constraints: each tag max 100 chars, combined max 500 chars, duplicates removed.
10188
10196
  */
@@ -10219,6 +10227,11 @@ export type Post = {
10219
10227
  updatedAt?: string;
10220
10228
  };
10221
10229
 
10230
+ /**
10231
+ * `cancelled` is set by POST /v1/posts/{postId}/unpublish once every platform entry has been removed from its platform (a post with published entries left becomes `partial`); cancelled posts can be edited and rescheduled like drafts. `pending_approval` (set by `requiresApproval: true`) never publishes until POST /v1/posts/{postId}/review approves it.
10232
+ */
10233
+ export type status28 = 'draft' | 'pending_approval' | 'scheduled' | 'publishing' | 'published' | 'partial' | 'failed' | 'cancelled';
10234
+
10222
10235
  export type visibility2 = 'public' | 'private' | 'unlisted';
10223
10236
 
10224
10237
  export type PostAnalytics = {
@@ -10454,7 +10467,7 @@ export type Product = {
10454
10467
  publishedAt?: (string) | null;
10455
10468
  };
10456
10469
 
10457
- export type status28 = 'active' | 'draft' | 'archived';
10470
+ export type status29 = 'active' | 'draft' | 'archived';
10458
10471
 
10459
10472
  export type ProductImage = {
10460
10473
  url?: string;
@@ -10673,7 +10686,7 @@ export type RcsAgent = {
10673
10686
  createdAt?: string;
10674
10687
  };
10675
10688
 
10676
- export type status29 = 'requested' | 'changes_requested' | 'brand_vetting' | 'agent_review' | 'testing' | 'launch_review' | 'launching' | 'live' | 'rejected' | 'deactivated';
10689
+ export type status30 = 'requested' | 'changes_requested' | 'brand_vetting' | 'agent_review' | 'testing' | 'launch_review' | 'launching' | 'live' | 'rejected' | 'deactivated';
10677
10690
 
10678
10691
  export type useCase = 'MULTI_USE' | 'PROMOTIONAL' | 'TRANSACTIONAL' | 'OTP';
10679
10692
 
@@ -10725,7 +10738,7 @@ export type RcsBrand = RcsBrandInput & {
10725
10738
  /**
10726
10739
  * draft = not filed yet (still editable).
10727
10740
  */
10728
- export type status30 = 'draft' | 'vetting' | 'verified' | 'rejected';
10741
+ export type status31 = 'draft' | 'vetting' | 'verified' | 'rejected';
10729
10742
 
10730
10743
  export type RcsBrandInput = {
10731
10744
  displayName: string;
@@ -10812,7 +10825,7 @@ export type RcsCarrierApproval = {
10812
10825
 
10813
10826
  export type scope2 = 'carrier' | 'hub' | 'bot';
10814
10827
 
10815
- export type status31 = 'PENDING' | 'SUBMITTED' | 'APPROVED' | 'REJECTED';
10828
+ export type status32 = 'PENDING' | 'SUBMITTED' | 'APPROVED' | 'REJECTED';
10816
10829
 
10817
10830
  /**
10818
10831
  * Message content. `suggestions` (max 11) render as chips under the message.
@@ -11644,7 +11657,7 @@ export type SupportRun = {
11644
11657
  /**
11645
11658
  * queued and running are in progress. needs_human means the assistant handed the question to a person instead of answering; when `supportTicket` is set, a Zernio teammate has been notified and will follow up by email.
11646
11659
  */
11647
- export type status32 = 'queued' | 'running' | 'completed' | 'needs_human' | 'failed';
11660
+ export type status33 = 'queued' | 'running' | 'completed' | 'needs_human' | 'failed';
11648
11661
 
11649
11662
  /**
11650
11663
  * Why the run stopped. Null while it is in progress.
@@ -12546,7 +12559,7 @@ export type UploadTokenResponse = {
12546
12559
  status?: 'pending' | 'completed' | 'expired';
12547
12560
  };
12548
12561
 
12549
- export type status33 = 'pending' | 'completed' | 'expired';
12562
+ export type status34 = 'pending' | 'completed' | 'expired';
12550
12563
 
12551
12564
  export type UploadTokenStatusResponse = {
12552
12565
  token?: string;
@@ -13053,7 +13066,7 @@ export type Verification = {
13053
13066
  resend?: boolean;
13054
13067
  };
13055
13068
 
13056
- export type status34 = 'pending' | 'approved' | 'expired' | 'max_attempts_reached' | 'canceled' | 'delivery_failed';
13069
+ export type status35 = 'pending' | 'approved' | 'expired' | 'max_attempts_reached' | 'canceled' | 'delivery_failed';
13057
13070
 
13058
13071
  export type channel5 = 'sms' | 'whatsapp';
13059
13072
 
@@ -13211,7 +13224,7 @@ export type WebhookLog = {
13211
13224
  /**
13212
13225
  * Delivery outcome
13213
13226
  */
13214
- export type status35 = 'success' | 'failed';
13227
+ export type status36 = 'success' | 'failed';
13215
13228
 
13216
13229
  /**
13217
13230
  * Webhook payload for `account.ads.initial_sync_completed` events.
@@ -13328,7 +13341,7 @@ export type event = 'account.ads.initial_sync_completed';
13328
13341
  /**
13329
13342
  * Overall outcome of the initial sync.
13330
13343
  */
13331
- export type status36 = 'success' | 'failure';
13344
+ export type status37 = 'success' | 'failure';
13332
13345
 
13333
13346
  /**
13334
13347
  * Stable category for UX branching. New values may be added; existing ones are
@@ -13719,7 +13732,7 @@ export type event7 = 'ad.video.processed';
13719
13732
  /**
13720
13733
  * `ready`: usable as `video.id` on the create endpoints. `error`: Meta could not process it; upload again.
13721
13734
  */
13722
- export type status37 = 'ready' | 'error';
13735
+ export type status38 = 'ready' | 'error';
13723
13736
 
13724
13737
  /**
13725
13738
  * Webhook payload for `analytics.synced`. Fired once per connected account each
@@ -15826,7 +15839,7 @@ export type event30 = 'post.platform.published' | 'post.platform.failed' | 'post
15826
15839
  /**
15827
15840
  * Terminal status this event fires on. Matches the event suffix.
15828
15841
  */
15829
- export type status38 = 'published' | 'failed' | 'deleted';
15842
+ export type status39 = 'published' | 'failed' | 'deleted';
15830
15843
 
15831
15844
  /**
15832
15845
  * Webhook payload for reaction received events (WhatsApp, Telegram, Slack, Instagram, Facebook Messenger, TikTok)
@@ -16223,7 +16236,7 @@ export type event39 = 'whatsapp.account.name_status_updated';
16223
16236
  /**
16224
16237
  * Normalized from Meta's `decision` (REJECTED -> DECLINED, DEFERRED -> PENDING_REVIEW; the review is still open on DEFERRED, not a rejection).
16225
16238
  */
16226
- export type status39 = 'APPROVED' | 'DECLINED' | 'PENDING_REVIEW';
16239
+ export type status40 = 'APPROVED' | 'DECLINED' | 'PENDING_REVIEW';
16227
16240
 
16228
16241
  /**
16229
16242
  * Webhook payload for `whatsapp.account.quality_updated`. Fired when a connected
@@ -16357,7 +16370,7 @@ export type event41 = 'whatsapp.account.status_updated';
16357
16370
  /**
16358
16371
  * `active` only on a reinstatement (DISABLED_UPDATE with ban state REINSTATE).
16359
16372
  */
16360
- export type status40 = 'restricted' | 'active';
16373
+ export type status41 = 'restricted' | 'active';
16361
16374
 
16362
16375
  /**
16363
16376
  * Webhook payload for the `whatsapp.contact.identity_changed` event. Fired when
@@ -16573,7 +16586,7 @@ export type event44 = 'whatsapp.template.status_updated';
16573
16586
  * request before the template is actually removed.
16574
16587
  *
16575
16588
  */
16576
- export type status41 = 'APPROVED' | 'REJECTED' | 'PENDING' | 'PAUSED' | 'DISABLED' | 'IN_APPEAL' | 'PENDING_DELETION';
16589
+ export type status42 = 'APPROVED' | 'REJECTED' | 'PENDING' | 'PAUSED' | 'DISABLED' | 'IN_APPEAL' | 'PENDING_DELETION';
16577
16590
 
16578
16591
  export type WebhookPayloadWorkflowRun = {
16579
16592
  /**
@@ -16637,7 +16650,7 @@ export type event45 = 'workflow.run.started' | 'workflow.run.completed' | 'workf
16637
16650
  /**
16638
16651
  * 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.
16639
16652
  */
16640
- export type status42 = 'running' | 'waiting' | 'completed' | 'exited' | 'failed';
16653
+ export type status43 = 'running' | 'waiting' | 'completed' | 'exited' | 'failed';
16641
16654
 
16642
16655
  /**
16643
16656
  * The profiles this event belongs to, each with the externalId you set on it (null when none is set). Present on every event tied to a profile and absent on events that belong to none. Events spanning several profiles (a post published to accounts of different profiles) list each once. Use it to route the event to your tenant without storing Zernio profile ids.
@@ -17035,7 +17048,7 @@ export type WorkflowExecutionEvent = {
17035
17048
 
17036
17049
  export type action2 = 'execution_started' | 'execution_completed' | 'execution_exited' | 'execution_paused' | 'execution_resumed' | 'node_started' | 'node_completed' | 'node_failed' | 'node_skipped';
17037
17050
 
17038
- export type status43 = 'success' | 'failed' | 'pending';
17051
+ export type status44 = 'success' | 'failed' | 'pending';
17039
17052
 
17040
17053
  /**
17041
17054
  * A node in a workflow graph. `config` shape depends on `type`.
@@ -19878,7 +19891,7 @@ export type ListPostsData = {
19878
19891
  * Which collection to read. `zernio` (default) returns posts authored through Zernio. `external` returns posts synced from the platform (existing/historical posts that were published outside Zernio). Combine with `accountId` and paginate via `page`/`limit` to walk the full synced history (we keep up to the last ~12 months per account).
19879
19892
  */
19880
19893
  source?: 'zernio' | 'external';
19881
- status?: 'draft' | 'scheduled' | 'publishing' | 'published' | 'partial' | 'failed' | 'cancelled';
19894
+ status?: 'draft' | 'pending_approval' | 'scheduled' | 'publishing' | 'published' | 'partial' | 'failed' | 'cancelled';
19882
19895
  /**
19883
19896
  * Comma-separated tags (at most 20). Returns only posts carrying every listed tag, matched exactly and case-sensitively against the tags set when the post was created. An empty value means no tag filter. `tag` is accepted as an alias.
19884
19897
  */
@@ -19937,6 +19950,10 @@ export type CreatePostData = {
19937
19950
  * When true, saves the post as a draft. When none of scheduledFor, publishNow, or queuedFromProfile are provided, the post defaults to draft automatically.
19938
19951
  */
19939
19952
  isDraft?: boolean;
19953
+ /**
19954
+ * When true, saves the post as pending_approval instead of scheduled. Needs scheduledFor, at the root or on every platform; cannot be combined with isDraft, publishNow, queuedFromProfile or queueId. The post publishes only after POST /v1/posts/{postId}/review approves it; approving after the scheduled time publishes within a couple of minutes.
19955
+ */
19956
+ requiresApproval?: boolean;
19940
19957
  /**
19941
19958
  * TikTok only. Preview whether each `tiktok` entry in `platforms` could publish right now under the TikTok Direct Post daily limits, without creating, scheduling or publishing anything: no post is persisted and no upload slot is claimed, so it can be repeated freely. The request still goes through auth, the payment gate and body validation, then returns HTTP 200 with `{ dryRun: true, canPublish, tiktok: [...] }` instead of 201. Only `tiktok` entries are evaluated; other platforms in the body are ignored, and a body with no `tiktok` entry is rejected with 400 `invalid_field_value` on `platforms`. An entry with `platformSpecificData.tiktokSettings.draft: true` (Creator Inbox upload) is not subject to the limit and always reports `canPublish: true`. Accounts connected through the TikTok for Business app do not go through these limits at all and also always report `canPublish: true`, so on those accounts a dry run confirms the request is well-formed rather than gating it.
19942
19959
  */
@@ -20125,6 +20142,10 @@ export type UpdatePostData = {
20125
20142
  * When omitted, the post keeps its current draft status. Send `false` to promote a draft to scheduled (combined with `scheduledFor`, `publishNow`, or a queue).
20126
20143
  */
20127
20144
  isDraft?: boolean;
20145
+ /**
20146
+ * Send true on a draft to submit it for approval: it becomes pending_approval and publishes only after POST /v1/posts/{postId}/review approves it. Cannot be combined with isDraft, publishNow, queuedFromProfile or queueId. Returns 409 when the post is not a draft.
20147
+ */
20148
+ requiresApproval?: boolean;
20128
20149
  timezone?: string;
20129
20150
  visibility?: 'public' | 'private' | 'unlisted';
20130
20151
  tags?: Array<(string)>;
@@ -20223,6 +20244,24 @@ export type RetryPostError = (ErrorResponse | {
20223
20244
  };
20224
20245
  });
20225
20246
 
20247
+ export type ReviewPostData = {
20248
+ body: {
20249
+ /**
20250
+ * approve schedules the post; reject returns it to draft.
20251
+ */
20252
+ decision: 'approve' | 'reject';
20253
+ };
20254
+ path: {
20255
+ postId: string;
20256
+ };
20257
+ };
20258
+
20259
+ export type ReviewPostResponse = (PostGetResponse);
20260
+
20261
+ export type ReviewPostError = (ErrorResponse | {
20262
+ error?: string;
20263
+ });
20264
+
20226
20265
  export type UnpublishPostData = {
20227
20266
  body: {
20228
20267
  /**