Can’t turn your site traffic into sales?
Your customers abandoning their carts?
Make potential customers notice special offers.
Struggling to collect form submissions?
Let them call you directly via popups.
Having trouble growing your email list?
Choose your offer and let the game begin.
Make sure important news unmissed.
Keep visitors & customers on your site longer.
Can’t draw attention to your surveys?
Grow social media followers and likes!
HTTP Method: GET
Endpoint: /api/leads
Query Parameters:
• take (optional): The number of leads to return. Default is 50. Example: take=1
• skip (optional): The number of leads to skip. Default is 0. Example: skip=5
Headers:
• x-token (personal data > API key)
• x-campaign-id
Example Request:
GET /api/leads?take=100&skip=50 HTTP/1.1
Host: example.com
Headers:
x-token: {APIkey}
x-campaign-id: {Campaignld}
HTTP Status Code: 200
Headers:
Content-Type: application/json
Example Response:
HTTP/1.1 200 OK
{
"leads": [
{
"date": "2023-02-28T09:48:36.362Z",
"sessionId": "111e1a1b-1ca1-1111-ad1b-11111ffa1",
"accountId": 1111,
"location": {
"ip": "111.11.11.11",
"countryCode": "UK",
"country": "United Kingdom",
"region": "London",
"regionCode": "1",
"city": "London",
"latitude": "11.11111",
"longitude": "11.11111",
"timezone": "Europe/London",
"asOrganization": "John Doe's Organization",
"postalCode": "1111"
},
"url": "https://johndoe.com/?ps-preview=4948",
"page": "/",
"host": "johndoe.com",
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/110.0.0.0 Safari/537.36",
"device": "Desktop",
"resolution": "1112x1112",
"os": "Mac OS",
"browser": "Chrome",
"language": "en-US",
"referrer": "",
"type": "lead",
"campaignId": 1111,
"triggerIntegrations": true,
"meta": {
"utm_campaign": null,
"utm_source": null,
"utm_medium": null,
"utm_content": null,
"utm_term": null,
"ps-preview": "1111"
},
"formData": {
"ULLE3_email_input": "[email protected]",
"IKQMY_text_input": "123asd"
}
]
}
curl --location 'https://app.popupsmart.com/api/leads?take=2&skip=10' \ --header 'x-token: V2-1ZTPYBU1IBY1FQNHP1M11CCRDQFSU1F1CQAF1MHGQGCQQWXH1KTB11B1XBLH1BPK' \ --header 'x-campaign-id: 1111'
Notes:
• The header
should contain a valid x-token and x-campaign-id for authentication.
• The leads
field in the response contains an array of leads.
• The take
and skip
query parameters can be used to control the pagination of the results.