@getlatedev/node 0.2.1237 → 0.2.1239
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 +6 -0
- 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.1239",
|
|
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.1239",
|
|
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
|
@@ -4403,6 +4403,10 @@ export const acceptConversationRequest = <ThrowOnError extends boolean = false>(
|
|
|
4403
4403
|
* For iMessage, this also marks the conversation read with the contact
|
|
4404
4404
|
* (1:1 conversations only). Best-effort.
|
|
4405
4405
|
*
|
|
4406
|
+
* For Instagram (Instagram Login and Facebook Login) and Facebook Messenger,
|
|
4407
|
+
* this also sends a `mark_seen` read receipt to the contact, so they see the
|
|
4408
|
+
* conversation as seen. Best-effort: a Meta failure never fails the request.
|
|
4409
|
+
*
|
|
4406
4410
|
* This is the explicit, human-driven counterpart to `GET .../messages`,
|
|
4407
4411
|
* which is side-effect-free and does NOT mark anything read. Call this when
|
|
4408
4412
|
* a user actually views the conversation.
|
|
@@ -13058,6 +13062,8 @@ export const archiveLeadForm = <ThrowOnError extends boolean = false>(options: O
|
|
|
13058
13062
|
*
|
|
13059
13063
|
* 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
13064
|
*
|
|
13065
|
+
* 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.
|
|
13066
|
+
*
|
|
13061
13067
|
*/
|
|
13062
13068
|
export const listFormLeads = <ThrowOnError extends boolean = false>(options: OptionsLegacyParser<ListFormLeadsData, ThrowOnError>) => {
|
|
13063
13069
|
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);
|