@getlatedev/node 0.2.1236 → 0.2.1238
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 +21 -0
- package/dist/index.d.ts +21 -0
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
- package/src/generated/sdk.gen.ts +3 -1
- package/src/generated/types.gen.ts +21 -0
package/dist/index.d.mts
CHANGED
|
@@ -49248,6 +49248,13 @@ type ListLeadsResponse = ({
|
|
|
49248
49248
|
hasMore?: boolean;
|
|
49249
49249
|
cursor?: (string) | null;
|
|
49250
49250
|
};
|
|
49251
|
+
meta?: {
|
|
49252
|
+
/**
|
|
49253
|
+
* Meta only, present when `accountId` is passed: when Zernio last re-read the Page's forms from Meta to catch leads the webhook missed. Null when no leads matched or before the first pass.
|
|
49254
|
+
*/
|
|
49255
|
+
lastCheckedAt?: (string) | null;
|
|
49256
|
+
lastUpdated?: string;
|
|
49257
|
+
};
|
|
49251
49258
|
});
|
|
49252
49259
|
type ListLeadsError = (ErrorResponse | unknown);
|
|
49253
49260
|
type ListLeadFormsData = {
|
|
@@ -49535,6 +49542,20 @@ type ListFormLeadsResponse = ({
|
|
|
49535
49542
|
hasMore?: boolean;
|
|
49536
49543
|
cursor?: (string) | null;
|
|
49537
49544
|
};
|
|
49545
|
+
meta?: {
|
|
49546
|
+
platform?: string;
|
|
49547
|
+
accountId?: string;
|
|
49548
|
+
formId?: string;
|
|
49549
|
+
/**
|
|
49550
|
+
* persisted: leads stored from the webhook and the reconcile pass. live: read from Meta because none are stored for this form yet.
|
|
49551
|
+
*/
|
|
49552
|
+
source?: 'persisted' | 'live';
|
|
49553
|
+
/**
|
|
49554
|
+
* When Zernio last read this form's leads from Meta. For persisted leads, the last reconcile pass for the Page (null before the first one). For live reads, when the cached Graph read was made.
|
|
49555
|
+
*/
|
|
49556
|
+
lastCheckedAt?: (string) | null;
|
|
49557
|
+
lastUpdated?: string;
|
|
49558
|
+
};
|
|
49538
49559
|
});
|
|
49539
49560
|
type ListFormLeadsError = (ErrorResponse);
|
|
49540
49561
|
type CreateTestLeadData = {
|
package/dist/index.d.ts
CHANGED
|
@@ -49248,6 +49248,13 @@ type ListLeadsResponse = ({
|
|
|
49248
49248
|
hasMore?: boolean;
|
|
49249
49249
|
cursor?: (string) | null;
|
|
49250
49250
|
};
|
|
49251
|
+
meta?: {
|
|
49252
|
+
/**
|
|
49253
|
+
* Meta only, present when `accountId` is passed: when Zernio last re-read the Page's forms from Meta to catch leads the webhook missed. Null when no leads matched or before the first pass.
|
|
49254
|
+
*/
|
|
49255
|
+
lastCheckedAt?: (string) | null;
|
|
49256
|
+
lastUpdated?: string;
|
|
49257
|
+
};
|
|
49251
49258
|
});
|
|
49252
49259
|
type ListLeadsError = (ErrorResponse | unknown);
|
|
49253
49260
|
type ListLeadFormsData = {
|
|
@@ -49535,6 +49542,20 @@ type ListFormLeadsResponse = ({
|
|
|
49535
49542
|
hasMore?: boolean;
|
|
49536
49543
|
cursor?: (string) | null;
|
|
49537
49544
|
};
|
|
49545
|
+
meta?: {
|
|
49546
|
+
platform?: string;
|
|
49547
|
+
accountId?: string;
|
|
49548
|
+
formId?: string;
|
|
49549
|
+
/**
|
|
49550
|
+
* persisted: leads stored from the webhook and the reconcile pass. live: read from Meta because none are stored for this form yet.
|
|
49551
|
+
*/
|
|
49552
|
+
source?: 'persisted' | 'live';
|
|
49553
|
+
/**
|
|
49554
|
+
* When Zernio last read this form's leads from Meta. For persisted leads, the last reconcile pass for the Page (null before the first one). For live reads, when the cached Graph read was made.
|
|
49555
|
+
*/
|
|
49556
|
+
lastCheckedAt?: (string) | null;
|
|
49557
|
+
lastUpdated?: string;
|
|
49558
|
+
};
|
|
49538
49559
|
});
|
|
49539
49560
|
type ListFormLeadsError = (ErrorResponse);
|
|
49540
49561
|
type CreateTestLeadData = {
|
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.1238",
|
|
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.1238",
|
|
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
|
@@ -10841,7 +10841,7 @@ export const getAd = <ThrowOnError extends boolean = false>(options: OptionsLega
|
|
|
10841
10841
|
* and creative (uploads new media, creates a replacement inline creative on the same
|
|
10842
10842
|
* campaign, pauses the old one).
|
|
10843
10843
|
* - **Pinterest / X / OpenAI Ads**: status + budget only. Sending
|
|
10844
|
-
* `targeting` or `creative` returns 501 with code `
|
|
10844
|
+
* `targeting` or `creative` returns 501 with code `feature_not_available`.
|
|
10845
10845
|
* OpenAI Ads budget is the campaign's spend cap, daily or lifetime (see `budget.type` below).
|
|
10846
10846
|
* - **Reddit Ads**: status, budget, `name` (renames the ad) and targeting. `budget` goes to
|
|
10847
10847
|
* the ad's ad group, or to its campaign when the ad group spends a campaign budget, and
|
|
@@ -13058,6 +13058,8 @@ export const archiveLeadForm = <ThrowOnError extends boolean = false>(options: O
|
|
|
13058
13058
|
*
|
|
13059
13059
|
* Serves persisted leads (ingested via the leadgen webhook) when available, falling back to a live Graph read. Accepts a Facebook account or a metaads business-login account with leads_retrieval access to the form; the latter uses its system-user token without a posting parent.
|
|
13060
13060
|
*
|
|
13061
|
+
* Persisted leads arrive in real time through Meta's webhook, and a background pass re-reads every Page from Meta to catch the leads the webhook misses: every 15 minutes for Pages that received a lead in the last 7 days. `meta.lastCheckedAt` says when that pass last ran, so polling this endpoint faster than that returns nothing new; subscribe to the `lead.received` webhook instead. The live Graph read is cached for 5 minutes, and `meta.lastCheckedAt` is when it was read.
|
|
13062
|
+
*
|
|
13061
13063
|
*/
|
|
13062
13064
|
export const listFormLeads = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<ListFormLeadsData, ThrowOnError>) => {
|
|
13063
13065
|
return (options?.client ?? client).get<ListFormLeadsResponse, ListFormLeadsError, ThrowOnError>({
|
|
@@ -50081,6 +50081,13 @@ export type ListLeadsResponse = ({
|
|
|
50081
50081
|
hasMore?: boolean;
|
|
50082
50082
|
cursor?: (string) | null;
|
|
50083
50083
|
};
|
|
50084
|
+
meta?: {
|
|
50085
|
+
/**
|
|
50086
|
+
* Meta only, present when `accountId` is passed: when Zernio last re-read the Page's forms from Meta to catch leads the webhook missed. Null when no leads matched or before the first pass.
|
|
50087
|
+
*/
|
|
50088
|
+
lastCheckedAt?: (string) | null;
|
|
50089
|
+
lastUpdated?: string;
|
|
50090
|
+
};
|
|
50084
50091
|
});
|
|
50085
50092
|
|
|
50086
50093
|
export type ListLeadsError = (ErrorResponse | unknown);
|
|
@@ -50383,6 +50390,20 @@ export type ListFormLeadsResponse = ({
|
|
|
50383
50390
|
hasMore?: boolean;
|
|
50384
50391
|
cursor?: (string) | null;
|
|
50385
50392
|
};
|
|
50393
|
+
meta?: {
|
|
50394
|
+
platform?: string;
|
|
50395
|
+
accountId?: string;
|
|
50396
|
+
formId?: string;
|
|
50397
|
+
/**
|
|
50398
|
+
* persisted: leads stored from the webhook and the reconcile pass. live: read from Meta because none are stored for this form yet.
|
|
50399
|
+
*/
|
|
50400
|
+
source?: 'persisted' | 'live';
|
|
50401
|
+
/**
|
|
50402
|
+
* When Zernio last read this form's leads from Meta. For persisted leads, the last reconcile pass for the Page (null before the first one). For live reads, when the cached Graph read was made.
|
|
50403
|
+
*/
|
|
50404
|
+
lastCheckedAt?: (string) | null;
|
|
50405
|
+
lastUpdated?: string;
|
|
50406
|
+
};
|
|
50386
50407
|
});
|
|
50387
50408
|
|
|
50388
50409
|
export type ListFormLeadsError = (ErrorResponse);
|