Command Palette

Search for a command to run...

Generic Links API

API endpoints for creating and managing generic links.

Overview

Generic Links are public landing pages with email capture forms. Use the API to create, list, and manage generic links for lead generation.

Endpoints

MethodEndpointDescription
GET/api/v1/generic-linksList all generic links
GET/api/v1/generic-links/:idGet a specific generic link
POST/api/v1/generic-linksCreate a generic link
PATCH/api/v1/generic-links/:idUpdate a generic link
DELETE/api/v1/generic-links/:idDelete a generic link
GET/api/v1/generic-links/:id/submissionsList submissions

GET /api/v1/generic-links

Retrieve all generic links, optionally filtered by lead magnet.

Query Parameters

ParameterTypeDescription
lead_magnet_idstringFilter by lead magnet
pagenumberPage number (default: 1)
per_pagenumberItems per page (default: 20, max: 100)

Response

json

GET /api/v1/generic-links/:id

Retrieve a specific generic link by ID.

Path Parameters

ParameterTypeRequiredDescription
idstringYesGeneric link ID

Response

json

POST /api/v1/generic-links

Create a new generic link for a lead magnet.

Request Body

FieldTypeRequiredDescription
lead_magnet_idstringYesID of the lead magnet
slugstringNoURL slug (auto-generated if not provided)
titlestringNoLanding page headline
descriptionstringNoLanding page description
collect_namebooleanNoCollect name field (default: false)
require_verificationbooleanNoRequire email verification (default: false)
thumbnail_urlstringNoCustom thumbnail image URL

Example Request

json

Response

json

Error Responses

StatusCodeDescription
400invalid_lead_magnetLead magnet doesn't exist
400slug_takenSlug already in use
403limit_reachedGeneric link limit for plan
422validation_errorInvalid field values

PATCH /api/v1/generic-links/:id

Update an existing generic link.

Path Parameters

ParameterTypeRequiredDescription
idstringYesGeneric link ID

Request Body

All fields optional:

FieldTypeDescription
slugstringURL slug
titlestringLanding page headline
descriptionstringLanding page description
collect_namebooleanCollect name field
require_verificationbooleanRequire email verification
thumbnail_urlstringCustom thumbnail URL
activebooleanEnable/disable link

Example Request

json

Response

Returns the updated generic link object.

DELETE /api/v1/generic-links/:id

Delete a generic link. This also deletes all associated submissions.

Path Parameters

ParameterTypeRequiredDescription
idstringYesGeneric link ID

Response

json

Deleting a generic link is permanent and removes all submission data.

List Submissions

GET /api/v1/generic-links/:id/submissions

Retrieve all submissions for a generic link.

Path Parameters

ParameterTypeRequiredDescription
idstringYesGeneric link ID

Query Parameters

ParameterTypeDescription
pagenumberPage number (default: 1)
per_pagenumberItems per page (default: 50, max: 100)
sincestringFilter submissions after date (ISO 8601)
untilstringFilter submissions before date (ISO 8601)

Response

json
FieldTypeDescription
idstringUnique identifier
lead_magnet_idstringAssociated lead magnet
slugstringURL slug
urlstringFull public URL
titlestringLanding page headline
descriptionstringLanding page description
thumbnail_urlstringThumbnail image URL
collect_namebooleanWhether name is collected
require_verificationbooleanWhether email verification required
submission_countnumberTotal submissions
view_countnumberTotal landing page views
activebooleanWhether link is active
lead_magnetobjectEmbedded lead magnet (detail view)
created_atstringCreation timestamp
updated_atstringLast update timestamp

Submission Object

FieldTypeDescription
idstringUnique identifier
generic_link_idstringParent generic link
emailstringSubmitted email
namestringSubmitted name (if collected)
verifiedbooleanEmail verified
viewedbooleanContent viewed
view_countnumberTimes viewed
submitted_atstringSubmission timestamp
first_viewed_atstringFirst view timestamp
last_viewed_atstringLast view timestamp

Code Examples

javascript

Fetch Submissions (Python)

python