@zernio/node 0.2.307 → 0.2.309
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +35 -6
- package/dist/index.d.ts +35 -6
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
- package/src/generated/sdk.gen.ts +4 -0
- package/src/generated/types.gen.ts +35 -6
package/dist/index.d.mts
CHANGED
|
@@ -2574,6 +2574,10 @@ type InboxWebhookAccount = {
|
|
|
2574
2574
|
* Social account ID
|
|
2575
2575
|
*/
|
|
2576
2576
|
id: string;
|
|
2577
|
+
/**
|
|
2578
|
+
* Social account ID (same value as id). Canonical field so consumers can filter every webhook event on one field (e.g. route staging vs production by account). id is kept for backward compatibility.
|
|
2579
|
+
*/
|
|
2580
|
+
accountId?: string;
|
|
2577
2581
|
platform: string;
|
|
2578
2582
|
username: string;
|
|
2579
2583
|
displayName?: string;
|
|
@@ -4399,7 +4403,7 @@ type Webhook = {
|
|
|
4399
4403
|
/**
|
|
4400
4404
|
* Events subscribed to
|
|
4401
4405
|
*/
|
|
4402
|
-
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
4406
|
+
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
4403
4407
|
/**
|
|
4404
4408
|
* Whether webhook delivery is enabled
|
|
4405
4409
|
*/
|
|
@@ -5040,6 +5044,10 @@ type WebhookPayloadComment = {
|
|
|
5040
5044
|
* Social account ID
|
|
5041
5045
|
*/
|
|
5042
5046
|
id: string;
|
|
5047
|
+
/**
|
|
5048
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
5049
|
+
*/
|
|
5050
|
+
accountId?: string;
|
|
5043
5051
|
platform: string;
|
|
5044
5052
|
username: string;
|
|
5045
5053
|
};
|
|
@@ -5115,6 +5123,10 @@ type WebhookPayloadExternalPost = {
|
|
|
5115
5123
|
post: ExternalPostWebhookPost;
|
|
5116
5124
|
account: {
|
|
5117
5125
|
id: string;
|
|
5126
|
+
/**
|
|
5127
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
5128
|
+
*/
|
|
5129
|
+
accountId?: string;
|
|
5118
5130
|
platform: string;
|
|
5119
5131
|
username: string;
|
|
5120
5132
|
};
|
|
@@ -5174,6 +5186,10 @@ type WebhookPayloadLead = {
|
|
|
5174
5186
|
* Social account ID (the facebook account owning the Page)
|
|
5175
5187
|
*/
|
|
5176
5188
|
id: string;
|
|
5189
|
+
/**
|
|
5190
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
5191
|
+
*/
|
|
5192
|
+
accountId?: string;
|
|
5177
5193
|
platform: 'facebook';
|
|
5178
5194
|
};
|
|
5179
5195
|
timestamp: string;
|
|
@@ -5656,7 +5672,9 @@ type WebhookPayloadPost = {
|
|
|
5656
5672
|
type event18 = 'post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled';
|
|
5657
5673
|
/**
|
|
5658
5674
|
* Webhook payload for the per-platform terminal events
|
|
5659
|
-
* `post.platform.published` and `post.platform.failed
|
|
5675
|
+
* `post.platform.published` and `post.platform.failed`, and for
|
|
5676
|
+
* `post.tiktok.url_resolved` (same shape, fired when a published
|
|
5677
|
+
* TikTok post's public URL is backfilled). Terminal events fire once
|
|
5660
5678
|
* per platform target inside a post as that platform reaches a
|
|
5661
5679
|
* terminal state (published or permanent failure). The `post`
|
|
5662
5680
|
* envelope mirrors the shape of `WebhookPayloadPost` so consumers
|
|
@@ -5670,7 +5688,7 @@ type WebhookPayloadPostPlatform = {
|
|
|
5670
5688
|
* Stable webhook event ID.
|
|
5671
5689
|
*/
|
|
5672
5690
|
id: string;
|
|
5673
|
-
event: 'post.platform.published' | 'post.platform.failed';
|
|
5691
|
+
event: 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved';
|
|
5674
5692
|
post: {
|
|
5675
5693
|
id: string;
|
|
5676
5694
|
content: string;
|
|
@@ -5731,7 +5749,7 @@ type WebhookPayloadPostPlatform = {
|
|
|
5731
5749
|
};
|
|
5732
5750
|
timestamp: string;
|
|
5733
5751
|
};
|
|
5734
|
-
type event19 = 'post.platform.published' | 'post.platform.failed';
|
|
5752
|
+
type event19 = 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved';
|
|
5735
5753
|
/**
|
|
5736
5754
|
* Webhook payload for reaction received events (WhatsApp, Telegram)
|
|
5737
5755
|
*/
|
|
@@ -5794,6 +5812,10 @@ type WebhookPayloadReviewNew = {
|
|
|
5794
5812
|
review: ReviewWebhookReview;
|
|
5795
5813
|
account: {
|
|
5796
5814
|
id: string;
|
|
5815
|
+
/**
|
|
5816
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
5817
|
+
*/
|
|
5818
|
+
accountId?: string;
|
|
5797
5819
|
platform: string;
|
|
5798
5820
|
username: string;
|
|
5799
5821
|
};
|
|
@@ -5816,6 +5838,10 @@ type WebhookPayloadReviewUpdated = {
|
|
|
5816
5838
|
review: ReviewWebhookReview;
|
|
5817
5839
|
account: {
|
|
5818
5840
|
id: string;
|
|
5841
|
+
/**
|
|
5842
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
5843
|
+
*/
|
|
5844
|
+
accountId?: string;
|
|
5819
5845
|
platform: string;
|
|
5820
5846
|
username: string;
|
|
5821
5847
|
};
|
|
@@ -8139,6 +8165,9 @@ type UpdatePostData = {
|
|
|
8139
8165
|
}>;
|
|
8140
8166
|
scheduledFor?: string;
|
|
8141
8167
|
publishNow?: boolean;
|
|
8168
|
+
/**
|
|
8169
|
+
* When omitted, the post keeps its current draft status. Send `false` to promote a draft to scheduled (combined with `scheduledFor`, `publishNow`, or a queue).
|
|
8170
|
+
*/
|
|
8142
8171
|
isDraft?: boolean;
|
|
8143
8172
|
timezone?: string;
|
|
8144
8173
|
visibility?: 'public' | 'private' | 'unlisted';
|
|
@@ -12360,7 +12389,7 @@ type CreateWebhookSettingsData = {
|
|
|
12360
12389
|
/**
|
|
12361
12390
|
* Events to subscribe to (at least one required)
|
|
12362
12391
|
*/
|
|
12363
|
-
events: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
12392
|
+
events: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
12364
12393
|
/**
|
|
12365
12394
|
* Enable or disable webhook delivery. Defaults to `true` when omitted.
|
|
12366
12395
|
*/
|
|
@@ -12401,7 +12430,7 @@ type UpdateWebhookSettingsData = {
|
|
|
12401
12430
|
/**
|
|
12402
12431
|
* Events to subscribe to. Must contain at least one event if provided.
|
|
12403
12432
|
*/
|
|
12404
|
-
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
12433
|
+
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
12405
12434
|
/**
|
|
12406
12435
|
* Enable or disable webhook delivery
|
|
12407
12436
|
*/
|
package/dist/index.d.ts
CHANGED
|
@@ -2574,6 +2574,10 @@ type InboxWebhookAccount = {
|
|
|
2574
2574
|
* Social account ID
|
|
2575
2575
|
*/
|
|
2576
2576
|
id: string;
|
|
2577
|
+
/**
|
|
2578
|
+
* Social account ID (same value as id). Canonical field so consumers can filter every webhook event on one field (e.g. route staging vs production by account). id is kept for backward compatibility.
|
|
2579
|
+
*/
|
|
2580
|
+
accountId?: string;
|
|
2577
2581
|
platform: string;
|
|
2578
2582
|
username: string;
|
|
2579
2583
|
displayName?: string;
|
|
@@ -4399,7 +4403,7 @@ type Webhook = {
|
|
|
4399
4403
|
/**
|
|
4400
4404
|
* Events subscribed to
|
|
4401
4405
|
*/
|
|
4402
|
-
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
4406
|
+
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
4403
4407
|
/**
|
|
4404
4408
|
* Whether webhook delivery is enabled
|
|
4405
4409
|
*/
|
|
@@ -5040,6 +5044,10 @@ type WebhookPayloadComment = {
|
|
|
5040
5044
|
* Social account ID
|
|
5041
5045
|
*/
|
|
5042
5046
|
id: string;
|
|
5047
|
+
/**
|
|
5048
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
5049
|
+
*/
|
|
5050
|
+
accountId?: string;
|
|
5043
5051
|
platform: string;
|
|
5044
5052
|
username: string;
|
|
5045
5053
|
};
|
|
@@ -5115,6 +5123,10 @@ type WebhookPayloadExternalPost = {
|
|
|
5115
5123
|
post: ExternalPostWebhookPost;
|
|
5116
5124
|
account: {
|
|
5117
5125
|
id: string;
|
|
5126
|
+
/**
|
|
5127
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
5128
|
+
*/
|
|
5129
|
+
accountId?: string;
|
|
5118
5130
|
platform: string;
|
|
5119
5131
|
username: string;
|
|
5120
5132
|
};
|
|
@@ -5174,6 +5186,10 @@ type WebhookPayloadLead = {
|
|
|
5174
5186
|
* Social account ID (the facebook account owning the Page)
|
|
5175
5187
|
*/
|
|
5176
5188
|
id: string;
|
|
5189
|
+
/**
|
|
5190
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
5191
|
+
*/
|
|
5192
|
+
accountId?: string;
|
|
5177
5193
|
platform: 'facebook';
|
|
5178
5194
|
};
|
|
5179
5195
|
timestamp: string;
|
|
@@ -5656,7 +5672,9 @@ type WebhookPayloadPost = {
|
|
|
5656
5672
|
type event18 = 'post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled';
|
|
5657
5673
|
/**
|
|
5658
5674
|
* Webhook payload for the per-platform terminal events
|
|
5659
|
-
* `post.platform.published` and `post.platform.failed
|
|
5675
|
+
* `post.platform.published` and `post.platform.failed`, and for
|
|
5676
|
+
* `post.tiktok.url_resolved` (same shape, fired when a published
|
|
5677
|
+
* TikTok post's public URL is backfilled). Terminal events fire once
|
|
5660
5678
|
* per platform target inside a post as that platform reaches a
|
|
5661
5679
|
* terminal state (published or permanent failure). The `post`
|
|
5662
5680
|
* envelope mirrors the shape of `WebhookPayloadPost` so consumers
|
|
@@ -5670,7 +5688,7 @@ type WebhookPayloadPostPlatform = {
|
|
|
5670
5688
|
* Stable webhook event ID.
|
|
5671
5689
|
*/
|
|
5672
5690
|
id: string;
|
|
5673
|
-
event: 'post.platform.published' | 'post.platform.failed';
|
|
5691
|
+
event: 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved';
|
|
5674
5692
|
post: {
|
|
5675
5693
|
id: string;
|
|
5676
5694
|
content: string;
|
|
@@ -5731,7 +5749,7 @@ type WebhookPayloadPostPlatform = {
|
|
|
5731
5749
|
};
|
|
5732
5750
|
timestamp: string;
|
|
5733
5751
|
};
|
|
5734
|
-
type event19 = 'post.platform.published' | 'post.platform.failed';
|
|
5752
|
+
type event19 = 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved';
|
|
5735
5753
|
/**
|
|
5736
5754
|
* Webhook payload for reaction received events (WhatsApp, Telegram)
|
|
5737
5755
|
*/
|
|
@@ -5794,6 +5812,10 @@ type WebhookPayloadReviewNew = {
|
|
|
5794
5812
|
review: ReviewWebhookReview;
|
|
5795
5813
|
account: {
|
|
5796
5814
|
id: string;
|
|
5815
|
+
/**
|
|
5816
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
5817
|
+
*/
|
|
5818
|
+
accountId?: string;
|
|
5797
5819
|
platform: string;
|
|
5798
5820
|
username: string;
|
|
5799
5821
|
};
|
|
@@ -5816,6 +5838,10 @@ type WebhookPayloadReviewUpdated = {
|
|
|
5816
5838
|
review: ReviewWebhookReview;
|
|
5817
5839
|
account: {
|
|
5818
5840
|
id: string;
|
|
5841
|
+
/**
|
|
5842
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
5843
|
+
*/
|
|
5844
|
+
accountId?: string;
|
|
5819
5845
|
platform: string;
|
|
5820
5846
|
username: string;
|
|
5821
5847
|
};
|
|
@@ -8139,6 +8165,9 @@ type UpdatePostData = {
|
|
|
8139
8165
|
}>;
|
|
8140
8166
|
scheduledFor?: string;
|
|
8141
8167
|
publishNow?: boolean;
|
|
8168
|
+
/**
|
|
8169
|
+
* When omitted, the post keeps its current draft status. Send `false` to promote a draft to scheduled (combined with `scheduledFor`, `publishNow`, or a queue).
|
|
8170
|
+
*/
|
|
8142
8171
|
isDraft?: boolean;
|
|
8143
8172
|
timezone?: string;
|
|
8144
8173
|
visibility?: 'public' | 'private' | 'unlisted';
|
|
@@ -12360,7 +12389,7 @@ type CreateWebhookSettingsData = {
|
|
|
12360
12389
|
/**
|
|
12361
12390
|
* Events to subscribe to (at least one required)
|
|
12362
12391
|
*/
|
|
12363
|
-
events: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
12392
|
+
events: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
12364
12393
|
/**
|
|
12365
12394
|
* Enable or disable webhook delivery. Defaults to `true` when omitted.
|
|
12366
12395
|
*/
|
|
@@ -12401,7 +12430,7 @@ type UpdateWebhookSettingsData = {
|
|
|
12401
12430
|
/**
|
|
12402
12431
|
* Events to subscribe to. Must contain at least one event if provided.
|
|
12403
12432
|
*/
|
|
12404
|
-
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
12433
|
+
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
12405
12434
|
/**
|
|
12406
12435
|
* Enable or disable webhook delivery
|
|
12407
12436
|
*/
|
package/dist/index.js
CHANGED
|
@@ -36,7 +36,7 @@ module.exports = __toCommonJS(index_exports);
|
|
|
36
36
|
// package.json
|
|
37
37
|
var package_default = {
|
|
38
38
|
name: "@zernio/node",
|
|
39
|
-
version: "0.2.
|
|
39
|
+
version: "0.2.309",
|
|
40
40
|
description: "The official Node.js library for the Zernio API",
|
|
41
41
|
main: "dist/index.js",
|
|
42
42
|
module: "dist/index.mjs",
|
package/dist/index.mjs
CHANGED
|
@@ -5,7 +5,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
5
5
|
// package.json
|
|
6
6
|
var package_default = {
|
|
7
7
|
name: "@zernio/node",
|
|
8
|
-
version: "0.2.
|
|
8
|
+
version: "0.2.309",
|
|
9
9
|
description: "The official Node.js library for the Zernio API",
|
|
10
10
|
main: "dist/index.js",
|
|
11
11
|
module: "dist/index.mjs",
|
package/package.json
CHANGED
package/src/generated/sdk.gen.ts
CHANGED
|
@@ -730,6 +730,10 @@ export const getPost = <ThrowOnError extends boolean = false>(options: OptionsLe
|
|
|
730
730
|
* Update an existing post. Draft, scheduled, failed, partial, and cancelled posts can be edited.
|
|
731
731
|
* Published posts can only have their recycling config updated.
|
|
732
732
|
*
|
|
733
|
+
* To promote a draft to scheduled, send `isDraft: false` together with `scheduledFor` (or `publishNow: true`,
|
|
734
|
+
* or `queuedFromProfile`). If `isDraft` is omitted the post keeps its current draft status, so sending only
|
|
735
|
+
* `scheduledFor` to a draft returns 200 but the post remains a draft.
|
|
736
|
+
*
|
|
733
737
|
*/
|
|
734
738
|
export const updatePost = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<UpdatePostData, ThrowOnError>) => {
|
|
735
739
|
return (options?.client ?? client).put<UpdatePostResponse, UpdatePostError, ThrowOnError>({
|
|
@@ -1864,6 +1864,10 @@ export type InboxWebhookAccount = {
|
|
|
1864
1864
|
* Social account ID
|
|
1865
1865
|
*/
|
|
1866
1866
|
id: string;
|
|
1867
|
+
/**
|
|
1868
|
+
* Social account ID (same value as id). Canonical field so consumers can filter every webhook event on one field (e.g. route staging vs production by account). id is kept for backward compatibility.
|
|
1869
|
+
*/
|
|
1870
|
+
accountId?: string;
|
|
1867
1871
|
platform: string;
|
|
1868
1872
|
username: string;
|
|
1869
1873
|
displayName?: string;
|
|
@@ -3784,7 +3788,7 @@ export type Webhook = {
|
|
|
3784
3788
|
/**
|
|
3785
3789
|
* Events subscribed to
|
|
3786
3790
|
*/
|
|
3787
|
-
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
3791
|
+
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
3788
3792
|
/**
|
|
3789
3793
|
* Whether webhook delivery is enabled
|
|
3790
3794
|
*/
|
|
@@ -4451,6 +4455,10 @@ export type WebhookPayloadComment = {
|
|
|
4451
4455
|
* Social account ID
|
|
4452
4456
|
*/
|
|
4453
4457
|
id: string;
|
|
4458
|
+
/**
|
|
4459
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
4460
|
+
*/
|
|
4461
|
+
accountId?: string;
|
|
4454
4462
|
platform: string;
|
|
4455
4463
|
username: string;
|
|
4456
4464
|
};
|
|
@@ -4532,6 +4540,10 @@ export type WebhookPayloadExternalPost = {
|
|
|
4532
4540
|
post: ExternalPostWebhookPost;
|
|
4533
4541
|
account: {
|
|
4534
4542
|
id: string;
|
|
4543
|
+
/**
|
|
4544
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
4545
|
+
*/
|
|
4546
|
+
accountId?: string;
|
|
4535
4547
|
platform: string;
|
|
4536
4548
|
username: string;
|
|
4537
4549
|
};
|
|
@@ -4593,6 +4605,10 @@ export type WebhookPayloadLead = {
|
|
|
4593
4605
|
* Social account ID (the facebook account owning the Page)
|
|
4594
4606
|
*/
|
|
4595
4607
|
id: string;
|
|
4608
|
+
/**
|
|
4609
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
4610
|
+
*/
|
|
4611
|
+
accountId?: string;
|
|
4596
4612
|
platform: 'facebook';
|
|
4597
4613
|
};
|
|
4598
4614
|
timestamp: string;
|
|
@@ -5091,7 +5107,9 @@ export type event18 = 'post.scheduled' | 'post.published' | 'post.failed' | 'pos
|
|
|
5091
5107
|
|
|
5092
5108
|
/**
|
|
5093
5109
|
* Webhook payload for the per-platform terminal events
|
|
5094
|
-
* `post.platform.published` and `post.platform.failed
|
|
5110
|
+
* `post.platform.published` and `post.platform.failed`, and for
|
|
5111
|
+
* `post.tiktok.url_resolved` (same shape, fired when a published
|
|
5112
|
+
* TikTok post's public URL is backfilled). Terminal events fire once
|
|
5095
5113
|
* per platform target inside a post as that platform reaches a
|
|
5096
5114
|
* terminal state (published or permanent failure). The `post`
|
|
5097
5115
|
* envelope mirrors the shape of `WebhookPayloadPost` so consumers
|
|
@@ -5105,7 +5123,7 @@ export type WebhookPayloadPostPlatform = {
|
|
|
5105
5123
|
* Stable webhook event ID.
|
|
5106
5124
|
*/
|
|
5107
5125
|
id: string;
|
|
5108
|
-
event: 'post.platform.published' | 'post.platform.failed';
|
|
5126
|
+
event: 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved';
|
|
5109
5127
|
post: {
|
|
5110
5128
|
id: string;
|
|
5111
5129
|
content: string;
|
|
@@ -5167,7 +5185,7 @@ export type WebhookPayloadPostPlatform = {
|
|
|
5167
5185
|
timestamp: string;
|
|
5168
5186
|
};
|
|
5169
5187
|
|
|
5170
|
-
export type event19 = 'post.platform.published' | 'post.platform.failed';
|
|
5188
|
+
export type event19 = 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved';
|
|
5171
5189
|
|
|
5172
5190
|
/**
|
|
5173
5191
|
* Webhook payload for reaction received events (WhatsApp, Telegram)
|
|
@@ -5234,6 +5252,10 @@ export type WebhookPayloadReviewNew = {
|
|
|
5234
5252
|
review: ReviewWebhookReview;
|
|
5235
5253
|
account: {
|
|
5236
5254
|
id: string;
|
|
5255
|
+
/**
|
|
5256
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
5257
|
+
*/
|
|
5258
|
+
accountId?: string;
|
|
5237
5259
|
platform: string;
|
|
5238
5260
|
username: string;
|
|
5239
5261
|
};
|
|
@@ -5258,6 +5280,10 @@ export type WebhookPayloadReviewUpdated = {
|
|
|
5258
5280
|
review: ReviewWebhookReview;
|
|
5259
5281
|
account: {
|
|
5260
5282
|
id: string;
|
|
5283
|
+
/**
|
|
5284
|
+
* Social account ID (same as id); canonical field for account filtering.
|
|
5285
|
+
*/
|
|
5286
|
+
accountId?: string;
|
|
5261
5287
|
platform: string;
|
|
5262
5288
|
username: string;
|
|
5263
5289
|
};
|
|
@@ -7737,6 +7763,9 @@ export type UpdatePostData = {
|
|
|
7737
7763
|
}>;
|
|
7738
7764
|
scheduledFor?: string;
|
|
7739
7765
|
publishNow?: boolean;
|
|
7766
|
+
/**
|
|
7767
|
+
* When omitted, the post keeps its current draft status. Send `false` to promote a draft to scheduled (combined with `scheduledFor`, `publishNow`, or a queue).
|
|
7768
|
+
*/
|
|
7740
7769
|
isDraft?: boolean;
|
|
7741
7770
|
timezone?: string;
|
|
7742
7771
|
visibility?: 'public' | 'private' | 'unlisted';
|
|
@@ -12297,7 +12326,7 @@ export type CreateWebhookSettingsData = {
|
|
|
12297
12326
|
/**
|
|
12298
12327
|
* Events to subscribe to (at least one required)
|
|
12299
12328
|
*/
|
|
12300
|
-
events: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
12329
|
+
events: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
12301
12330
|
/**
|
|
12302
12331
|
* Enable or disable webhook delivery. Defaults to `true` when omitted.
|
|
12303
12332
|
*/
|
|
@@ -12341,7 +12370,7 @@ export type UpdateWebhookSettingsData = {
|
|
|
12341
12370
|
/**
|
|
12342
12371
|
* Events to subscribe to. Must contain at least one event if provided.
|
|
12343
12372
|
*/
|
|
12344
|
-
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
12373
|
+
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'post.cancelled' | 'post.recycled' | 'post.platform.published' | 'post.platform.failed' | 'post.tiktok.url_resolved' | 'post.external.created' | 'post.external.updated' | 'post.external.deleted' | 'account.connected' | 'account.disconnected' | 'account.ads.initial_sync_completed' | 'message.received' | 'message.sent' | 'message.edited' | 'message.deleted' | 'message.delivered' | 'message.read' | 'message.failed' | 'reaction.received' | 'comment.received' | 'review.new' | 'review.updated' | 'ad.status_changed' | 'whatsapp.template.status_updated' | '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')>;
|
|
12345
12374
|
/**
|
|
12346
12375
|
* Enable or disable webhook delivery
|
|
12347
12376
|
*/
|