Lead Capture API

Build and manage lead capture forms, collect viewer submissions from your publications, and export lead data as CSV.

On this page

Lead Capture API

The Lead Capture API lets you create forms that appear within your flipbook publications to collect viewer information. You can configure form fields, trigger conditions, and styling. Captured leads are stored and available for listing, searching, and CSV export.

Base URL: https://api.zenflip.io/v1/leads

Capture a Lead (Public)

Submit a lead from the publication viewer. This is a public endpoint --- no authentication is required. It is called by the embedded viewer when a reader fills out a lead capture form.

Rate limit: 10 submissions per minute per IP address.

Path Parameters

Parameter

Type

Description

pubId

string

Publication UUID

Request Body

Field

Type

Required

Description

email

string

Yes

Email address of the lead

name

string

No

Full name

company

string

No

Company or organization name

phone

string

No

Phone number

customFields

object

No

Key-value pairs for custom form fields

sourcePage

integer

No

Page number where the form was triggered

triggerType

string

No

How the form appeared: page, exit, timer, scroll

Example Request

Example Response

List Leads

Retrieve a paginated list of all captured leads for your organization.

Query Parameters

Parameter

Type

Required

Description

pubId

string

No

Filter by publication ID

page

integer

No

Page number (default: 1)

limit

integer

No

Items per page (default: 20)

search

string

No

Search by email or name

Example Request

Example Response

Export Leads as CSV

Export all leads for your organization (or a specific publication) as a CSV file.

Query Parameters

Parameter

Type

Required

Description

pubId

string

No

Filter by publication ID

Example Request

Example Response

Lead Capture Forms

Lead capture forms define the fields, trigger conditions, and styling for forms shown to viewers inside your publications.

List Forms for a Publication

Example Request

Example Response

Create a Lead Capture Form

Required role: editor or above. Required plan feature: leadCapture.

Request Body

Field

Type

Required

Description

title

string

Yes

Form title (max 200 characters)

description

string

No

Description shown above the form

fields

array

Yes

Array of field definitions (see below)

trigger

object

Yes

Trigger configuration (see below)

styling

object

No

Custom styling options

Field Definition Object

Property

Type

Description

name

string

Field identifier (used as the key in submissions)

type

string

Field type: email, text, tel, select, textarea

label

string

Display label for the field

required

boolean

Whether the field is required

options

array

Options for select fields (array of strings)

Trigger Configuration Object

Property

Type

Description

type

string

Trigger type: page, exit, timer, scroll

page

integer

Page number (for page trigger)

delay

integer

Seconds to wait (for timer trigger)

percent

integer

Scroll percentage (for scroll trigger)

Example Request

Update a Lead Capture Form

Required role: editor or above.

All fields are optional. Only include the fields you want to change.

Field

Type

Description

title

string

Form title

description

string

Form description

fields

array

Updated field definitions

trigger

object

Updated trigger configuration

styling

object

Updated styling options

isActive

boolean

Enable or disable the form

Delete a Lead Capture Form

Required role: editor or above.

Response

Get Active Forms (Public)

Retrieve only the active lead capture forms for a publication. This is a public endpoint used by the viewer to know which forms to display.

No authentication required. Returns only forms where isActive is true.

← Previous
Analytics API
Next →
Teams API