@getlatedev/node 0.2.1338 → 0.2.1340
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 +65 -1
- package/dist/index.d.ts +65 -1
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
- package/src/generated/sdk.gen.ts +2 -2
- package/src/generated/types.gen.ts +67 -0
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: "@getlatedev/node",
|
|
39
|
-
version: "0.2.
|
|
39
|
+
version: "0.2.1340",
|
|
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: "@getlatedev/node",
|
|
8
|
-
version: "0.2.
|
|
8
|
+
version: "0.2.1340",
|
|
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
|
@@ -11205,8 +11205,8 @@ export const duplicateAd = <ThrowOnError extends boolean = false>(options: Optio
|
|
|
11205
11205
|
*
|
|
11206
11206
|
* Reads the ad set live from Meta, returned verbatim. The default projection includes
|
|
11207
11207
|
* `learning_stage_info` (learning-phase status: LEARNING / SUCCESS / FAIL / WAIVING; Meta
|
|
11208
|
-
* omits its `status` key on paused ad sets), delivery settings, budgets, schedule
|
|
11209
|
-
* targeting. `fields` is a raw-passthrough override; unknown fields return Meta's 400
|
|
11208
|
+
* omits its `status` key on paused ad sets), delivery settings, budgets, schedule, dayparting
|
|
11209
|
+
* (`adset_schedule`, `pacing_type`) and targeting. `fields` is a raw-passthrough override; unknown fields return Meta's 400
|
|
11210
11210
|
* verbatim.
|
|
11211
11211
|
*/
|
|
11212
11212
|
export const getAdSetDetails = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<GetAdSetDetailsData, ThrowOnError>) => {
|
|
@@ -1105,6 +1105,7 @@ export type AdLead = {
|
|
|
1105
1105
|
fieldData?: Array<{
|
|
1106
1106
|
[key: string]: unknown;
|
|
1107
1107
|
}>;
|
|
1108
|
+
consents?: AdLeadConsents;
|
|
1108
1109
|
/**
|
|
1109
1110
|
* Meta leads only. `contacted` is set when the first WhatsApp message of a lead_received workflow is delivered, `unreachable` when it fails or the phone number is not valid.
|
|
1110
1111
|
*/
|
|
@@ -1127,6 +1128,22 @@ export type AdLead = {
|
|
|
1127
1128
|
*/
|
|
1128
1129
|
export type status2 = 'new' | 'contacted' | 'unreachable' | 'qualified' | 'converted' | 'disqualified';
|
|
1129
1130
|
|
|
1131
|
+
/**
|
|
1132
|
+
* One custom disclaimer checkbox on a Meta lead form (for example a TCPA call or SMS consent), as Meta returns it in custom_disclaimer_responses.
|
|
1133
|
+
*/
|
|
1134
|
+
export type AdLeadConsent = {
|
|
1135
|
+
/**
|
|
1136
|
+
* The checkbox key as Meta returns it: the one set in platformSpecificData.customDisclaimer.checkboxes[].key on POST /v1/ads/lead-forms, or otherwise a key Meta derives from the checkbox text, which can be long and contain spaces and punctuation.
|
|
1137
|
+
*/
|
|
1138
|
+
checkboxKey: string;
|
|
1139
|
+
isChecked: boolean;
|
|
1140
|
+
};
|
|
1141
|
+
|
|
1142
|
+
/**
|
|
1143
|
+
* Meta lead forms only: the answer to every custom disclaimer checkbox, required or optional. Empty when the form has none, and may be empty on leads stored before 2026-10-22. LinkedIn leads do not carry the field.
|
|
1144
|
+
*/
|
|
1145
|
+
export type AdLeadConsents = Array<AdLeadConsent>;
|
|
1146
|
+
|
|
1130
1147
|
export type AdMetrics = {
|
|
1131
1148
|
spend?: number;
|
|
1132
1149
|
impressions?: number;
|
|
@@ -10088,6 +10105,27 @@ export type MessengerIceBreakerLocale = {
|
|
|
10088
10105
|
}>;
|
|
10089
10106
|
};
|
|
10090
10107
|
|
|
10108
|
+
/**
|
|
10109
|
+
* Meta ad set dayparting: the hours the ad set delivers, in whole hours. Same `dayOfWeek` /
|
|
10110
|
+
* `startHour` / `endHour` naming as the Google `PUT /v1/ads/campaigns/{campaignId}/ad-schedule`,
|
|
10111
|
+
* but Meta has no minutes and no bid modifiers. Windows on one day must not overlap (adjacent is
|
|
10112
|
+
* fine) and every window must use the same `timezoneType`. Invalid windows are a 400 on
|
|
10113
|
+
* `platformSpecificData.adSchedule`.
|
|
10114
|
+
*
|
|
10115
|
+
*/
|
|
10116
|
+
export type MetaAdSchedule = Array<{
|
|
10117
|
+
dayOfWeek: 'MONDAY' | 'TUESDAY' | 'WEDNESDAY' | 'THURSDAY' | 'FRIDAY' | 'SATURDAY' | 'SUNDAY';
|
|
10118
|
+
startHour: number;
|
|
10119
|
+
/**
|
|
10120
|
+
* Must be after startHour. 24 is midnight at the end of the day.
|
|
10121
|
+
*/
|
|
10122
|
+
endHour: number;
|
|
10123
|
+
/**
|
|
10124
|
+
* Meta `timezone_type`: USER runs the hours in each viewer's time zone, ADVERTISER in the ad account time zone.
|
|
10125
|
+
*/
|
|
10126
|
+
timezoneType?: 'USER' | 'ADVERTISER';
|
|
10127
|
+
}>;
|
|
10128
|
+
|
|
10091
10129
|
/**
|
|
10092
10130
|
* Meta (facebook/instagram) options for platformSpecificData on POST /v1/ads/boost and /v1/ads/create. Unknown keys are rejected, not dropped.
|
|
10093
10131
|
*/
|
|
@@ -10110,6 +10148,15 @@ export type MetaAdsPlatformData = {
|
|
|
10110
10148
|
*/
|
|
10111
10149
|
lifetimeMinSpendTarget?: number;
|
|
10112
10150
|
customerLifecycle?: MetaCustomerLifecycle;
|
|
10151
|
+
/**
|
|
10152
|
+
* Dayparting on the ad set being created (Meta `adset_schedule` with `pacing_type: ["day_parting"]`).
|
|
10153
|
+
* Meta runs a schedule only on a LIFETIME budget, so a daily budget (on the ad set, or on the
|
|
10154
|
+
* campaign joined with `existingCampaignId`) is a 400 with `param: platformSpecificData.adSchedule`.
|
|
10155
|
+
* Also a 400 when empty, in adSetId attach mode and with `buyingType: RESERVED`. Change it later with
|
|
10156
|
+
* `PUT /v1/ads/ad-sets/{adSetId}`.
|
|
10157
|
+
*
|
|
10158
|
+
*/
|
|
10159
|
+
adSchedule?: (MetaAdSchedule);
|
|
10113
10160
|
};
|
|
10114
10161
|
|
|
10115
10162
|
export type MetaAssignedUser = {
|
|
@@ -15949,6 +15996,10 @@ export type WebhookPayloadLead = {
|
|
|
15949
15996
|
fields: {
|
|
15950
15997
|
[key: string]: (string);
|
|
15951
15998
|
};
|
|
15999
|
+
/**
|
|
16000
|
+
* Sent on every delivery since 2026-10-25. Absent when an older event is redelivered, since redeliveries replay the stored payload.
|
|
16001
|
+
*/
|
|
16002
|
+
consents?: (AdLeadConsents);
|
|
15952
16003
|
/**
|
|
15953
16004
|
* True when the lead came from an organic post rather than a paid ad
|
|
15954
16005
|
*/
|
|
@@ -46197,6 +46248,17 @@ export type UpdateAdSetData = {
|
|
|
46197
46248
|
*/
|
|
46198
46249
|
lifetimeMinSpendTarget?: number;
|
|
46199
46250
|
customerLifecycle?: MetaCustomerLifecycle;
|
|
46251
|
+
/**
|
|
46252
|
+
* Replaces the ad set's dayparting (Meta `adset_schedule`, `pacing_type: ["day_parting"]`).
|
|
46253
|
+
* Meta runs a schedule only on a lifetime budget. Before anything in the request is written,
|
|
46254
|
+
* Zernio takes `budget.type` from the same request or reads the ad set's budget (or its
|
|
46255
|
+
* campaign's under Advantage campaign budget), and a daily one is a 400 with
|
|
46256
|
+
* `param: platformSpecificData.adSchedule`. An empty array removes the schedule
|
|
46257
|
+
* (`pacing_type: ["standard"]`). Read it back with `GET /v1/ads/ad-sets/{adSetId}`
|
|
46258
|
+
* (`adset_schedule`, `pacing_type`) or as `adSchedule` on `GET /v1/ads/accounts/live`.
|
|
46259
|
+
*
|
|
46260
|
+
*/
|
|
46261
|
+
adSchedule?: (MetaAdSchedule);
|
|
46200
46262
|
/**
|
|
46201
46263
|
* Meta ad-set promoted_object (same shape as /v1/ads/create). Meta makes promoted_object immutable once the ad set exists, so only `pixelId`, `customEventType`, `customEventStr` (with `customEventType` OTHER), `applicationId` and `productCatalogId` can be sent here. Any other key (`pageId`, `whatsappPhoneNumber`, `customConversionId`, `objectStoreUrl`, `productSetId`, `offlineConversionDataSetId`) is a 400 with `param: platformSpecificData.promotedObject` and nothing is written; changing them needs a new ad set (POST /v1/ads/create). Unknown keys are rejected with 400.
|
|
46202
46264
|
*/
|
|
@@ -51003,6 +51065,10 @@ export type GetAdAccountLiveEntitiesResponse = ({
|
|
|
51003
51065
|
*/
|
|
51004
51066
|
endDate?: string;
|
|
51005
51067
|
} | null;
|
|
51068
|
+
/**
|
|
51069
|
+
* Meta only. The ad set's dayparting (`adset_schedule`) in the `platformSpecificData.adSchedule` shape, one window per day (a window Meta stores off the hour is widened to whole hours). Null when the ad set runs around the clock. Absent on TikTok.
|
|
51070
|
+
*/
|
|
51071
|
+
adSchedule?: (MetaAdSchedule | null);
|
|
51006
51072
|
}>;
|
|
51007
51073
|
/**
|
|
51008
51074
|
* One entry per level read. `after` is null on the last page.
|
|
@@ -53738,6 +53804,7 @@ export type ListFormLeadsResponse = ({
|
|
|
53738
53804
|
fieldData?: Array<{
|
|
53739
53805
|
[key: string]: unknown;
|
|
53740
53806
|
}>;
|
|
53807
|
+
consents?: AdLeadConsents;
|
|
53741
53808
|
}>;
|
|
53742
53809
|
pagination?: {
|
|
53743
53810
|
hasMore?: boolean;
|