@zernio/node 0.2.1003 → 0.2.1005
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 +11 -14
- package/dist/index.d.ts +11 -14
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
- package/src/generated/sdk.gen.ts +16 -4
- package/src/generated/types.gen.ts +11 -14
package/dist/index.d.mts
CHANGED
|
@@ -5652,9 +5652,9 @@ type actionSource = 'web' | 'app' | 'offline' | 'crm' | 'phone_call' | 'system_g
|
|
|
5652
5652
|
* creative fields must NOT be set on this shape.
|
|
5653
5653
|
*
|
|
5654
5654
|
* Existing post references work on messaging and CTWA only (not call ads).
|
|
5655
|
-
* They cannot be combined with each other or with headline, body, imageUrl
|
|
5656
|
-
*
|
|
5657
|
-
* retained. Fresh creatives still require headline, body, and image or video.
|
|
5655
|
+
* They cannot be combined with each other or with headline, body, imageUrl
|
|
5656
|
+
* or video. `welcomeMessage` works on them (it lives on the ad, not the post).
|
|
5657
|
+
* No media is uploaded and the organic post is retained. Fresh creatives still require headline, body, and image or video.
|
|
5658
5658
|
*
|
|
5659
5659
|
* The route enforces this at the Zod boundary; OpenAPI's
|
|
5660
5660
|
* `required` cannot express the OR cleanly.
|
|
@@ -5691,7 +5691,7 @@ type CtwaAdRequestBody = {
|
|
|
5691
5691
|
*/
|
|
5692
5692
|
adSetName?: string;
|
|
5693
5693
|
/**
|
|
5694
|
-
* Messaging and CTWA only. Platform post or reel ID, the same input boostPost takes as platformPostId. Facebook IDs become object_story_id; Instagram IDs become source_instagram_media_id
|
|
5694
|
+
* Messaging and CTWA only. Platform post or reel ID, the same input boostPost takes as platformPostId. Facebook IDs become object_story_id; Instagram IDs become source_instagram_media_id run as the media owner (resolved from the media on a Meta ads business-login connection, so no Instagram connection is needed). Mutually exclusive with objectStoryId and fresh creative fields.
|
|
5695
5695
|
*/
|
|
5696
5696
|
platformPostId?: string;
|
|
5697
5697
|
/**
|
|
@@ -5803,7 +5803,7 @@ type CtwaAdRequestBody = {
|
|
|
5803
5803
|
*/
|
|
5804
5804
|
creatives?: Array<{
|
|
5805
5805
|
/**
|
|
5806
|
-
* Messaging and CTWA only. Platform post or reel ID, the same input boostPost takes as platformPostId. Facebook IDs become object_story_id; Instagram IDs become source_instagram_media_id
|
|
5806
|
+
* Messaging and CTWA only. Platform post or reel ID, the same input boostPost takes as platformPostId. Facebook IDs become object_story_id; Instagram IDs become source_instagram_media_id run as the media owner (resolved from the media on a Meta ads business-login connection, so no Instagram connection is needed). Mutually exclusive with objectStoryId and fresh creative fields.
|
|
5807
5807
|
*/
|
|
5808
5808
|
platformPostId?: string;
|
|
5809
5809
|
/**
|
|
@@ -12472,7 +12472,7 @@ type ValueRuleSet = {
|
|
|
12472
12472
|
type Verification = {
|
|
12473
12473
|
id?: string;
|
|
12474
12474
|
status?: 'pending' | 'approved' | 'expired' | 'max_attempts_reached' | 'canceled' | 'delivery_failed';
|
|
12475
|
-
channel?: 'sms';
|
|
12475
|
+
channel?: 'sms' | 'whatsapp';
|
|
12476
12476
|
to?: string;
|
|
12477
12477
|
expiresAt?: string;
|
|
12478
12478
|
attempts?: number;
|
|
@@ -12489,7 +12489,7 @@ type Verification = {
|
|
|
12489
12489
|
resend?: boolean;
|
|
12490
12490
|
};
|
|
12491
12491
|
type status29 = 'pending' | 'approved' | 'expired' | 'max_attempts_reached' | 'canceled' | 'delivery_failed';
|
|
12492
|
-
type channel4 = 'sms';
|
|
12492
|
+
type channel4 = 'sms' | 'whatsapp';
|
|
12493
12493
|
/**
|
|
12494
12494
|
* Individual webhook configuration for receiving real-time notifications
|
|
12495
12495
|
*/
|
|
@@ -51741,20 +51741,17 @@ type RunCommerceCatalogSyncError = (ErrorResponse | {
|
|
|
51741
51741
|
} | unknown);
|
|
51742
51742
|
type CreateVerificationData = {
|
|
51743
51743
|
body: {
|
|
51744
|
+
channel: 'sms' | 'whatsapp';
|
|
51744
51745
|
/**
|
|
51745
|
-
*
|
|
51746
|
-
*/
|
|
51747
|
-
channel: 'sms';
|
|
51748
|
-
/**
|
|
51749
|
-
* E.164 phone number.
|
|
51746
|
+
* E.164 phone number. WhatsApp only delivers to a phone number, never to a username.
|
|
51750
51747
|
*/
|
|
51751
51748
|
to: string;
|
|
51752
51749
|
/**
|
|
51753
|
-
* The
|
|
51750
|
+
* The number on your account to send from: an SMS-enabled number for `sms`, a connected WhatsApp number for `whatsapp`. Defaults to your only number on that channel.
|
|
51754
51751
|
*/
|
|
51755
51752
|
from?: string;
|
|
51756
51753
|
/**
|
|
51757
|
-
* Your app or business name, rendered in the message. Defaults to your account name. Letters, numbers, and basic punctuation only.
|
|
51754
|
+
* Your app or business name, rendered in the SMS message. Defaults to your account name. Not shown on WhatsApp, where Meta fixes the message and shows your WhatsApp display name. Letters, numbers, and basic punctuation only.
|
|
51758
51755
|
*/
|
|
51759
51756
|
brandName?: string;
|
|
51760
51757
|
codeLength?: number;
|
package/dist/index.d.ts
CHANGED
|
@@ -5652,9 +5652,9 @@ type actionSource = 'web' | 'app' | 'offline' | 'crm' | 'phone_call' | 'system_g
|
|
|
5652
5652
|
* creative fields must NOT be set on this shape.
|
|
5653
5653
|
*
|
|
5654
5654
|
* Existing post references work on messaging and CTWA only (not call ads).
|
|
5655
|
-
* They cannot be combined with each other or with headline, body, imageUrl
|
|
5656
|
-
*
|
|
5657
|
-
* retained. Fresh creatives still require headline, body, and image or video.
|
|
5655
|
+
* They cannot be combined with each other or with headline, body, imageUrl
|
|
5656
|
+
* or video. `welcomeMessage` works on them (it lives on the ad, not the post).
|
|
5657
|
+
* No media is uploaded and the organic post is retained. Fresh creatives still require headline, body, and image or video.
|
|
5658
5658
|
*
|
|
5659
5659
|
* The route enforces this at the Zod boundary; OpenAPI's
|
|
5660
5660
|
* `required` cannot express the OR cleanly.
|
|
@@ -5691,7 +5691,7 @@ type CtwaAdRequestBody = {
|
|
|
5691
5691
|
*/
|
|
5692
5692
|
adSetName?: string;
|
|
5693
5693
|
/**
|
|
5694
|
-
* Messaging and CTWA only. Platform post or reel ID, the same input boostPost takes as platformPostId. Facebook IDs become object_story_id; Instagram IDs become source_instagram_media_id
|
|
5694
|
+
* Messaging and CTWA only. Platform post or reel ID, the same input boostPost takes as platformPostId. Facebook IDs become object_story_id; Instagram IDs become source_instagram_media_id run as the media owner (resolved from the media on a Meta ads business-login connection, so no Instagram connection is needed). Mutually exclusive with objectStoryId and fresh creative fields.
|
|
5695
5695
|
*/
|
|
5696
5696
|
platformPostId?: string;
|
|
5697
5697
|
/**
|
|
@@ -5803,7 +5803,7 @@ type CtwaAdRequestBody = {
|
|
|
5803
5803
|
*/
|
|
5804
5804
|
creatives?: Array<{
|
|
5805
5805
|
/**
|
|
5806
|
-
* Messaging and CTWA only. Platform post or reel ID, the same input boostPost takes as platformPostId. Facebook IDs become object_story_id; Instagram IDs become source_instagram_media_id
|
|
5806
|
+
* Messaging and CTWA only. Platform post or reel ID, the same input boostPost takes as platformPostId. Facebook IDs become object_story_id; Instagram IDs become source_instagram_media_id run as the media owner (resolved from the media on a Meta ads business-login connection, so no Instagram connection is needed). Mutually exclusive with objectStoryId and fresh creative fields.
|
|
5807
5807
|
*/
|
|
5808
5808
|
platformPostId?: string;
|
|
5809
5809
|
/**
|
|
@@ -12472,7 +12472,7 @@ type ValueRuleSet = {
|
|
|
12472
12472
|
type Verification = {
|
|
12473
12473
|
id?: string;
|
|
12474
12474
|
status?: 'pending' | 'approved' | 'expired' | 'max_attempts_reached' | 'canceled' | 'delivery_failed';
|
|
12475
|
-
channel?: 'sms';
|
|
12475
|
+
channel?: 'sms' | 'whatsapp';
|
|
12476
12476
|
to?: string;
|
|
12477
12477
|
expiresAt?: string;
|
|
12478
12478
|
attempts?: number;
|
|
@@ -12489,7 +12489,7 @@ type Verification = {
|
|
|
12489
12489
|
resend?: boolean;
|
|
12490
12490
|
};
|
|
12491
12491
|
type status29 = 'pending' | 'approved' | 'expired' | 'max_attempts_reached' | 'canceled' | 'delivery_failed';
|
|
12492
|
-
type channel4 = 'sms';
|
|
12492
|
+
type channel4 = 'sms' | 'whatsapp';
|
|
12493
12493
|
/**
|
|
12494
12494
|
* Individual webhook configuration for receiving real-time notifications
|
|
12495
12495
|
*/
|
|
@@ -51741,20 +51741,17 @@ type RunCommerceCatalogSyncError = (ErrorResponse | {
|
|
|
51741
51741
|
} | unknown);
|
|
51742
51742
|
type CreateVerificationData = {
|
|
51743
51743
|
body: {
|
|
51744
|
+
channel: 'sms' | 'whatsapp';
|
|
51744
51745
|
/**
|
|
51745
|
-
*
|
|
51746
|
-
*/
|
|
51747
|
-
channel: 'sms';
|
|
51748
|
-
/**
|
|
51749
|
-
* E.164 phone number.
|
|
51746
|
+
* E.164 phone number. WhatsApp only delivers to a phone number, never to a username.
|
|
51750
51747
|
*/
|
|
51751
51748
|
to: string;
|
|
51752
51749
|
/**
|
|
51753
|
-
* The
|
|
51750
|
+
* The number on your account to send from: an SMS-enabled number for `sms`, a connected WhatsApp number for `whatsapp`. Defaults to your only number on that channel.
|
|
51754
51751
|
*/
|
|
51755
51752
|
from?: string;
|
|
51756
51753
|
/**
|
|
51757
|
-
* Your app or business name, rendered in the message. Defaults to your account name. Letters, numbers, and basic punctuation only.
|
|
51754
|
+
* Your app or business name, rendered in the SMS message. Defaults to your account name. Not shown on WhatsApp, where Meta fixes the message and shows your WhatsApp display name. Letters, numbers, and basic punctuation only.
|
|
51758
51755
|
*/
|
|
51759
51756
|
brandName?: string;
|
|
51760
51757
|
codeLength?: number;
|
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.1005",
|
|
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.1005",
|
|
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
|
@@ -15638,10 +15638,22 @@ export const runCommerceCatalogSync = <ThrowOnError extends boolean = false>(opt
|
|
|
15638
15638
|
* one per 60 seconds (429 with `retryAfterSeconds` inside the cooldown).
|
|
15639
15639
|
* The stored brandName/codeLength/ttlMinutes win on a resend.
|
|
15640
15640
|
*
|
|
15641
|
-
* Codes deliver
|
|
15642
|
-
*
|
|
15643
|
-
*
|
|
15644
|
-
*
|
|
15641
|
+
* Codes deliver from a number on your account (`from` optional when
|
|
15642
|
+
* you own exactly one number on the channel), always with a fixed
|
|
15643
|
+
* template:
|
|
15644
|
+
*
|
|
15645
|
+
* - `sms`: from an SMS-enabled number. Each accepted send bills one
|
|
15646
|
+
* verification fee plus the standard message rate.
|
|
15647
|
+
* - `whatsapp`: from a connected WhatsApp number, as a Meta
|
|
15648
|
+
* AUTHENTICATION template with a copy-code button. The first
|
|
15649
|
+
* WhatsApp verification on a WhatsApp Business Account creates the
|
|
15650
|
+
* `zernio_verify_code` template there and answers 422
|
|
15651
|
+
* `template_pending` until Meta approves it (usually minutes; retry
|
|
15652
|
+
* after `retryAfterSeconds`). Meta fixes the message text, so
|
|
15653
|
+
* `brandName` is not shown and the code's validity is not stated in
|
|
15654
|
+
* the message (`ttlMinutes` is still enforced). Each accepted send
|
|
15655
|
+
* bills one verification fee; Meta bills its authentication rate to
|
|
15656
|
+
* your WhatsApp Business Account.
|
|
15645
15657
|
*
|
|
15646
15658
|
*/
|
|
15647
15659
|
export const createVerification = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<CreateVerificationData, ThrowOnError>) => {
|
|
@@ -3861,9 +3861,9 @@ export type actionSource = 'web' | 'app' | 'offline' | 'crm' | 'phone_call' | 's
|
|
|
3861
3861
|
* creative fields must NOT be set on this shape.
|
|
3862
3862
|
*
|
|
3863
3863
|
* Existing post references work on messaging and CTWA only (not call ads).
|
|
3864
|
-
* They cannot be combined with each other or with headline, body, imageUrl
|
|
3865
|
-
*
|
|
3866
|
-
* retained. Fresh creatives still require headline, body, and image or video.
|
|
3864
|
+
* They cannot be combined with each other or with headline, body, imageUrl
|
|
3865
|
+
* or video. `welcomeMessage` works on them (it lives on the ad, not the post).
|
|
3866
|
+
* No media is uploaded and the organic post is retained. Fresh creatives still require headline, body, and image or video.
|
|
3867
3867
|
*
|
|
3868
3868
|
* The route enforces this at the Zod boundary; OpenAPI's
|
|
3869
3869
|
* `required` cannot express the OR cleanly.
|
|
@@ -3900,7 +3900,7 @@ export type CtwaAdRequestBody = {
|
|
|
3900
3900
|
*/
|
|
3901
3901
|
adSetName?: string;
|
|
3902
3902
|
/**
|
|
3903
|
-
* Messaging and CTWA only. Platform post or reel ID, the same input boostPost takes as platformPostId. Facebook IDs become object_story_id; Instagram IDs become source_instagram_media_id
|
|
3903
|
+
* Messaging and CTWA only. Platform post or reel ID, the same input boostPost takes as platformPostId. Facebook IDs become object_story_id; Instagram IDs become source_instagram_media_id run as the media owner (resolved from the media on a Meta ads business-login connection, so no Instagram connection is needed). Mutually exclusive with objectStoryId and fresh creative fields.
|
|
3904
3904
|
*/
|
|
3905
3905
|
platformPostId?: string;
|
|
3906
3906
|
/**
|
|
@@ -4012,7 +4012,7 @@ export type CtwaAdRequestBody = {
|
|
|
4012
4012
|
*/
|
|
4013
4013
|
creatives?: Array<{
|
|
4014
4014
|
/**
|
|
4015
|
-
* Messaging and CTWA only. Platform post or reel ID, the same input boostPost takes as platformPostId. Facebook IDs become object_story_id; Instagram IDs become source_instagram_media_id
|
|
4015
|
+
* Messaging and CTWA only. Platform post or reel ID, the same input boostPost takes as platformPostId. Facebook IDs become object_story_id; Instagram IDs become source_instagram_media_id run as the media owner (resolved from the media on a Meta ads business-login connection, so no Instagram connection is needed). Mutually exclusive with objectStoryId and fresh creative fields.
|
|
4016
4016
|
*/
|
|
4017
4017
|
platformPostId?: string;
|
|
4018
4018
|
/**
|
|
@@ -10993,7 +10993,7 @@ export type ValueRuleSet = {
|
|
|
10993
10993
|
export type Verification = {
|
|
10994
10994
|
id?: string;
|
|
10995
10995
|
status?: 'pending' | 'approved' | 'expired' | 'max_attempts_reached' | 'canceled' | 'delivery_failed';
|
|
10996
|
-
channel?: 'sms';
|
|
10996
|
+
channel?: 'sms' | 'whatsapp';
|
|
10997
10997
|
to?: string;
|
|
10998
10998
|
expiresAt?: string;
|
|
10999
10999
|
attempts?: number;
|
|
@@ -11012,7 +11012,7 @@ export type Verification = {
|
|
|
11012
11012
|
|
|
11013
11013
|
export type status29 = 'pending' | 'approved' | 'expired' | 'max_attempts_reached' | 'canceled' | 'delivery_failed';
|
|
11014
11014
|
|
|
11015
|
-
export type channel4 = 'sms';
|
|
11015
|
+
export type channel4 = 'sms' | 'whatsapp';
|
|
11016
11016
|
|
|
11017
11017
|
/**
|
|
11018
11018
|
* Individual webhook configuration for receiving real-time notifications
|
|
@@ -53165,20 +53165,17 @@ export type RunCommerceCatalogSyncError = (ErrorResponse | {
|
|
|
53165
53165
|
|
|
53166
53166
|
export type CreateVerificationData = {
|
|
53167
53167
|
body: {
|
|
53168
|
+
channel: 'sms' | 'whatsapp';
|
|
53168
53169
|
/**
|
|
53169
|
-
*
|
|
53170
|
-
*/
|
|
53171
|
-
channel: 'sms';
|
|
53172
|
-
/**
|
|
53173
|
-
* E.164 phone number.
|
|
53170
|
+
* E.164 phone number. WhatsApp only delivers to a phone number, never to a username.
|
|
53174
53171
|
*/
|
|
53175
53172
|
to: string;
|
|
53176
53173
|
/**
|
|
53177
|
-
* The
|
|
53174
|
+
* The number on your account to send from: an SMS-enabled number for `sms`, a connected WhatsApp number for `whatsapp`. Defaults to your only number on that channel.
|
|
53178
53175
|
*/
|
|
53179
53176
|
from?: string;
|
|
53180
53177
|
/**
|
|
53181
|
-
* Your app or business name, rendered in the message. Defaults to your account name. Letters, numbers, and basic punctuation only.
|
|
53178
|
+
* Your app or business name, rendered in the SMS message. Defaults to your account name. Not shown on WhatsApp, where Meta fixes the message and shows your WhatsApp display name. Letters, numbers, and basic punctuation only.
|
|
53182
53179
|
*/
|
|
53183
53180
|
brandName?: string;
|
|
53184
53181
|
codeLength?: number;
|