OverviewPlatformsAPI ReferenceResources
Lead Gen

List leads for a single form

GEThttps://zernio.com/api/v1/ads/lead-forms/{formId}/leads

Lists the leads submitted through one Meta lead form.

It serves persisted leads (ingested via the leadgen webhook) when available, falling back to a live Graph read.

PlatformsMeta

Authentication

AuthorizationBearer tokenRequired

API key authentication: send your Zernio API key in the Authorization header, prefixed with Bearer.

Path parameters

formIdstringRequired

Query parameters

accountIdstringRequired
limitintegerDefault 25
cursorstring
sinceinteger

Unix seconds.

Responses

Success· the request worked

Errors· the request failed

How it behaves

Accounts

Accepts either of these with leads_retrieval access to the form:

  • a Facebook account
  • a metaads business-login account, which uses its system-user token without a posting parent

Freshness

Persisted leads arrive in real time through Meta's webhook. 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.

GET/v1/ads/lead-forms/{formId}/leads
import Zernio from '@zernio/node';const zernio = new Zernio({ apiKey: process.env.ZERNIO_API_KEY });const { data } = await zernio.leadgen.listFormLeads({  path: {    formId: 'form_abc123',  },  query: {    accountId: 'account_abc123',  },});console.log(data);
{  "status": "string",  "leads": [    {      "id": "string",      "leadId": "string",      "status": "string",      "createdTime": "string",      "adId": "string",      "formId": "string",      "fields": {        "property1": "string",        "property2": "string"      },      "fieldData": [        {}      ],      "consents": [        {          "checkboxKey": "string",          "isChecked": true        }      ]    }  ],  "pagination": {    "hasMore": true,    "cursor": "string"  },  "meta": {    "platform": "string",    "accountId": "string",    "formId": "string",    "source": "persisted",    "lastCheckedAt": "2019-08-24T14:15:22Z",    "lastUpdated": "2019-08-24T14:15:22Z"  }}
OpenAPI specification
Was this page helpful?